[GRASS-user] Re: problem using r.watershed

Filipe Silva Dias filipesdias at gmail.com
Mon Mar 26 11:32:02 EDT 2012


Thanks, it took a while but it worked.

On Mon, Mar 26, 2012 at 3:11 PM, Markus Metz <
markus.metz.giswork at googlemail.com> wrote:

> On Sun, Mar 25, 2012 at 2:59 PM, Filipe Silva Dias
> <filipesdias at gmail.com> wrote:
> > Thanks. Out of curiosity and tried with Grass 7 with -m (and 30 m
> > resolution) and I obtained this error message:
> >
> > r.watershed -m elevation=DemPT2 at Grass7 threshold=10000
> > stream=streams
> > SECTION 1 beginning: Initiating Variables. 5 sections total.
> > SECTION 1a: Mark masked and NULL cells
> > SECTION 1b: Determining Offmap Flow.
> > SECTION 2: A* Search.
> > SECTION 3: Accumulating Surface Flow with MFD.
> > SECTION 4: Watershed determination.
> > SECTION 5: Closing Maps.
> > ERROR: Rast_make_random_colors: min (1) > max (0)
>
> Apparently no basins were determined, probably because the threshold
> of 10000 for flow accumulation was never reached. Maybe the current
> region was either too small or did not cover parts of the DEM DemPT2?
>
> BTW, if you want to try out GRASS 7 in a separate mapset, you don't
> need to copy over the DEM if you just want to read it. Within the
> mapset Grass7, the following commands should work:
> g.region -p rast=DemPt at ETRS89
> r.watershed elevation=DemPt at ETRS89 stream=stream threshold=10000 -m
>
> Markus M
>
> >
> > Subprocess failed with exit code 1
> > category information for [streams] in [Grass7] missing or invalid
> >
> >
> >
> >
> > On Sun, Mar 25, 2012 at 11:49 AM, Markus Metz
> > <markus.metz.giswork at googlemail.com> wrote:
> >>
> >> On Sun, Mar 25, 2012 at 12:30 PM, Filipe Silva Dias
> >> <filipesdias at gmail.com> wrote:
> >> > I switched the resolution from 30x30 to 100x100 and now it works.
> >> > Problem
> >> > solved.
> >> >
> >> >
> >> > On Sun, Mar 25, 2012 at 11:12 AM, Filipe Silva Dias
> >> > <filipesdias at gmail.com>
> >> > wrote:
> >> >>
> >> >> I'm using GRASS 6.4.2 and I'm on Windows 7
> >> >>
> >> >>
> >> >> On Sun, Mar 25, 2012 at 11:11 AM, Filipe Silva Dias
> >> >> <filipesdias at gmail.com> wrote:
> >> >>>
> >> >>> Dear all
> >> >>>
> >> >>> I'm trying to run r.watershed on a ASTER DEM (with the size of
> >> >>> Portugal)
> >> >>> but I'm getting this error:
> >> >>>
> >> >>> r.watershed elevation=DemPt at ETRS89 stream=stream
> >> >>> threshold=10000
> >> >>> SECTION 1a (of 5): Initiating Memory.
> >> >>> ERROR: G_malloc: unable to allocate 1515173064 bytes at
> >> >>> init_vars.c:134
> >> >>> Subprocess failed with exit code 1
> >> >>> category information for [stream] in [ETRS89] missing or invalid
> >> >>>
> >> >>> What am I doing wrong?
> >> >>>
> >> As you figured out already, the region, i.e. number of cells was too
> >> large. In order to run r.watershed with that region (Portugal at 30m
> >> resolution) on Windows, you would need GRASS 7 and run r.watershed
> >> with the -m option.
> >>
> >> Markus M
> >
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20120326/e8b77ea0/attachment-0001.html


More information about the grass-user mailing list