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 missing uncertainty bug #67

Merged
merged 2 commits into from
Mar 4, 2024
Merged

Fix missing uncertainty bug #67

merged 2 commits into from
Mar 4, 2024

Conversation

robbibt
Copy link
Member

@robbibt robbibt commented Mar 4, 2024

We encountered missing values in our elevation uncertainty layers, despite there being meant to be a 1:1 match between uncertainty and elevation:
image

This turned out to occur in pixels where the modelled elevation value sucessfully split observations perfectly, resulting in no misclassified observations. Because you can't calculate the variance of zero observations, we were getting back nodata for these pixels.

image

This PR addresses this issue by adding a new min_misclassified param: if a pixel has less than n misclassified observations, it is assigned an uncertainty value of 0 metres. This helps fix both this issue, and a related issue where we could sometimes get extremely high uncertainty values caused by trying to calculate the variance of a very small set of misclassified points.

Copy link

github-actions bot commented Mar 4, 2024

For full integration test results, refer to the Tests directory README.

@robbibt robbibt merged commit afb94dd into main Mar 4, 2024
@robbibt robbibt deleted the fix_uncertainty branch March 4, 2024 04:43
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.

2 participants