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

classify.binary: handle NaNs and infinite values #763

Merged
merged 5 commits into from
Feb 16, 2023

Conversation

thuydotm
Copy link
Contributor

@thuydotm thuydotm commented Jan 19, 2023

Fixes #757

To be consistent with all other tools in classify module, this PR changes the way classify.binary() treats NaNs and infinite values. It now considers those values as outliers and classify them as NaNs instead of 0s as of previously.

  • numpy case
  • cupy case

@thuydotm thuydotm added the WIP Work in progress label Jan 19, 2023
@codecov-commenter
Copy link

codecov-commenter commented Jan 19, 2023

Codecov Report

Base: 79.90% // Head: 79.94% // Increases project coverage by +0.03% 🎉

Coverage data is based on head (cf3627e) compared to base (e47c278).
Patch coverage: 66.66% of modified lines in pull request are covered.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #763      +/-   ##
==========================================
+ Coverage   79.90%   79.94%   +0.03%     
==========================================
  Files          19       19              
  Lines        4175     4178       +3     
==========================================
+ Hits         3336     3340       +4     
+ Misses        839      838       -1     
Impacted Files Coverage Δ
xrspatial/classify.py 78.67% <66.66%> (+0.23%) ⬆️
xrspatial/utils.py 63.01% <0.00%> (-1.37%) ⬇️
xrspatial/proximity.py 97.99% <0.00%> (+1.20%) ⬆️

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.
📢 Do you have feedback about the report comment? Let us know in this issue.

@thuydotm thuydotm added ready to merge PR is ready to merge and removed WIP Work in progress labels Jan 30, 2023
Copy link
Contributor

@brendancol brendancol left a comment

Choose a reason for hiding this comment

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

Hey @thuydotm this LGTM

@brendancol brendancol merged commit b0c87a9 into master Feb 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready to merge PR is ready to merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

classify.binary(): handle NaN values
3 participants