-
Notifications
You must be signed in to change notification settings - Fork 225
Bytetrack adjustments #158
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
AlexBodner
wants to merge
66
commits into
feat/core/bytetrack
Choose a base branch
from
feat/core/bytetrack-fix
base: feat/core/bytetrack
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
updates: - [github.com/astral-sh/ruff-pre-commit: v0.11.9 → v0.11.10](astral-sh/ruff-pre-commit@v0.11.9...v0.11.10)
chore(pre_commit): ⬆ pre_commit autoupdate
Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 6.0.1 to 6.1.0. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](astral-sh/setup-uv@6b9c606...f0ec1fc) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-version: 6.1.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
…stral-sh/setup-uv-6.1.0 ⬆️ Bump astral-sh/setup-uv from 6.0.1 to 6.1.0
updates: - [github.com/astral-sh/ruff-pre-commit: v0.11.10 → v0.11.11](astral-sh/ruff-pre-commit@v0.11.10...v0.11.11)
--- updated-dependencies: - dependency-name: aiohttp dependency-version: 3.12.2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
chore(pre_commit): ⬆ pre_commit autoupdate
⬆️ Bump aiohttp from 3.11.18 to 3.12.2
--- updated-dependencies: - dependency-name: aiohttp dependency-version: 3.12.4 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump aiohttp from 3.12.2 to 3.12.4
--- updated-dependencies: - dependency-name: aiohttp dependency-version: 3.12.6 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump aiohttp from 3.12.4 to 3.12.6
updates: - [github.com/astral-sh/ruff-pre-commit: v0.11.11 → v0.11.12](astral-sh/ruff-pre-commit@v0.11.11...v0.11.12) - [github.com/pre-commit/mirrors-mypy: v1.15.0 → v1.16.0](pre-commit/mirrors-mypy@v1.15.0...v1.16.0)
chore(pre_commit): ⬆ pre_commit autoupdate
Bumps [torchvision](https://github.com/pytorch/vision) from 0.21.0+cu124 to 0.22.0. - [Release notes](https://github.com/pytorch/vision/releases) - [Commits](https://github.com/pytorch/vision/commits/v0.22.0) --- updated-dependencies: - dependency-name: torchvision dependency-version: 0.22.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [wandb](https://github.com/wandb/wandb) from 0.19.11 to 0.20.0. - [Release notes](https://github.com/wandb/wandb/releases) - [Changelog](https://github.com/wandb/wandb/blob/main/CHANGELOG.md) - [Commits](wandb/wandb@v0.19.11...v0.20.0) --- updated-dependencies: - dependency-name: wandb dependency-version: 0.20.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump wandb from 0.19.11 to 0.20.0
….22.0 ⬆️ Bump torchvision from 0.21.0+cu124 to 0.22.0
Bumps [torch](https://github.com/pytorch/pytorch) from 2.6.0+cu124 to 2.7.0. - [Release notes](https://github.com/pytorch/pytorch/releases) - [Changelog](https://github.com/pytorch/pytorch/blob/main/RELEASE.md) - [Commits](https://github.com/pytorch/pytorch/commits/v2.7.0) --- updated-dependencies: - dependency-name: torch dependency-version: 2.7.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump torch from 2.6.0+cu124 to 2.7.0
Bumps [torchvision](https://github.com/pytorch/vision) from 0.21.0+cu124 to 0.22.1. - [Release notes](https://github.com/pytorch/vision/releases) - [Commits](https://github.com/pytorch/vision/commits/v0.22.1) --- updated-dependencies: - dependency-name: torchvision dependency-version: 0.22.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
updates: - [github.com/astral-sh/ruff-pre-commit: v0.11.12 → v0.11.13](astral-sh/ruff-pre-commit@v0.11.12...v0.11.13)
chore(pre_commit): ⬆ pre_commit autoupdate
Bumps [wandb](https://github.com/wandb/wandb) from 0.20.0 to 0.20.1. - [Release notes](https://github.com/wandb/wandb/releases) - [Changelog](https://github.com/wandb/wandb/blob/main/CHANGELOG.md) - [Commits](wandb/wandb@v0.20.0...v0.20.1) --- updated-dependencies: - dependency-name: wandb dependency-version: 0.20.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
--- updated-dependencies: - dependency-name: aiohttp dependency-version: 3.12.13 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump aiohttp from 3.12.6 to 3.12.13
⬆️ Bump wandb from 0.20.0 to 0.20.1
Bumps [torch](https://github.com/pytorch/pytorch) from 2.6.0+cu124 to 2.7.1. - [Release notes](https://github.com/pytorch/pytorch/releases) - [Changelog](https://github.com/pytorch/pytorch/blob/main/RELEASE.md) - [Commits](https://github.com/pytorch/pytorch/commits/v2.7.1) --- updated-dependencies: - dependency-name: torch dependency-version: 2.7.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
….22.1 ⬆️ Bump torchvision from 0.21.0+cu124 to 0.22.1
⬆️ Bump torch from 2.6.0+cu124 to 2.7.1
updates: - [github.com/PyCQA/bandit: 1.8.4 → 1.8.5](PyCQA/bandit@1.8.4...1.8.5) - [github.com/astral-sh/ruff-pre-commit: v0.11.13 → v0.12.0](astral-sh/ruff-pre-commit@v0.11.13...v0.12.0) - [github.com/pre-commit/mirrors-mypy: v1.16.0 → v1.16.1](pre-commit/mirrors-mypy@v1.16.0...v1.16.1)
chore(pre_commit): ⬆ pre_commit autoupdate
Bumps [timm](https://github.com/huggingface/pytorch-image-models) from 1.0.15 to 1.0.16. - [Release notes](https://github.com/huggingface/pytorch-image-models/releases) - [Commits](huggingface/pytorch-image-models@v1.0.15...v1.0.16) --- updated-dependencies: - dependency-name: timm dependency-version: 1.0.16 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 6.3.0 to 6.3.1. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](astral-sh/setup-uv@445689e...bd01e18) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-version: 6.3.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
updates: - [github.com/astral-sh/ruff-pre-commit: v0.12.0 → v0.12.1](astral-sh/ruff-pre-commit@v0.12.0...v0.12.1)
chore(pre_commit): ⬆ pre_commit autoupdate
Bumps [wandb](https://github.com/wandb/wandb) from 0.20.1 to 0.21.0. - [Release notes](https://github.com/wandb/wandb/releases) - [Changelog](https://github.com/wandb/wandb/blob/main/CHANGELOG.md) - [Commits](wandb/wandb@v0.20.1...v0.21.0) --- updated-dependencies: - dependency-name: wandb dependency-version: 0.21.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
⬆️ Bump wandb from 0.20.1 to 0.21.0
⬆️ Bump timm from 1.0.15 to 1.0.16
…stral-sh/setup-uv-6.3.1 ⬆️ Bump astral-sh/setup-uv from 6.3.0 to 6.3.1
updates: - [github.com/PyCQA/bandit: 1.8.5 → 1.8.6](PyCQA/bandit@1.8.5...1.8.6) - [github.com/astral-sh/ruff-pre-commit: v0.12.1 → v0.12.2](astral-sh/ruff-pre-commit@v0.12.1...v0.12.2)
chore(pre_commit): ⬆ pre_commit autoupdate
Update theme
Use same docs stylesheet as supervision
Bumps [supervision](https://github.com/roboflow/supervision) from 0.26.0rc7 to 0.27.0rc0. - [Release notes](https://github.com/roboflow/supervision/releases) - [Changelog](https://github.com/roboflow/supervision/blob/develop/docs/changelog.md) - [Commits](roboflow/supervision@0.26.0rc7...0.27.0rc0) --- updated-dependencies: - dependency-name: supervision dependency-version: 0.27.0rc0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
…0.27.0rc0 ⬆️ Bump supervision from 0.26.0rc7 to 0.27.0rc0
…track style of matching, added score fusing
… original bytetrack, making the assignment of those higher than cost limit less attractive and then having an additional check just in case
… original bytetrack, making the assignment of those higher than cost limit less attractive and then having an additional check just in case and pre commit fixed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Made the corrections pointed out by Tomasz, which are:
Default parameters now meet original bytetrack defaults
RE-ID is now default as None.
added additional parameters that were in original bytetrack and modified names (hardcoded there), which are:
Modified: minimum_iou_threshold-> minimum_iou_threshold_high_conf, high_prob_boxes_threshold-> high_conf_boxes_threshold
added: minimum_iou_threshold_low_conf, minimum_iou_threshold_unconfirmed (these 2 basically now give the chance to the user of having different cost limits to each different association step), low_conf_boxes_lower_bound (the minimum value we will use to consider low confidence boxes, hardcoded to 0.1 in original)
Fixed how we use the minimum_iou_threshold in each association step. Now that is not only the limit, but we first modify the IoU matrix to not match those with higher lower IoU than the limit, imitating what the original does with the lap library, but building a similar solution around scipy linear_sum_assignment. This can be found in trackers/utils/bytetrack_utils.py
Added score fusion to IoU based association, which weights IoU by object confidence. Can also be found in trackers/utils/bytetrack_utils.py
Now in association step we internally minimize, which matches the implementation of the original bytetrack (just to avoid confussions, same behaviour)
Renamed trackers list to tracks
Changed behaviour with uncofirmed tracks to match the original implementation. We now put unmatched high confidence detections in an unconfirmed list, which is then matched in t+1 with the remaining high confidence detections, if there is a match we then add them to the tracks list.
Also merged main into this branch in order to fix the supervision version problem with 'box_iou_batch' import.
Type of change
How has this change been tested, please provide a testcase or example of how you tested the change?
Been testing it with an additional notebook that is not pushed. Have been viewing if results are ok and some prints to see if values were as expected. We still need to add a proper test section for trackers.
Can also be run in https://colab.research.google.com/drive/1nLNHT-MN03wuuzVOZAI934vy_-KucqPm?usp=sharing
Evaluation of results still doesnt match with ByteTrack metrics from McByte paper, but metrics in this version are overall LOWER than the ones in the first PR.
Docs