[GRASS-user] r.stream.basins error

Jasiewicz Jarosław jarekj at amu.edu.pl
Tue Oct 12 05:32:15 EDT 2010


  W dniu 12.10.2010 09:49, Francesco Mirabella pisze:
> Hi,
> thanks for you message,
> the modules were compiled from the add-ons about one week ago, I 
> suppose they should be the updated version.
> What do you mean by "unique streams"? If you mean the number of 
> streams which come out from the operation, these are about 7500. Do 
> you think is the area too large? BTW I was successful with r.watershed 
> on the same dataset but I just wanted to test these new modules
>
> Francesco
>
>
>
> Jarek Jasiewicz wrote:
>> Francesco Mirabella pisze:
>>> Hi all,
>>> I am trying to generate a basins map from a dem using r.stream.basins
>>>
>>> I first cut the dem to the area I want to work on than run g.region 
>>> to set the region to this map.
>>> Then I calculated streams and streams flow directions with 
>>> r.stream.extract.
>>>
>>> In order to get stream basins I used r.stream.basins:
>>> r.stream.basins  dir=rivers_flow    stream=rivers   
>>> basins=basins_rivers
>>>
>>> The output gives an error saying:
>>>
>>> Reading maps...
>>> Calculate basins using streams...
>>> Finding nodes...
>>> ERROR: Stream and direction maps probably do not match
>>> (Mon Oct 11 11:15:28 2010) Comando terminato (0 sec
>>
>>>
>>> Why do they not match if I derived them with the same command and 
>>> from the same dem ? Am I doing something wrong ?
>> such errors appears when region dir map and stream map comes from 
>> different operations. Try if you are using most actual 
>> r.stream.extract and r.stream basins modules.
>> How much unique streams you have created with r.stream.extract?
>>>
>>> thanks in advance
>>> Francesco
>>> _______________________________________________
>>> grass-user mailing list
>>> grass-user at lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/grass-user
>>
>
GRASS 6 or 7?

This error appears when the number of possible outlets overcome the 
allocated memory for given raster. Memory is allocated as a sum of 
vertical and horizontal resolution times 2. If the number of possible 
outlets overcomes that values the error is throwing. In most standard 
network this allocation is enough and is stored as a bug-handler to 
avoid crashes or infinite loops if user will use maps from different 
sources.

If you have a 7500 streams and you have raster map grater than 2000x2000 
cells it should not happen. If not I have a problem.

For future use:

if you find any problem with continuosly developed software (like these 
in add-ons) first:

- give us more information about version, of your GRASS and add-on
- try to reproduce this error on standard GRASS dataset like SPEARFISH or NC
if error canot be reproduced:
- give us more information of data type you are using: resolution, 
region etc.


More information about the grass-user mailing list