[Thread Prev][Thread Next][Index]

[ferret_users] regridding problem - axis not compatable with itself?



We've run into a weird regridding problem where an axis appears incompatable with itself.
What's worse (for us) is that distilling the problem down to smaller example datasets (seems to) fix the problem.
So I'm not sure what we are doing wrong.  Any suggestions?


The error we get is:

 LISTing to file all_stations.cdf
 **TMAP ERR: error in line definition
             file coords dont match variable coords on axis ZSTATIONS

We are trying to get AIRT from files that contain single weather station data into a single file with the average AIRT from all stations, where the Z axis becomes the "station number".

Initial data grid:
   GRID GNS1
 name       axis              # pts   start                end
 XSTATS    X                    3 r   1                    3
 YSOURCE   Y                    4 r   1                    4
 normal    Z
 TIME      TIME             40542 r   01-JAN-1900 00:00    31-DEC-2010 00:00



Final data grid (note that the "YSOURCE" axis is removed (we want to average over this before putting in the final dataset) and there is a new "ZSTATIONS" axis to represent all of the weather stations we have.
  GRID (G006)
 name       axis              # pts   start                end
 XSTATS    X                    3 r   1                    3
 normal    Y
 
ZSTATIONS Z                  727 r   1                    727
 TIME      TIME             40542 r   01-JAN-1900 00:00    31-DEC-2010 00:00

To do this, we use the script (note the input and output datasets both are already created and the variable name in both cases is "AIRT"):


use "all_stations.cdf"           ! the final data set with all the stations
define grid/like=airt[d=1] gnew
let zeroz = k[g=gnew]*0          ! a variable with all zeros in the Z axis

use "station14.cdf"              ! the single station input data - in this case we want this data
                                 ! in the final dataset under "k=14"

use dummy.cdf                    ! a completely bogus dataset just used to allow us to define "AIRT" on it
let/d=3 airt = airt[d=2, j=1:4@ave] + zeroz

save/file="all_stations.cdf"/append/k=14 airt[d=3]


And this gets us the error:

LISTing to file all_stations.cdf
 **TMAP ERR: error in line definition
             file coords dont match variable coords on axis ZSTATIONS

Which seems weird because the ZSTATIONS axis is taken directly from the dataset we are saving into (via the ZEROZ variable and the GNEW grid definition).  Doing "SHOW GRID AIRT[D=3]" reveals no differences with the dataset's z axis.

When we pared this down to an example dataset with only 40 points in time (instead of 40000+) and only 10 points in z (instead of 727) it worked fine.  So is there a memory issue here?  The file size for "all_stations.cdf" is only ~ 400MB (the pared down files were tiny), so there is no 2GB limit issue.


Any thoughts?

Thanks for your help!


- Sim Larkin
USFS AirFire Team
larkin@xxxxxxxxx


[Thread Prev][Thread Next][Index]

Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement