[gradsusr] Different output values from Grads and wgrib2

Huddleston, John Huddleston at cira.colostate.edu
Mon Oct 17 10:26:56 EDT 2011


Hi Bo

It looks like there is a problem with the data file itself. GrADS has a utility grib2scan. If you run it against the data file it shows there is a problem. Here is an excerpt of the output.

Record 5 starts at 241138 of length 48209
  Discipline=0 (Meteorological)
  Reference Time = 2010-05-08 06:00:00  Start of Forecast
 Field 1
  GDT=0 (Lat/Lon) nx*ny=65160
   XDEF 360 linear 0.000000 1.000000
   YDEF 181 linear 90.000000 1.000000
  PDT=0,  0 Hour Forecast,  Valid Time = 2010-05-08 06:00
   Parameter: disc,cat,num = 0,2,10
   Level: ltype,lval = 100,1000   (sf,sval = 0 1000)
  DRT=40 (Grid Point Data - JPEG2000 Compression) (Lossless)
 Field 2
Header error, section 4 expected, found 230

The utility grib_dump also shows there is an error in the message length.

John

-----Original Message-----
From: gradsusr-bounces at gradsusr.org [mailto:gradsusr-bounces at gradsusr.org] On Behalf Of Bo Zhang
Sent: Sunday, October 16, 2011 10:13 AM
To: GrADS Users Forum
Subject: Re: [gradsusr] Different output values from Grads and wgrib2

Hi John,

You should be able to find it here.
http://tooreturn.com/wordpress/wp-content/Temp/

Thanks for your help so far. 

Bo Zhang
Dow 824,Civil and Environmental Engineering Michigan Tech University
1400 Townsends Drive. 
Houghton, MI, 49931

----- Original Message -----
From: "John Huddleston" <Huddleston at cira.colostate.edu>
To: "GrADS Users Forum" <gradsusr at gradsusr.org>
Sent: Sunday, October 16, 2011 8:26:10 AM (GMT-0500) Auto-Detected
Subject: Re: [gradsusr] Different output values from Grads and wgrib2

Hi Bo

Can you post your /home/campus03/bzhang3/Grads/fnl_20100508_06_00 on a website to download?

John

________________________________________
From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] On Behalf Of Bo Zhang [bzhang3 at mtu.edu]
Sent: Friday, October 14, 2011 1:47 PM
To: GrADS Users Forum
Subject: Re: [gradsusr] Different output values from Grads and wgrib2

Hi John,

I just started using Grads. I used g2ctl and gribmap to generate the ctl and index file, which are all attached. The weird thing to me is, I tried out several fnl and gfs data files, I have this bump at 30mb for every of those.

Bo Zhang
Dow 824,Civil and Environmental Engineering Michigan Tech University
1400 Townsends Drive.
Houghton, MI, 49931

Bo Zhang
Dow 824,Civil and Environmental Engineering Michigan Tech University
1400 Townsends Drive.
Houghton, MI, 49931

----- Original Message -----
From: "John Huddleston" <Huddleston at cira.colostate.edu>
To: "GrADS Users Forum" <gradsusr at gradsusr.org>
Sent: Friday, October 14, 2011 8:37:07 AM (GMT-0500) Auto-Detected
Subject: Re: [gradsusr] Different output values from Grads and wgrib2

Hi Bo

Attached is tmp at 30mb displayed in GrADS for the date time you use.  There is no 300.

What is your GrADS control file?

John Huddleston

________________________________________
From: gradsusr-bounces at gradsusr.org [gradsusr-bounces at gradsusr.org] On Behalf Of Bo Zhang [bzhang3 at mtu.edu]
Sent: Thursday, October 13, 2011 6:59 PM
To: gradsusr at gradsusr.org
Subject: [gradsusr] Different output values from Grads and wgrib2

Hi great grads users,

I was trying to plot temperature profile with Grads and just found different results from Grads and wgrib2. I am sure that I am reading the same data file. I got the attached profile plot from Grads and the following result from wgrib2 at the same position. One thing should be noticed is that Gtads and wgrib2 number the grid box in different ways. The (0, 0) grid box in Grads (-180:179, -90,90) should be (181,91) in a (0:360, 0,181) system. The bump at 30 mb in the figure exists for any lon-lat position I try, which is wired to me. The other values are also slightly various.

$ ./wgrib2 ***/Grads/fnl_20100508_06_00 -s -ij 181 91 | grep :TMP
3:120296:d=2010050806:TMP:10 mb:anl::val=240.5
8:393851:d=2010050806:TMP:20 mb:anl::val=220.9
13:666758:d=2010050806:TMP:30 mb:anl::val=215.9
18:961202:d=2010050806:TMP:50 mb:anl::val=204.1
23:1271647:d=2010050806:TMP:70 mb:anl::val=193.5
28:1588656:d=2010050806:TMP:100 mb:anl::val=190.7
36:1997953:d=2010050806:TMP:150 mb:anl::val=207.4
43:2356630:d=2010050806:TMP:200 mb:anl::val=223.1
50:2732191:d=2010050806:TMP:250 mb:anl::val=235.9
57:3106953:d=2010050806:TMP:300 mb:anl::val=244.9
64:3498361:d=2010050806:TMP:350 mb:anl::val=254.5
71:3898258:d=2010050806:TMP:400 mb:anl::val=260.8
78:4302495:d=2010050806:TMP:450 mb:anl::val=266.3
85:4751606:d=2010050806:TMP:500 mb:anl::val=270.9
92:5208947:d=2010050806:TMP:550 mb:anl::val=274.5
99:5689297:d=2010050806:TMP:600 mb:anl::val=277.9
106:6172793:d=2010050806:TMP:650 mb:anl::val=282.1
113:6640256:d=2010050806:TMP:700 mb:anl::val=284.2
120:7112632:d=2010050806:TMP:750 mb:anl::val=286
127:7585314:d=2010050806:TMP:800 mb:anl::val=289.1
134:8055101:d=2010050806:TMP:850 mb:anl::val=291.8
141:8545830:d=2010050806:TMP:900 mb:anl::val=294.6
148:9033256:d=2010050806:TMP:925 mb:anl::val=296.2
155:9515141:d=2010050806:TMP:950 mb:anl::val=297.4
162:9986444:d=2010050806:TMP:975 mb:anl::val=299.5
169:10444342:d=2010050806:TMP:1000 mb:anl::val=301.6


Bo Zhang
Dow 824,Civil and Environmental Engineering Michigan Tech University
1400 Townsends Drive.
Houghton, MI, 49931
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org
http://gradsusr.org/mailman/listinfo/gradsusr




More information about the gradsusr mailing list