HDF attribute extract [message #46800] |
Thu, 05 January 2006 06:50 |
Liberum
Messages: 48 Registered: September 2005
|
Member |
|
|
Hi everyone,
I would like to extract an attribute (satillite_id) from an hdf file
that is readable by IDL.
My attempt is as follows:
loc_id = H5F_OPEN(file)
s = H5A_OPEN_NAME(loc_id,"satellite_id")
with the following error:
H5A_OPEN_NAME: location is not valid for an attribute: (Object
ID:67108866, Object Name:"satellite_id")
Now when I parse the file and print the tag names with the commands:
res = H5_PARSE(file,/read_data)
print, res.satellite_id
print, tag_names(res)
I get:
{satellite_id text ATTRIBUTE noaa16 0 0 1
H5T_STRING 7 56}
_NAME
_ICONTYPE
_TYPE _FILE
_PATH
_COMMENT
OUTPUTVALUENAMELIST
PALETTE
REGION
CLOUDMASK
QUALITY_FLAG
REGION_1
TEST_FLAG
VERSION
DESCRIPTION
SATELLITE_ID
SEC_1970
ORBIT_NUMBER
This is the same structure viewed when using the HDF_browser where the
last five tags are seen as attributes. Now I cannot extract the data
located under these attributes. Can anyone render some much needed help
here? I have tried different combinations of the HA5 without success.
Sincerely,
Sheldon
|
|
|