WaterFlow
![](https://img.shields.io/badge/License-MIT-yellow.svg)
WaterFlow is a Go program that provides community-maintained free and open-source hydrology tools, implementing state-of-the-art algorithms found in the literature. WaterFlow tools aim to be API-compatible with ESRI Hydrology toolset but do not necessarily guarantee to produce exactly the same output in the pixel/cell level as ESRI tools.
Install
go get -v github.com/artulab/waterflow
Usage
Import the package:
import "github.com/artulab/waterflow"
Fill
Fill attempts to correct cells of given inRaster by filling sinks/pits.
Parameters
Parameter |
Description |
inRaster |
Input raster data. |
zLimit |
Maximum elevation difference between the sink and its pour point. Those sinks whose elevation difference is greater than zLimit will not be filled. If the zLimit is zero, all sinks will be filled. |
Algorithm
Barnes, R., Lehman, C., & Mulla, D. (2014). Priority-flood: An optimal depression-filling and watershed-labeling algorithm for digital elevation models. Computers & Geosciences, 62, 117-127
Direction (In Progress)
Computes the hydrologic flow directions on the input DEM that directs flow from each grid cell to one or more of its neighbors.
Parameters
Parameter |
Description |
inRaster |
Input raster data. Note that the input raster does not need to be filled beforehand. |
forceFlow |
Determines if edge cells always flow outward or the direction is computed based on normal flow rules. |
computeDrop |
The ratio of the maximum change in elevation from each cell along the direction of flow to the path length between centers of cells, expressed in percentages. |
skipFillingOneCellSinks |
The tool fills one-cell sinks by default on inRaster. Set true if the input raster is already filled or this is not desired. |
Algorithm
Survila, K., Yildirim, A. A., Li, T., Liu, Y. Y., Tarboton, D. G., & Wang, S. (2016, July). A scalable high-performance topographic flow direction algorithm for hydrological information analysis. In Proceedings of the XSEDE16 Conference on Diversity, Big Data, and Science at Scale (pp. 1-7).
Run tests
go test
Authors
Ahmet Artu Yildirim
Contributing
Contributions, issues and feature requests are welcome!
Feel free to check issues page.
Show your support
Give a ⭐️ if this project helped you!
License
This project is MIT licensed.