The Nile River Basin from SRTM data

Someone asked the other day whether the cross-platform, free and open-source GIS Whitebox GAT can handle watershed delineation from massive, regional-scale DEMs. They had a particular interest in the Nile River basin. Heck, if you’re going to go big, why not go huge, right? So I decided to give it a try. First off, I used the Retrieve SRTM Data tool to download the approximately 800 SRTM 3-arcsecond (~90 m) tiles that make up the Nile River basin. This required some experimentation because my first attempt at doing so hit the boundary of the basin and I had to give it a second try. The tool downloaded each of the tiles and mosaicked them into a single large DEM. The final DEM was 45,601 rows by 25,201 columns (a little over 1.1 billion grid cells) and was 4.28 GB in size. I then used the new Breach Depressions (Fast) tool to hydrologically pre-process the DEM by removing artifact topographic depressions and flat areas (i.e. cells with no downslope neighbours). I used a D8 flow algorithm to calculate flow directions, perform flow accumulation, trace the flowpaths issuing from Lake Victoria (the White Nile) and Lake Tana (the Blue Nile), and lastly, to delineate the watershed. The result was this map:

The Nile River Basin (click to enlarge)

The Nile River Basin (click to enlarge)

To fully appreciate this amazing map, you need to enlarge it. Just to put a bit of perspective on the scale of this analysis, take a look at this one:

Nile River World Map (click to enlarge)

Nile River World Map (click to enlarge)

All of Europe has an area of approximately 10,180,000 km2 and the Nile River basin has an area of 3,400,000 km2. That is truly vast.

For my initial attempt, the one in which I truncated the watershed, I used my 13 inch Macbook Pro (2.8 GHz dual-core i7, 16 GB RAM, SSD). When I expanded the area, I also moved to my workstation (3.0 GHz 8-core Xeon, 64 GB RAM, SSD) just to speed up the process a little. I even extracted a long-profile for the White and Blue Nile, although I should have converted the distance units to metres:

Long profile for the Nile River, extracted from SRTM 3-arcsecond data (click to enlarge)

Long profile for the Nile River, extracted from SRTM 3-arcsecond data (click to enlarge).

It was the longest river that I have ever plotted a long profile for; of course, it is the longest river so I guess you can’t get much larger than that! I probably should have extracted the river network using a dispersive flow algorithm like Tarboton’s excellent D-infinity, since there are places where the river bifurcates (i.e. the river course splits), even before the delta. Nonetheless, I’m quite pleased with the result. In fact, I was quite surprised at how well the river course, extracted from the 90 m resolution SRTM DEM data, matched a mapped Nile River shapefile that I located:

Mapped vs. extracted river (click to enlarge)

Mapped vs. extracted river (click to enlarge)

Leave your comments below and, as always, best wishes and happy geoprocessing.


7 thoughts on “The Nile River Basin from SRTM data

  1. James says:

    I was the one who posted the initial question on the stack exchange. Many many thanks for introducing me to Whitebox GAT. I wasted days and days trying to do much smaller watersheds in GRASS and ArcGIS unsuccessfully.

    I have some big projects in mind. I seriously need to hunt around for some more RAM and make use of this!

    • Hi James,

      Thank you for asking this question. It was a lot of fun for me to explore. I hope that Whitebox GAT works for you for your applications. Yes, having a computer with a lot of RAM is quite essential when you’re working with massive datasets. Also, a SSD is much better than a hard drive for these applications. If you have any difficulties just send me an email and I’d be happy to walk you through the process. Good luck.



  2. surajitdb says:

    Hi John,
    I need to extract DEM for Brahmaputra river basin, whose lat and long are 24°44’ to 30°3’ north latitudes and 88°11’ to 96°57’ east longitudes using Whitebox GAT 3.4 Montreal. I have been not able to extract/delineate the DEM from SRTM [3-arcsecond (90 m)] using Whitebox 3.4 as I am getting an error as: “An error has occurred during operation. See log file for details”.

    I have tried setting different combinations of lat/long such that the river basin is within the mosaiked DEM. What might have gone wrong?

    Thanking you.



    • Hi Surajit,

      I think that the web service where SRTM data can be downloaded by individual tiles is down at the moment. I think that NASA/USGS prefers people to download the data set from their various web portals (e.g. EarthViewer). Unfortunately there won’t be anything that I can do about this change and it is likely that the Retrieve SRTM DEM Data tool will need to be disabled at some point in the future.





Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s