-
Notifications
You must be signed in to change notification settings - Fork 1
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
Update xcube-cds to work with new CDS backend API #84
Comments
The main difficulty is the change in ERA5. Previously any ERA5 request to the
Here's a fairly minimal example demonstrating this behaviour with the new API: import cdsapi
dataset = "reanalysis-era5-single-levels-monthly-means"
request = {
'product_type': ['monthly_averaged_reanalysis'],
'variable': ['2m_temperature', 'mean_wave_direction'],
'year': ['2015'],
'month': ['10'],
'time': ['00:00'],
'data_format': 'netcdf',
'area': [1, -1, -1, 1]
}
client = cdsapi.Client()
client.retrieve(dataset, request).download() This produces a Zip file containing two NetCDFs, each containing one of the requested variables. The NetCDFs have different resolutions, but this isn't always the case: sometimes a Zip is produced containing multiple NetCDFs with identical dimensions. The equivalent code for the old API is: import cdsapi
dataset = "reanalysis-era5-single-levels-monthly-means"
request = {
'product_type': ['monthly_averaged_reanalysis'],
'variable': ['2m_temperature', 'mean_wave_direction'],
'year': ['2015'],
'month': ['10'],
'time': ['00:00'],
'data_format': 'netcdf',
'area': [1, -1, -1, 1]
}
client = cdsapi.Client()
client.retrieve(dataset, request).download() This produces a single NetCDF on a common grid. |
Sketch of a solution for ERA5:
|
The current CDS API servers are scheduled to be shut down on 2024-09-03. As of 2024-07-25, ECMWF has not yet deployed any production-grade replacement, but there is a beta version of the planned successor at https://cds-beta.climate.copernicus.eu/. xcube-cds will need to support this new version before the current version is shut down.
More information:
The text was updated successfully, but these errors were encountered: