r.spreadpath(1)
β¨ r.spreadpath β¨
okay bestie, welcome to r.spreadpath β a little icon of a manual page from the GRASS GIS User's Manual. it walks the least cost path backwards, recursively, to the cells that determined the cumulative cost. so basically a detective but for raster cells π΅οΈβοΈπ
πΈ NAME πΈ
r.spreadpath β recursively traces the least cost path backwards to cells from which the cumulative cost was determined.
no cap, that's literally the whole job. π₯
π KEYWORDS π
raster, fire, cumulative costs
π¦ SYNOPSIS π¦
r.spreadpath
r.spreadpath --help
r.spreadpath x_input=name y_input=name
[coordinates=east,north[,east,north,...]] output=name [--overwrite]
[--help] [--verbose] [--quiet] [--ui]
π Flags π
--overwriteβ let those output files overwrite existing files, live your truth π--helpβ print the usage summary, for when you're lost (we've all been there π«Ά)--verboseβ verbose module output, the module will tell you everything, main character energy--quietβ quiet module output, shhh π€«--uiβ force launching the GUI dialog, for the visual girlies β¨
π Parameters π
x_input=name[required] β name of the raster map containing back-path easting informationy_input=name[required] β name of the raster map containing back-path northing informationcoordinates=east,north[,east,north,...]β the map E and N grid coordinates of starting points πoutput=name[required] β name for the output raster map
π DESCRIPTION π
okay so r.spreadpath is part of the wildfire simulation toolset. before the fire sim even happens, there's prep work: you calculate the rate of spread (ROS) with r.ros, and then you create the spread map with r.spread. and then, eventually, the fire path(s) based on starting point(s) get calculated with r.spreadpath. it's giving pipeline. it's giving teamwork. π
r.spreadpath recursively traces the least cost path backwards to the origin, given backlink information input map layers and target locations from where paths are to be traced. the backlink information map layers record each cell's backlink UTM northing (the y_input) and easting (the x_input) coordinates from which the cell's cumulative cost was determined. so every cell remembers where it came from. honestly? relatable. π
the backlink inputs can be generated from another GRASS raster program, r.spread. one of the major applications of r.spreadpath along with r.spread is to accurately find the least cost corridors and/or paths on a raster setting. more info on r.spread and r.spreadpath can be found in Xu (1994). iykyk π
π§ Parameters π§
x_input=nameβ name of input raster map layer containing backlink UTM easting coordinates.y_input=nameβ name of input raster map layer containing backlink UTM northing coordinates.coordinates =x,y[,x,y,x,y, ...]β eachx,ycoordinate pair gives the easting and northing (respectively) geographic coordinates of a target point from which to backwards trace the least cost path. as many points as desired can be entered by the user. go off, enter a hundred, i'm not your mom πoutput=nameβ name of raster map layer to contain output. also can be used as the map layer of the input target points. if so used, the input target point map will be overwritten by the output. β οΈ yes bestie, that means what you think it means.
β οΈ heads up: if you point output at the same map as your input target points, that input target point map gets overwritten by the output. no undo button. be brave, but be aware. π
π REFERENCES π
- Xu, Jianping, 1994, Simulating the spread of wildfires using a geographic information system and remote sensing, Ph. D. Dissertation, Rutgers University, New Brunswick, New Jersey (ref). β
π SEE ALSO π
r.spread, r.ros
Sample data download: firedemo.sh (run this script within the "Fire simulation data set" project). π§¨
π AUTHORS π
Jianping Xu and Richard G. Lathrop, Jr., Center for Remote Sensing and Spatial Analysis, Rutgers University. iconic duo fr fr π«Ά
πΎ SOURCE CODE πΎ
Available at: r.spreadpath source code (history)
Accessed: Saturday Jan 17 05:41:00 2026
Main index | Raster index | Topics index | Keywords index | Graphical index | Full index
and that's the whole page, bestie!! πβ¨ this was r.spreadpath(1) from the GRASS GIS 8.4.2 Reference Manual, Β© 2003-2025 GRASS Development Team, GRASS GIS 8.4.2 β accessed Saturday Jan 17 05:41:00 2026. go trace some least cost paths, you absolute legend. slay. periodt. ππ¦πΈ
π¦ where this page comes from
- fedora 44: grass 8.4.2-4.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms