Mappings Of Stream Channel Networks Computer Science Essay

Published: Last Edited:

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.

The proper mappings of stream channel networks have always been very important to delineation of watersheds and other hydrological models. A stream channel network is a digital representation of waterways. A number of different methods have been proposed to process digital elevation models (DEMs) automatically to extract drainage networks and measure their properties (O'Callaghan and Mark, 1984; Jenson and Domingue, 1988). The most widely used method for automatically delineating drainage networks from DEMs are based on deterministic (D8) flow direction method and the use of an arbitrary constant threshold value for the minimum contributing area needed to form a stream. The stream threshold value choice will have influence on the drainage networks. This procedure is implemented in most GIS software like ESRI ArcGIS.

A significant challenge is to select the appropriate threshold value that will result in delineating stream network from DEM that corresponds to network obtained from traditional method (Tarboton et al. 1991).This will lead to selecting the threshold on trial and error bases until the resulted drainage network resemble the network from digitize map. Towards this end, several authors over the past decades have suggested various quantitative (statistical) methods to describe the properties of drainage networks.

The quantitative analysis of the properties of the drainage network can be use to choose an appropriate threshold value objectively. Tarboton et al. (1991) investigated the use of constant stream drop property to select the most appropriate threshold objectively. Montgomery and Foufoula-Georgiou (1993) also proposed a method to objectively select an appropriate threshold based on slope and area law.

This focus of this present study is twofold. First of all, examining the above mentioned procedures and investigate the effects of altering some of the properties of the drainage networks. The resulting drainage density will be compared with results from other procedures in literature. Secondly, the study will also focus on the implementation of the above procedures as an ArcGIS toolbar using python programming. Python is a cross platform language and is officially supported by most GIS packages.


Today, most GIS packages are open for users to create customization at any level, automating tedious work in processing data. Similarly, GIS packages contain basic terrain analysis (watershed) procedures. However, they lack the flexibility and advanced functionality needed by new users. Therefore, there is the need to develop terrain analysis extensions to provide the needed flexibility and also to achieve the advanced functionality. GIS extensions are developed as GIS add-ins.

This section comprises of term and their definitions most relevant to this study and which will be used frequently in this proposal.

2.1 Python add-in

An add-in is a customization that plugs into GIS Desktop applications, to provide supplemental and flexible functionality for accomplishing custom tasks (ArcGIS Resources). GIS Desktop applications rely on programming languages and collection of existing tools for developing add-ins. The introduction of add-ins model in ArcGIS 10 has facilitated the building, installing and sharing of ArcGIS add-ins. The add-ins can be authored in .NET, Java and new at ArcGIS 10.1, python.

ArcGIS Python add-in is a single compressed file with Esri add-in extension. It contains config.xml for defining add-in properties, python script and resource files such as images (Arc GIS Resources). Python add-ins are authored in python, therefore making add-ins easier to build. Furthermore the python Add-In Wizard is used to simplify the development of python add-ins. Python does not require compiling DLLs to build an add-ins and also the number of lines of code required to execute a specific task is less as compare to .NET or Java. Python add-ins do not need com registrations and is also cross platform.

2.2 Properties of channel networks

Studies in geomorphology over the past decades has largely been on the development of quantitative methods to describe the properties of drainage networks(Horton,1945;Strahler ,1957; Shreve ,1996;Tarboton et al.,1991,). Studies have shown that the properties of channel networks can be determined quantitatively. Therefore it is necessary to know the relative terms of the properties of the channel networks.

2.2.1 Stream Order

The method for characterizing stream networks is called Stream Ordering. This is done by assigning numerical values to streams on the basis of their position in the network. It is the first step of quantitative analysis of Watershed. Horton (1932, 1945) first introduced the stream ordering systems. However strahler (1957) suggested a modification to Horton's theory. The Strahler method begins by assigning an order of 1 to first-order stream (stream that has no tributaries). The order increases as each link is encountered. For example, the intersection of two first-order result to second order. However, the order only increases at the intersections of the same order. When a stream of a given order receives a tributary of lower order, its order does not change. There are several methods of ordering streams such as Shreve method. Following this, the ordering system to be used in this proposal is the strahler ordering system. Horton also proposed stream length ratio and stream slope ratio.

2.2.2 Stream Length Ratio

Horton (1945, p.291) stated that the length ratio is the ratio of the mean length of stream of order r(Lr) to the mean length of segments of the next lower order (Lr-1), is constant throughout the successive orders of the watershed .

2.2.3 Slope ratio

Horton (1945) stated that the slope ratio is the ratio of the mean slope of stream of lower order (S r-1) to the mean slope of streams of the next higher order (Sr), is constant throughout the successive orders of a watershed.

2.2.4 Stream Drop

Stream drop is defined in literature as the difference in elevation between the beginning and end of Strahler streams of the same order.

2.2.5 Constant drop property

The average stream drop along strahler streams of order w (Hw) is constant .i.e. independent of order (Broscoe, 1959 cited by Tarboton et al.1991). Ideally stream length ratio is equal to slope ratio. Other researchers also equate them to Constant drop Property.

2.3 Fundamentals of DEM Method for Watershed

A short overview of the fundamentals of automatic delineation of stream networks is given.

Grid-base DEMs have seen widespread application in the automatic watershed delineation than the other DEMs representations. This is because, it is readily available and simple to use (Moore et al., 1991).However care must be taken about the resolution of the DEM. Following this, grid-base DEM will be used in this study.

Pit removal is the first thing to do with a DEM.A pit is a cell or cells surrounded by higher-elevation values. Unless these pits are removed they become sinks and separate portions of the watershed. Pits are removed from DEMs using the standard approach described by Jenson and Domingue (1988) that is to increase pit cell value to the lowest overflow point out of the sink. There are other methods used to remove pit but the one describe above is the most widely used.The next and perhaps most fundamental step in the watershed delineation process is the "Flow Direction". A flow direction raster shows the direction water will flow out of each cell of a filled DEM using the elevation in the DEM. The accuracy of this step determines the stream flow paths, subwatersheds boundaries and the outlets of the stream. The D8 method assigns a cell's flow direction to the one of its eight surrounding cells that has the steepest distance weighted gradient (O'Callaghan and Mark, 1984) and it has been widely used as discussed in Tarboton (1997).However there exist some problem with D8 method as recognized by various authors including Tarboton (1997). Multiple flow direction methods have also been suggested. These proportion flows from a grid cell between more than one downstream grid cell, and by doing this avoid some of the biases associated with D8 flow directions, resulting in better estimates of drainage area, especially on hill slopes (Tarboton and Ames, 2001).An example is the D Infinity method which partitions flow from a cell into two adjacent cells.( Tarboton ,1997).

The next step is the calculation of contribution area, which is the drainage area contributing to each grid cell or by calculating the weight of each cell in the grid, based on the number of cells that flow into that cell and then assigns that weight to a new grid. The later is the most widely used method.

The most widely use method for delineating stream network uses an arbitrary support area threshold applied to the contribution area. The stream networks start points are mapped as those grid cells where the support threshold is exceeded. Hence, the accuracy of the stream depends on the support threshold. However, other researchers have also suggested the use of constant stream drop property and other terrain attributes to objectively select the support threshold.


The advent of Digital Elevation Model (DEM) have spurred growth in research and developments of automatic, computer-based channel network models that use digital elevation data as their primary input (Moore,et al.,1991). Today, tools used for delineating watershed and other hydrological analysis can include anything from websites to open source programs for standalone computers. United States Geological Survey for instance has developed a tool for web based geographical information systems known as StreamStats. The primary functionality of StreamStats allows users to delineate drainage-base boundaries and also obtain basin characteristics (Kernell et al., 2009).

Peucker and Douglas (1975) use DEM to identify potential streams. They employed the 'upward concave' and 'convex' procedure. This algorithm flags the pixel of highest elevation from each possible square of four adjacent grid cells. After one sweep of the matrix the unflagged grid cells represent drainage courses. Kikuchi, et al. (1982) developed a FORTRAN program called 'HILO' (High and Low Point Detection) base on the Peucker and Douglas algorithm to delineate streams.

Pack, Tarboton, and Goodwin (1998) developed a terrain stability mapping tool Called SINMAP (Stability Index Mapping) which uses a DEM in a GIS to compute and map slope stability. SINMAP was first developed for ArcView 3.0 in 1998, but now has been implemented by the author as an ArcGIS toolbar which is programmed with ArcObjects, Visual Basic and Visual C++.

Garbrecht and Martz (1992) conducted a study to initiates delineating subwatersheds at source points and at the points of intersection of drainage using DEM.They developed a tool based on their study called TOPAZ (Topographic Parameterization).TOPAZ is widely used by hydrologists .One of the capabilities of TOPAZ is its ability to remove all the depressions in the DEM.However, TOPAZ has limitation of been restrictive in analysis. It precludes the delineation of subwatersheds around specific points of interest.

Akinchan and Aruna (2012) presented a new approach to derive the Geomorphological parameters and to delineate watersheds using Free Open Source Software (FOSS), GRASS GIS. GRASS GIS provides complete tools for the quantitative analysis of drainage and watershed analysis such as stream flow direction, flow accumulation, drainage network extraction and stream network. Different ordering system including Horton, hack and Topological Diameter is available in GRASS GIS, presently not available in other software‟ (Jaroslaw and Markus 2011, cited by Akinchan and Aruna 2012). GRASS GIS use SEGMENT Library which allows one to make calculations on very large raster map without consuming large space in memory.

Maidment (2002) presented an Arc Hydro as a tool to assist in hydrological analysis.

Arc Hydro is an Add-on tool to ArcGIS software use to build hydrologic information systems which synthesize geospatial and temporal water resources data for hydrologic analysis and modelling (Maidment, 2002).He used the tool to populate the attributes of the features in the data framework and interconnected the features in different data layers. Arc Hydro is use for raster analysis of digital elevation models to produce drainage features.

Even though there are more tools developed for the extraction of stream networks and other hydrological attributes from DEM, they are mostly based on D8 flow direction method and an arbitrary constant threshold for the minimum contributing area needed to form a stream channel. One of the limitations with choosing an arbitrary constant threshold is the trial and error nature of the method, because the resulted stream network should look like networks digitized from a topographical map. Trial and error wastes time and is based on personal choice.

Further work has been done in the determination of the constant threshold, Tarboton et al. (1991) and Montgomery and Foufoula-Georgiou (1993) have investigated using quantitative approaches to derive stream threshold objectively. The quantitative methods used are constant drop property law and using the slope and area power law. However, slope and area are dependent on the soil and climate therefore should be taken into consideration.

Tarboton (2003) presented Terrain Analysis Using Digital Elevation Models (TauDEM) tool set as a set of functions for delineating stream networks and other drainage attributes from digital elevation models (DEM).TauDEM uses a method for the delineation of drainage networks based on the weighted accumulation of upwards curved grid cells. It is adaptive to spatial variability in drainage density. The weighted support area threshold is chosen objectively using a t test to select the highest resolution drainage network with mean drop of first order streams not significantly different from the mean drop of higher order streams (Tarboton, and Ames, 2001).Therefore, the trial and error method is avoided in TauDEM. TauDEM is implemented as an ArcGIS extension using Visual Basic, C++ and the ESRI ArcObjects library. The software accesses data in the ESRI grid data format directly using the GRIDIO application programmers' interface that is part of ArcGIS.

Key Issues for Further Research

Terrain analysis using Digital Elevation Model (TauDEM) is one of the most successful ArcGIS extensions as far as hydrological analysis is concerned. Even though TauDEM has solved the issue of choosing arbitrary threshold, there are some loopholes which need to be investigated. The first one is concerned with the issue of flexibility in the usage of TauDEM. TauDEM is written in C++ and it depends on third party software (MPICH2 library) for its usage in ArcGIS. Some of its functions are executed through command line which is inconvenient to new users. The installation of MPICH2 follows series of steps which is also difficult for inexperienced people. Hence, there is the need to develop an extension like TauDEM without any support from third party software like MPICH2. This thesis will investigate whether developing an extension like TauDEM using python only will be possible. ArcGIS support python; therefore there is no need for any third party software.

The second concerns the issue of procedure used by TauDEM to delineate channel network. TauDEM is based on D8 flow direction model for delineating a channel network. However, the D8 approach has disadvantages arising from the discretization of flow into only one of eight possible directions (Tarboton, 2003).A possible solution to this challenge is suggested by Tarboton (1997). He suggested a procedure based on multiple directions called D infinity. Therefore, D infinity flow direction method will be investigated in delineating the watershed

Thirdly there is the issue of using T Test to evaluate the difference in mean stream drop between first and higher order streams. Different statistical approach like normal distribution will be used to evaluate the difference and compare the result with the T Test.


The overall aim of this study is to develop a set of GIS tools that takes input from digital elevation model (DEM) to objectively delineate drainage networks and to implement these tools as a toolbar for ArcGIS using python. To achieve this goal, the following objectives have been set:

1. To develop an ArcGIS add-ins using Python, for delineating drainage network in compliant with TauDEM tools.

2. To develop a similar ArcGIS add-ins using D infinity flow direction method rather than D8 flow direction.

3. To investigate the use of normal distribution to evaluate the difference in mean stream drop between first and higher order streams. TauDEM used T-distribution, however normal distribution is preferred over the t distribution when sample contain more than 30 values (Paul and Charles, 1997)

4. To develop an ArcGIS extension for automatic delineation of watersheds based on the most appropriate method for the extraction of the stream networks above.


Research will be based on a Linach valley data. Linach valley is a small valley located in the Black Forest in south-west Germany.


Figure 1: Linach valley, Black Forest, Southwest Germany

The following data sets will be use to create the required DEM:

Contour lines of the topographic map 1:25 000 from the Linach valley, height points digitized from the topographic map and digitized Linach stream from the topographic map. A Topo to Raster tool in ArcGIS will be used to create the DEM.

In terms of the software, ArcGIS10.1 has been selected as the main software for this study since it has proven to be the most efficient and reliable software for spatial analysis. One of the advantages of using ArcGIS is that it is open for users to create customization, extending already existing tools with additional tools for advance functions. ArcGIS 10.1 contains numpy library which is useful for manipulating raster data. As a developer, the availability of sample codes makes it easier to work with ArcGIS .

Python would be used as the programming (scripting) language for the creation of the individual tools. Python is an open source software that can be use to develop another software without paying any royalty or licence fee. It is a cross-platform language and also easy to learn. Python 2.7 is installed with ArcGIS10.1 and it contains ArcPy site-package. Python uses ArcPy to have access to ArcGIS toolbox tools. Hence, developers don't have to waste time inventing their own basic tools if they are available within ArcGIS. One of the flexibility with python is that scripts can be tested without running ArcGIS Desktop.

Python Add-In Wizard will be downloaded from ArcGIS resource centre. Python Add-In Wizard will be used to build the toolbar.  The wizard will generate all the required files necessary for the add-ins to work.


The research methodology proposed for the first part of this study is based on Tarboton (2003) method for delineating drainage network.

The first step is to remove all the pits using Jenson and Domingue (1988) algorithms. The D8 flow direction method will then be used to assign the direction water will flow out of each cell of the filled DEM. In flat areas, where the steepest downwards slope is zero, (Garbrecht and Martz, 1997) theory will be used. Their algorithm assigns flow directions by forcing flow away from higher terrain and towards lower terrain. Calculation of contributing area will be followed after flow direction has been assigned. The area contributing to each cell is computed by counting the number of grid cells that drain through each grid cell and then multiplying each by their grid cell area. Peucker and Douglas (1975) theory will be used to identify upward curved cell from the contributing area. The upwards curved grid cells will then be use as a weighting field in the weighted drainage area computation. The weighted support area threshold will be chosen objectively based on the constant stream drop property of channel networks. The smallest weighted support area threshold that will produce a channel network where the mean stream drop in first order streams will not be statistically different from the mean stream drop in higher order streams is selected using the T Test. The selected threshold will be used to delineate the stream network.

Therefore, the individual tools will be used to build a toolbar using python add-in wizard and the result will be verified in the field (Linach valley dam).

The second toolbar will follow the same procedure as the first one; however, the flow direction method will be changed. D infinity flow direction method will be used to assign the direction water will flow instead of D8 method. The third toolbar will also follow like the first toolbar; however normal distribution will be used to select the threshold whose mean stream drop in first order stream will not be statistically different from the mean stream drop in higher order streams.

Finally, developing an add-in for automatic delineation of watershed based on the most appropriate method for stream network extraction.