[GRASSLIST:6902] r.out.gdal problems

hi everyone,

was trying to export a GRASS raster with r.out.gdal and had the following
error:

-------------------------------------------------------------------------
r.out.gdal in=amox out=amox format=GTiff type=Float32
Writing format: GTiff
Writing type: Float32
Failed to process SRS definition: 'PROJCS["UTM
-------------------------------------------------------------------------

I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source

any ideas?

thanks!

--
Dylan Beaudette
Soils and Biogeochemistry Graduate Group
University of California at Davis
530.754.7341

was trying to export a GRASS raster with r.out.gdal and had the
following error:

---------------------------------------------------------------------
r.out.gdal in=amox out=amox format=GTiff type=Float32
Writing format: GTiff
Writing type: Float32
Failed to process SRS definition: 'PROJCS["UTM
---------------------------------------------------------------------

I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source

any ideas?

How old is your 6.1-cvs? This was fixed in the last couple of weeks.

Or is it still broken with today's CVS?

Hamish

On Thursday 26 May 2005 04:39 pm, Hamish wrote:

> was trying to export a GRASS raster with r.out.gdal and had the
> following error:
>
> ---------------------------------------------------------------------
> r.out.gdal in=amox out=amox format=GTiff type=Float32
> Writing format: GTiff
> Writing type: Float32
> Failed to process SRS definition: 'PROJCS["UTM
> ---------------------------------------------------------------------
>
> I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source
>
> any ideas?

How old is your 6.1-cvs? This was fixed in the last couple of weeks.

Or is it still broken with today's CVS?

Hamish

This happened with this morning's CVS version...

--
Dylan Beaudette
Soils and Biogeochemistry Graduate Group
University of California at Davis
530.754.7341

> > was trying to export a GRASS raster with r.out.gdal and had the
> > following error:
> >
> > ---------------------------------------------------------------------
> > r.out.gdal in=amox out=amox format=GTiff type=Float32
> > Writing format: GTiff
> > Writing type: Float32
> > Failed to process SRS definition: 'PROJCS["UTM
> > ---------------------------------------------------------------------
> >
> > I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source

..

This happened with this morning's CVS version...

Yes, confirmed with Spearfish. The quoting bug still lives.

GRASS 6.1> r.out.gdal in=elevation.10m out=elev format=GTiff type=Float32
Writing format: GTiff
Writing type: Float32
Failed to process SRS definition: 'PROJCS["UTM

By changing the top line of the script to
#!/bin/sh -x

and changing the PROJECTION line to (just for clarity; same result)
- PROJECTION="-a_srs '${WKT}'"
+ PROJECTION="-a_srs ${WKT}"

we see that the failing command is:

gdal_translate -of $FORMAT -ot $TYPE $PROJECTION $CREATEKEY $METAKEY \
  $CELLHD $OUTPUT

which expands to:

  gdal_translate -of GTiff -ot Float32 -a_srs 'PROJCS["UTM' Zone 13, Northern 'Hemisphere",GEOGCS["clark66",DATUM["North_American_Datum_1927",SPHEROID["clark66",6378206.4,294.9786982]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",-105],PARAMETER["scale_factor",0.9996],PARAMETER["false_easting",500000],PARAMETER["false_northing",0],UNIT["meter",1]]' /home/hamish/grassdata/spearfish57/PERMANENT/cellhd/elevation.10m elev

It is adding 'single quotes' around things with spaces in the WKT such
as "WKT Zone 13". How can this be stopped?

Hamish

On Thursday 26 May 2005 05:36 pm, Hamish wrote:

> > > was trying to export a GRASS raster with r.out.gdal and had the
> > > following error:
> > >
> > > ---------------------------------------------------------------------
> > > r.out.gdal in=amox out=amox format=GTiff type=Float32
> > > Writing format: GTiff
> > > Writing type: Float32
> > > Failed to process SRS definition: 'PROJCS["UTM
> > > ---------------------------------------------------------------------
> > >
> > > I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source

..

> This happened with this morning's CVS version...

Yes, confirmed with Spearfish. The quoting bug still lives.

[snip]

Hmmm... ok well I was able to use r.out.gdal in the GRASS6.0 release.

thanks,

--
Dylan Beaudette
Soils and Biogeochemistry Graduate Group
University of California at Davis
530.754.7341

> > > > was trying to export a GRASS raster with r.out.gdal and had the
> > > > following error:
> > > >
> > > > ---------------------------------------------------------------------
> > > > r.out.gdal in=amox out=amox format=GTiff type=Float32
> > > > Writing format: GTiff
> > > > Writing type: Float32
> > > > Failed to process SRS definition: 'PROJCS["UTM
> > > > ---------------------------------------------------------------------
> > > >
> > > > I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source

..

> > This happened with this morning's CVS version...
>
> Yes, confirmed with Spearfish. The quoting bug still lives.

Hmmm... ok well I was able to use r.out.gdal in the GRASS6.0 release.

Yes, there is a bug fix after 6.0 in CVS which is causing new problems.
Seems simple enough so hopefully fixed soon.

Hamish

On Fri, May 27, 2005 at 12:58:25PM -0700, Dylan Beaudette wrote:

On Thursday 26 May 2005 05:36 pm, Hamish wrote:
> > > > was trying to export a GRASS raster with r.out.gdal and had the
> > > > following error:
> > > >
> > > > ---------------------------------------------------------------------
> > > > r.out.gdal in=amox out=amox format=GTiff type=Float32
> > > > Writing format: GTiff
> > > > Writing type: Float32
> > > > Failed to process SRS definition: 'PROJCS["UTM
> > > > ---------------------------------------------------------------------
> > > >
> > > > I am using GRASS6.1-cvs and GDAL 1.2.6, both installed from source
>
> ..
>
> > This happened with this morning's CVS version...
>
> Yes, confirmed with Spearfish. The quoting bug still lives.
>
[snip]

Hmmm... ok well I was able to use r.out.gdal in the GRASS6.0 release.

Fixed today in CVS (both 6.1-CVS and 6.0-CVS).

Markus