Thanks to visit codestin.com
Credit goes to github.com

Skip to content

No latitudes/longitudes provided by ecCodes for gridType #28

@alexamici

Description

@alexamici

cfgrib relies on the ECMWF ecCodes C-library for encoding and decoding the GRIB format, including everything related to the coordinate systems. GRIB files encoded in a gridType not supported by the installed ecCodes version will print the warning: No latitudes/longitudes provided by ecCodes for gridType.

The GRIB file will be opened but the geographic portion of the data will be represented by as single dimension without coordinate named values.

For example:

>>> cfgrib.open_dataset('../ST4.2018080204.01h')
No latitudes/longitudes provided by ecCodes for gridType = 'polar_stereographic'
<xarray.Dataset>
Dimensions:     (values: 987601)
Coordinates:
    time        datetime64[ns] ...
    step        timedelta64[ns] ...
    surface     int64 ...
    valid_time  datetime64[ns] ...
Dimensions without coordinates: values
Data variables:
    tp          (values) float32 ...
Attributes:
    GRIB_edition:            1
    GRIB_centre:             kwbc
    GRIB_centreDescription:  US National Weather Service - NCEP 
    GRIB_subCentre:          4
    history:                 GRIB to CDM+CF via cfgrib-0.9.../ecCodes-2.8...

The list of known supported gridTypes is:

  • latitude and longitude as dimension coordinates
    • regular_ll
    • regular_gg
  • xand y as dimensions and latitude and longitude as non-dimension coordinates
    • rotated_ll
    • rotated_gg
    • lambert
    • lambert_azimuthal_equal_area
    • albers
    • polar_stereographic (ecCodes > 2.9.0)
  • values as dimension and latitude and longitude as non-dimension coordinates
    • reduced_ll
    • reduced_gg
    • unstructured_grid

see http://xarray.pydata.org/en/stable/data-structures.html#coordinates for details on xarray naming conventions.

Initially noted in #27.

Metadata

Metadata

Assignees

No one assigned

    Labels

    won't fixThis will not be worked on

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions