Testing creating and opening raster datasets

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Testing creating and opening raster datasets

Ari Jolma
Hi, below is an output from my test script for gdal.pm. It goes through
all available drivers and all announced datatypes, and creates a dataset
and then opens it and checks if the size is ok. Looks good, only minor
issues:

- What does the "unsupported combination.." mean and how to detect it
before creating a dataset?
- ENVI hdr reports that it can create "UInt32Float32" datatypes, this is
a bug in envidataset.cpp:1375.
- Atlantis MFF2 (HKV) Raster announces that it can create datasets of
more types than it actually can.
- It takes a bit of guessing (I hard coded that into the test script)
what filename to give to the Open function to make it succeed. Is the
extension available somewhere in the metadata? (sorry, too lazy to look
now).

Ari

--->  Virtual Raster
Byte: ok (only create)
Int16: ok (only create)
UInt16: ok (only create)
Int32: ok (only create)
UInt32: ok (only create)
Float32: ok (only create)
Float64: ok (only create)
CInt16: ok (only create)
CInt32: ok (only create)
CFloat32: ok (only create)
CFloat64: ok (only create)

--->  GeoTIFF
Byte: ok
UInt16: ok
Int16: ok
UInt32: ok
Int32: ok
Float32: ok
Float64: ok
CInt16: ok
CInt32: ok
CFloat32: ok
CFloat64: ok

--->  National Imagery Transmission Format
Byte: ok
UInt16: ok
Int16: ok
UInt32: ok
Int32: ok
Float32: ok
CFloat32: not ok (create failed)
Unsupported combination of PVTYPE(C) and NBPP(64).
CFloat64: not ok (create failed)
Unsupported combination of PVTYPE(C) and NBPP(12).

--->  Erdas Imagine Images (.img)
Byte: ok
Int16: ok
UInt16: ok
Int32: ok
UInt32: ok
Float32: ok
Float64: ok
CFloat32: ok
CFloat64: ok

--->  ELAS
Byte: ok
Float32: ok
Float64: ok

--->  In Memory Raster
Byte: ok (only create)
Int16: ok (only create)
UInt16: ok (only create)
Int32: ok (only create)
UInt32: ok (only create)
Float32: ok (only create)
Float64: ok (only create)
CInt16: ok (only create)
CInt32: ok (only create)
CFloat32: ok (only create)
CFloat64: ok (only create)

--->  MS Windows Device Independent Bitmap
Byte: ok

--->  PCIDSK Database File
Byte: ok
UInt16: ok
Int16: ok
Float32: ok

--->  ILWIS Raster Map
Byte: ok
Int16: ok
Int32: ok
Float64: ok

--->  Portable Pixmap Format (netpbm)
Byte: ok
UInt16: ok

--->  ENVI .hdr Labelled
Byte: ok
Int16: ok
UInt16: ok
Int32: ok
UInt32Float32: not ok (create failed silently)
Float64: ok
CFloat32: ok
CFloat64: ok

--->  ESRI .hdr Labelled
Byte: ok
Int16: ok
UInt16: ok
Float32: ok

--->  PCI .aux Labelled
Byte: ok
Int16: ok
UInt16: ok
Float32: ok

--->  Atlantis MFF Raster
Byte: ok
UInt16: ok
Float32: ok
CInt16: ok
CFloat32: ok

--->  Atlantis MFF2 (HKV) Raster
Byte: ok
Int16: ok
UInt16: ok
Int32: not ok (create failed)
Attempt to create HKV file with currently unsupported data type (Int32).
UInt32: not ok (create failed)
Attempt to create HKV file with currently unsupported data type (UInt32).
CInt16: ok
CInt32: ok
Float32: ok
Float64: not ok (create failed)
Attempt to create HKV file with currently unsupported data type (Float64).
CFloat32: ok
CFloat64: not ok (create failed)
Attempt to create HKV file with currently unsupported data type (CFloat64).

--->  VTP .bt (Binary Terrain) 1.3 Format
Int16: ok
Int32: ok
Float32: ok

--->  Image Data and Analysis

--->  Raster Matrix Format
Byte: ok

_______________________________________________
Gdal-dev mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: Testing creating and opening raster datasets

Frank Warmerdam-2
On 9/13/05, Ari Jolma <[hidden email]> wrote:
> - What does the "unsupported combination.." mean and how to detect it
> before creating a dataset?

Ari,

There are cases where particular combinations of pixel
data type and band number are not supported.   However,
in the NITF driver case, I think I just never implemented proper
creation support for complex data types.  I have removed these
from the format list till I have time to implement and test them
properly.

> - ENVI hdr reports that it can create "UInt32Float32" datatypes, this is
> a bug in envidataset.cpp:1375.

Fixed.

> - Atlantis MFF2 (HKV) Raster announces that it can create datasets of
> more types than it actually can.

I'll leave this to Gillian to address.

> - It takes a bit of guessing (I hard coded that into the test script)
> what filename to give to the Open function to make it succeed. Is the
> extension available somewhere in the metadata? (sorry, too lazy to look
> now).

Where there is a clearly preferred extension for a format,
it is set in the driver metadata like this:
        poDriver->SetMetadataItem( GDAL_DMD_EXTENSION, "ntf" );

For some formats there is no obvious preferred extension.  In some
cases it may just be that there is no metadata definition of it when
there ought to be.

I would add that while I try to declare enough information in the
driver metadata to allow deciding what options are supported by
what formats, I have not been completely successful.  To some
extent the user still ends up having to read the format docs for
odd situations.

Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, [hidden email]
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent

_______________________________________________
Gdal-dev mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/gdal-dev