-
Notifications
You must be signed in to change notification settings - Fork 8
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
floor and ceiling for DTR #163
Conversation
…orrection service with the ceiling functionality and tests
So we can keep track of it, can someone list out the downscaleCMIP6 issues this is related to? This will create links and it will be easier to keep track of what needs to be rerun. I see ClimateImpactLab/downscaleCMIP6#476. What else? Edit: |
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.
@emileten I think this looks good. I have two quick comments/suggestions on expanding documentation. Aside from these, I think we can merge this and take things for a run. Thanks!
I took a look at this with a programmer's eye. @dgergel, I'd appreciate it if you could review this and double-check the method actually does what you want/described. |
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.
@emileten this looks really good. Nice work!
My one suggestion for change - which should be really quick - is adding a correction_type
argument to the CLI with options ceiling
, floor
or both
(or something like that). Even though we're using dodola core functions in our workflow, since we're applying the ceiling and floor functionality at different points in the workflow, I think it'd be nice to have the option to only apply one here and have that be a service.
@dgergel @brews I addressed all your concerns and following our conversation, structurally modified things a bit.
@brews I am modifying the header of this to include all related issues. |
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.
LGTM!
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.
@emileten Technically, I think this revision is fine (good, fast turn-around on this!). The changelog and PR description are a bit terse, but that's a minor comment given the deadline you're under for this.
@emileten BTW, I think you can merge this whenever you're ready! |
helps closing (but does not close) :
#468, #470, #472, #473, #474, #475, #476, #477, #481 from https://github.com/ClimateImpactLab/downscaleCMIP6/issues
tests added / passed
docs reflect changes
entry in CHANGELOG.md
rename the DTR correction core function to 'floor...'
added an equivalent one for a ceiling only applied to [-60, 60]. Default ceiling is 70.
merged these two functionalities in one service renamed to correct_dtr
added tests for the latter
accordingly modified click
changed
<
to<=
in the DTR range validationThis means our DTR 'validation' looses its meaning from when the DTR correction is applied on. It's a quick-and-dirty fix.
@dgergel this is just applying a cap at 70. This follows what I saw in the data (data points away from 60th north parallel but with a value significantly larger than 70) and me realizing (1) that 60th north parallel already crosses a significant european population area and (2) 70 diff in kelvin is already quite extreme