Opened 12 years ago
Last modified 9 years ago
#1689 new defect
weird import with r.in.gdal
Reported by: | madi | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 6.4.6 |
Component: | Raster | Version: | svn-releasebranch64 |
Keywords: | r.in.gdal | Cc: | madi |
CPU: | x86-64 | Platform: | Linux |
Description (last modified by )
Hi all,
I pointed this out already in ML, but in the same thread there were many topics so that i better separate this one in a dedicated ticket. I have generated a vrt file by this procedure http://grass.osgeo.org/wiki/Large_raster_data_processing and imported it into grass with the following commands:
r.in.gdal input="/forest/ASTER-GDEM/Dem_lzw/mosaic.vrt" output="mosaic"
and
r.external -r input="/forest/ASTER-GDEM/Dem_lzw/mosaic.vrt" output="mosaic2"
Then, comparing mosaic and mosaic2, i get:
GRASS 6.4.3svn (ASTER_GDEM):~ > r.info map=mosaic +----------------------------------------------------------------------------+ | Layer: mosaic Date: Tue Jul 17 17:57:31 2012 | | Mapset: PERMANENT Login of Creator: leomarg | | Location: ASTER_GDEM | | DataBase: /forest/GRASS/grassdata | | Title: ( mosaic ) | | Timestamp: none | |----------------------------------------------------------------------------| | | | Type of Map: raster Number of Categories: 6518 | | Data Type: CELL | | Rows: 140401 | | Columns: 198001 | | Total Cells: 27799538401 | | Projection: Latitude-Longitude | | N: 72:00:00.5N S: 32:59:59.5N Res: 0:00:01 | | E: 44:00:00.5E W: 11:00:00.5W Res: 0:00:01 | | Range of data: min = -9999 max = 6518 | | | | Data Description: | | generated by r.in.gdal | | | | Comments: | | r.in.gdal input="/forest/ASTER-GDEM/Dem_lzw/mosaic.vrt" output="mosa\ | | ic" | | | +----------------------------------------------------------------------------+
GRASS 6.4.3svn (ASTER_GDEM):~ > r.info map=mosaic2 +----------------------------------------------------------------------------+ | Layer: mosaic2 Date: Wed Jul 18 10:54:37 2012 | | Mapset: PERMANENT Login of Creator: leomarg | | Location: ASTER_GDEM | | DataBase: /forest/GRASS/grassdata | | Title: ( mosaic2 ) | | Timestamp: none | |----------------------------------------------------------------------------| | | | Type of Map: raster Number of Categories: 0 | | Data Type: CELL | | Rows: 140401 | | Columns: 198001 | | Total Cells: 27799538401 | | Projection: Latitude-Longitude | | N: 72:00:00.5N S: 32:59:59.5N Res: 0:00:01 | | E: 44:00:00.5E W: 11:00:00.5W Res: 0:00:01 | | Range of data: min = -9999 max = 6518 | | | | Data Description: | | generated by r.external | | | | Comments: | | r.external -r input="/forest/ASTER-GDEM/Dem_lzw/mosaic.vrt" output="\ | | mosaic2" | | | +----------------------------------------------------------------------------+
The problem is that with r.in.gdal, the map is shrinked, while the map produced by r.external is correct. See the attached pictures.
Attachments (2)
Change History (8)
by , 12 years ago
Attachment: | Screenshot-1.png added |
---|
comment:1 by , 12 years ago
Cc: | added |
---|
comment:2 by , 12 years ago
Description: | modified (diff) |
---|
trac tips of the day: use three curly brackets to quote ascii art, and no need to cc yourself: anyone who created, comments on, or otherwise touches the bug is added to the cc list automatically.
Hamish
comment:3 by , 12 years ago
how about if you make a geotiff from the .vrt with gdal_translate? what then?
btw, r.null can take care of those -9999 for you.
Hamish
comment:5 by , 12 years ago
comment:6 by , 9 years ago
Milestone: | 6.4.3 → 6.4.6 |
---|
map imported with r.external