...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
# create a local virtual environment, you can call it as you wish, here 'myenv' is used. conda create -n myenv python=3.8 # add repository channel conda config --add channels conda-forge # activate the local environment. conda activate myenv # install the required packages conda install -c conda-forge/label/main xarray cfgrib eccodes conda install cartopy netcdf4 matplotlib # and the cdsapi pip install cdsapi |
Visualize EFAS products
Retrieve data
These exercises require EFAS model output parameters and auxiliary data. You can retrieve them using the CDS API, as described in the code blocks below:
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
import xarray as xr ds = xr.open_dataset('esd_2021013000.nc') ds.sd.plot(col="step",col_wrap=4, robust=True) |
Visualize GLOFAS products
Also for this exercise we are going to retrieve data from the CDS API, as described in the code blocks below:
...