From b590ce3dcee69e9dc739e89b683db0ac62834f92 Mon Sep 17 00:00:00 2001 From: "mikel.brostrom" Date: Tue, 22 Aug 2023 13:10:55 +0200 Subject: [PATCH] fix per class --- boxmot/trackers/hybridsort/hybridsort.py | 2 +- boxmot/utils/__init__.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/boxmot/trackers/hybridsort/hybridsort.py b/boxmot/trackers/hybridsort/hybridsort.py index 8938e77d8e..216d0c18e5 100644 --- a/boxmot/trackers/hybridsort/hybridsort.py +++ b/boxmot/trackers/hybridsort/hybridsort.py @@ -340,7 +340,7 @@ def __init__(self, reid_weights, device, half, det_thresh, max_age=30, min_hits= self.min_hits = min_hits self.iou_threshold = iou_threshold self.trackers = [] - self.per_class = True, + self.per_class = True self.frame_count = 0 self.det_thresh = det_thresh self.delta_t = delta_t diff --git a/boxmot/utils/__init__.py b/boxmot/utils/__init__.py index ee52def0a0..8ada8f6771 100644 --- a/boxmot/utils/__init__.py +++ b/boxmot/utils/__init__.py @@ -30,7 +30,7 @@ def wrapper(*args, **kwargs): im = modified_args[1] # input one class of detections at a time in order to not mix them up - if instance.per_class[0] is True and dets.size != 0: + if instance.per_class is True and dets.size != 0: dets_dict = { class_id: np.array([det for det in dets if det[5] == class_id]) for class_id in set(det[5] for det in dets)