Published August 30, 2021
| Version v0.29.0
Software
Open
Ouranosinc/xclim: v0.29.0
Authors/Creators
- 1. Ouranos
- 2. ECCC
- 3. CERFACS
- 4. @jakarto3d
- 5. STFC CEDA
Description
Announcements
- It was found that the
ExtremeValuesadjustment algorithm was not as accurate and stable as first thought. It is now hidden fromxclim.sdbabut can still be accessed viaxclim.sdba.adjustment, with a warning. Work on improving the algorithm is ongoing, and a better implementation will be in a future version. - It was found that the
add_dimsargument ofsdba.Grouperhad some caveats throughoutsdba. This argument is to be used with care before a careful analysis and more testing is done withinxclim.
xclimhas switched back to updating thehistoryattribute (instead ofxclim_history). This impacts all indicators, most ensemble functions,percentile_doyandsdba.processing(see below).- Refactor of
sdba.processing. Now all functions take one or more dataarrays as input, plus some parameters. And output one or more dataarrays (not Datasets). Units and metadata is handled. This impactssdba.processing.adapt_freqespecially. - Add unit handling in
sdba. Most parameters involving quantities are now expecting strings (and not numbers). Adjustment objects will ensure ref, hist and sim all have the same units (taking ref as reference). - The Adjustment` classes of
xclim.sdbahave been refactored into 2 categories:TrainAdjustobjects (most of the algorithms), which are created and trained in the same call:obj = Adj.train(ref, hist, **kwargs). The.adjuststep stays the same.Adjustobjects (onlyNpdfTransform), which are never initialized. Theiradjustclass method performs all the work in one call.
snowfall_approximationused a"<"condition instead of"<="to determine the snow fraction based on the freezing point temperature. The new version sticks to the convention used in the Canadian Land Surface Scheme (CLASS).- Removed the
"gis","docs","test"and"setup"extra dependencies fromsetup.py. Thedevrecipe now includes all tools needed for xclim's development.
snowfall_approximationhas gained support for new estimation methods used in CLASS: 'brown' and 'auer'.- A
ValidationErrorwill be raised if temperature units are given as 'deg C', which is misinterpreted by pint. - Functions computing run lengths (sequences of consecutive
"True"values) now take theindexargument. Possible values arefirstandlast, indicating which item in the run should be used to index the run length. The default is set to"first", preserving the current behavior. - New
sdba_encode_cfoption to workaround a cftime/xarray performance issue when using dask.
effective_growing_degree_daysindice returns growing degree days using dynamic start and end dates for the growing season (based on Bootsma et al. (2005)). This has also been wrapped as an indicator.qian_weighted_mean_average(based on Qian et al. (2010)) is offered as an alternate method for determining the start date using a weighted 5-day average (method="qian"). Can also be used directly as an indice.cold_and_dry_daysindicator returns the number of days where the mean daily temperature is below the 25th percentile and the mean daily precipitation is below the 25th percentile over period. Added asCDindicator to ICCLIM module.warm_and_dry_daysindicator returns the number of days where the mean daily temperature is above the 75th percentile and the mean daily precipitation is below the 25th percentile over period. Added asWDindicator to ICCLIM module.warm_and_wet_daysindicator returns the number of days where the mean daily temperature is above the 75th percentile and the mean daily precipitation is above the 75th percentile over period. Added asWWindicator to ICCLIM module.cold_and_wet_daysindicator returns the number of days where the mean daily temperature is below the 25th percentile and the mean daily precipitation is above the 75th percentile over period. Added asCWindicator to ICCLIM module.calm_daysindicator returns the number of days where surface wind speed is below threshold.windy_daysindicator returns the number of days where surface wind speed is above threshold.
- Various bug fixes in bootstrapping:
- in
percentile_bootstrapdecorator, fix the popping of bootstrap argument to propagate in to the function call. - in
bootstrap_func, fix some issues with the resampling frequency which was not working when anchored.
- in
- Made argument
threshofsdba.LOCIrequired, as not giving it raised an error. Made defaults explicit in the adjustments docstrings. - Fixes in
sdba.processing.adapt_freqandsdba.nbutils.vecquantileswhen handling all-nan slices. - Dimensions in a grouper's
add_dimsare now taken into consideration in function wrapped withmap_blocks/groups. This feature is still not fully tested throughoutsdbathough, so use with caution. - Better dtype preservation throughout
sdba. - "constant" extrapolation in the quantile mappings' adjustment is now padding values just above and under the target's max and min, instead of
±np.inf. - Fixes in
sdba.LOCIfor the case where a grouping with additionnal dimensions is used.
- The behaviour of
xclim.testing._utils.getfilewas adjusted to launch file download requests for web-hosted md5 files for every call to compare against local test data. This was done to validate that locally-stored test data is identical to test data available online, without resorting to git-based actions. This approach may eventually be revised/optimized in the future.
Files
Ouranosinc/xclim-v0.29.0.zip
Files
(731.4 kB)
| Name | Size | Download all |
|---|---|---|
|
md5:1147dfd5a43c2b68cd49419ac838b0b8
|
731.4 kB | Preview Download |
Additional details
Related works
- Is supplement to
- https://github.com/Ouranosinc/xclim/tree/v0.29.0 (URL)