-
Notifications
You must be signed in to change notification settings - Fork 102
📝 Add Examples to utils/metrics.py
#921
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
Conversation
for more information, see https://pre-commit.ci
utils/metrics.py
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #921 +/- ##
===========================================
- Coverage 99.70% 99.70% -0.01%
===========================================
Files 71 71
Lines 8848 8847 -1
Branches 1154 1154
===========================================
- Hits 8822 8821 -1
Misses 23 23
Partials 3 3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
- Remove redundant line breaks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds example usage code to the docstrings of the functions in utils/metrics.py to better illustrate how to use them.
- Added examples for pair_coordinates
- Added examples for f1_detection
- Added examples for dice
| Indices of unpaired points in set B. | ||
| Examples: |
Copilot
AI
May 9, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider including comments on expected output for the pair_coordinates examples to help users validate the function's behavior.
| """Calculate the F1-score for predicted set of coordinates.""" | ||
| """Calculate the F1-score for predicted set of coordinates. | ||
| Examples: |
Copilot
AI
May 9, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider adding a brief note on the expected f1_score value or output format for the f1_detection examples for clarity.
| :class:`float`: | ||
| An estimate of Sørensen-Dice coefficient value. | ||
| Examples: |
Copilot
AI
May 9, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider including expected output details in the dice examples to assist users in verifying the Sørensen-Dice coefficient results.
Add examples to utils/metrics.py.