-
Notifications
You must be signed in to change notification settings - Fork 14
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
Rework python-cmethods: replace the CMethods
class by the new adjust
function
#48
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #48 +/- ##
==========================================
- Coverage 98.23% 98.08% -0.15%
==========================================
Files 1 7 +6
Lines 283 261 -22
==========================================
- Hits 278 256 -22
Misses 5 5
Flags with carried forward coverage won't be shown. Click here to find out more.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job with this! I just focused mainly on the apply ufunc implementation. Just a few comments here. It worked on my example data over 1-4D, and very quickly with dask.
CMethods
class with the new adjust
function
CMethods
class with the new adjust
functionCMethods
class by the new adjust
function
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alles gute bei mir! Well done.
To improve the performance of applied bias corrections, the complete CMethods class was removed. Individual techniques can't be executed directly by calling their function anymore. Also the
adjust_3d
function was removed.Instead, a new function named
adjust
was added which acts like the oldadjust_3d
function but can handle single and multidimensional data sets and will return the bias corrected data as xarray.Dataset. By using xarrays ufunc function instead of iterating over entries per dimension, the execution time could be reduced drastically.linear_scaling
,variance_scaling
and so on are now internal functions and should not be called directly, they are not part of the documentation anymore. Instead, a new section in the documentation was added - which describes the implemented methods and provides some examples.More changes:
Follow-up: Create issue for improving the DQM function (#48 (comment)).