Update app.py
Browse files
app.py
CHANGED
|
@@ -66,7 +66,7 @@ class ImageStoryteller:
|
|
| 66 |
if boxes is not None:
|
| 67 |
for box in boxes:
|
| 68 |
confidence = box.conf.item()
|
| 69 |
-
if confidence > 0.
|
| 70 |
class_id = int(box.cls.item())
|
| 71 |
class_name = self.yolo_model.names[class_id]
|
| 72 |
bbox = box.xyxy[0].tolist()
|
|
|
|
| 66 |
if boxes is not None:
|
| 67 |
for box in boxes:
|
| 68 |
confidence = box.conf.item()
|
| 69 |
+
if confidence > 0.25: # Confidence threshold
|
| 70 |
class_id = int(box.cls.item())
|
| 71 |
class_name = self.yolo_model.names[class_id]
|
| 72 |
bbox = box.xyxy[0].tolist()
|