Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion motpy/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def __init__(
self.feature = feature

def __repr__(self):
return f'Detection(box={self.box}, score={self.score:.5f}, class_id={self.class_id}, feature={self.feature})'
return f'Detection(box={self.box}, score={f"{self.score:.5f}" if self.score else None}, class_id={self.class_id}, feature={self.feature})'


""" utils """
Expand Down
2 changes: 1 addition & 1 deletion motpy/tracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ def active_tracks(self,
if cond1 and cond2 and cond3:
tracks.append(Track(id=tracker.id, box=tracker.box(), score=tracker.score, class_id=tracker.class_id))

logger.debug('active/all tracks: %d/%d' % (len(self.trackers), len(tracks)))
logger.debug(f'active/all tracks: {len(tracks)}/{len(self.trackers)}')
return tracks

def cleanup_trackers(self) -> None:
Expand Down