-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
xarray.open_mfdataset returns inconsistent times #1263
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
Labels
Comments
(This is related to #1261.) |
I think I like your solution (2) the best. |
In order to maintain a list of currently relevant issues, we mark issues as stale after a period of inactivity If this issue remains relevant, please comment here; otherwise it will be marked as closed automatically |
This remains an issue, though only for dates from a standard calendar now. |
This was referenced Feb 8, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Problem
I am running into inconsistent time coordinates with a long climate model experiment that exceeds the limits of
pandas.tslib.Timestamp
(covers roughly 17th to 23rd century).Currently,
xarray.open_mfdataset
delegates decoding of the time axis toxarray.open_dataset
which decodes either to pandas time stamps or, of this fails, tonetcdftime.datetime
objects.xarray.open_mfdataset
later combines the single-file datasets and just concatenates all the time axes.Solution
xarray.open_mfdataset
preventxarray.open_dataset
from decoding the times for each file and only decode times after everything is combined.The latter is equivalent to a workaround I use for the moment: Pass
decode_times=False
toxarray.open_mfdataset
and then explicitly callxarray.decode_cf
on the dataset.The text was updated successfully, but these errors were encountered: