ultralytics 8.0.91 tracker fix and docs comments (#2343)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Laughing <61612323+Laughing-q@users.noreply.github.com>
This commit is contained in:
Glenn Jocher
2023-05-01 22:20:05 +02:00
committed by GitHub
parent 44c7c3514d
commit 3fd317edfd
65 changed files with 585 additions and 258 deletions

View File

@ -39,8 +39,7 @@ def on_predict_start(predictor, persist=False):
def on_predict_postprocess_end(predictor):
"""Postprocess detected boxes and update with object tracking."""
bs = predictor.dataset.bs
im0s = predictor.batch[2]
im0s = im0s if isinstance(im0s, list) else [im0s]
im0s = predictor.batch[1]
for i in range(bs):
det = predictor.results[i].boxes.cpu().numpy()
if len(det) == 0: