Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

You want to dump a specific section of a GRIB message rather than all its sections.

Step-by-step guide

...

To find out the sections and their contents of each edition, see here:

 For example let's look at the Grid Description Section of a GRIB 1 file. This would be Section 2 for edition 1 so we use the key "section_2":

Code Block
% grib_dump -O -p section_2 data/regular_latlon_surface.grib1
======================   SECTION_2 ( length=32, padding=0 )    ======================
1-3       section2Length = 32
4         numberOfVerticalCoordinateValues = 0
5         pvlLocation = 255
6         dataRepresentationType = 0 [Latitude/Longitude Grid (grib1/6.table) ]
7-8       Ni = 16
9-10      Nj = 31
11-13     latitudeOfFirstGridPoint = 60000
14-16     longitudeOfFirstGridPoint = 0
17        resolutionAndComponentFlags = 128 [10000000]
18-20     latitudeOfLastGridPoint = 0
21-23     longitudeOfLastGridPoint = 30000
24-25     iDirectionIncrement = 2000
26-27     jDirectionIncrement = 2000
...

...