Tip
Need help? Please let us know in the UMEP Community.
Please report issues with the manual on the GitHub Issues.
Please cite SUEWS with proper information from our Zenodo page.
6.1.3.2.1.1. supy.util.download_era5#
- supy.util.download_era5(lat_x: float, lon_x: float, start: str, end: str, simple_mode: bool, dir_save=PosixPath('.'), grid=None, scale=0, logging_level=20) dict [source]#
Generate ERA-5 cdsapi-based requests and download data for area of interests.
6.1.3.2.1.1. Parameters#
- lat_xfloat
Latitude of centre at the area of interest.
- lon_xfloat
Longitude of centre at the area of interest.
- startstr
Any datetime-like string that can be parsed by
pandas.daterange()
.- endstr
Any datetime-like string that can be parsed by
pandas.daterange()
.- gridlist, optional
grid size used in CDS request API, by default [0.125, 0.125].
- scaleint, optional
scaling factor that determines the area of interest (i.e.,
area=grid[0]*scale
), by default 0.- dir_save: Path or path-like string
path to directory for saving downloaded ERA5 netCDF files.
- logging_level: logging level
one of these values [50 (CRITICAL), 40 (ERROR), 30 (WARNING), 20 (INFO), 10 (DEBUG)]. A lower value informs SuPy for more verbose logging info.
6.1.3.2.1.1. Returns#
- dict
key: name of downloaded file. value: CDS API request used for downloading the file named by the corresponding key.
6.1.3.2.1.1. Note#
This function uses CDS API to download ERA5 data; follow this for configuration first: https://cds.climate.copernicus.eu/api-how-to