modify byte.trackerupdate, add list first_finded
This commit is contained in:
Binary file not shown.
@ -214,6 +214,8 @@ class BYTETracker:
|
||||
refind_stracks = []
|
||||
lost_stracks = []
|
||||
removed_stracks = []
|
||||
|
||||
first_finded = []
|
||||
|
||||
scores = results.conf
|
||||
cls = results.cls
|
||||
@ -328,6 +330,9 @@ class BYTETracker:
|
||||
continue
|
||||
track.activate(self.kalman_filter, self.frame_id)
|
||||
activated_stracks.append(track)
|
||||
|
||||
first_finded.append(track)
|
||||
|
||||
# Step 5: Update state
|
||||
for track in self.lost_stracks:
|
||||
if self.frame_id - track.end_frame > self.max_time_lost:
|
||||
@ -359,7 +364,7 @@ class BYTETracker:
|
||||
for x in self.tracked_stracks if x.is_activated]
|
||||
|
||||
output2 = [x.tlwh_to_tlbr(x._tlwh).tolist() + [x.track_id, x.score, x.cls, x.frame_id, x.idx]
|
||||
for x in activated_stracks if x.first_find]
|
||||
for x in first_finded if x.first_find]
|
||||
|
||||
output = np.asarray(output1+output2, dtype=np.float32)
|
||||
|
||||
|
Reference in New Issue
Block a user