4.7.2. thuner.data.era5

Process ERA5 data.

Functions

get_era5_filepaths(dataset_options[, start, end])

Generate era5 filepaths from dataset options dictionary.

pydantic model thuner.data.era5.ERA5Options[source]

Bases: BaseDatasetOptions

Options for ERA5 datasets.

Fields:
Validators:
  • _check_defaults » all fields

  • _check_filepaths » all fields

  • _check_ranges » all fields

  • _check_times » all fields

field data_format: Literal['pressure-levels', 'single-levels'] = 'pressure-levels'

Data format, e.g. pressure-levels.

field latitude_range: list[float] = [-90, 90]

Latitude range if accessing a directory of subsetted era5 data.

field longitude_range: list[float] = [-180, 180]

Longitude range if accessing a directory of subsetted era5 data.

field mode: Literal['reanalysis'] = 'reanalysis'

Mode of the data, e.g. reannalysis.

field pressure_levels: list[str] | list[float] | None = None

Pressure levels; required if data_format is pressure-levels.

field storage: str = 'monthly'

Storage format of the data, e.g. monthly.

field type: Literal['ERA5Options'] = 'ERA5Options'
get_filepaths()[source]

Override the get_filepaths method with the era5 version.

update_input_record(time, input_record, track_options, grid_options)[source]

Update the era5 dataset.

thuner.data.era5.get_era5_filepaths(dataset_options: ERA5Options, start=None, end=None)[source]

Generate era5 filepaths from dataset options dictionary.

Parameters:

dataset_options (dict) – Dictionary containing the input dataset_options.

Returns:

  • urls (list) – List of URLs.

  • times (list) – Times associated with the URLs.