[python #RNH-188237]: Using CFGRIB
- Subject: [python #RNH-188237]: Using CFGRIB
- Date: Fri, 09 Oct 2020 11:43:06 -0600
Hello! Thanks for reaching out to us.
In this case, the cfgrib -> xarray interface can not read in data contained in
your GRIB file indexed along multiple different vertical coordinates (e.g.
isobaric, surface, etc.) So here, you have two primary solutions.
If your goal is to pick out just the variables for one vertical coordinate of
your choice, check out this link:
https://github.com/ecmwf/cfgrib#filter-heterogeneous-grib-files and try
ds = xr.open_dataset(<file>, engine='cfgrib',
and if your goal is for cfgrib to pull out each collection of data, grouped by
their shared vertical coordinates, check out this link :
https://github.com/ecmwf/cfgrib#automatic-filtering and try
datasets = cfgrib.open_datasets(<file>)
which will give you a list of xarray datasets, each by the different available
I hope this helps, and don't hesitate to reach out if there's more we can point
you in the direction of!
All the best,
> Could you please provide your expertise on why this fileÂisnât working?
> ÂIâm using HRRR grib files located here:ÂHRRR Download Page
> | |
> HRRR Download Page
Ticket ID: RNH-188237
Department: Support Python
NOTE: All email exchanges with Unidata User Support are recorded in the Unidata
inquiry tracking system and then made publicly available through the web. If
you do not want to have your interactions made available in this way, you must
let us know in each email you send to us.