* VideoInfo.fps returns float instead of int Truncating the raw CAP_PROP_FPS value with int() causes timing drift for non-integer frame rates (23.976, 29.97, 59.94). Over a long video this accumulates into noticeable sync errors — e.g. 23 vs 23.976 drifts ~1s per minute of footage. Changes: - VideoInfo.fps type annotation: int -> float - from_video_path: int(video.get(CAP_PROP_FPS)) -> float(...) - ByteTrack.frame_rate type annotation: int -> float (already converts to int internally via max_time_lost = int(frame_rate / 30.0 * buffer)) - Tests: assert fps is float, add float_fps_video_path fixture at 23.976 * fix: update examples to cast float fps to int where required * fix: wrap long docstring line in FPSBasedTimer (ruff E501) * test: remove unused float_fps_video_path fixture --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> Co-authored-by: Jirka Borovec <6035284+Borda@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| assets | ||
| classification | ||
| datasets | ||
| detection | ||
| how_to | ||
| javascripts | ||
| keypoint | ||
| metrics | ||
| notebooks | ||
| stylesheets | ||
| theme | ||
| utils | ||
| CNAME | ||
| assets.md | ||
| changelog.md | ||
| code_of_conduct.md | ||
| contributing.md | ||
| cookbooks.md | ||
| deprecated.md | ||
| index.md | ||
| license.md | ||
| trackers.md | ||