Versions Compared

Key

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

...

Code Block
% grib_set -s setBitsPerValue=17 in.grib out.grib

or use the "repack" (-r) option with the "bitsPerValue" key:

Code Block
% grib_set -r -s bitsPerValue=17 in.grib out.grib

...

In these commands, we first decode the data values, then change the bitsPerValue key and then repack (i.e., encode those values back in).

It is advisable to check the field values after such a change, for example by printing and comparing the statistics before and after:

Code Block
% grib_ls -n statistics in.grib
% grib_ls -n statistics out.grib

Of course you can also use grib_compare.

Content by Label
showLabelsfalse
max5
spacesUDOC
showSpacefalse
sortmodified
reversetrue
typepage
excludeCurrenttrue
cqllabel = "grib" and label in ("encode","grib") and type = "page" and space = "UDOC"
labelsgrib

...