linhcuem commited on
Commit
5df42c4
1 Parent(s): df84a49

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -60,7 +60,7 @@ def yolov8_img_inference(
60
  object_counts = {x: 0 for x in names}
61
  for r in results:
62
  for c in r.boxes.cls:
63
- c = int(c)
64
  if c in names:
65
  object_counts[c] += 1
66
  elif c not in names:
 
60
  object_counts = {x: 0 for x in names}
61
  for r in results:
62
  for c in r.boxes.cls:
63
+ c = c.add(names[int(c)])
64
  if c in names:
65
  object_counts[c] += 1
66
  elif c not in names: