[GRASS-user] Problem with display of Raster file.

HI!
I am trying to display the tif file ,

by first importing the tif file by
r.in.gdal -e in=nf42_geo.tif out=tm
WARNING: Datum ‘unknown’ not recognised by GRASS and no parameters found.
Datum transformation will not be possible using this projection
information.
Projection of input dataset and current location appear to match.
Proceeding with import…
100%
CREATING SUPPORT FILES FOR tm.red
SETTING GREY COLOR TABLE FOR tm.red (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.green
SETTING GREY COLOR TABLE FOR tm.green (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.blue
SETTING GREY COLOR TABLE FOR tm.blue (8bit, full range)
r.in.gdal complete.

now i am trying to display the imported file…
i got the error

g.region rast=tm
ERROR: raster map not found.

when i observe three files are created in PERMANENT/cats
tm.red,tm.blue,tm.green.
but it is not the actual file that i want to see…
Please tell how could i display it.
Thanks in Advance

On 2/21/08, Kunal Malik <kunal.malik81@gmail.com> wrote:

Hi!
Thanks for ur support.

As u have said ,i got the georefercing information using gdalinfo.
It give following output
Driver: GTiff/GeoTIFF
Size is 5177, 3450
Coordinate System is:
GEOGCS[" Unable to match Ellipsoid (Datum) to a GeographicTypeGeoKey value Ellipsoid = Modified Everest Datum = Modified Everest",
DATUM[“unknown”,
SPHEROID[“unnamed”,6377304.063,300.8017000971244]],
PRIMEM[“Greenwich”,0],
UNIT[“degree”,0.0174532925199433]]
Origin = (65.999420352116971,24.000579647883026)
Pixel Size = (0.001159295766052,-0.001159295766052)
Metadata:
AREA_OR_POINT=Area
TIFFTAG_SOFTWARE=ERDAS IMAGINE
TIFFTAG_XRESOLUTION=1
TIFFTAG_YRESOLUTION=1
TIFFTAG_RESOLUTIONUNIT=1 (unitless)
Image Structure Metadata:
INTERLEAVE=PIXEL
Corner Coordinates:
Upper Left ( 65.9994204, 24.0005796) ( 65d59’57.91"E, 24d 0’2.09"N)
Lower Left ( 65.9994204, 20.0010093) ( 65d59’57.91"E, 20d 0’3.63"N)
Upper Right ( 72.0010945, 24.0005796) ( 72d 0’3.94"E, 24d 0’2.09"N)
Lower Right ( 72.0010945, 20.0010093) ( 72d 0’3.94"E, 20d 0’3.63"N)
Center ( 69.0002574, 22.0007945) ( 69d 0’0.93"E, 22d 0’2.86"N)
Band 1 Block=64x64 Type=Byte, ColorInterp=Red
Metadata:
LAYER_TYPE=athematic
Band 2 Block=64x64 Type=Byte, ColorInterp=Green
Metadata:
LAYER_TYPE=athematic
Band 3 Block=64x64 Type=Byte, ColorInterp=Blue
Metadata:
LAYER_TYPE=athematic

and then i tried to import the tif file .
r.in.gdal -e in=nf42_geo.tif out=tm
WARNING: Datum ‘unknown’ not recognised by GRASS and no parameters found.
Datum transformation will not be possible using this projection
information.
Projection of input dataset and current location appear to match.
Proceeding with import…
100%
CREATING SUPPORT FILES FOR tm.red
SETTING GREY COLOR TABLE FOR tm.red (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.green
SETTING GREY COLOR TABLE FOR tm.green (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.blue
SETTING GREY COLOR TABLE FOR tm.blue (8bit, full range)
r.in.gdal complete.

now i am trying to display the imported file…
i got the error

g.region rast=tm
ERROR: raster map not found.
Please tell how could i display it.
Thanks in Advance

//--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

On 2/20/08, Glynn Clements <glynn@gclements.plus.com> wrote:

Kunal Malik wrote:

If i don’t know the Projection Information of the File to be Imported,could
i import the raster/vector file available…

The “Projection of dataset does not appear to match the current
location” error can only occur if the file is georeferenced. If it
isn’t, r.in.gdal will just assume that it matches the projection of
the current location.

As Frank mentions, you can use gdalinfo to obtain the georeferencing
information.

And you can use “r.in.gdal location=” or “g.proj -c location=” to
create a new location with the correct projection based upon what’s in
the file.

If a file isn’t georeferenced and you don’t have that information
available, you can import the file into an location with an X/Y
projection, although you will lose the ability to perform operations
which require projection information (e.g. reprojection).

More generally, if you have some data but don’t know what part of the
planet that data refers to, you don’t really have any data. It’s like
knowing that the answer is 42 without knowing what the question is.

Glynn Clements <glynn@gclements.plus.com>


Thanks & Regards

Kunal Malik
09871147561


Thanks & Regards

Kunal Malik
09871147561

Kunal,
you have got 3 bands, red, green and blue of your tiff. To get a
RGB-Picture use
r.composite.
In the shell first start GRASS in PERMANENT, mark the following 5 lines
with your mouse and insert them in the shell by clicking the middle
mouse button (mouse wheel (or just copy it))
###############################################################
r.composite red=tm.red green=tm.green blue=tm.blue output=tm
g.regiion rast=tm
d.mon start=x3
d.rast tm

################################################################
Have luck

For more calculation it might be better to create a user mapset. From
there you can use the maps in permanent too, but they stay save there.

cheers
Philipp

Kunal Malik schrieb:

HI!
I am trying to display the tif file ,

by first importing the tif file by
r.in.gdal -e in=nf42_geo.tif out=tm
WARNING: Datum 'unknown' not recognised by GRASS and no parameters found.
         Datum transformation will not be possible using this projection
         information.
Projection of input dataset and current location appear to match.
Proceeding with import...
100%
CREATING SUPPORT FILES FOR tm.red
SETTING GREY COLOR TABLE FOR tm.red (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.green
SETTING GREY COLOR TABLE FOR tm.green (8bit, full range)
100%
CREATING SUPPORT FILES FOR tm.blue
SETTING GREY COLOR TABLE FOR tm.blue (8bit, full range)
r.in.gdal complete.

now i am trying to display the imported file..
i got the error

g.region rast=tm
ERROR: raster map <tm> not found.

when i observe three files are created in PERMANENT/cats
tm.red,tm.blue,tm.green.
but it is not the actual file that i want to see..
Please tell how could i display it.
Thanks in Advance