-
Notifications
You must be signed in to change notification settings - Fork 53
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
Bug fix: Assure that feature dataframe indices are unique #187
Bug fix: Assure that feature dataframe indices are unique #187
Conversation
Codecov ReportBase: 35.06% // Head: 35.68% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## RC_v1.4.0 #187 +/- ##
=============================================
+ Coverage 35.06% 35.68% +0.61%
=============================================
Files 10 10
Lines 2099 2099
=============================================
+ Hits 736 749 +13
+ Misses 1363 1350 -13
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
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.
Great work and glad that we can quickly address #184!
) | ||
def test_filter_min_distance(test_threshs, min_distance, dxy): | ||
""" | ||
Tests ```tobac.feature_detection.filter_min_distance |
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.
needs closing ```
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.
Good job @JuliaKukulies ! Nothing to complain about in this quick bug fix and great that the code coverage is increased at the same time!
Thanks for the quick review! I will merge after #186 has been merged |
The feature detection does currently not work when
min_distance
is not 0. An exception is raised infilter_min_distance()
, because the input feature dataframe for this function can contain index values that are double-defined as a consequence of concatenating dataframes infeature_detection_multithreshold_timestep()
. This PR solves #184 by assuring that the feature dataframe that is created infeature_detection_multithreshold_timestep()
gets unique indices.I also added a test for
filter_min_distance()
to test if features are removed as expected within a specified minimum distance and I removed redundant imports fromtest_feature_detection.py
.