-
Notifications
You must be signed in to change notification settings - Fork 10
Add support for rainfall amount diagnostics #1480
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
Add support for rainfall amount diagnostics #1480
Conversation
histogram type, and move unit conversion to read callback.
|
Link to full cset-workflow outputs (based on 2 West Africa UM vs LFRic cases): Plots below illustrate alternative precip pdf methods proposed for amount (left) and rate (right). There is nothing particularly "unique" about one needing to be in one form, the other another, but I suggest there may be value for building confidence and insight on the alternative methods to generate both (i.e. exploit availability of both amount and rate diagnostics) to compare over time etc: Examples below highlight near-but-not-exact equivalence between accumulated rainfall amount in hour (LHS) and the instantaneous rainfall rate on hour (RHS). Marking as ready for review, propose by @Sylviabohnenstengel given has looked after initial precip pdf treatment. |
|
Could you please try to run a timeseries? I am getting the following error message for this branch: |
Sylviabohnenstengel
left a comment
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.
Changes look correct and happy to approve when comments in PR are addressed.
|
I can successfully run the branch now |
…rainfall-amount-diagnostics
|
Review responses Have pushed updates for: Re-running a cset-workflow example and will post link to output here. On other points of feedback 1) Timeseries plotting Below illustrates a rainfall rate timeseries (generated using cset bake on command line) that has correct mm/hr units. Colorbar file has been updated to set y-axis max to 1.0 mm/hr. Not sure of difference in setup with example posted by Sylvia further above in this conversation. As aside here, we could/should push small PR to update timeseries axis labelling (currently based on cube.name() as can often pick up different variable name to title, and the use of 'units' for time axis label pulls out the new basing of all time dimensions to hours since...., which is not reflecting the dates shown 2) Spatial plots Have put in a new layer to unit conversion to translate kg m-2 to mm (just a 1:1 conversion), and added relevant testing. I also updated the logging.WARNING to logging.INFO here (and updated tests), partly as lots of warning messages result for reading in probability_of_visibility cubes. Below shows (left) rainfall amount, now in mm and (right) rainfall rate. _note different cube.name() based colorbar title to the varname-based title. I think this suggestion therefore addressed. 3) Histograms Note #1377 will offer some tidying of histogram default behaviour (i.e. 1-histogram per case, or select to output hourly histograms if required). Note the 'jumping' of y-range for histograms is common to ALL variables (and so more noticeable when scanning through hour-by-hour). When developing #1396, I left the y-axis of histograms alone. Given the area under curve illustrates the mean rainfall when using 'Klingaman' method, there may be value in setting a Note rainfall amount histograms now also in units "mm". Useful to also highlight #1303 as in-progress PR to add greater range of methods for histogram plotting. I have built this PR on top of the update for rainfall_rate, but should resolve choices on ymin, ymax and flexibility of methods in considering how to merge this PR. Note there is still likely to be a need to control different histogram choices for precip variables than for others however. Histogram recipe descriptions have been updated as suggested (bearing in mind further revision proposed via #1303). Note also that the description suggested for main histogram recipe in #1303 discusses noisy outputs. Wondering if 'jumpiness' might be a separate issue/PR rather than resolving here, and re-review after #1377 if histograms more likely used for more aggregated inputs? 4) Aggregation
Example below shows (left) rainfall amount in mm and (right) rainfall rate time series aggregation by hour of day. Suggest the aggregation challenge is now resolved? @Sylviabohnenstengel - could you please check responses above and latest code changes? |
|
Output directory from testing with SWUK 300m data with this branch: https://wwwspice/~huw.lewis/CSET/CSET_testing/ |
Sylviabohnenstengel
left a comment
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.
happy with the changes and ready to merge.










Addresses #1367 and #1479.
a) Adds colorbar settings for rainfall_amount diagnostics (would capture rainfall and snowfall amount).
b) Introduces a new histogram method for rainfall amount, based on https://gmd.copernicus.org/articles/10/57/2017/gmd-10-57-2017.html (and subsequent iteration by Segolene Berthou in published work, used in K-Scale etc).
c) Moved unit conversion to read.py callback rather than embedded in plotting code.
Contribution checklist
Aim to have all relevant checks ticked off before merging. See the developer's guide for more detail.