[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GRIB to netCDF (fwd)
- Subject: Re: GRIB to netCDF (fwd)
- Date: Fri, 21 Feb 2003 17:15:48 -0700 (MST)
John, et al
I used the example grib file that was send to test the decoders packeage,
the bugs were very apparent. The bugs were fixed and I also update the
gribdump program to use the -g flag ( user params table ) and updated the
gribtonc and gribdump man pages. The table file that was sent had a
error, the name of a NetCDF variable name cannot start with a digit, so I
created another one. ie,
Grib;netCDF;long name ;units;comments
167 ;T_2meter ;2 metre temperature ;K ;
228 ;precep_total ;Total precipitation ;m ;
The ecmf.tbl and eecmf.cdl file are included as attachments.
There is a new decoders release with the fixes: decoders-2.4.3.tar.Z
%ftp www.unidata.ucar.edu
login as anonymous
% cd pub/decoders
% get decoders-2.4.3.tar.Z
There is more documentation on the decoders page at:
http://www.unidata.ucar.edu/packages/decoders
Robb...
>
> Date: Thu, 20 Feb 2003 10:45:58 -0500
> From: "John A. Dutton" <address@hidden>
> To: address@hidden
> cc: address@hidden, address@hidden
> Subject: GRIB to netCDF
>
> Hi Russ..
>
> It seems I have a flood of questions after years of silence...
>
> Thanks for your prompt reply on Monday. I got the SST data I needed
> via a direct compile and execution of a little program via gcc, but I
> still have not gotten the library to work in Code Warrior. I sent a
> message to Metrowerks...we'll see if I get an answer.
>
> New problem: We are encountering difficulties in trying to convert
> ECMWF GRIB files of ensemble seasonal forecasts to netCDF. The
> issue seems to turn on the fact that the Unidata gribtocdl utilities
> are using the NCEP GRIB
> parameter tables and that there are differences with ECMWF.
>
> Any information or assistance would be greatly appreciated.
>
> Please REPLY to ALL since Ben Hauger above is actually doing the work.
>
> Again, many thanks, John
> --
> John A. Dutton
> Professor of Meteorology and Dean Emeritus
> College of Earth and Mineral Sciences
> The Pennsylvania State University
> 814 865 1534
>
> ------- End of Forwarded Message
>
>
===============================================================================
Robb Kambic Unidata Program Center
Software Engineer III Univ. Corp for Atmospheric Research
address@hidden WWW: http://www.unidata.ucar.edu/
===============================================================================
Grib;netCDF;long name ;units;comments
167 ;T_2meter ;2 metre temperature ;K ;
228 ;precep_total ;Total precipitation ;m ;
netcdf WVL_ECMWF_SEAS_20030201_1_GB{
dimensions:
record = UNLIMITED ; // (reference time, forecast time)
lat = 91 ;
lon = 240 ;
datetime_len = 21 ;
nmodels = 2 ;
ngrids = 1 ;
nav = 1 ;
nav_len = 100 ;
variables:
double reftime(record) ; // reference time of the model
reftime:long_name = "reference time" ;
reftime:units = "hours since 1992-1-1" ;
double valtime(record) ; // forecast time ("valid" time)
valtime:long_name = "valid time" ;
valtime:units = "hours since 1992-1-1" ;
:record = "reftime, valtime" ; // "dimension attribute" -- means
// (reftime, valtime) uniquely
// determine record
char datetime(record, datetime_len) ; // derived from reftime
datetime:long_name = "reference date and time" ;
// units YYYY-MM-DD hh:mm:ssZ (ISO 8601)
float valtime_offset(record) ; // derived as valtime-reftime
valtime_offset:long_name = "hours from reference time" ;
valtime_offset:units = "hours" ;
// The following lat and lon coordinate variables are redundant,
// since the navigation variables provide the necessary information.
// The extra information is included here for human readability.
float lat(lat) ;
lat:long_name = "latitude" ;
lat:units = "degrees_north" ;
float lon(lon) ;
lon:long_name = "longitude" ;
lon:units = "degrees_east" ;
long model_id(nmodels) ;
model_id:long_name = "generating process ID number" ;
// navigation variables all use nav dimension
char nav_model(nav, nav_len) ; // navigation parameterization
nav_model:long_name = "navigation model name" ;
int grid_type_code(nav) ;
grid_type_code:long_name = "GRIB-1 GDS data representation type"
;
char grid_type(nav, nav_len) ;
grid_type:long_name = "GRIB-1 grid type" ;
char grid_name(nav, nav_len) ;
grid_name:long_name = "grid name" ;
int grid_center(nav) ;
grid_center:long_name = "GRIB-1 originating center ID" ;
int grid_number(nav, ngrids) ;
grid_number:long_name = "GRIB-1 catalogued grid numbers" ;
grid_number:_FillValue = -9999 ;
char i_dim(nav, nav_len) ;
i_dim:long_name = "longitude dimension name" ;
char j_dim(nav, nav_len) ;
j_dim:long_name = "latitude dimension name" ;
int Ni(nav) ;
Ni:long_name = "number of points along a latitude circle" ;
int Nj(nav) ;
Nj:long_name = "number of points along a longitude
circle" ;
float La1(nav) ;
La1:long_name = "latitude of first grid point" ;
La1:units = "degrees_north" ;
float Lo1(nav) ;
Lo1:long_name = "longitude of first grid point" ;
Lo1:units = "degrees_east" ;
float La2(nav) ;
La2:long_name = "latitude of last grid point" ;
La2:units = "degrees_north" ;
float Lo2(nav) ;
Lo2:long_name = "longitude of last grid point" ;
Lo2:units = "degrees_east" ;
float Di(nav) ;
Di:long_name = "Longitudinal direction increment" ;
Di:units = "degrees" ;
float Dj(nav) ;
Dj:long_name = "Latitudinal direction increment" ;
Dj:units = "degrees" ;
byte ResCompFlag(nav) ;
ResCompFlag:long_name = "resolution and component flags" ;
// end of navigation variables
float T_2meter_sfc(record,lat,lon) ;
T_2meter_sfc:long_name = "2 metre temperature" ;
T_2meter_sfc:units = "K" ;
T_2meter_sfc:_FillValue = -9999.f ;
T_2meter_sfc:navigation = "nav" ;
float precep_total_sfc(record,lat,lon) ;
precep_total_sfc:long_name = "Total precipitation" ;
precep_total_sfc:units = "m" ;
precep_total_sfc:_FillValue = -9999.f ;
precep_total_sfc:navigation = "nav" ;
// global attributes
:history = "2003-02-21 14:47:11 - created by gribtocdl 1.4 -
12.12.2002" ;
:title = "WVL_ECMWF_SEAS_20030201_1_GB" ;
:Conventions = "NUWG" ;
:version = 0.0 ;
data:
model_id = 199, 152 ;
// Navigation
nav_model = "GRIB1" ;
grid_type_code = 0 ;
grid_type = "Latitude/Longitude" ;
grid_name = " " ;
grid_center = 98 ;
grid_number = 255 ;
i_dim = "lon" ;
j_dim = "lat" ;
Ni = 240 ;
Nj = 91 ;
La1 = -60.000000 ;
Lo1 = 0.000000 ;
La2 = 75.000000 ;
Lo2 = 358.500000 ;
Di = 1.500000 ;
Dj = 1.500000 ;
ResCompFlag = 128 ;
lon = 0.00, 1.50, 3.00, 4.50, 6.00, 7.50, 9.00, 10.50,
12.00, 13.50, 15.00, 16.50, 18.00, 19.50, 21.00, 22.50,
24.00, 25.50, 27.00, 28.50, 30.00, 31.50, 33.00, 34.50,
36.00, 37.50, 39.00, 40.50, 42.00, 43.50, 45.00, 46.50,
48.00, 49.50, 51.00, 52.50, 54.00, 55.50, 57.00, 58.50,
60.00, 61.50, 63.00, 64.50, 66.00, 67.50, 69.00, 70.50,
72.00, 73.50, 75.00, 76.50, 78.00, 79.50, 81.00, 82.50,
84.00, 85.50, 87.00, 88.50, 90.00, 91.50, 93.00, 94.50,
96.00, 97.50, 99.00,100.50,102.00,103.50,105.00,106.50,
108.00,109.50,111.00,112.50,114.00,115.50,117.00,118.50,
120.00,121.50,123.00,124.50,126.00,127.50,129.00,130.50,
132.00,133.50,135.00,136.50,138.00,139.50,141.00,142.50,
144.00,145.50,147.00,148.50,150.00,151.50,153.00,154.50,
156.00,157.50,159.00,160.50,162.00,163.50,165.00,166.50,
168.00,169.50,171.00,172.50,174.00,175.50,177.00,178.50,
180.00,181.50,183.00,184.50,186.00,187.50,189.00,190.50,
192.00,193.50,195.00,196.50,198.00,199.50,201.00,202.50,
204.00,205.50,207.00,208.50,210.00,211.50,213.00,214.50,
216.00,217.50,219.00,220.50,222.00,223.50,225.00,226.50,
228.00,229.50,231.00,232.50,234.00,235.50,237.00,238.50,
240.00,241.50,243.00,244.50,246.00,247.50,249.00,250.50,
252.00,253.50,255.00,256.50,258.00,259.50,261.00,262.50,
264.00,265.50,267.00,268.50,270.00,271.50,273.00,274.50,
276.00,277.50,279.00,280.50,282.00,283.50,285.00,286.50,
288.00,289.50,291.00,292.50,294.00,295.50,297.00,298.50,
300.00,301.50,303.00,304.50,306.00,307.50,309.00,310.50,
312.00,313.50,315.00,316.50,318.00,319.50,321.00,322.50,
324.00,325.50,327.00,328.50,330.00,331.50,333.00,334.50,
336.00,337.50,339.00,340.50,342.00,343.50,345.00,346.50,
348.00,349.50,351.00,352.50,354.00,355.50,357.00,358.50 ;
lat =-60.00,-58.50,-57.00,-55.50,-54.00,-52.50,-51.00,-49.50,
-48.00,-46.50,-45.00,-43.50,-42.00,-40.50,-39.00,-37.50,
-36.00,-34.50,-33.00,-31.50,-30.00,-28.50,-27.00,-25.50,
-24.00,-22.50,-21.00,-19.50,-18.00,-16.50,-15.00,-13.50,
-12.00,-10.50, -9.00, -7.50, -6.00, -4.50, -3.00, -1.50,
0.00, 1.50, 3.00, 4.50, 6.00, 7.50, 9.00, 10.50,
12.00, 13.50, 15.00, 16.50, 18.00, 19.50, 21.00, 22.50,
24.00, 25.50, 27.00, 28.50, 30.00, 31.50, 33.00, 34.50,
36.00, 37.50, 39.00, 40.50, 42.00, 43.50, 45.00, 46.50,
48.00, 49.50, 51.00, 52.50, 54.00, 55.50, 57.00, 58.50,
60.00, 61.50, 63.00, 64.50, 66.00, 67.50, 69.00, 70.50,
72.00, 73.50, 75.00 ;
}