HDF files
Jennifer Adams
jma at COLA.IGES.ORG
Fri Feb 4 10:14:06 EST 2005
Andrea,
Try this 'dtype hdfsds' descriptor file with the 'open' command:
DSET ^CER_ES4_Aqua-FM3_Edition2_024024.200207
DTYPE hdfsds
TITLE This is only a test
UNDEF 3.4028235e+38 _FillValue
XDEF 144 LINEAR -180.0 2.5
YDEF 72 LINEAR -90.0 2.5
ZDEF 1 LEVELS 1000
TDEF 1 LINEAR 0Z01JUL2002 1dy
VARS 5
Solar_incidence=>solin 0 y,x Incident Radiation
Net_radiant_flux=>netflux 0 y,x Net radiation
Longwave_flux=>lwflux 0 y,x Longwave flux
Shortwave_flux=>swflux 0 y,x Shortwave flux
Albedo=>albedo 0 y,x Albedo
ENDVARS
In the dump file you sent in your original email, there was a second
listing for the variable "Shortwave flux" that also varied in a time
dimension -- can't imagine how you got an HDF file with two variables
of the same name with different shapes, but ... if you want that
instead change the tdef size to 31 instead of 1 and change y,x in that
variable's units declaration to "t,y,x" instead of "y,x" .
Jennifer
On Feb 3, 2005, at 6:33 PM, Andreea Ira wrote:
> Oh i am sorry, of course ...The error now is this:
>
>
>
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> udunits(3): syntax error:
> 1 = data available, 127 = no data available
> ^
> Alleged lon dimension (from YDEF) is not an SDF
> dimension. Cannot continue.
> Lon dimension name is:
> 2_5_deg__regional_colat__zones
> .
> Alleged lat dimension (from XDEF) is not an SDF
> dimension. Cannot continue.
> Lat dimension name is:
> 2_5_deg__regional_long__zones
> .
> Data file CER_ES4_Aqua-FM3_Edition2_024024.200207 was
> not successfully opened & parsed.
>
> Thank you again,
>
> Andreea
>
>
>
>
>
>
>
>>>>> From: Andreea Ira <andreea_ira at YAHOO.COM>
>>>>>
>>>>> Dear all,
>>>>>
>>>>> I am having some troubles in completing the
>> task
>>>> of
>>>>> reading and displaying data in hdf format
>> using
>>>> GrADS
>>>>> and I would appreciate your assistance.
>>>>>
>>>>> Since according to the directions to read and
>>>> display
>>>>> the data in question, I need to create a .ddf
>>>> file, I
>>>>> did so using the information that I can obtain
>>>> from a
>>>>> dump (created using hdf binaries and following
>> the
>>>>> from the README file).
>>>>>
>>>>> 1. I include here the contents of the dump
>> file:
>>>>>
>>>>> dimensions:
>>>>> 2_5_deg__regional_colat__zones = 72 ;
>>>>> 2_5_deg__regional_long__zones = 144 ;
>>>>> days = 31 ;
>>>>> hours = 24 ;
>>>>> 5_0_deg__regional_colat__zones = 36 ;
>>>>> 5_0_deg__regional_long__zones = 72 ;
>>>>> 10_0_deg__regional_colat__zones = 18 ;
>>>>> 10_0_deg__regional_long__zones = 36 ;
>>>>> 2_5_deg__zonal_colat__zones = 72 ;
>>>>> 5_0_deg__zonal_colat__zones = 36 ;
>>>>> 10_0_deg__zonal_colat__zones = 18 ;
>>>>> 2_5_deg__global_zone = 1 ;
>>>>> 5_0_deg__global_zone = 1 ;
>>>>> 10_0_deg__global_zone = 1 ;
>>>>>
>>>>> variables:
>>>>> float
>>>>>
>> Solar_incidence(2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>> Solar_incidence:_FillValue =
>>>>> 3.4028235e+38f ;
>>>>> Solar_incidence:valid_range =
>> 0.f,
>>>>> 500000.f ;
>>>>> Solar_incidence:long_name =
>> "2.5
>>>>> Degree Regional, Monthly (Day), Total-sky
>>>> Averages" ;
>>>>> Solar_incidence:units = "Watt
>>>> hours
>>>>> per square meter" ;
>>>>> float
>>>>>
>> Net_radiant_flux(2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>> Net_radiant_flux:_FillValue =
>>>>> 3.4028235e+38f ;
>>>>> Net_radiant_flux:valid_range =
>>>> -200.f,
>>>>> 200.f ;
>>>>> Net_radiant_flux:long_name =
>> "2.5
>>>>> Degree Regional, Monthly (Day), Total-sky
>>>> Averages" ;
>>>>> Net_radiant_flux:units =
>> "Watts
>>>> per
>>>>> square meter" ;
>>>>> float
>>>>> Longwave_flux(2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>> Longwave_flux:_FillValue =
>>>>> 3.4028235e+38f ;
>>>>> Longwave_flux:valid_range =
>> 50.f,
>>>>> 450.f ;
>>>>> Longwave_flux:long_name = "2.5
>>>> Degree
>>>>> Regional, Monthly (Day), Total-sky Averages" ;
>>>>> Longwave_flux:units = "Watts
>> per
>>>>> square meter" ;
>>>>> float
>>>>> Shortwave_flux(2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>> Shortwave_flux:_FillValue =
>>>>> 3.4028235e+38f ;
>>>>> Shortwave_flux:valid_range =
>> 0.f,
>>>>> 1400.f ;
>>>>> Shortwave_flux:long_name =
>> "2.5
>>>> Degree
>>>>> Regional, Monthly (Day), Total-sky Averages" ;
>>>>> Shortwave_flux:units = "Watts
>> per
>>>>> square meter" ;
>>>>> float
>>>> Albedo(2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>> Longwave_flux:units = "Watts per square meter"
>> ;
>>>>> byte
>>>> Number_of_hours_of_longwave_flux(days,
>>>>> 2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>>
>>>>> Number_of_hours_of_longwave_flux:valid_range =
>>>> '\0',
>>>>> '\30' ;
>>>>>
>>>>> Number_of_hours_of_longwave_flux:_FillValue =
>>>> '\177' ;
>>>>>
>>>>> Number_of_hours_of_longwave_flux:long_name =
>> "2.5
>>>>> Degree Regional, Daily, Total-sky Averages" ;
>>>>>
>>>> Number_of_hours_of_longwave_flux:units
>>>>> = "hours" ;
>>>>> float Shortwave_flux(days,
>>>>> 2_5_deg__regional_colat__zones,
>>>>> 2_5_deg__regional_long__zones) ;
>>>>>
>>>>> 2. I used information from here to create a
>> .ddf
>>>> file
>>>>> that will then be used with the GrADS xdfopen
>> file
>>>>> command. I include the file here (I followed
>> the
>>>>> example provided by the GrADS web site that
>>>> describe
>>>>> this):
>>>>>
>>>>> DSET ^CER_ES4_Aqua-FM3_Edition2_024024.200207
>>>>> TITLE This is only a test
>>>>> UNDEF 1.0E15
>>>>> XDEF 2_5_deg__regional_long__zones 144 LINEAR
>>>> -180.0
>>>>> 2.5
>>>>> YDEF 2_5_deg__regional_colat__zones 91 LINEAR
>>>> -90.0
>>>>> 2.0
>>>>> TDEF days 31 LINEAR 0Z01JUL2002 1MO
>>>>> ZDEF 1 LEVELS 1000
>>>>> VARS 5
>>>>> Solar_incidence=>solin 0 99 Incident Radiation
>>>>> Net_radiant_flux=>netflux 0 99 Net radiation
>>>>> Longwave_flux=>lwflux 0 99 Longwave flux
>>>>> Shortwave_flux=>swflux 0 99 Shortwave flux
>>>>> Albedo=>albedo 0 99 Albedo
>>>>> ENDVARS
>>>>>
>>
> === message truncated ===
>
>
>
>
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail - Find what you need with new enhanced search.
> http://info.mail.yahoo.com/mail_250
>
>
--
Jennifer Miletta Adams
IGES/COLA
4041 Powder Mill Rd., Suite 302
Calverton, MD 20705
More information about the gradsusr
mailing list