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

Request: Add optional parameters for rounding and capping #88

Closed
interob opened this issue Jul 7, 2020 · 2 comments · Fixed by #104
Closed

Request: Add optional parameters for rounding and capping #88

interob opened this issue Jul 7, 2020 · 2 comments · Fixed by #104
Labels
enhancement New feature or request suggestion

Comments

@interob
Copy link
Collaborator

interob commented Jul 7, 2020

Request: introduce parameters for rounding and capping upon grid export (modis/window.py), Explained in more detail below:

Rounding: as the value array is retrieved from HDF(s) here...

value_array = self.get_array(dataset, ix, self.dt_gdal[1])

... next it would be to round values to an exponent of 10 (e.g. 2 => 10^2 = 100; rounding 10466 would become 10500)

Capping: all values in the retrieved array that are below or above the provided minimum or maximum respectively are set to nodata

@interob
Copy link
Collaborator Author

interob commented Jul 7, 2020

Remark: let's stay away from scaling by applying some factor (1/10000 typically) as this would require a change of output datatype

@valpesendorfer valpesendorfer added enhancement New feature or request suggestion labels Jul 21, 2020
@valpesendorfer valpesendorfer linked a pull request Aug 14, 2020 that will close this issue
@valpesendorfer
Copy link
Member

implemented with #104

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request suggestion
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants