Errors when open more than 1 file

Eric Altshuler ela at COLA.IGES.ORG
Thu Aug 30 11:14:40 EDT 2007


I think a better solution is to do the following:

'd apcpsfc.1(t=1) + apcpsfc.2(t=1) + apcpsfc.3(t=1) + ...'

This ensures that the time is set correctly for each of your data files. If you do not specify t=1, then whatever time is currently set in the dimension environment will be used for all data files. In your case, this is OK for the first dataset but not for the others, since they correspond to later times. You opened the first dataset and the time in grads was set to 2007:8:31:18, which corresponds to t=1 for this dataset. But for data file 2, t=1 corresponds to 2007:9:1:0. To force grads to use this time for data file 2, you must specify t=1 in the variable specification: apcpsfc.2(t=1). Similarly for data file 3, etc.

Best regards,


Eric L. Altshuler
Assistant Research Scientist
Center for Ocean-Land-Atmosphere Studies
4041 Powder Mill Road, Suite 302
Calverton, MD 20705-3106
USA

E-mail: ela at cola.iges.org
Phone: (301) 902-1257
Fax: (301) 595-9793

----- Original Message -----
From: "Viviane Silva" <viviane_silva1 at YAHOO.COM>
To: GRADSUSR at LIST.CINECA.IT
Sent: Thursday, August 30, 2007 5:45:28 AM (GMT-0500) America/New_York
Subject: Re: Errors when open more than 1 file

Ivan, if your ctl files do not have the same time you
can have problems.

solutions:
1) use the same time for all the ctls (even though you
know they are not the same)
or
1) open 1 file, define a variable then close it. Do
the same with the other files. When defining a
variable, grads keeps it in the memory, so you can
make your sum at the end.

I hope it helps.
Viviane

--- Ivan Toman <ivtoman at INET.HR> wrote:

> Hi!
>
> Does anybody know what could cause these errors
> below. I calculating
> precipitation sum over forecasted period by opening
> all ctl files and
> summing like this
>
> 'd apcpsfc.1 + apcpsfc.2 + apcpsfc.3 +... '
>
> Unfortunately, very often get error like this:
>
> Data Request Error: Invalid grid coordinates
>   World coordinates convert to non-integer grid
> coordinates
>     Variable = apcpsfc.2  Dimension = 3
>   Error ocurred at column 1
> DISPLAY error:  Invalid expression
>   Expression = apcpsfc.2
>
>
> When I try to load files manually and look what
> happen, I found that
> problem should be somwhere here; please look:
>
>
> $ gradsc -b -l
>
> Grid Analysis and Display System (GrADS) Version
> 1.9b4
> Copyright (c) 1988-2005 by Brian Doty and IGES
> Center for Ocean-Land-Atmosphere Studies (COLA)
> Institute for Global Environment and Society (IGES)
> GrADS comes with ABSOLUTELY NO WARRANTY
> See file COPYRIGHT for more information
>
> Config: v1.9b4 32-bit little-endian readline lats
> athena im/image-output
> printim
>
> Issue 'q config' command for more information.
>
> GX Package Initialization: Size = 11 8.5
> Running in Batch mode
> ga-> open
> data/input/gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1.ctl
> Scanning description file:
> data/input/gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1.ctl
> Data file
> data/input/gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1 is
> open as file 1
> LON set to -7 30
> LAT set to 33 60
> LEV set to 1000 1000
> Time values set: 2007:8:31:18 2007:8:31:18
> ga-> open
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
> Scanning description file:
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
> Data file
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1 is
> open as file 2
> ga-> q files
> File 1 : gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1
>   Descriptor:
> data/input/gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1.ctl
>   Binary:
> data/input/gfs.t00z.pgrb2f42.noaa_g2_rc_ci.grib1
> File 2 : gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1
>   Descriptor:
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
>   Binary:
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1
> ga-> d apcpsfc.1
> Contouring: 0 to 24 interval 2
> ga-> d apcpsfc.2
> Data Request Error: Invalid grid coordinates
>   World coordinates convert to non-integer grid
> coordinates
>     Variable = apcpsfc.2  Dimension = 3
>   Error ocurred at column 1
> DISPLAY error:  Invalid expression
>   Expression = apcpsfc.2
> ga->
>
>
>
> But, it is not problem with
> gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
> file, I think. Because of:
>
>
> $ gradsc -b -l
>
> Grid Analysis and Display System (GrADS) Version
> 1.9b4
> Copyright (c) 1988-2005 by Brian Doty and IGES
> Center for Ocean-Land-Atmosphere Studies (COLA)
> Institute for Global Environment and Society (IGES)
> GrADS comes with ABSOLUTELY NO WARRANTY
> See file COPYRIGHT for more information
>
> Config: v1.9b4 32-bit little-endian readline lats
> athena im/image-output
> printim
>
> Issue 'q config' command for more information.
>
> GX Package Initialization: Size = 11 8.5
> Running in Batch mode
> ga-> open
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
> Scanning description file:
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1.ctl
> Data file
> data/input/gfs.t00z.pgrb2f48.noaa_g2_rc_ci.grib1 is
> open as file 1
> LON set to -7 30
> LAT set to 33 60
> LEV set to 1000 1000
> Time values set: 2007:9:1:0 2007:9:1:0
> ga-> d apcpsfc
> Contouring: 0 to 11 interval 1
> ga->
>
>
> Can anybody help please. Thank you.
>




____________________________________________________________________________________
Moody friends. Drama queens. Your life? Nope! - their life, your story. Play Sims Stories at Yahoo! Games.
http://sims.yahoo.com/



More information about the gradsusr mailing list