issues: 322091500
This data as json
id | node_id | number | title | user | state | locked | assignee | milestone | comments | created_at | updated_at | closed_at | author_association | active_lock_reason | draft | pull_request | body | reactions | performed_via_github_app | state_reason | repo | type |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
322091500 | MDU6SXNzdWUzMjIwOTE1MDA= | 2116 | time array with mixture of types decoded from non-standard calendar | 11436996 | closed | 0 | 2 | 2018-05-10T21:27:52Z | 2018-05-10T22:04:15Z | 2018-05-10T22:04:15Z | NONE | Reading a set of files with 360-day calendar with open_mf_dataset(), yields a time array with a mixture of types cftime._cftime.Datetime360Day and Timestamp. The files are CMIP5 output for HadGEM2-ES. I don't think there is a way to force it to use only cftime type for all times? All times should have the same type so slicing is possible (see below).
Problem descriptionOne consistent type is needed for slicing. It would be fine if they were all type cftime.Datetime360Day, as one could then do the following:
Expected OutputFor some reason with another set of 360-day calendar files (from HadGEM2-CC for what it's worth) it did decode for me with all one type, the time array looks as expected, and slicing as above works:
Output of
|
{ "url": "https://api.github.com/repos/pydata/xarray/issues/2116/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 } |
completed | 13221727 | issue |