[Gdal-dev] Bathymetry data...

Frank Warmerdam warmerdam at pobox.com
Thu Mar 25 09:17:08 EST 2004


IMD Listuser wrote:
> Greetings all
> 
> I would like to be able to use a global bathymetric data set stored in a
> format which I am unfamiliar with and wondering if GDAL supports it.
> 
> The url to the data set is:
> ftp://topex.ucsd.edu/pub/global_topo_2min/
> 
> The file is topo_8.2.img and there appears to be a header
> topo_8.2.img.ers which refers to an ERStaorage format. Ive tried using
> gdalinfo to retrieve info about the file, but I receive an error to the
> effect of 'not an HFA file'.
> 
> Ideally I would like to move this data into GeoTIFF format.

Charlie,

The suggestions with regard to converting to netcdf format and then accessing
via GDAL would likely work but may be a bit of a hassle.  The README_V8.2
says:

"""
The gridded data are stored in an integer*2 format without any
header or record information.

*.img              A 6336 by 10800 grid of 2-byte integers = 136,857,600 bytes.
                    Byte order is big_endian.
                    The topography is meters above sea level. An even
                    value signifies the cell does not have a ship or coastline
                    measurement while an odd value signifies that it does.
                    The Mercator projected image spans longitudes from 0 E to
                    360 E and latitudes from 72.006 N to -72.006 N.
                    A spherical earth is used for the Mercator projection.
                    The center of the upper left grid cell (i.e. the first
                    integer in the file) is located at 72.0009 N, .01667 E.
                    Longtiudes increase with a 1/30 degree spacing.  The
                    The center of the last integer in the file is located
                    at -72.0009 N, 359.933 E.  Note the latitude spacing is
                    1/30 degree at the equator but decreases as 1/cos(latitude)
                    according to a Mercator projection on a sphere.
"""

So, I think the easiest thing would just be to write a .aux file for this.
Likely something like:

--- start of topo_8.2.aux ---
AuxilaryTarget: topo_8.2.img
RawDefinition: 10800 6336 1
ChanDefinition-1: 16U 0 2 21600 Unswapped
--- end of .aux file ---

I found the projection information kind of confusing, so I didn't try to
replicate that.

Best regards,
-- 
---------------------------------------+--------------------------------------
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 Programmer for Rent




More information about the Gdal-dev mailing list