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

Added predefined distance functions for typical cases #135

Merged
merged 1 commit into from Aug 16, 2022

Conversation

javiber
Copy link
Collaborator

@javiber javiber commented Jul 29, 2022

  • added predefined functions
  • allowed the Tracker to receive a distance by name
  • renamed some of the distances to be more precise. For instance, what we were caling euclidean is actually frobenius
  • small refactor to the tracker, separating the calculations of distances to a separate instance method. The motivation is that this will accommodate vectorized implementations easier by overwriting this new method.
  • updated most of the demos, unifying some of the implementation implementations to ran Alphapose so I left it unchanged. motmetrics4norfair demo was also left unchanged because it uses a pretty custom distance, we can discuss if we want to incorporate it as another distance.

@javiber javiber force-pushed the predefined_distances branch 3 times, most recently from 6aeaa28 to 15164e9 Compare August 3, 2022 15:19
@javiber javiber marked this pull request as ready for review August 3, 2022 18:36
demos/profiling/src/utils.py Outdated Show resolved Hide resolved
demos/profiling/src/utils.py Outdated Show resolved Hide resolved
@javiber javiber force-pushed the predefined_distances branch 2 times, most recently from 7d0b95a to 7ee2857 Compare August 8, 2022 15:11
# areas - the interesection area
iou = inter_area / float(box_a_area + box_b_area - inter_area)
# Since 0 <= IoU <= 1, we define 1/IoU as a distance.
# Distance values will be in [1, inf)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Distance values will be in [0, 1] right? Since you did 1-IoU instead of 1/IoU

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you're right! this is from when I was doing 1/iou

@aguscas aguscas self-assigned this Aug 9, 2022
@aguscas aguscas merged commit ae2d95e into master Aug 16, 2022
@aguscas aguscas deleted the predefined_distances branch August 16, 2022 16:55
javiber pushed a commit that referenced this pull request Sep 13, 2022
javiber pushed a commit that referenced this pull request Sep 13, 2022
@dekked dekked changed the title Added predefined distances Added predefined distance functions for typical cases Sep 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants