Progress in Spatial Data Handling pp 825-844 | Cite as

# I/O-Efficient Hierarchical Watershed Decomposition of Grid Terrain Models

## Abstract

Recent progress in remote sensing has made massive amounts of high resolution terrain data readily available. Often the data is distributed as regular grid terrain models where each grid cell is associated with a height. When terrain analysis applications process such massive terrain models, data movement between main memory and slow disk (*I/O*), rather than CPU time, often becomes the performance bottleneck. Thus it is important to consider I/O-efficient algorithms for fundamental terrain problems. One such problem is the hierarchical decomposition of a grid terrain model into *watersheds*—regions where all water flows towards a single common outlet. Several different hierarchical watershed decompositions schemes have been described in the hydrology literature. One important such scheme is the *Pfafstetter* label method where each watershed is assigned a unique label and each grid cell is assigned a sequence of labels corresponding to the (nested) watersheds to which it belongs.

In this paper we present an I/O-efficient algorithm for computing the Pfafstetter label of each cell of a grid terrain model. The algorithm uses *O*(*s* rt(*T*)) I/Os, the number of I/Os needed to sort *T* elements, where *T* is the total length of the cell labels. To our knowledge, our algorithm is the first efficient algorithm for the problem. We also present the results of a experimental study using massive real life terrain data that shows our algorithm is practically as well as theoretically efficient.

## Keywords

Drainage Area United States Geological Survey External Memory Left Child Lower Neighbor## Preview

Unable to display preview. Download preview PDF.

## References

- 1.Aggarwal A, Vitter JS (1988) The Input/Output complexity of sorting and related problems. Communications of the ACM 31(9):1116–1127CrossRefGoogle Scholar
- 2.Arge L (2002) External memory data structures. In: Abello J, Pardalos PM, Resende MGC (eds) Handbook of Massive Data Sets. Kluwer Academic Publishers, pp 313–358Google Scholar
- 3.Arge L (2003) The buffer tree: A technique for designing batched external data structures. Algorithmica 37(1):1–24CrossRefGoogle Scholar
- 4.Arge L, Barve R, Hutchinson D, Procopiuc O, Toma L, Vengroff DE, Wickremesinghe R (2002) TPIE User Manual and Reference (ed 082902). Duke University. The manual and software distribution are available on the web at http://www.cs.duke.edu/TPIE/Google Scholar
- 5.Arge L, Chase J, Halpin P, Toma L, Urban D, Vitter JS, Wickremesinghe R (2003) Flow computation on massive grid terrains. GeoInformatica 7(4):283–313CrossRefGoogle Scholar
- 6.Brodal GS, Katajainen J (1998) Worst-case efficient external-memory priority queues. In: Proc Scandinavian Workshop on Algorithms Theory (= LNCS 1432), pp 107–118Google Scholar
- 7.Chiang YJ, Goodrich MT, Grove EF, Tamassia R, Vengroff DE, Vitter JS (1995) External-memory graph algorithms. In: Proc ACM-SIAM Symp on Discrete Algorithms, pp 139–149Google Scholar
- 8.Freeman T (1991) Calculating catchment area with divergent flow based on a regular grid. Computers and Geosciences 17:413–422CrossRefGoogle Scholar
- 9.Gabow HN, Bentley JL, Tarjan RE (1984) Scaling and related techniques for geometry problems. In: Proc of 16
^{th}ACM Symp on Theory of Computing, pp 135–143Google Scholar - 10.Jenson S, Domingue J (1988) Extracting topographic structure from digital elevation data for geographic information system analysis. Photogrammetric Engineering and Remote Sensing 54(11):1593–1600Google Scholar
- 11.Morris D, Heerdegen R (1988) Automatically derived catchment boundary and channel networks and their hydrological applications. Geomorphology 1:131–141CrossRefGoogle Scholar
- 12.O’Callaghan JF, Mark DM (1984) The extraction of drainage networks from digital elevation data. Computer Vision, Graphics and Image Processing 28Google Scholar
- 13.Peucker TK (1975) Detection of surface specific points by local parallel processing of discrete terrain elevation data. Computer Graphics and Image Processing 4:375–387Google Scholar
- 14.Seaber P, Kapinos F, Knapp G (1987) Hydrologic unit maps (= USGS water supply 2294). 63 pGoogle Scholar
- 15.Tarboton D (1997) A new method for the determination of flow directions and contributing areas in grid digital elevation models. Water Resources Research 33:309–31CrossRefGoogle Scholar
- 16.Verdin KL, Verdin JP (1999) A topological system for delineation and codification of the Earth’s river basins. J of Hydrology 218:1–12CrossRefGoogle Scholar
- 17.Vitter JS (2001) External memory algorithms and data structures: Dealing with MASSIVE data. ACM Computing Surveys 33(2):209–271CrossRefGoogle Scholar