Skip to content
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

fix Detections.get_data_item() bug (#1061) #1062

Merged
merged 3 commits into from
Mar 28, 2024

Conversation

rolson24
Copy link
Contributor

Description

When I tried to use boolean array indexing to get specific detections from a Detections object, the data field sometimes returned the wrong values (everything is the second value) and sometimes it just didn't work. (See issue #1061)

This is an issue I ran into while trying to simplify ByteTrack.update_with_detections(). Boolean indexing is a feature that is commonly used in general and it would be good to ensure Detections works the same way np.arrays and lists work.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How has this change been tested, please provide a testcase or example of how you tested the change?

I tested this with the same test cases from my bug report. Colab notebook

Any specific deployment considerations

For example, documentation changes, usability, usage/costs, secrets, etc.

Docs

  • Docs updated? What were the changes:

@SkalskiP SkalskiP added bug Something isn't working api:detection labels Mar 28, 2024
@SkalskiP
Copy link
Collaborator

Hi @rolson24 👋🏻 Thanks a lot for identifying the bug and preparing the fix. I've tested it; I'll add some unit tests as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api:detection bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants