[GRASS-user] trying to get unprojected raster data into a projected location

Michael Barton michael.barton at asu.edu
Sat Sep 22 12:30:26 EDT 2007


Pietro,

See below


On 9/20/07 8:56 PM, "Pietro Calogero" <pietro at calogero.us> wrote:

> I received a set of data that was developed in ArgGIS, including shapefiles
> and a .sid raster file. The shapefiles came with projection information, but
> the .sid file did not (and it extends out further than the vector info on the
> edges). So I created an x,y location for the .sid file and imported it using
> GDAL. It imported fine; the satphoto looks good. I also created a UTM location
> for the shapefiles using their proj info, and then extended the region and
> increased the resolution based on the extents of the raster (all units are in
> meters).

If you KNOW the projection of the .sid file AND it IS projected (just
doesn't have a header with projection information) you can initially create
a proper location and simply import the file overriding its (lack of)
projection information. This is a check box in the GUI and the -o flag on
the command line. No need to reproject the file.


> Now I want to reproject the raster from the x,y location into the UTM
> location. Both are in meters, both have the same N,S,W,E extents, both have
> the same resolution.
> 

If you have the file in an xy location and want project it into a UTM
location, the simplest way is to use the georectification module in the GUI.

Start GRASS in the proper UTM location. Make sure that you set the region
extents and resolution to match the image extents and native resolution for
best results. Use g.region to do this.

First, display one of your vector maps in the normal way.

Start the georectification module under the file menu.

1) select the location/mapset of the file you want to georectify
2) create a georectifcation "group" if you have not already defined one.
Your group will contain only 1 file
3) select that group
4) select a map/image to display for georectification. In your case, it is
your single image.
5) start georectification

If you don't know the correspondence between xy points and desired UTM
equivalents, you could interactively click a point on your image and a
corresponding point on your vector to get that information for a series of
points.

However, in your case, it sounds like you already know that there is a 1:1
correspondence between x/y values and UTM east/north and your map is already
rectified (i.e., doesn't need any kind of warping). If so, you can just type
the corner coordinates into the xy box (separate by commas as in
xcoord,ycoord) and the same number into the eastnorth box (format as
east,north). Do this for the four corners, pick 1st order rectification and
click the georectify button.

Hope this helps.

Michael

__________________________________________
Michael Barton, Professor of Anthropology
Director of Graduate Studies
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University

phone: 480-965-6213
fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton





More information about the grass-user mailing list