1GRIB_COMPARE(1)                  User Commands                 GRIB_COMPARE(1)
2
3
4

NAME

6       grib_compare - manual page for grib_compare
7

DESCRIPTION

9       NAME    grib_compare
10
11       DESCRIPTION
12
13              Compare  GRIB  messages contained in two files.  If some differ‐
14              ences are found  it  fails  returning  an  error  code.   Float‐
15              ing-point values are compared exactly by default, different tol‐
16              erances can be defined (see -P -A -R).  Default behaviour: abso‐
17              lute error=0, bit-by-bit compare, same order in files.
18
19       USAGE
20
21              grib_compare [options] grib_file1 grib_file2
22
23       OPTIONS
24
25       -r     Compare  files  in which the messages are not in the same order.
26              This option is time expensive.
27
28       -b key,key,...
29
30              All the keys  in  this  list  are  skipped  in  the  comparison.
31              Bit-by-bit compare on.
32
33       -e     Edition  independent compare. It is used to compare GRIB edition
34              1 and 2.
35
36       -2     Enable two-way comparison.
37
38       -c key[:i|d|s|n],key[:i|d|s|n],...
39
40              Only the listed keys or namespaces (:n) are  compared.  The  op‐
41              tional  letter  after the colon is used to force the type in the
42              comparison: i->integer, d->float, s->string, n->namespace.   See
43              -a option. Incompatible with -H option.
44
45       -S start
46              First field to be processed.
47
48       -E end Last field to be processed.
49
50       -a       -c option modifier. The keys listed with the option -c will be
51              added to the list of keys compared without -c.
52
53       -H     Compare only message headers (everything except  data  and  bit‐
54              map). Bit-by-bit compare on. Incompatible with -c option.
55
56       -R key1=relative_error1,key2=relative_error2,...
57
58              Compare floating-point values using the relative error as toler‐
59              ance.  key1=relative_error1 will compare key1 using relative_er‐
60              ror1.   all=relative_error  will  compare all the floating-point
61              keys using relative_error. Default all=0.
62
63       -A absolute error
64
65              Compare floating-point values using the absolute error as toler‐
66              ance.  Default is absolute error=0
67
68       -P     Compare data values using the packing error as tolerance.
69
70       -T factor
71              Compare  data  values  using  factor multiplied by the tolerance
72              specified in options -P -R -A.
73
74       -w key[:{s|d|i}]{=|!=}value,key[:{s|d|i}]{=|!=}value,...
75
76              Where clause.  Messages are processed only if they match all the
77              key/value  constraints.  A valid constraint is of type key=value
78              or key!=value.  For each key a string (key:s), a double  (key:d)
79              or  an  integer  (key:i)  type can be specified. Default type is
80              string.  In the value you can also use the forward-slash charac‐
81              ter  '/' to specify an OR condition (i.e. a logical disjunction)
82              Note: only one -w clause is allowed.
83
84       -f     Force. Force the execution not to fail on error.
85
86       -V     Version.
87
88       -7     Does not fail when the message has wrong length
89
90       -v     Verbose.
91
92       NAME    grib_compare
93
94       DESCRIPTION
95
96              Compare GRIB messages contained in two files.  If  some  differ‐
97              ences  are  found  it  fails  returning  an  error code.  Float‐
98              ing-point values are compared exactly by default, different tol‐
99              erances can be defined (see -P -A -R).  Default behaviour: abso‐
100              lute error=0, bit-by-bit compare, same order in files.
101
102       USAGE
103
104              grib_compare [options] grib_file1 grib_file2
105
106       OPTIONS
107
108       -r     Compare files in which the messages are not in the  same  order.
109              This option is time expensive.
110
111       -b key,key,...
112
113              All  the  keys  in  this  list  are  skipped  in the comparison.
114              Bit-by-bit compare on.
115
116       -e     Edition independent compare. It is used to compare GRIB  edition
117              1 and 2.
118
119       -2     Enable two-way comparison.
120
121       -c key[:i|d|s|n],key[:i|d|s|n],...
122
123              Only  the  listed  keys or namespaces (:n) are compared. The op‐
124              tional letter after the colon is used to force the type  in  the
125              comparison:  i->integer, d->float, s->string, n->namespace.  See
126              -a option. Incompatible with -H option.
127
128       -S start
129              First field to be processed.
130
131       -E end Last field to be processed.
132
133       -a      -c option modifier. The keys listed with the option -c will  be
134              added to the list of keys compared without -c.
135
136       -H     Compare  only  message  headers (everything except data and bit‐
137              map). Bit-by-bit compare on. Incompatible with -c option.
138
139       -R key1=relative_error1,key2=relative_error2,...
140
141              Compare floating-point values using the relative error as toler‐
142              ance.  key1=relative_error1 will compare key1 using relative_er‐
143              ror1.  all=relative_error will compare  all  the  floating-point
144              keys using relative_error. Default all=0.
145
146       -A absolute error
147
148              Compare floating-point values using the absolute error as toler‐
149              ance.  Default is absolute error=0
150
151       -P     Compare data values using the packing error as tolerance.
152
153       -T factor
154              Compare data values using factor  multiplied  by  the  tolerance
155              specified in options -P -R -A.
156
157       -w key[:{s|d|i}]{=|!=}value,key[:{s|d|i}]{=|!=}value,...
158
159              Where clause.  Messages are processed only if they match all the
160              key/value constraints.  A valid constraint is of type  key=value
161              or  key!=value.  For each key a string (key:s), a double (key:d)
162              or an integer (key:i) type can be  specified.  Default  type  is
163              string.  In the value you can also use the forward-slash charac‐
164              ter '/' to specify an OR condition (i.e. a logical  disjunction)
165              Note: only one -w clause is allowed.
166
167       -f     Force. Force the execution not to fail on error.
168
169       -V     Version.
170
171       -7     Does not fail when the message has wrong length
172
173       -v     Verbose.
174
175
176
177grib_compare                     December 2022                 GRIB_COMPARE(1)
Impressum