I have Contour lines shapefile which I imported that into GRASS and converted to a DEM using the IDW interpolation technique (r.surf.idw with npoints 250). Now I want watershed analysis to be done where I can get Flow accumulation, Flow direction, basin, Stream order, drainage pattern etc.

When I Try to run r.fill.dir after a while GRASS crashes and the process doesn't give any output. I have tried other hydrologic modelling under raster but it does the same.

Can anybody help me out with the procedure of doing this analysis in GRASS GIS.

  • Welcome to GIS SE! As a new user be sure to take the Tour to learn about our focussed Q&A format. In what precise way were you "not that successful"?
    – PolyGeo
    Nov 11, 2016 at 4:37
  • 1
    Please read grasswiki.osgeo.org/wiki/Contour_lines_to_DEM for correct ways to generate a DEM from contour lines
    – markusN
    Nov 12, 2016 at 17:31

1 Answer 1


Instead of filling depression, you can use r.watershed command for your purpose. you don't need to remove depression as post processing due to the module works with least-cost algorithm. You can refer the manual with

g.manual r.watershed

or, https://grass.osgeo.org/grass73/manuals/r.watershed.html.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.