You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Various satellite products are shipped by the CDS in zip archives containing daily netcdfs.
Those files do not have a time dimension, and therefore can not be concatenated by xarray.
Here I'm showing an example using satellite-aerosol-properties, but other products are also affected (e.g., satellite-methane)
It's possible to concatenate them using xr.open_mfdataset kwargs. Are users supposed to use xarray's kwargs for these products?
Side note: I can figure out xarray's kwargs needed by using the _indexes property. As far as I can tell that's the only way, but it feels I'm doing a hack. Should _indexes be a public property?
What are the steps to reproduce the bug?
importearthkit.datacollection_id="satellite-aerosol-properties"request= {
"format": "zip",
"time_aggregation": "daily_average",
"variable": "aerosol_optical_depth",
"sensor_on_satellite": "aatsr_on_envisat",
"algorithm": "adv",
"year": "2002",
"month": "05",
"day": ["20", "21"],
"version": "v3.11",
}
ds=earthkit.data.from_source("cds", collection_id, request)
ds.to_xarray() # ValueError: Could not find any dimension coordinates to use to order the datasets for concatenation
@malmans2, I can confirm that the preferred way to control NetCDF concatenation in to_xarray is to use xarray_open_mfdataset_kwargs. It will be added to the documentation.
What happened?
Various satellite products are shipped by the CDS in zip archives containing daily netcdfs.
Those files do not have a time dimension, and therefore can not be concatenated by xarray.
Here I'm showing an example using
satellite-aerosol-properties
, but other products are also affected (e.g.,satellite-methane
)It's possible to concatenate them using
xr.open_mfdataset
kwargs. Are users supposed to use xarray's kwargs for these products?Side note: I can figure out xarray's kwargs needed by using the
_indexes
property. As far as I can tell that's the only way, but it feels I'm doing a hack. Should_indexes
be a public property?What are the steps to reproduce the bug?
Workaround:
Version
0.5.1
Platform (OS and architecture)
Darwin MacBook-Pro-3.local 22.6.0 Darwin Kernel Version 22.6.0: Wed Jul 5 22:21:56 PDT 2023; root:xnu-8796.141.3~6/RELEASE_X86_64 x86_64
Relevant log output
Accompanying data
No response
Organisation
B-Open / CADS-EQC
The text was updated successfully, but these errors were encountered: