Edvin Behdadijd commited on
Commit
dc0055b
·
verified ·
1 Parent(s): f42c4c8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -37,7 +37,7 @@ def detect_objects(image):
37
 
38
  # Put the class name above the bounding box
39
  class_name = model.model.names[int(class_id)]
40
- cv2.putText(image, f'{class_name} {score:.2f}', (x1, y1 - 10), cv2.FONT_HERSHEY_SIMPLEX, 4, color, 1)
41
 
42
  # Convert back to PIL image
43
  return Image.fromarray(image)
 
37
 
38
  # Put the class name above the bounding box
39
  class_name = model.model.names[int(class_id)]
40
+ cv2.putText(image, f'{class_name} {score:.2f}', (x1, y1 - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.4, color, 1)
41
 
42
  # Convert back to PIL image
43
  return Image.fromarray(image)