[GRASS-user] r.stream.extract Syntax Problem

Rich Shepard rshepard at appl-ecosys.com
Thu Apr 5 17:29:43 EDT 2012


   I'm learning to use r.stream.extract by following the detailed example on
the manual page. The last two steps are to extract steam maps using both
weighted and unweighted accumulation maps. The example syntax is:

# extract streams
r.stream.extract elevation=elevation.10m at PERMANENT \
                  accumulation=elevation.10m.acc.weighed \
                  threshold=1000 \
                  stream_rast=elevation.10m.streams

And the example syntax to create the weighted flow accumulation map is:

# weigh accumulation map
r.mapcalc "elevation.10m.acc.weighed = elevation.10m.acc * weight"

   For one of my sub-watersheds I ran the following:

r.mapcalc "dem10m.acc.weighted = dem10m.acc * weight"

(all on one line but it may wrap to two lines when you view it).

I check that this worked properly by displaying demm10m.avg on d.mon x0, then
displaying dem10m.acc.weighted on the same monitor. The two maps are congruent. So,
when I run r.stream.extract I get an error that the accumulation map does
not match the elevation map from which r.mapcalc created it:

r.stream.extract elevation=dem10m.avg accumulation=dem10m.acc.weighted threshold=1000 stream_rast=dem10m.streams

(NOTE: again, all on one line, but may display on two lines.)

Load input maps and get start points...
ERROR: Accumulation map does not match elevation map!

   There is no error with the unweighted accumulation map (dem10m.acc).

   I'm not seeing why this error is generated, and need to understand why so
I can model a dozen or so small basins.

TIA,

Rich



More information about the grass-user mailing list