GFS#

This demonstrates how to download and use GFS data.

[1]:
from herbie import Herbie
from herbie.toolbox import EasyMap, pc, ccrs
from herbie import paint

import matplotlib.pyplot as plt
[2]:
H = Herbie("2021-07-11", model="gfs", product="pgrb2.0p25")
βœ… Found β”Š model=gfs β”Š product=pgrb2.0p25 β”Š 2021-Jul-11 00:00 UTC F00 β”Š GRIB2 @ aws β”Š IDX @ aws
[3]:
# Show all available sources
H.SOURCES
[3]:
{'aws': 'https://noaa-gfs-bdp-pds.s3.amazonaws.com/gfs.20210711/00/atmos/gfs.t00z.pgrb2.0p25.f000',
 'ftpprd': 'https://ftpprd.ncep.noaa.gov/data/nccf/com/gfs/prod/gfs.20210711/00/atmos/gfs.t00z.pgrb2.0p25.f000',
 'nomads': 'https://nomads.ncep.noaa.gov/pub/data/nccf/com/gfs/prod/gfs.20210711/00/atmos/gfs.t00z.pgrb2.0p25.f000',
 'google': 'https://storage.googleapis.com/global-forecast-system/gfs.20210711/00/atmos/gfs.t00z.pgrb2.0p25.f000',
 'azure': 'https://noaagfs.blob.core.windows.net/gfs/gfs.20210711/00/atmos/gfs.t00z.pgrb2.0p25.f000',
 'ncar_rda': 'https://data.rda.ucar.edu/d084001/2021/20210711/gfs.0p25.2021071100.f000.grib2'}
[4]:
# Show all available products
H.PRODUCTS
[4]:
{'pgrb2.0p25': 'common fields, 0.25 degree resolution',
 'pgrb2.0p50': 'common fields, 0.50 degree resolution',
 'pgrb2.1p00': 'common fields, 1.00 degree resolution',
 'pgrb2b.0p25': 'uncommon fields, 0.25 degree resolution',
 'pgrb2b.0p50': 'uncommon fields, 0.50 degree resolution',
 'pgrb2b.1p00': 'uncommon fields, 1.00 degree resolution',
 'pgrb2full.0p50': 'combined grids of 0.50 resolution',
 'sfluxgrb': 'surface flux fields, T1534 Semi-Lagrangian grid',
 'goesimpgrb2.0p25': ', 0.50 degree resolution'}
[5]:
ds = H.xarray(":TMP:2 m above")
πŸ‘¨πŸ»β€πŸ­ Created directory: [/home/blaylock/data/gfs/20210711]
[6]:
ax = EasyMap(crs=ds.herbie.crs, figsize=[10, 8]).ax
p = ax.pcolormesh(
    ds.longitude,
    ds.latitude,
    ds.t2m - 273.15,
    transform=pc,
    **paint.NWSTemperature.kwargs2,
)
plt.colorbar(
    p, ax=ax, orientation="horizontal", pad=0.05, **paint.NWSTemperature.cbar_kwargs2
)

ax.set_title(ds.t2m.GRIB_name, loc="right")
ax.set_title(f"{ds.model.upper()}: {H.product_description}", loc="left")
[6]:
Text(0.0, 1.0, 'GFS: common fields, 0.25 degree resolution')
../../_images/gallery_noaa_models_gfs_6_1.png

Let’s change it up and plot on a Geostationary projection.

[7]:
ax = EasyMap(crs=ccrs.Geostationary(central_longitude=-100), figsize=[10, 10]).ax

p = ax.pcolormesh(
    ds.longitude,
    ds.latitude,
    ds.t2m - 273.15,
    transform=pc,
    **paint.NWSTemperature.kwargs2,
)
plt.colorbar(
    p,
    ax=ax,
    orientation="horizontal",
    pad=0.05,
    shrink=0.8,
    **paint.NWSTemperature.cbar_kwargs2,
)

ax.set_title(ds.t2m.GRIB_name, loc="right")
ax.set_title(f"{ds.model.upper()}: {H.product_description}", loc="left")
[7]:
Text(0.0, 1.0, 'GFS: common fields, 0.25 degree resolution')
../../_images/gallery_noaa_models_gfs_8_1.png
[8]:
ds2 = H.xarray("RH:2 m above")

ax = EasyMap(crs=ccrs.Robinson(), figsize=[8, 8]).ax
p = ax.pcolormesh(
    ds2.longitude,
    ds2.latitude,
    ds2.r2,
    transform=pc,
    **paint.NWSRelativeHumidity.kwargs,
)

plt.colorbar(
    p,
    ax=ax,
    orientation="horizontal",
    pad=0.05,
    shrink=0.8,
    **paint.NWSRelativeHumidity.cbar_kwargs,
)
[8]:
<matplotlib.colorbar.Colorbar at 0x7fb369862a20>
../../_images/gallery_noaa_models_gfs_9_1.png

GFS from NCEI#

Depending on the date, Herbie might find old GFS data at NCEI or RDA for dates older than January 1, 2021.

[9]:
# Look for file in all available sources
H = Herbie("2020-06-01", model="gfs")
βœ… Found β”Š model=gfs β”Š product=0.5-degree β”Š 2020-Jun-01 00:00 UTC F00 β”Š GRIB2 @ ncei_analysis β”Š IDX @ ncei_analysis
[10]:
H.SOURCES, H.PRODUCTS
[10]:
({'ncei_analysis': 'https://www.ncei.noaa.gov/data/global-forecast-system/access/grid-004-0.5-degree/analysis/202006/20200601/gfs_4_20200601_0000_000.grb2',
  'ncei_forecast': 'https://www.ncei.noaa.gov/data/global-forecast-system/access/grid-004-0.5-degree/forecast/202006/20200601/gfs_4_20200601_0000_000.grb2',
  'ncar_rda': 'https://data.rda.ucar.edu/d084001/2020/20200601/gfs.0p25.2020060100.f000.grib2'},
 {'0.5-degree': '0.5 degree grid', '1.0-degree': '1.0 degree grid'})
[11]:
H.inventory("GRD:80 m above")
[11]:
grib_message start_byte end_byte range reference_time valid_time variable level forecast_time search_this
465 466 80208994 80496003.0 80208994-80496003 2020-06-01 2020-06-01 UGRD 80 m above ground anl :UGRD:80 m above ground:anl
466 467 80496004 80780823.0 80496004-80780823 2020-06-01 2020-06-01 VGRD 80 m above ground anl :VGRD:80 m above ground:anl

GFS GraphCast#

This demonstrates how to download and plot data from the experimental GFS GraphCast AI model.

[22]:
H = Herbie("2024-05-10 12:00", model="graphcast", fxx=6)
H.SOURCES, H.PRODUCTS
βœ… Found β”Š model=graphcast β”Š product=pgrb2.0p25 β”Š 2024-May-10 12:00 UTC F06 β”Š GRIB2 @ aws β”Š IDX @ aws
[22]:
({'aws': 'https://noaa-nws-graphcastgfs-pds.s3.amazonaws.com/graphcastgfs.20240510/12/forecasts_13_levels/graphcastgfs.t12z.pgrb2.0p25.f006'},
 {'pgrb2.0p25': 'common fields, 0.25 degree resolution'})

The current version of the GraphCast has a limited set of parameters on 13 different levels.

[23]:
H.inventory()
[23]:
grib_message start_byte end_byte range reference_time valid_time variable level forecast_time search_this
0 1 0 3244678.0 0-3244678 2024-05-10 12:00:00 2024-05-10 18:00:00 VGRD 50 mb 6 hour fcst :VGRD:50 mb:6 hour fcst
1 2 3244679 6489357.0 3244679-6489357 2024-05-10 12:00:00 2024-05-10 18:00:00 VGRD 100 mb 6 hour fcst :VGRD:100 mb:6 hour fcst
2 3 6489358 9734036.0 6489358-9734036 2024-05-10 12:00:00 2024-05-10 18:00:00 VGRD 150 mb 6 hour fcst :VGRD:150 mb:6 hour fcst
3 4 9734037 12978715.0 9734037-12978715 2024-05-10 12:00:00 2024-05-10 18:00:00 VGRD 200 mb 6 hour fcst :VGRD:200 mb:6 hour fcst
4 5 12978716 16223394.0 12978716-16223394 2024-05-10 12:00:00 2024-05-10 18:00:00 VGRD 250 mb 6 hour fcst :VGRD:250 mb:6 hour fcst
... ... ... ... ... ... ... ... ... ... ...
79 80 256329689 259574367.0 256329689-259574367 2024-05-10 12:00:00 2024-05-10 18:00:00 VVEL 600 mb 6 hour fcst :VVEL:600 mb:6 hour fcst
80 81 259574368 262819046.0 259574368-262819046 2024-05-10 12:00:00 2024-05-10 18:00:00 VVEL 700 mb 6 hour fcst :VVEL:700 mb:6 hour fcst
81 82 262819047 266063725.0 262819047-266063725 2024-05-10 12:00:00 2024-05-10 18:00:00 VVEL 850 mb 6 hour fcst :VVEL:850 mb:6 hour fcst
82 83 266063726 269308404.0 266063726-269308404 2024-05-10 12:00:00 2024-05-10 18:00:00 VVEL 925 mb 6 hour fcst :VVEL:925 mb:6 hour fcst
83 84 269308405 NaN 269308405- 2024-05-10 12:00:00 2024-05-10 18:00:00 VVEL 1000 mb 6 hour fcst :VVEL:1000 mb:6 hour fcst

84 rows Γ— 10 columns

Plot 2m temperature

[24]:
ds = H.xarray("TMP:2 m")
πŸ‘¨πŸ»β€πŸ­ Created directory: [/home/blaylock/data/graphcast/20240510]
[25]:
ax = EasyMap(crs=ds.herbie.crs, figsize=[10, 8]).ax
p = ax.pcolormesh(
    ds.longitude,
    ds.latitude,
    ds.t2m - 273.15,
    transform=pc,
    **paint.NWSTemperature.kwargs2,
)
plt.colorbar(
    p, ax=ax, orientation="horizontal", pad=0.05, **paint.NWSTemperature.cbar_kwargs2
)

ax.set_title(ds.t2m.GRIB_name, loc="right")
ax.set_title(f"{ds.model.upper()}: {H.product_description}", loc="left")
[25]:
Text(0.0, 1.0, 'GRAPHCAST: common fields, 0.25 degree resolution')
../../_images/gallery_noaa_models_gfs_20_1.png

GFS wave data#

This demonstrates getting data from the GFS wave output.

[26]:
H = Herbie("2021-07-11", model="gfs_wave")
βœ… Found β”Š model=gfs_wave β”Š product=arctic.9km β”Š 2021-Jul-11 00:00 UTC F00 β”Š GRIB2 @ aws β”Š IDX @ aws
[27]:
H.inventory()
[27]:
grib_message start_byte end_byte range reference_time valid_time variable level forecast_time search_this
0 1 0 430315.0 0-430315 2021-07-11 2021-07-11 WIND surface anl :WIND:surface:anl
1 2 430316 1049179.0 430316-1049179 2021-07-11 2021-07-11 WDIR surface anl :WDIR:surface:anl
2 3 1049180 1480558.0 1049180-1480558 2021-07-11 2021-07-11 UGRD surface anl :UGRD:surface:anl
3 4 1480559 1908976.0 1480559-1908976 2021-07-11 2021-07-11 VGRD surface anl :VGRD:surface:anl
4 5 1908977 2174765.0 1908977-2174765 2021-07-11 2021-07-11 HTSGW surface anl :HTSGW:surface:anl
5 6 2174766 2497195.0 2174766-2497195 2021-07-11 2021-07-11 PERPW surface anl :PERPW:surface:anl
6 7 2497196 3016884.0 2497196-3016884 2021-07-11 2021-07-11 DIRPW surface anl :DIRPW:surface:anl
7 8 3016885 3260188.0 3016885-3260188 2021-07-11 2021-07-11 WVHGT surface anl :WVHGT:surface:anl
8 9 3260189 3529929.0 3260189-3529929 2021-07-11 2021-07-11 SWELL 1 in sequence anl :SWELL:1 in sequence:anl
9 10 3529930 3764422.0 3529930-3764422 2021-07-11 2021-07-11 SWELL 2 in sequence anl :SWELL:2 in sequence:anl
10 11 3764423 3968458.0 3764423-3968458 2021-07-11 2021-07-11 SWELL 3 in sequence anl :SWELL:3 in sequence:anl
11 12 3968459 4247105.0 3968459-4247105 2021-07-11 2021-07-11 WVPER surface anl :WVPER:surface:anl
12 13 4247106 4558848.0 4247106-4558848 2021-07-11 2021-07-11 SWPER 1 in sequence anl :SWPER:1 in sequence:anl
13 14 4558849 4873389.0 4558849-4873389 2021-07-11 2021-07-11 SWPER 2 in sequence anl :SWPER:2 in sequence:anl
14 15 4873390 5158236.0 4873390-5158236 2021-07-11 2021-07-11 SWPER 3 in sequence anl :SWPER:3 in sequence:anl
15 16 5158237 5558668.0 5158237-5558668 2021-07-11 2021-07-11 WVDIR surface anl :WVDIR:surface:anl
16 17 5558669 6033914.0 5558669-6033914 2021-07-11 2021-07-11 SWDIR 1 in sequence anl :SWDIR:1 in sequence:anl
17 18 6033915 6470115.0 6033915-6470115 2021-07-11 2021-07-11 SWDIR 2 in sequence anl :SWDIR:2 in sequence:anl
18 19 6470116 NaN 6470116- 2021-07-11 2021-07-11 SWDIR 3 in sequence anl :SWDIR:3 in sequence:anl
[28]:
ds = H.xarray("SWELL:1 in sequence", remove_grib=False)
ds
πŸ‘¨πŸ»β€πŸ­ Created directory: [/home/blaylock/data/gfs_wave/20210711]
ECCODES ERROR   :  Polar stereographic Geoiterator: Only supported for spherical earth.
ECCODES ERROR   :  Geoiterator factory: Error instantiating iterator polar_stereographic (Problem with calculation of geographic attributes)
ECCODES ERROR   :  latitudes: Unable to create iterator
---------------------------------------------------------------------------
GeocalculusError                          Traceback (most recent call last)
Cell In[28], line 1
----> 1 ds = H.xarray("SWELL:1 in sequence", remove_grib=False)
      2 ds

File ~/GITHUB/Herbie/herbie/core.py:1137, in Herbie.xarray(self, search, searchString, backend_kwargs, remove_grib, **download_kwargs)
   1133 backend_kwargs.setdefault("errors", "raise")
   1135 # Use cfgrib.open_datasets, just in case there are multiple "hypercubes"
   1136 # for what we requested.
-> 1137 Hxr = cfgrib.open_datasets(
   1138     local_file,
   1139     backend_kwargs=backend_kwargs,
   1140 )
   1142 # Get CF grid projection information with pygrib and pyproj because
   1143 # this is something cfgrib doesn't do (https://github.com/ecmwf/cfgrib/issues/251)
   1144 # NOTE: Assumes the projection is the same for all variables
   1145 with pygrib.open(str(local_file)) as grb:

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_store.py:105, in open_datasets(path, backend_kwargs, **kwargs)
    103 backend_kwargs = backend_kwargs.copy()
    104 backend_kwargs["squeeze"] = False
--> 105 datasets = open_variable_datasets(path, backend_kwargs=backend_kwargs, **kwargs)
    107 type_of_level_datasets = {}  # type: T.Dict[str, T.List[xr.Dataset]]
    108 for ds in datasets:

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_store.py:93, in open_variable_datasets(path, backend_kwargs, **kwargs)
     91     bk["filter_by_keys"] = backend_kwargs.get("filter_by_keys", {}).copy()
     92     bk["filter_by_keys"]["paramId"] = param_id
---> 93     datasets.extend(raw_open_datasets(path, bk, **kwargs))
     94 return datasets

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_store.py:66, in raw_open_datasets(path, backend_kwargs, **kwargs)
     64 datasets = []
     65 try:
---> 66     datasets.append(open_dataset(path, backend_kwargs=backend_kwargs, **kwargs))
     67 except DatasetBuildError as ex:
     68     fbks.extend(ex.args[2])

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_store.py:39, in open_dataset(path, **kwargs)
     37     raise ValueError("only engine=='cfgrib' is supported")
     38 kwargs["engine"] = "cfgrib"
---> 39 return xr.open_dataset(path, **kwargs)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/xarray/backends/api.py:573, in open_dataset(filename_or_obj, engine, chunks, cache, decode_cf, mask_and_scale, decode_times, decode_timedelta, use_cftime, concat_characters, decode_coords, drop_variables, inline_array, chunked_array_type, from_array_kwargs, backend_kwargs, **kwargs)
    561 decoders = _resolve_decoders_kwargs(
    562     decode_cf,
    563     open_backend_dataset_parameters=backend.open_dataset_parameters,
   (...)
    569     decode_coords=decode_coords,
    570 )
    572 overwrite_encoded_chunks = kwargs.pop("overwrite_encoded_chunks", None)
--> 573 backend_ds = backend.open_dataset(
    574     filename_or_obj,
    575     drop_variables=drop_variables,
    576     **decoders,
    577     **kwargs,
    578 )
    579 ds = _dataset_from_backend_dataset(
    580     backend_ds,
    581     filename_or_obj,
   (...)
    591     **kwargs,
    592 )
    593 return ds

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_plugin.py:109, in CfGribBackend.open_dataset(self, filename_or_obj, mask_and_scale, decode_times, concat_characters, decode_coords, drop_variables, use_cftime, decode_timedelta, lock, indexpath, filter_by_keys, read_keys, encode_cf, squeeze, time_dims, errors, extra_coords, cache_geo_coords)
     87 def open_dataset(
     88     self,
     89     filename_or_obj: T.Union[str, abc.MappingFieldset[T.Any, abc.Field]],
   (...)
    107     cache_geo_coords: bool = True,
    108 ) -> xr.Dataset:
--> 109     store = CfGribDataStore(
    110         filename_or_obj,
    111         indexpath=indexpath,
    112         filter_by_keys=filter_by_keys,
    113         read_keys=read_keys,
    114         encode_cf=encode_cf,
    115         squeeze=squeeze,
    116         time_dims=time_dims,
    117         lock=lock,
    118         errors=errors,
    119         extra_coords=extra_coords,
    120         cache_geo_coords=cache_geo_coords,
    121     )
    122     with xr.core.utils.close_on_error(store):
    123         vars, attrs = store.load()  # type: ignore

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/xarray_plugin.py:40, in CfGribDataStore.__init__(self, filename, lock, **backend_kwargs)
     38 else:
     39     opener = dataset.open_fieldset
---> 40 self.ds = opener(filename, **backend_kwargs)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/dataset.py:800, in open_file(path, errors, indexpath, filter_by_keys, read_keys, time_dims, extra_coords, **kwargs)
    797 index_keys = compute_index_keys(time_dims, extra_coords)
    798 index = open_fileindex(stream, indexpath, index_keys, filter_by_keys=filter_by_keys)
--> 800 return open_from_index(index, read_keys, time_dims, extra_coords, errors=errors, **kwargs)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/dataset.py:743, in open_from_index(index, read_keys, time_dims, extra_coords, **kwargs)
    736 def open_from_index(
    737     index: abc.Index[T.Any, abc.Field],
    738     read_keys: T.Sequence[str] = (),
   (...)
    741     **kwargs: T.Any,
    742 ) -> Dataset:
--> 743     dimensions, variables, attributes, encoding = build_dataset_components(
    744         index, read_keys=read_keys, time_dims=time_dims, extra_coords=extra_coords, **kwargs
    745     )
    746     return Dataset(dimensions, variables, attributes, encoding)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/dataset.py:673, in build_dataset_components(index, errors, encode_cf, squeeze, log, read_keys, time_dims, extra_coords, cache_geo_coords)
    671 var_index = index.subindex(paramId=param_id)
    672 try:
--> 673     dims, data_var, coord_vars = build_variable_components(
    674         var_index,
    675         encode_cf,
    676         filter_by_keys,
    677         errors=errors,
    678         squeeze=squeeze,
    679         read_keys=read_keys,
    680         time_dims=time_dims,
    681         extra_coords=extra_coords,
    682         cache_geo_coords=cache_geo_coords,
    683     )
    684 except DatasetBuildError as ex:
    685     # NOTE: When a variable has more than one value for an attribute we need to raise all
    686     #   the values in the file, not just the ones associated with that variable. See #54.
    687     key = ex.args[1]

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/dataset.py:543, in build_variable_components(index, encode_cf, filter_by_keys, log, errors, squeeze, read_keys, time_dims, extra_coords, cache_geo_coords)
    541         geo_coords = GEOCACHE[cache_key]
    542     else:
--> 543         geo_coords = build_geography_coordinates(index.first(), encode_cf, errors)
    544         GEOCACHE[cache_key] = geo_coords
    545 else:

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/dataset.py:414, in build_geography_coordinates(first, encode_cf, errors, log)
    410 geo_shape = (first["Ny"], first["Nx"])
    411 try:
    412     geo_coord_vars["latitude"] = Variable(
    413         dimensions=("y", "x"),
--> 414         data=np.array(first["latitudes"]).reshape(geo_shape),
    415         attributes=COORD_ATTRS["latitude"],
    416     )
    417     geo_coord_vars["longitude"] = Variable(
    418         dimensions=("y", "x"),
    419         data=np.array(first["longitudes"]).reshape(geo_shape),
    420         attributes=COORD_ATTRS["longitude"],
    421     )
    422 except KeyError:  # pragma: no cover

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/messages.py:246, in ComputedKeysAdapter.__getitem__(self, item)
    244     return getter(self)
    245 else:
--> 246     return self.context[item]

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/messages.py:168, in Message.__getitem__(self, item)
    166     raise ValueError("key type not supported %r" % key_type_text)
    167 key_type = KEY_TYPES[key_type_text]
--> 168 return self.message_get(key, key_type=key_type)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/cfgrib/messages.py:131, in Message.message_get(self, item, key_type, default)
    129 try:
    130     if eccodes.codes_get_size(self.codes_id, item) > 1:
--> 131         values = eccodes.codes_get_array(self.codes_id, item, key_type)
    132     else:
    133         values = [eccodes.codes_get(self.codes_id, item, key_type)]

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/gribapi/gribapi.py:2028, in grib_get_array(msgid, key, ktype)
   2026     result = grib_get_long_array(msgid, key)
   2027 elif ktype is float or ktype is np.float64:
-> 2028     result = grib_get_double_array(msgid, key)
   2029 elif ktype is np.float32:
   2030     result = grib_get_float_array(msgid, key)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/gribapi/gribapi.py:1196, in grib_get_double_array(msgid, key)
   1194 vals_p = ffi.cast("double *", arr.ctypes.data)
   1195 err = lib.grib_get_double_array(h, key.encode(ENC), vals_p, length_p)
-> 1196 GRIB_CHECK(err)
   1197 return arr

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/gribapi/gribapi.py:226, in GRIB_CHECK(errid)
    218 """
    219 Utility function checking the ecCodes error code and raising
    220 an error if that was set.
   (...)
    223 @exception CodesInternalError
    224 """
    225 if errid:
--> 226     errors.raise_grib_error(errid)

File ~/miniconda3/envs/herbie-dev/lib/python3.12/site-packages/gribapi/errors.py:381, in raise_grib_error(errid)
    377 def raise_grib_error(errid):
    378     """
    379     Raise the GribInternalError corresponding to ``errid``.
    380     """
--> 381     raise ERROR_MAP[errid](errid)

GeocalculusError: Problem with calculation of geographic attributes