[GRASS-user] Re: grass-user Digest, Vol 44, Issue 45

Michael Barton michael.barton at asu.edu
Tue Dec 15 10:18:07 EST 2009


If you are using a current version of GRASS (and current version of  
gdal if you are on Linux or Mac), run the location wizard to create a  
new location and mapset in the same projection as your problematic one  
(I'm assuming that you are not in an xy location). You get to the  
location wizard from the "create location" button on the startup screen.

Select the new location and mapset and start GRASS.

Try 'display region' from the configure menu or type g.region -p from  
the command line.

Do you have any different results?

Michael


On Dec 15, 2009, at 7:56 AM, grass-user-request at lists.osgeo.org wrote:

> Date: Tue, 15 Dec 2009 08:46:44 +0100
> From: Giacomo Piva <piva at meeo.it>
> Subject: Re: [GRASS-user] g.region (was v.to.rast conversion)
> To: grass-user at lists.osgeo.org
> Message-ID: <4B273EE4.5070308 at meeo.it>
> Content-Type: text/plain; charset=UTF-8; format=flowed
>
> Giacomo Piva wrote:
>> Hamish wrote:
>>> Giacomo Piva:
>>>> First of all, thanks for your reply.
>>>> To clarify my problem, i want to specify that the main
>>>> problem is that all command that involves the g.region always
>>>> returns the
>>>> reported error (ERROR: default region is not set.) also the "help".
>>>>
>>>> I found a similar discussion here:
>>>> http://lists.osgeo.org/pipermail/grass-user/2009-November/052988.html
>>>>
>>>> Where the solution was to use of the SVN version of the
>>>> grass.
>>>> I already tried to use that version, bunt nothing changed.
>>>> Any me any suggestions?
>>>
>>>
>>> maybe the rc5 bug is now gone, but the corrupted WIND file still
>>> remains in your mapset. try 'g.region -d' to reset it.
>>>
>>> does it work from a newly created mapset?
>>>
>>>
>>> Hamish
>>>
>>
>> Hi Hamish,
>> Maybe it could be usefull to do a backward step.
>>
>> I should convert a shapefile into a raster file (GeoTIFF format) at a
>> given resolution and I want to use the GRASS modules as a command  
>> line
>> tools.
>> I followed the instructions in the chapter "Automated usage of grass"
>> in the Markus's book and I created a bash script in order to prepare
>> the grass enviroment:
>>
>> #!/bin/bash
>> LOCATION=test
>>
>> GISBASE=/usr/local/grass-6.5.svn
>> GISDBASE=/usr/local/share/grassdata
>>
>> rm $HOME/.grassrc6
>> rm -rf "$GISDBASE/$LOCATION" #cleaning LOCATION
>>
>> TMPDIR=$$.tmp
>> mkdir -p $GISDBASE/$TMPDIR/temp
>>
>> echo "LOCATION_NAME: $TMPDIR" > $HOME/.grassrc6
>> echo "MAPSET: temp" >> $HOME/.grassrc6
>> echo "DIGITIZER: none" >> $HOME/.grassrc6
>> echo "GISDBASE: $GISDBASE" >> $HOME/.grassrc6
>>
>> export GISBASE=$GISBASE
>> export GISRC=$HOME/.grassrc6
>> export PATH=$PATH:$GISBASE/bin:$GISBASE/scripts
>>
>> After these lines I run the v.in.ogr module to import the vector:
>> v.in.ogr -o -e dsn=./test_data/test_data.shp output=grass_map
>>
>> And the following is the error i get.
>> ERROR: region for current mapset is not set
>> run "g.region"
>>
>> I tried to get the g.region help message, also I tried to reset the
>> region (with g.region -d) and to set a default region (with g.region
>> -s) but I get always the same error.
>>
>> I'm very new with GRASS and I cannot understand if there is a problem
>> in the installation, or it is a bug (as it seemed), or I'm not  
>> working
>> in the proper way.
>>
>> Thanks (also for the patience)
>>
>
> No suggestions?



More information about the grass-user mailing list