<div dir="ltr">Hi Stefan,<br><div><br>On Fri, Jun 14, 2019 at 10:03 PM Stefan Blumentrath <<a href="mailto:Stefan.Blumentrath@nina.no">Stefan.Blumentrath@nina.no</a>> wrote:<br>><br>> Hei,<br>><br>> Before investing time in getting r.terraflow to work on larger regions I actually tried r.fill.dir.<br>><br>> The problem is that the results are significantly different and those of r.terraflow and r.hydrodem (where no breaching is performed) are more suitable for my needs. Here, r.terraflow fills most, r.fill.dir least and r.hydrodem inbetween.<br><div><br></div><div>I remember from previous tests that r.fill.dir might need several runs. Using elevation from nc_spm_08 as in your example, r.fill.dir apparently needs to be run 5 times to resolve all problem areas. Maybe you get the desired results by running r.fill.dir multiple times, using the output of the previous run as input for the next run. r.fill.dir should also use far less resources (disk space and memory) than r.terraflow or r.hydrodem.</div><div><br></div><div>Markus M<br></div><div>></div>> Here a little comparison based on NC data:<br>><br>> g.extension extension=r.hydrodem operation=add<br>> g.region -p raster=elevation<br>><br>> r.fill.dir --overwrite --verbose input=elevation output=elevation_fill_dir_depressionless direction=elevation_fill_dir_direction areas=elevation_fill_dir_pas<br>><br>> r.hydrodem -a --overwrite input=elevation memory=5000 output=elevation_hydrodem_depressionless<br>><br>> r.terraflow --overwrite --verbose elevation=elevation filled=elevation_terraflow_depressionless memory=5000<br>><br>> for m in terraflow fill_dir hydrodem<br>> do<br>> r.mapcalc --o expression="${m}_effect=if((elevation_${m}_depressionless-elevation)>0,elevation_${m}_depressionless-elevation,null())"<br>> done<br>><br>> r.univar map="terraflow_effect"<br>> total null and non-null cells: 2025000<br>> total null cells: 1901290<br>><br>> Of the non-null cells:<br>> ----------------------<br>> n: 123710<br>> minimum: 7.62939e-06<br>> maximum: 12.5168<br>> range: 12.5168<br>> mean: 1.49711<br>> mean of absolute values: 1.49711<br>> standard deviation: 1.97871<br>> variance: 3.91528<br>> variation coefficient: 132.169 %<br>> sum: 185206.976940155<br>><br>> r.univar map="fill_dir_effect"<br>> total null and non-null cells: 2025000<br>> total null cells: 1964852<br>><br>> Of the non-null cells:<br>> ----------------------<br>> n: 60148<br>> minimum: 7.62939e-06<br>> maximum: 10.9003<br>> range: 10.9003<br>> mean: 0.499953<br>> mean of absolute values: 0.499953<br>> standard deviation: 0.939429<br>> variance: 0.882526<br>> variation coefficient: 187.903 %<br>> sum: 30071.1971092224<br>><br>> r.univar map="hydrodem_effect"<br>> total null and non-null cells: 2025000<br>> total null cells: 1020396<br>><br>> Of the non-null cells:<br>> ----------------------<br>> n: 1004604<br>> minimum: 3.8147e-06<br>> maximum: 4.74686<br>> range: 4.74685<br>> mean: 0.00587574<br>> mean of absolute values: 0.00587574<br>> standard deviation: 0.08715<br>> variance: 0.00759513<br>> variation coefficient: 1483.22 %<br>> sum: 5902.79515457153<br>><br>> Cheers<br>> Stefan<br>> ________________________________<br>> Fra: Markus Metz <<a href="mailto:markus.metz.giswork@gmail.com">markus.metz.giswork@gmail.com</a>><br>> Sendt: fredag 14. juni 2019 14.25<br>> Til: Stefan Blumentrath<br>> Kopi: <a href="mailto:grass-dev@lists.osgeo.org">grass-dev@lists.osgeo.org</a><br>> Emne: Re: [GRASS-dev] r.terraflow vs. r.hydrodem<br>>  <br>><br>><br>> On Fri, Jun 14, 2019 at 1:23 PM Stefan Blumentrath <<a href="mailto:Stefan.Blumentrath@nina.no">Stefan.Blumentrath@nina.no</a>> wrote:<br>> ><br>> > Hi,<br>> ><br>> > While trying to make r.terraflow work with larger regions, I was wondering if it would be doable to add a flag to r.hydrodem that forces the module to perform only sink filling and no breaching / carving?<br>> ><br>> > Sink filling is the function I need from r.terraflow but if it would be an option to add this function to r.hydrodem, that would be fine as well of course...<br>><br>> what about r.fill.dir? It should work as is with larger regions.<br>><br>> Markus M<br>><br></div></div>