2
$\begingroup$

I am having trouble interpreting the output of wgrib2. I was expecting this command to produce a set of four measurements: one for each corner of a box at the specified pressure level. Instead I got a large amount of data. I don't understand what I am looking at, and was hoping someone could tell me how to interpret it.

Here is a sample out from a grib2 file. It was produced with the following command:

wgrib2 test.grib2 -set_lev '850 mb' -undefine out-box 0:1 0:40 -match ':TMP:' -csv -

16:8032172"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39,180.817

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39,180.667

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39.25,180.787

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39.25,180.707

:d=2021101506:TMP:850 mb:4 hour fcst:

26:15798999"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39,198.943

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39,196.703

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39.25,199.273

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39.25,197.793

:d=2021101506:TMP:850 mb:4 hour fcst:

36:24377875"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39,202.97

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39,203.69

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1,39.25,202.98

"2021-10-15 06:00:00","2021-10-15 10:00:00","TMP","850 mb",1.25,39.25,203.12

$\endgroup$
2
$\begingroup$

What you are seeing is the netadata about one grib message, specifically the 850 mb level (as that is what you specified). Based on my guess, it looks like it is a narrow boxed subset, not the corners like you want.

Without knowing what dataset you are inquiring about, I can only guess. But from what I see, this is what I can tell.

  • The first column describes when the data was started.
  • The second column describes when the model is valid.
  • The third column describes, in shortened terms, the variable that the data represents (TMP=temperature).
  • The fourth column describes the height that the variable is valid for (850 mb).
  • The fifth column is either latitude or longitude.
  • The sixth column is either longitude or latitude (the one that it wasn't in #5)
  • The last column is the value at that gridpoint.

Generally, I use wgrib to just do a cursory glance at the metadata of a file. I usually use pygrib to look at the actual data.

$\endgroup$
1
  • $\begingroup$ The grid point is repeated, but has different values. Also each set of four measurements starts with nn:mmmmmmmm. I don't know what that number is $\endgroup$
    – Craeft
    Oct 17 at 18:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.