[gdal-dev] Difficulties reading a ODIM HDF5 file

Frank Warmerdam warmerdam at pobox.com
Thu Mar 14 08:53:32 PDT 2013


Sjur,

Could you file a ticket on the metadata and projection issues, and
attach or point to the dataset?  I think these regressions deserve a
careful review and I don't want to lose the issue in ephemeral email.

Best regards,
Frank


On Thu, Mar 14, 2013 at 5:48 AM, Sjur Kolberg <Sjur.A.Kolberg at sintef.no> wrote:
>
> Hello again!
>
> Thanks for your help. I downloaded the pre-built GDAL binaries from Tamas Szekeres' www.gisinternals.com and managed to read the HDF5 file.
>
> Almost.
>
> And actually better with GDAL 1.7.3 than with GDAL 1.9.2, both downloaded prebuilt from www.gisinternals.com. 1.7.3 can read the projection info, 1.9.2 cannot.
>
> They also seem to handle metadata (and subdataset?) differently; 1.9.2 seem to attribute the first 7 metadata items to a dataset1, whereas 1.7.3 does not. 1.9.2 also finds the "Conventions" attribute.
>
> None of the two detects the what:nodata attribute.
>
> I can see that the corner coordinates are wrong, I'll discuss that with the provider.
>
> But does anyone see what causes 1.9.2 to miss the refsystem?
>
> Grateful for any clue. The attached file may be different from the one in the previous mail.
>
> Sjur :-)
>
>
>
> GDALINFO output from 1.9.2:, command window spawn from SDKShell.bat:
>
> Setting environment for using the GDAL and MapServer tools.
> Hiding the OCI plugin library.
> C:\Devel_VS2010\GDAL-1.9.2>gdalinfo norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000
> 039Z.hdf
> Driver: HDF5Image/HDF5 Dataset
> Files: norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000039Z.hdf
> Size is 480, 480
> Coordinate System is `'
> Metadata:
>   Conventions=ODIM_H5/V2_1
>   dataset1_what_gain=0.5
>   dataset1_what_nodata=255
>   dataset1_what_offset=-32
>   dataset1_what_prodpar=0.5
>   dataset1_what_product=PPI
>   dataset1_what_quantity=DBZH
>   dataset1_what_undetect=0
>   how_endepochs=1180656039
>   how_software=RAINBOW
>   how_startepochs=1180656009
>   how_system=GEMA
>   what_date=20070601
>   what_object=IMAGE
>   what_source=NOD:norsa
>   what_source_plc=PLC:Rissa
>   what_source_wmoid=WMO:00
>   what_time=000039
>   what_version=H5rad 2.1
>   where_height=620
>   where_lat=63.69
>   where_lat_sphere=63.536783
>   where_LL_lat=61.303028
>   where_LL_lon=5.70656
>   where_lon=10.204
>   where_lon_sphere=10.204
>   where_projdef=+proj=aeqd +lat_0=63.536783 +lon_0=10.204000 +R=6371000 +datum=W
> GS84
>   where_UR_lat=65.59814
>   where_UR_lon=15.411344
>   where_xscale=1000
>   where_xsize=480
>   where_yscale=1000
>   where_ysize=480
> Corner Coordinates:
> Upper Left  (    0.0,    0.0)
> Lower Left  (    0.0,  480.0)
> Upper Right (  480.0,    0.0)
> Lower Right (  480.0,  480.0)
> Center      (  240.0,  240.0)
> Band 1 Block=480x480 Type=Byte, ColorInterp=Undefined
>   Metadata:
>     dataset1_data1_data_CLASS=IMAGE
>     dataset1_data1_data_IMAGE_VERSION=1.2
>
> C:\Devel_VS2010\GDAL-1.9.2>
>
>
>
>
> GDALINFO output from 1.7.3:, command window spawn from SDKShell.bat:
>
> Setting environment for using the GDAL and MapServer tools.
> Hiding the OCI plugin library.
> C:\Devel_VS2010\GDAL-1.7.3>gdalinfo norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000
> 039Z.hdf
> Driver: HDF5Image/HDF5 Dataset
> Files: norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000039Z.hdf
> Size is 480, 480
> Coordinate System is:
> GEOGCS["WGS 84",
>     DATUM["WGS_1984",
>         SPHEROID["WGS 84",6378137,298.257223563,
>             AUTHORITY["EPSG","7030"]],
>         TOWGS84[0,0,0,0,0,0,0],
>         AUTHORITY["EPSG","6326"]],
>     PRIMEM["Greenwich",0,
>         AUTHORITY["EPSG","8901"]],
>     UNIT["degree",0.0174532925199433,
>         AUTHORITY["EPSG","9108"]],
>     AUTHORITY["EPSG","4326"]]
> Metadata:
>   what:product=PPI
>   what:prodpar=0.5
>   what:quantity=DBZH
>   what:gain=0.5
>   what:offset=-32
>   what:nodata=255
>   what:undetect=0
>   how:system=GEMA
>   how:software=RAINBOW
>   how:startepochs=1180656009
>   how:endepochs=1180656039
>   what:object=IMAGE
>   what:version=H5rad 2.1
>   what:date=20070601
>   what:time=000039
>   what:source=NOD:norsa
>   what:source_wmoid=WMO:00
>   what:source_plc=PLC:Rissa
>   where:LL_lat=61.303
>   where:LL_lon=5.70656
>   where:UR_lat=65.5981
>   where:UR_lon=15.4113
>   where:projdef=+proj=aeqd +lat_0=63.536783 +lon_0=10.204000 +R=6371000 +datum=W
> GS84
>   where:lat=63.69
>   where:lon=10.204
>   where:lat_sphere=63.5368
>   where:lon_sphere=10.204
>   where:height=620
>   where:xsize=480
>   where:ysize=480
>   where:xscale=1000
>   where:yscale=1000
> Corner Coordinates:
> Upper Left  (    0.0,    0.0)
> Lower Left  (    0.0,  480.0)
> Upper Right (  480.0,    0.0)
> Lower Right (  480.0,  480.0)
> Center      (  240.0,  240.0)
> Band 1 Block=480x480 Type=Byte, ColorInterp=Undefined
>   Metadata:
>     data:CLASS=IMAGE
>     data:IMAGE_VERSION=1.2
>
> C:\Devel_VS2010\GDAL-1.7.3>
>
>
>
> GDALINFO output from 1.7.3 on Linux at met.no, with h5ls: Version 1.8.7. This is equal to the result I get with GDAL 1.7.3 on Windows.
>
> christofferae at pc2752:~/src/prorad-clean/processing/prorad-process$ gdalinfo norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000039Z.hdf
> Driver: HDF5Image/HDF5 Dataset
> Files: norsa.ss.ppi-00.5-dbz.aeqd-1000.20070601T000039Z.hdf
> Size is 480, 480
> Coordinate System is:
> GEOGCS["WGS 84",
>     DATUM["WGS_1984",
>         SPHEROID["WGS 84",6378137,298.257223563,
>             AUTHORITY["EPSG","7030"]],
>         TOWGS84[0,0,0,0,0,0,0],
>         AUTHORITY["EPSG","6326"]],
>     PRIMEM["Greenwich",0,
>         AUTHORITY["EPSG","8901"]],
>     UNIT["degree",0.0174532925199433,
>         AUTHORITY["EPSG","9108"]],
>     AUTHORITY["EPSG","4326"]]
> Metadata:
>   what:product=PPI
>   what:prodpar=0.5
>   what:quantity=DBZH
>   what:gain=0.5
>   what:offset=-32
>   what:nodata=255
>   what:undetect=0
>   how:system=GEMA
>   how:software=RAINBOW
>   how:startepochs=1180656009
>   how:endepochs=1180656039
>   what:object=IMAGE
>   what:version=H5rad 2.1
>   what:date=20070601
>   what:time=000039
>   what:source=NOD:norsa
>   what:source_wmoid=WMO:00
>   what:source_plc=PLC:Rissa
>   where:LL_lat=61.303
>   where:LL_lon=5.70656
>   where:UR_lat=65.5981
>   where:UR_lon=15.4113
>   where:projdef=+proj=aeqd +lat_0=63.536783 +lon_0=10.204000 +R=6371000 +datum=WGS84
>   where:lat=63.69
>   where:lon=10.204
>   where:lat_sphere=63.5368
>   where:lon_sphere=10.204
>   where:height=620
>   where:xsize=480
>   where:ysize=480
>   where:xscale=1000
>   where:yscale=1000
> Corner Coordinates:
> Upper Left  (    0.0,    0.0)
> Lower Left  (    0.0,  480.0)
> Upper Right (  480.0,    0.0)
> Lower Right (  480.0,  480.0)
> Center      (  240.0,  240.0)
> Band 1 Block=480x480 Type=Byte, ColorInterp=Undefined
>   Metadata:
>     data:CLASS=IMAGE
>     data:IMAGE_VERSION=1.2
> christofferae at pc2752:~/src/prorad-clean/processing/prorad-process$ h5ls --version
> h5ls: Version 1.8.7
> christofferae at pc2752:~/src/prorad-clean/processing/prorad-process$ gdalinfo --version GDAL 1.7.3, released 2010/11/10
>
>
>
>
>> -----Original Message-----
>> From: gdal-dev-bounces at lists.osgeo.org [mailto:gdal-dev-
>> bounces at lists.osgeo.org] On Behalf Of Frank Warmerdam
>> Sent: 13. mars 2013 16:46
>> To: Rutger
>> Cc: gdal-dev at lists.osgeo.org
>> Subject: Re: [gdal-dev] Difficulties reading a ODIM HDF5 file
>>
>> Sjur / Rutger,
>>
>> It also seems to work fine for me with trunk on linux.  I suspect the problem
>> is some sort of mixup at build time between versions of the HDF include files
>> or something like that.  Very hard to debug such a thing remotely.
>>
>> Best regards,
>> Frank
>>
>> On Wed, Mar 13, 2013 at 12:51 AM, Rutger <kassies at gmail.com> wrote:
>> > Hey,
>> >
>> > For what its worth; it works fine on Windows for me, using verion:
>> > GDAL 1.9.2, released 2012/10/08
>> >
>> > Gdalinfo output looks equal to your Linux output, and gdal_translate
>> > is able to convert the layer to a GeoTiff for example.
>> >
>> > Im using the pre-build cmd utilities from
>> > http://www.gisinternals.com/sdk/ <http://www.gisinternals.com/sdk/>  .
>> > Maybe you can peak over there to see if there is any difference in building.
>> >
>> > Regards,
>> > Rutger
>> >
>> >
>> >
>> > --
>> > View this message in context:
>> > http://osgeo-org.1560.n6.nabble.com/gdal-dev-Difficulties-reading-a-OD
>> > IM-HDF5-file-tp5039864p5040058.html
>> > Sent from the GDAL - Dev mailing list archive at Nabble.com.
>> > _______________________________________________
>> > gdal-dev mailing list
>> > gdal-dev at lists.osgeo.org
>> > http://lists.osgeo.org/mailman/listinfo/gdal-dev
>>
>>
>>
>> --
>> ---------------------------------------+--------------------------------
>> ---------------------------------------+------
>> I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
>> light and sound - activate the windows | http://pobox.com/~warmerdam
>> and watch the world go round - Rush    | Geospatial Software Developer
>> _______________________________________________
>> gdal-dev mailing list
>> gdal-dev at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev



-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Software Developer


More information about the gdal-dev mailing list