Search before asking
Bug
Rather surprising behavior instead of a bug, but the init-parameters of ByteTrack could be optimized:
We pass frame_rate (default 30) and lost_track_buffer (default 30) to compute the max_time_lost:
self.max_time_lost = int(frame_rate / 30.0 * lost_track_buffer)
To adapt the value, we can change both values (which are only used in this line!), but need to know that there is a hardcoded 30 in the computation.
Also the doc for lost_track_buffer is
lost_track_buffer (int): Number of frames to buffer when a track is lost.
Which is inconsistent with the implementation.
Proposal:
just remove the frame_rate-parameter and set
self.max_time_lost = lost_track_buffer
just like
self.minimum_consecutive_frames = minimum_consecutive_frames
Environment
- Supervision: develop
- Python: ALL
- OS: ALL
Minimal Reproducible Example
No response
Are you willing to submit a PR?
Search before asking
Bug
Rather surprising behavior instead of a bug, but the init-parameters of ByteTrack could be optimized:
supervision/src/supervision/tracker/byte_tracker/core.py
Line 16 in 48035c1
We pass frame_rate (default 30) and lost_track_buffer (default 30) to compute the max_time_lost:
self.max_time_lost = int(frame_rate / 30.0 * lost_track_buffer)To adapt the value, we can change both values (which are only used in this line!), but need to know that there is a hardcoded 30 in the computation.
Also the doc for lost_track_buffer is
Which is inconsistent with the implementation.
Proposal:
just remove the frame_rate-parameter and set
self.max_time_lost = lost_track_bufferjust like
self.minimum_consecutive_frames = minimum_consecutive_framesEnvironment
Minimal Reproducible Example
No response
Are you willing to submit a PR?