Open crangelsmith opened 1 year ago
The grouping for quantile methods has been removed in https://github.com/btschwertfeger/python-cmethods/commit/e3436310a4f927c86b30d7db137dd718c69fe1f7 since grouping distribution-based methods produces unrealistic high deviations in monthly (if group="time.month"
) transitions on large data sets. This also occurs when grouping to time.dayofyear
, and time.year
.
It was removed since the grouping was some kind of leftover of my bachelor theses in which I started implementing this tool and it is not described in any paper (for the mentioned reasons I think).
The grouping for quantile methods has been removed in btschwertfeger@e343631 since grouping distribution-based methods produces unrealistic high deviations in monthly (if
group="time.month"
) transitions on large data sets. This also occurs when grouping totime.dayofyear
, andtime.year
.It was removed since the grouping was some kind of leftover of my bachelor theses in which I started implementing this tool and it is not described in any paper (for the mentioned reasons I think).
Thank you @btschwertfeger for the explanation!
@RuthBowyer FYI.
Revisiting this. I think we should modify the code to gracefully fail early when grouping for quantile methods is requested. And also add information about this in the relevant docstrings.
Describe the bug
We cannot implement debiasing using groups on the following methods: quantile_mapping and quantile_delta_mapping.
To Reproduce
Running from clim-recal, in directory
python/debiasing
You can also add a grouping option to cell 7 from this notebook.
Error message
Additional context
This work in the other debiasing because the methods are based on computation on numpy arrays, so when it's giving a list of arrays the calculation is applied individually to each list. This is not the case for the distribution-based methods (quantile mapping), where no list is expected, but a single time series.
A bug fix should allow running the calculation on each component of the list that is returned when the grouping happens.