Ouranosinc / xscen

A climate change scenario-building analysis framework.
https://xscen.readthedocs.io/
Apache License 2.0
17 stars 2 forks source link

xs.climatological_mean and compute_deltas are broken with daily data #186

Open RondeauG opened 1 year ago

RondeauG commented 1 year ago

Setup Information

Description

xs.climatological_mean and xs.compue_deltas unstack data into [year, month, day] to perform their actions, then puts everything back into a 1D time array using: ds = ds.stack(time=("year", "month", "day")) (line 123 in climatological_mean)

This might have been an oversight on our part, but this only works when all values of day exist for every month. With daily data, this creates an array of size 372 (31 x 12), including many impossible days that make pandas crash.

Steps To Reproduce

No response

Additional context

No response

Contribution