luanhailiang 2023-09-21 21:54:35 +08:00
parent 209807058a
commit 7087e87559
1 changed files with 1 additions and 1 deletions

2
app.py
View File

@ -81,7 +81,7 @@ def worker(id,source,region=None,stream=False):
detections = sv.Detections.from_yolov8(result) detections = sv.Detections.from_yolov8(result)
if result.boxes.id is not None: if result.boxes.id is not None:
detections.tracker_id = result.boxes.id.cpu().numpy().astype(int) detections.tracker_id = result.boxes.id.cpu().numpy().astype(int)
detections = detections[(detections.tracker_id is not None)] detections = detections[(detections.tracker_id != None)]
count += 1 count += 1
names = {} names = {}