Versions Compared

Key

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

...

Excerpt
hiddentrue

For example if you are interested in comparing the differences between the data values of two GRIB files, you can blacklist blocklist (exclude) certain keys which show up in the comparison e.g

For example if you are interested in comparing the differences between the data values of two GRIB files, you can blacklist blocklist (exclude) certain keys which show up in the comparison e.g.,

Code Block
% grib_compare file1.grib1 file2.grib1
long [binaryScaleFactor]: [-4] != [-11]
double [referenceValue]: [-1.21940258789062500000e+03] != [-1.26698560714721679688e+01]
        absolute diff. = 1206.73, relative diff. = 0.98961
        tolerance=0.000244141
long [N]: [2694] != [1958]
long [P]: [1385] != [712]
double [values]: 4139 out of 4160 different
 max absolute diff. = 9.1467330932617188e+01, relative diff. = 0.319192
        max diff. element 0: 1.95091751098632812500e+02 2.86559082031250000000e+02
        tolerance=0.0000000000000000e+00 packingError: [0.0313721] [0.000244617]

% grib_compare -bbinaryScaleFactor,referenceValue,N,P file1.grib1 file2.grib1

You can also include what you want to compare rather than exclude with a blacklistblocklist. E.g.

Code Block
% grib_compare -c values file1.grib1 file2.grib1

Now only the values array is compared.  Now you can use the -P, -R and -A flags to control the tolerances.

Content by Label
showLabelsfalse
max5
spaces~usa
showSpacefalse
sortmodified
reversetrue
typepage
cqllabel = in ("kb-information-article","eccodes-faqs","grib_compare","keys","grib") and type = "page" and space = "UDOC"
labelskb-how-to-article

...