User Manual

  1. Click anywhere on the map
  2. Confirm the messages
  3. Stay patient
  4. Download the result if you like it
  5. Show the watershed climate statistic

Tipps & Tricks

  • Use the rainviewer in the lower left corner to see global current radar rain data
  • Use fullscreen for better experience

June 2023

Motivation

Hydrological analyses from DEMs (digital elevation models) for various classic GIS analyses always took plenty of time and resources. This tool is for everyone looking for quick and easy hydrological analysis.

Wild guessing river runoffs for my main hobby river surfing led to the development of this project. Web developments with integrated GIS solutions became my main interest and projects like this give me the opportunity to improve.

June 2023

Behind the Scenes

Since 2019, I've invested time planing, developing my own algorithm for watershed delineation based on the HydroSheds dataset. However, for practical reasons, I’m currently using the API provided by MGHydro. Their tool delivers cleaner and more accurate results. Feel free to check out his nice project—it's definitely worth a look!

That said, I’m still actively working on improving my own solution and hope to return to using it soon. Development continues!

May 2025

HydroSHEDS Dataset

HydroSHEDS (Hydrological data and maps based on SHuttle Elevation Derivatives at multiple Scales) provides consistent hydrographic information on a global scale. It contains various geodata sets including river networks, watershed boundaries, drainage directions, and flow accumulations.

The HydroBASINS product contains a global consistent coverage of nested sub-basins at different scales, which is supported with coding schemes that allow various analyses (Lehner and Grill, 2013).

June 2023

Pfaffstetter coding

The code behind the scenes

Is a nested coding system for horological river basins. It allows to identify upstream and downstream basins.

Basically, a basin is subdivided into 9 smaller basins and labeled from 1 to 9. Each sub-basin is divided again by 9 and labeled by appending the number to previous code numbers. Like this, the more levels of subdividing the more digits the code will have (Verdin and Verdin, 1999). The HydroBasins dataset comes with 12 levels.

In the context of this project, I wrote a short Python module for decoding, available at github.com/steinmnn/pfafhydrocode.

June 2023

FAQ

  • Why is the watershed polygon not exactly bordering my marker? The algorithm selects basins from a global consistent coverage of smaller sub-basins. The query is limited by the smallest polygon resolution (Pfaffstetter Level 12) of the HydroBASINS dataset. Therefore, the tool is not suitable for smaller streams.
  • Why does the download of the rivers as GeoJSON throw an error sometimes? The watershed is too big. The rivers.geojson can become quite big, and the download size is currently limited to a maximum of 5 MB.

June 2023

Issues

  • Slow calculating of watersheds. For big watersheds, computation time is up to 20 seconds. It is questionable that further optimizations will significantly reduce this. Anyway, I want to implement celery workers in the future to have proper asynchronous tasks and provide a smoother user experience.
  • Pfaffstetter decoding issue. The Python module I wrote at github.com/steinmnn/pfafhydrocode occasionally misses basins while watershed computations. I present this notebook on my website which discusses the problem and presents a dirty workaround also used in this project.

June 2023

Roadmap

  • Zoom to Watershed Button. A button within the leaflet map to center the watershed.
  • Add Radar Accumulation of the last 24h Better guessing of runoffs!
  • Integrate the HydroWASTE dataset. Another layer that shows all the wastewater plants. Through this, the water quality can be estimated.

June 2023