[GRASS5] GRASS, PROJ and NAD

Markus Neteler neteler at itc.it
Mon Oct 13 05:56:57 EDT 2003


On Sat, Oct 11, 2003 at 02:16:28PM +0100, Paul Kelly wrote:
> 
> On Sat, 11 Oct 2003, Markus Neteler wrote:
> 
> > I was playing a bit with PROJ and have generated
> > a Spearfish location with UTM/NAD83. Reprojection from
> > the sample NAD27 works well. Then I have created a
> > Spearfish-Lat-Long location and tried to reproject
> > data from the sample Spearfish location into.
> >
> > Here I get the error:
> > r.proj in=elevation.dem location=spearfish mapset=PERMANENT
> > pj_transform() failed
> > cause: failed to load NAD27-83 correction file
> > pj_transform() failed
> > cause: failed to load NAD27-83 correction file
> > pj_transform() failed
> > cause: failed to load NAD27-83 correction file
> > pj_transform() failed
> > cause: failed to load NAD27-83 correction file
> > pj_transform() failed
> > [...]
> 
> That message usually means the point you are trying to re-project falls
> outside the region covered by the NAD correction file, but there can be
> several other reasons. Did r.proj not print the parameters for each
> location first? What are the PROJ_INFO files?

Ah, sorry:

In spearfishLL:
r.proj in=elevation.dem location=spearfish mapset=PERMANENT

Input Projection Parameters: +proj=utm +zone=13 +a=6378206.4 +rf=294.9786982 +nadgrids=conus
Input Unit Factor: 1

Output Projection Parameters: +proj=latlong +a=6378137 +rf=298.257223563 +towgs84=0.000,0.000,0.000
Output Unit Factor: 1
pj_transform() failed
cause: failed to load NAD27-83 correction file
pj_transform() failed
cause: failed to load NAD27-83 correction file
pj_transform() failed
cause: failed to load NAD27-83 correction file
pj_transform() failed

       [ deleted 450000 lines ]

cause: failed to load NAD27-83 correction file
pj_transform() failed
cause: failed to load NAD27-83 correction file
Input:
Cols:	447 (633)
Rows:	104 (466)
North: 4920620.000000 (4928000.000000)
South: 4917500.000000 (4914020.000000)
West:  595590.000000 (590010.000000)
East:  609000.000000 (609000.000000)
ew-res:	30.000000
ns-res:	30.000000

Output:
Cols:	61 (129582)
Rows:	10 (10)
North: 44.433333 (44.433333)
South: 44.405556 (44.405556)
West:  -103.800000 (-103.800000)
East:  -103.630556 (256.150000)
                 ^^^^^^^^^^^^^^^^^
                         ooops!! I just realize it now.
ew-res:	0.002778
ns-res:	0.002778
Allocating memory and reading input map...100%
Projecting...    100%

There is something strange. Here is the spearfishLL PROJ_INFO file:

name: Latitude-Longitude
datum: wgs84
towgs84: 0.000,0.000,0.000
proj: ll
ellps: wgs84

Here is the spearfishLL DEFAULT_WIND file:
proj:       3
zone:	    0
north: 	    44:26N
south:	    44:24:20N
east:	    103:51W
west:	    103:48W
cols:	    129582          <--??
rows:	    10
e-w resol:  0:00:10
n-s resol:  0:00:10

The cols value is surprising (to me). However, this is what the
dialogue provides when defining spearfishLL:

  projection:   3 (Latitude-Longitude)
  zone:         0
  north:       44:26N
  south:       44:24:20N
  east:        103:51W
  west:        103:48W

  e-w res:     0:00:10
  n-s res:     0:00:10

  total rows:               10
  total cols:           129582
  total cells:       1,295,820


Do you accept this region? (y/n) [y] >

Maybe I am missing something, but above looks unusual.

Markus




More information about the grass-dev mailing list