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
This PR adds unit tests for ByteTrack. They do not all pass because of a bug introduced in the last PR, but I have tested them
on the current release of supervision and they pass correctly. They also pass after making the 1 line bug fix.
I chose the test cases to be the ones that I have encountered to be edge cases so far, as well as adding edge cases that I can imagine being problematic.
Type of change
How has this change been tested, please provide a testcase or example of how you tested the change?
I tested this change, by first running these pytests on the 0.18.0 release version of supervision to ensure they all pass. I then used them to validate my other changes to ByteTrack to ensure the changes still function correctly. I also tested the current develop branch, and 1 test failed due to a small bug in how update_with_detections handles no valid tracked detections. (added here)
Any specific deployment considerations
Need to make sure they tests will autorun on PR.
Docs