[GRASS-user] Stream extraction from pseudo-elevation map using r.watershed

Hi,

I tried something that was working at least several months ago, but somehow r.watershed has changed. What I am trying to do is to extract a stream network from a pseudo elevation map. This pseudo elevation map is created by getting the distance of each stream cell from to outlet in upstream direction (using r.cost). In addition, the streams are buffered (3 cells wide) with cells of a value that is much greater than the actual stream value. This map has several features: 1) The cell values for the stream are certainly decreasing in downstream direction (=elevation is decreasing) 2) The stream is carved into a valley (important at river junctions where two streams meet). So this should actually meet the requirements for r.watershed (at least it was working some time ago) to extract the stream and get the drainage directions (e.g. for other tools like r.stream.order etc.).

Now, when I try to run r.watershed (GRASS7.1) I get following warning several times:

WARNING: MFD: cumulative proportion of flow distribution not 1.0 but
-0.000000

Although I get a drainage map as output, no output is created for the extracted stream network. I am wondering what changed and why and if this is a bug in r.watershed or if I need to change settings differently.

Attached you can find the pseudo elevation map as geotiff to try it yourself!

The command I am using is:
r.watershed -m --o elevation=“pseudo_elevation” drainage=“drainage_test” stream=“stream_test” threshold=3

My system:

GRASS version: 7.1.svn
GRASS SVN revision: 65534
Build date: 2015-07-02
Build platform: i686-pc-linux-gnu
GDAL: 1.10.0
PROJ.4: 4.8.0
GEOS: 3.4.2
SQLite: 3.7.9
Python: 2.7.3
wxPython: 2.9.4.1

Any ideas or suggestions?

Best regards,
Johannes

(attachments)

pseudo_elevation.png
pseudo_elevation.gtiff (51.9 KB)

Dear GRASS users,

I further elaborated on this issue of r.watershed and I found what is actually causing this strange behaviour. It seems that r.watershed cannot handle (pseudo)elevation values data are larger than >2100000. My procedure is working value if the values are smaller, but I get an error message (see previous email) if my elevation map contains e.g. 2200000.

Here small working example using the NC dataset to reproduce the behaviour of getting stream segements (and stream order) from a raster river network without having the original elevation map available.

···

On Thu, Jul 2, 2015 at 2:18 PM, Johannes Radinger <johannesradinger@gmail.com> wrote:

Hi,

I tried something that was working at least several months ago, but somehow r.watershed has changed. What I am trying to do is to extract a stream network from a pseudo elevation map. This pseudo elevation map is created by getting the distance of each stream cell from to outlet in upstream direction (using r.cost). In addition, the streams are buffered (3 cells wide) with cells of a value that is much greater than the actual stream value. This map has several features: 1) The cell values for the stream are certainly decreasing in downstream direction (=elevation is decreasing) 2) The stream is carved into a valley (important at river junctions where two streams meet). So this should actually meet the requirements for r.watershed (at least it was working some time ago) to extract the stream and get the drainage directions (e.g. for other tools like r.stream.order etc.).

Now, when I try to run r.watershed (GRASS7.1) I get following warning several times:

WARNING: MFD: cumulative proportion of flow distribution not 1.0 but
-0.000000

Although I get a drainage map as output, no output is created for the extracted stream network. I am wondering what changed and why and if this is a bug in r.watershed or if I need to change settings differently.

Attached you can find the pseudo elevation map as geotiff to try it yourself!

The command I am using is:
r.watershed -m --o elevation=“pseudo_elevation” drainage=“drainage_test” stream=“stream_test” threshold=3

My system:

GRASS version: 7.1.svn
GRASS SVN revision: 65534
Build date: 2015-07-02
Build platform: i686-pc-linux-gnu
GDAL: 1.10.0
PROJ.4: 4.8.0
GEOS: 3.4.2
SQLite: 3.7.9
Python: 2.7.3
wxPython: 2.9.4.1

Any ideas or suggestions?

Best regards,
Johannes