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

Refactor mpop.projector and add a script for pre-calculating projection parameters #45

Merged
merged 5 commits into from Mar 16, 2017

Conversation

pnuu
Copy link
Member

@pnuu pnuu commented Feb 26, 2017

This pull request refactors mpop.projector so that more of the internals are usable from the outside. This was done for the utils/precompute_projection.py that can be used to pre-calculate projection LUTs for resampling done between areas defined in areas.def. With large areas the calculation of the LUT can take huge amount of memory, so now the calculations can be done outside the operational environment.

Also, unit tests were added for all the refactored functions.

- test calc_nearest_params()
- test calc_quick_params()
- test calc_bilinear_params()
- test calc_ewa_params()
- test get_precompute_cache_fname()
- test get_area_and_id()
@coveralls
Copy link

Coverage Status

Coverage increased (+0.4%) to 12.625% when pulling 4d098a4 on feature-preprecompute into 98b6662 on pre-master.

@mraspaud mraspaud merged commit 10e5be8 into pre-master Mar 16, 2017
@mraspaud mraspaud deleted the feature-preprecompute branch October 18, 2017 08:07
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

3 participants