[GRASSLIST:7283] Re: problems with r.texture

Hamish hamish_nospam at yahoo.com
Thu Jun 23 03:43:49 EDT 2005

> *Firstly how can I tell if I am running out of memory

run "top" along side in another term window

> *should I break the scene up to smaller areas. Basically I have 200
> small areas of interest. If this is the case how can I script this
> easily.

most raster calculations only work on the current region. So use d.zoom
or g.region in a script for each smaller part.

Neat little g.region trick:  (from the help page)

g.region n=n+1000 w=w-500 

  The n=value may also be specified as a function of its current value:
n=n+value increases the current northing, while n=n-value decreases it.
This is also true for s=value, e=value, and w=value. In this example the
current region's northern boundary is extended by 1000 units and the
current region's western boundary is decreased by 500 units. 

g.region n=s+1000 e=w+1000 

  This form allows the user to set the region boundary values relative
to one another. Here, the northern boundary coordinate is set equal to
1000 units larger than the southern boundary's coordinate value, and the
eastern boundary's coordinate value is set equal to 1000 units larger
than the western boundary's coordinate value. The corresponding forms
s=n-value and w=e-value may be used to set the values of the region's
southern and western boundaries, relative to the northern and eastern

so it isn't too hard to script a moving window.

> *is it possible to turn on some type of debugging to see where
> its falling over

For most of the older raster modules debugging is not built in so you'd
have to run it through a debugger like gdb. The newer vector and DB code 
is heavily instrumented.


More information about the grass-user mailing list