Spaces:
Runtime error
Runtime error
testmail-gmail
commited on
Commit
·
c74a17f
1
Parent(s):
212688f
Update app.py
Browse files
app.py
CHANGED
@@ -128,6 +128,9 @@ def detect_Custom(img,boundedImage):
|
|
128 |
if save_img or view_img:
|
129 |
label = f'{names[int(cls)]} {conf:.2f}'
|
130 |
plot_one_box(xyxy, im0, label=label, color=colors[int(cls)], line_thickness=3)
|
|
|
|
|
|
|
131 |
if view_img:
|
132 |
cv2.imshow(str(p), im0)
|
133 |
cv2.waitKey(1)
|
|
|
128 |
if save_img or view_img:
|
129 |
label = f'{names[int(cls)]} {conf:.2f}'
|
130 |
plot_one_box(xyxy, im0, label=label, color=colors[int(cls)], line_thickness=3)
|
131 |
+
H, W = im0.shape[:2]
|
132 |
+
box_voc = pbx.convert_bbox(xyxy, from_type="yolo", to_type="voc", image_size=(W,H))
|
133 |
+
print(box_voc)
|
134 |
if view_img:
|
135 |
cv2.imshow(str(p), im0)
|
136 |
cv2.waitKey(1)
|