Skip to content

Instantly share code, notes, and snippets.

View kathoef's full-sized avatar

Katharina Höflich kathoef

  • GEOMAR Helmholtz Centre for Ocean Research Kiel and Kiel University Computing Centre
  • Kiel, Schleswig-Holstein, Germany
View GitHub Profile
@kathoef
kathoef / era5-parallel-requests.py
Last active February 7, 2025 11:27
parallel download of ERA5 reanalysis data
import cdsapi
import multiprocessing
client = cdsapi.Client(url='xxx',key='xxx:xxx')
def cdsapi_worker(dataset):
result = client.retrieve('reanalysis-era5-single-levels', dataset)
result.download(dataset['file_name'])
def single_dataset(calendar_year, file_prefix):