using template control file for grib files

Dan Leins theedge981 at GMAIL.COM
Wed Apr 2 10:42:43 EDT 2008


List,

I am having a bit of trouble setting up and using a template control file to
display grib formatted model data. I've never used a template before (I've
always used an individual control file for each hour's worth of forecast
data) so this question may seem rather trivial. A similar question was asked
a few months ago, but I didn't see a response that helped me out.

I've got 36 hours worth of grib1 model data and would like to use a template
instead of opening 37 different control files.  The naming convention of the
files is as follows:

YYMMDDCC_arw_d01.GrbFHHHMM

(pretty straightforward, but YYMMDD is the 2 digit year/month/day of the run
and CC is the 2 digit cycle of the run (i.e. 00, 06, 12, 18). YYMMDDCC stays
constant for each file. Of course HHHMM is a 3 digit forecast hour and 2
digit minute which always happens to be 00).


I've set up my control file as follows: (I hard-coded the 06 cycle time into
the template for now)

dset /usr/local/archive/grib_out/%y2%m2%d206_arw_d02.GrbF%f300
index indexfile
OPTIONS template

When I run gribmap -v -i template.ctl, the 00 forecast hour works
fine. As a matter of fact, the first 17 files work just fine. However
hours 18 to 36 fail because it's
advancing DD by 1.

Here's the output from gribmap...

gribmap:  Opening GRIB file
/usr/local/archive/grib_out/08040306_arw_d02.GrbF01800
Warning: Could not open GRIB file:
/usr/local/archive/grib_out/08040306_arw_d02.GrbF01800
gribmap:  Opening GRIB file
/usr/local/archive/grib_out/08040306_arw_d02.GrbF01900
Warning: Could not open GRIB file:
/usr/local/archive/grib_out/08040306_arw_d02.GrbF01900


It should be looking for
/usr/local/archive/grib_out/08040206_arw_d02.GrbF01800 and GrbF01900
respectively.

Any idea how I can stop it from advancing the date? As a workaround, I tried
using CHSUB 1 37 08040206 and putting %ch in place of the %y2%m2%d206 and
that solved the problem.

My question though is how can I stop it from advancing the date incorrectly
and if that can't be done, is there any way I can pass in the CHSUB section
as an argument when I open the template control file? My template control
file works fine, as long as I go in ahead of time and manually change CHSUB
to the run I'm interested in. That's not really ideal though....

Any help would be greatly appreciated!

Thanks!
Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20080402/4f7bd2e7/attachment.html 


More information about the gradsusr mailing list