[Gdal-dev] gdalinfo vs Grass issues
Maciej Sieczka
tutey at o2.pl
Mon Jul 24 10:08:56 EDT 2006
Using todays' GDAL and GRASS CVS, gdal-grass 1.3.1.2.
Problems:
A. gdalinfo -mm reports Min/Max=nan,nan for any Grass raster exported
with r.out.gdal, [1], which is wrong - see [2] for actuall value range.
B. Also using the GDAL Grass driver wrong value is calculated, moreover
gdalinfo issues ERROR 6 twice and segfaults in the end [3].
C. ERROR 6 and segfault on gdalinfo take place for Grass rasters even if
-mm is not used [4].
Backtrace is attached.
[1]
$ r.out.gdal input=exp format=GTiff type=Float32 output=exp.tif
$ gdalinfo -mm exp.tif
Driver: GTiff/GeoTIFF
Size is 2181, 2187
Coordinate System is `'
Origin = (2009.000000,4493.000000)
Pixel Size = (1.00000000,-1.00000000)
Corner Coordinates:
Upper Left ( 2009.000, 4493.000)
Lower Left ( 2009.000, 2306.000)
Upper Right ( 4190.000, 4493.000)
Lower Right ( 4190.000, 2306.000)
Center ( 3099.500, 3399.500)
Band 1 Block=2181x1 Type=Float32, ColorInterp=Gray
Computed Min/Max=nan,nan
^
WRONG !!!
NoData Value=nan
Metadata:
COLOR_TABLE_RULES_COUNT=0
[2]
$ r.info -t exp
datatype=DCELL
$ r.info -r exp
min=1.000000
max=9.999998
[3]
$ gdalinfo -mm /home/grassdata/xy/nic/cellhd/exp
Driver: GRASS/GRASS Database Rasters (5.7+)
Size is 2181, 2187
Coordinate System is `'
Origin = (2009.000000,4493.000000)
Pixel Size = (1.00000000,-1.00000000)
Corner Coordinates:
Upper Left ( 2009.000, 4493.000)
Lower Left ( 2009.000, 2306.000)
Upper Right ( 4190.000, 4493.000)
Lower Right ( 4190.000, 2306.000)
Center ( 3099.500, 3399.500)
Band 1 Block=2181x1 Type=Float64, ColorInterp=Gray
Min=1.000 Max=10.000 Computed Min/Max=nan,nan
^
WRONG !!!
NoData Value=nan
Metadata:
COLOR_TABLE_RULES_COUNT=0
ERROR 6: SetDefaultRAT() not implemented for this format.
ERROR 6: SetDefaultRAT() not implemented for this format.
Segmentation fault (core dumped)
[4]
$ gdalinfo /home/grassdata/xy/nic/cellhd/exp
Driver: GRASS/GRASS Database Rasters (5.7+)
Size is 2181, 2187
Coordinate System is `'
Origin = (2009.000000,4493.000000)
Pixel Size = (1.00000000,-1.00000000)
Corner Coordinates:
Upper Left ( 2009.000, 4493.000)
Lower Left ( 2009.000, 2306.000)
Upper Right ( 4190.000, 4493.000)
Lower Right ( 4190.000, 2306.000)
Center ( 3099.500, 3399.500)
Band 1 Block=2181x1 Type=Float64, ColorInterp=Gray
Min=1.000 Max=10.000
NoData Value=nan
Metadata:
COLOR_TABLE_RULES_COUNT=0
ERROR 6: SetDefaultRAT() not implemented for this format.
ERROR 6: SetDefaultRAT() not implemented for this format.
Segmentation fault (core dumped)
Maciek
-------------- next part --------------
$ gdb gdalinfo core
GNU gdb 6.4-debian
Copyright 2005 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
Core was generated by `gdalinfo /home/grassdata/xy/nic/cellhd/exp'.
Program terminated with signal 11, Segmentation fault.
warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/local/lib/libgdal.so.1...done.
Loaded symbols for /usr/local//lib/libgdal.so.1
Reading symbols from /usr/lib/libpq.so.4...done.
Loaded symbols for /usr/lib/libpq.so.4
Reading symbols from /lib/tls/i686/cmov/librt.so.1...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /usr/lib/libstdc++.so.6...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/local/lib/libgeos.so.2...done.
Loaded symbols for /usr/local//lib/libgeos.so.2
Reading symbols from /usr/local/lib/libgeos_c.so.1...done.
Loaded symbols for /usr/local//lib/libgeos_c.so.1
Reading symbols from /usr/lib/i686/cmov/libssl.so.0.9.8...done.
Loaded symbols for /usr/lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /usr/lib/i686/cmov/libcrypto.so.0.9.8...done.
Loaded symbols for /usr/lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /usr/lib/libkrb5.so.3...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /usr/lib/libz.so.1...done.
Loaded symbols for /usr/lib/libz.so.1
Reading symbols from /usr/lib/libkrb5support.so.0...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /usr/local/lib/gdalplugins/gdal_GRASS.so...done.
Loaded symbols for /usr/local/lib/gdalplugins/gdal_GRASS.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_I.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_I.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_vask.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_vask.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_gmath.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_gmath.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_gis.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_gis.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_datetime.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_datetime.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_gproj.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_gproj.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_vect.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_vect.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_dbmibase.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_dbmibase.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_dbmiclient.so...done.Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_dbmiclient.so
Reading symbols from /usr/lib/libfftw3.so.3...done.
Loaded symbols for /usr/lib/libfftw3.so.3
Reading symbols from /lib/libncurses.so.5...done.
Loaded symbols for /lib/libncurses.so.5
Reading symbols from /usr/local/lib/libproj.so.0...done.
Loaded symbols for /usr/local//lib/libproj.so.0
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_dig2.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_dig2.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_dgl.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_dgl.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_rtree.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_rtree.so
Reading symbols from /usr/local/grass-6.1.cvs/lib/libgrass_linkm.so...done.
Loaded symbols for /usr/local/grass-6.1.cvs/lib/libgrass_linkm.so
#0 0xb7c7874a in GDALRasterAttributeTable::Serialize ()
from /usr/local//lib/libgdal.so.1
(gdb) bt
#0 0xb7c7874a in GDALRasterAttributeTable::Serialize ()
from /usr/local//lib/libgdal.so.1
#1 0xb7c78bb6 in GDALRasterAttributeTable::DumpReadable ()
from /usr/local//lib/libgdal.so.1
#2 0xb7c78c2a in GDALRATDumpReadable () from /usr/local//lib/libgdal.so.1
#3 0x0804a450 in main ()
(gdb) quit
More information about the Gdal-dev
mailing list