Skip to content

r.flowfill

Moves water downhill into pools or the ocean/map edge

r.flowfill input=name np=integer [threshold=float] [h_runoff=float] [h_runoff_raster=name] [ties=string] [ffpath=string] [output=name] [water=name] [--overwrite] [--verbose] [--quiet] [--qq] [--ui]

Example:

r.flowfill input=name np=integer

grass.script.run_command("r.flowfill", input, np, threshold=0.001, h_runoff=None, h_runoff_raster=None, ties="PREF", ffpath="flowfill", output=None, water=None, overwrite=False, verbose=False, quiet=False, superquiet=False)

Example:

gs.run_command("r.flowfill", input="name", np=integer)

Parameters

input=name [required]
    Input DEM
    Name of input raster map
np=integer [required]
    Number of processors to use (>= 3)
threshold=float
    Threshold water-surface elevation change to conclude calculation
    Default: 0.001
h_runoff=float
    Initial depth of uniform runoff [thickness in map units]
h_runoff_raster=name
    Initial depth of non-uniform runoff [thickness in map units]
    Name of input raster map
ties=string
    Tie-handling: counterclockwise from Northwest (PREF) or random (RAND)
    Allowed values: PREF, RAND
    Default: PREF
ffpath=string
    Path to the FlowFill executable
    Default: flowfill
output=name
    Output DEM + pooled/remaining runoff
    Name for output raster map
water=name
    Output water depth at the end of the run
    Name for output raster map
--overwrite
    Allow output files to overwrite existing files
--help
    Print usage summary
--verbose
    Verbose module output
--quiet
    Quiet module output
--qq
    Very quiet module output
--ui
    Force launching GUI dialog

input : str, required
    Input DEM
    Name of input raster map
    Used as: input, raster, name
np : int, required
    Number of processors to use (>= 3)
threshold : float, optional
    Threshold water-surface elevation change to conclude calculation
    Default: 0.001
h_runoff : float, optional
    Initial depth of uniform runoff [thickness in map units]
h_runoff_raster : str, optional
    Initial depth of non-uniform runoff [thickness in map units]
    Name of input raster map
    Used as: input, raster, name
ties : str, optional
    Tie-handling: counterclockwise from Northwest (PREF) or random (RAND)
    Allowed values: PREF, RAND
    Default: PREF
ffpath : str, optional
    Path to the FlowFill executable
    Default: flowfill
output : str, optional
    Output DEM + pooled/remaining runoff
    Name for output raster map
    Used as: output, raster, name
water : str, optional
    Output water depth at the end of the run
    Name for output raster map
    Used as: output, raster, name
overwrite: bool, optional
    Allow output files to overwrite existing files
    Default: False
verbose: bool, optional
    Verbose module output
    Default: False
quiet: bool, optional
    Quiet module output
    Default: False
superquiet: bool, optional
    Very quiet module output
    Default: False

DESCRIPTION

r.flowfill runs the FlowFill code (Callaghan and Wickert, 2019) that moves water cell-by-cell to flood depressions in a DEM. It can be used as a simplified/cellular simulation of downslope flow (though not equivalent to physics-based approaches for flow) or as a tool to fill depressions in a DEM. For further information, see the README at https://github.com/KCallaghan/FlowFill.

REFERENCES

Callaghan, K.\~L., and A.\~D. Wickert (in revision), Computing water flow through complex landscapes, part 1: Incorporating depressions in flow routing using FlowFill, Earth Surface Dynamics Discussions, doi:10.5194/esurf-2019-11.

SEE ALSO

r.fill.dir

AUTHORS

Kerry L. Callaghan, Andrew D. Wickert

SOURCE CODE

Available at: r.flowfill source code (history)
Latest change: Thursday Feb 20 13:02:26 2025 in commit 53de819