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 nan skipping in patches method #229

Merged
merged 10 commits into from
Nov 8, 2021

Conversation

rhugonnet
Copy link
Contributor

@rhugonnet rhugonnet commented Nov 5, 2021

Fixes a bug in the patches method where a patch was skipped if the central pixel was NaN, a behavior that discarded lots of valid patches within the perc_valid range.
I think this line was originally introduce to improve processing time for raster with a lot of no data, but I didn't see any difference when generating the docs, so seems all good. I used it on a Raster with quite a bit of NaNs, but maybe not as much as those where there is almost no stable terrain available...
I think we discussed this at one point @erikmannerfelt? Do you remember the ouput?

@rhugonnet rhugonnet changed the title Fix nan skipping in patch methods Fix nan skipping in patches method Nov 6, 2021
Copy link
Contributor

@erikmannerfelt erikmannerfelt left a comment

Choose a reason for hiding this comment

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

Seems good! I don't remember this issue, but this line definitely seems extraneous.

@rhugonnet rhugonnet merged commit 8240dc2 into GlacioHack:main Nov 8, 2021
@rhugonnet rhugonnet deleted the fix_patch_methods branch November 8, 2021 10:41
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