Spaces:
Runtime error
Runtime error
paoyingheng
commited on
Commit
•
1e74cc3
1
Parent(s):
adb423a
updates
Browse files
app.py
CHANGED
@@ -16,9 +16,7 @@ def para_func(image: gr.Image = None, image_size: gr.Slider = 640, conf_threshol
|
|
16 |
box = results[0].boxes
|
17 |
print("Object type:", box.cls)
|
18 |
print("Coordinates:", box.xyxy)
|
19 |
-
|
20 |
-
print("Probability:", f'{probability_percentage:.1f}%')
|
21 |
-
|
22 |
|
23 |
# Render the output image with bounding boxes around detected objects
|
24 |
render = render_result(model=model, image=image, result=results[0])
|
|
|
16 |
box = results[0].boxes
|
17 |
print("Object type:", box.cls)
|
18 |
print("Coordinates:", box.xyxy)
|
19 |
+
print("Probability:", box.conf)
|
|
|
|
|
20 |
|
21 |
# Render the output image with bounding boxes around detected objects
|
22 |
render = render_result(model=model, image=image, result=results[0])
|