the s5 data has lots of nuances
so in order to be a complete xarray object there are 4 different forecast_horizons for each month so that the only array with non-nan values is when the valid_time is the first of the next month.
the forecast_horizon is set to a size of 9 (28days, 30days, 31days + 30 + 60 ...) which is the way to code n month forecasts (1month = 28/30/31 depending on the length of the month).



So these forecasts are all initialised on 2014-01-01 and January is 31 days long. So the only valid data comes from the 3rd indexed forecast_horizon (here coded as step) which corresponds to 31 days. This takes the valid_time to 2014-02-01 which is the month ahead. Whereas February/March are 59 days long total. So the 4th indexed forecast_horizon[3] corresponds to 59 days which is the valid step here (valid_time == 2014-03-01)

We need a way to get the valid timesteps so that we have a complete xarray object with data at each timestep. I can think of a few ways but we could document them here.
the s5 data has lots of nuances
so in order to be a complete xarray object there are 4 different
forecast_horizonsfor each month so that the only array with non-nan values is when thevalid_timeis the first of the next month.the
forecast_horizonis set to a size of 9 (28days, 30days, 31days + 30 + 60 ...) which is the way to code n month forecasts (1month = 28/30/31 depending on the length of the month).So these forecasts are all initialised on
2014-01-01and January is 31 days long. So the only valid data comes from the 3rd indexedforecast_horizon(here coded asstep) which corresponds to 31 days. This takes thevalid_timeto2014-02-01which is the month ahead. Whereas February/March are 59 days long total. So the 4th indexedforecast_horizon[3]corresponds to 59 days which is the valid step here (valid_time==2014-03-01)We need a way to get the valid timesteps so that we have a complete xarray object with data at each timestep. I can think of a few ways but we could document them here.