[gradsusr] lats4d grib convertion problem

A. S. irln at hotmail.com
Tue Aug 30 08:34:21 EDT 2011


Hello,
I'm having some problem with cropping and subsetting GRIB files.
I found lats4d script very useful for that, but there is some annoying error it makes - in the resulting GRIB file it writes the wrong variable names (while in the resulting CTL file they are correct).

For example, I'm taking the lfff00120000p GRIB file (attached, together with its CTL and IDX),
and it has 5 fields inside: fi, omega, relhum, t, u, v.
You can see it in the attached lfff00120000p.ctl file, as well as by running "wgrib lfff00120000p".
Then I'm trying to extract only 2 fields, e.g. fi and t, to reduce the domain size, and to dump the result into a new GRIB file.
To do that, I'm using the following command:






  
  


lats4d.sh -i lfff00120000p.ctl -o lfff00120000p_crop.grb -format grads_grib -lat 29 33.5 -lon 34 36 -vars fi t

This command generates 3 new files: lfff00120000p_crop.grb, lfff00120000p_crop.ctl and lfff00120000p_crop.gmp (attached as well).
The resulting GRIB file seems to be valid, and the CTL file looks absolutely fine!
But when I try to run "wgrib lfff00120000p_crop.grb", instead of fi & t, I see PRES & PRMSL variables!
My guess is, that the lats4d script is in some way unaware of the fact that the original GRIB file is encoded according to Offenbach (center code 78) GRIB table, but I don't know how to define it.

Any help would be highly appreciated!
Thanks!
Alon.


P. S. some aditional technical info, don't know if it's relevant:

lats4d Version 2.1.5

Grads v2.0.a9.oga.1

Ubuntu 10.04 x86_64
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0003.html 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: lfff00120000p.ctl
Url: http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0006.pl 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lfff00120000p.idx
Type: application/octet-stream
Size: 1474 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0012.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lfff00120000p
Type: application/octet-stream
Size: 2511960 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0013.obj 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: lfff00120000p_crop.ctl
Url: http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0007.pl 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lfff00120000p_crop.gmp
Type: application/octet-stream
Size: 514 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0014.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lfff00120000p_crop.grb
Type: application/octet-stream
Size: 98040 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20110830/c4acfcae/attachment-0015.obj 


More information about the gradsusr mailing list