Science

How Do I Identify and Correct Single-Cell Depressions in a DEM?

How Do I Identify and Correct Single-Cell Depressions in a DEM?
Photo by turek on Pexels

Identify a single-cell depression by locating DEM cells with no lower neighboring cell and an undefined drainage direction, then inspect its depth, footprint, and landscape context before changing it. Fill small, evidently artificial pits to their pour-point elevation; preserve verified real closed depressions; and rerun flow direction and accumulation to confirm that water now reaches an outlet or true sink.

What is a single-cell depression in a digital elevation model?

A single-cell depression, often called a pit or sink, is a raster cell for which no surrounding cell is lower, leaving its drainage direction undefined. In practical terms, a routing algorithm reaches that cell and has nowhere to send the water. The cell is small; the analytical consequence is not.

This pattern can represent a real closed depression. It can also be an artifact of the elevation surface. Esri's explanation of how Fill works identifies data resolution and rounding elevations to the nearest integer as common causes of erroneous sinks and peaks. HydroSHEDS similarly defines sinks as one or more pixels surrounded by higher pixels, while observing that most are spurious deviations rather than natural endorheic depressions.

The first diagnostic is therefore not, "Can this cell be filled?" It is, "What evidence says this cell should interrupt drainage?" Inspect the source DEM, the cell's immediate neighborhood, and any mapped hydrographic context available for the study area. Keep the original raster unchanged and create a separate conditioned copy. That separation preserves the distinction between terrain measurement and terrain prepared for routing.

In ArcGIS Pro, use the Sink tool before Fill to inventory sink locations and depths. Esri defines a sink's pour point as the lowest boundary cell of its contributing area: if the depression filled with water, this is where water would leave. That definition gives a concrete measure for deciding whether a change is modest or consequential.

How Do I Identify and Correct Single-Cell Depressions in a DEM?
Photo by turek on Pexels

Why do single-cell pits cause incorrect flow-direction and watershed results?

Single-cell pits cause incorrect results because they terminate flow paths that should remain continuous across the DEM. Once flow direction stops, the downstream calculations built on it inherit the break: flow accumulation no longer represents the full contributing area, stream paths can be discontinuous, and watershed boundaries can be delineated from an incomplete drainage structure.

This is not merely a cosmetic defect in a hillshade. In the foundational 1988 workflow described by Jenson and Domingue through the U.S. Geological Survey, conditioning produces three connected datasets: a depression-filled DEM, flow direction for each cell, and flow accumulation equal to the total number of cells draining to each cell. Those derivatives then support drainage networks, overland paths, watersheds, sub-watersheds, and pour-point linkages. Break the first dependency and the later products cannot be interpreted as a continuous routing system.

The scale of propagation explains why a one-cell edit deserves restraint. A Virginia Tech study of 66 watersheds using 30-meter USGS DEMs found that depression removal changed elevations in 0% to 11% of cells, with flatter watersheds seeing a larger changed area. Each modified elevation cell changed flow-direction, flow-accumulation, and slope values for an average of two to three cells. Local correction, in other words, has a downstream footprint.

Esri reports published results for non-SDTS USGS 30-meter DEMs in which 0.9% to 4.7% of cells were sinks. In a raster with 1,000 by 1,000 cells, that corresponds to roughly 9,000 to 47,000 sinks. The point is not that every one must be filled. The point is that untreated artifacts can be numerous enough to turn a watershed exercise into a map of raster imperfections.

This logic also applies beyond coursework. When terrain-derived drainage informs property questions, the limits of a DEM should be understood before drawing conclusions about surface-water pathways around a house; it is one useful complement to the broader checks described in What Should I Check Before Buying an Older Bungalow?.

A practical validation sequence

  1. Run a sink inventory on the unmodified DEM and record each candidate's depth and spatial extent.
  2. Review candidates against the terrain and available hydrographic context; flag likely true sinks rather than assuming every low cell is erroneous.
  3. Create a conditioned copy, apply the selected treatment, and retain a raster showing elevation differences from the original.
  4. Generate flow direction and verify that paths are continuous except at retained true sinks.
  5. Generate flow accumulation and delineate the watershed again; compare the new drainage paths and boundary with the pre-treatment result.

The U.S. Geological Survey sets the governing test plainly: hydrologic conditioning should enable continuous water flow while removing isolated pits and retaining real sinks. Its specifications also require that a flow-direction raster from a hydro-conditioned DEM allow continuous flow except where true sinks exist.

Should I fill every sink in a DEM before hydrologic analysis?

No. Fill every artificial sink that would falsely terminate the flow model, but do not erase a real closed depression simply because it is inconvenient for the algorithm. A defensible workflow chooses among fill, a corroborated drainage breach or enforcement treatment, and leaving a true sink unchanged according to evidence rather than automation.

ConditionPreferred responseReason to validate
Small pit consistent with resolution or rounding errorFill to the pour-point elevationConfirm continuous downstream flow after conditioning.
Depression supported as a real sinkLeave unchanged and document itA true sink is an allowed endpoint in a conditioned flow model.
Large or deep filled area suggesting a missing drainage connectionReview for a missing breach feature or enforce the supported networkLarge fills can conceal a drainage representation problem rather than solve one.

ArcGIS Pro's Fill tool offers a useful control: the z-limit. It is the maximum elevation difference allowed between a sink and its pour point. Sinks deeper than that value remain unchanged; qualifying sinks are raised to the pour-point elevation, not merely increased by the z-limit. This makes the parameter a screening rule, not a promise of a particular fill depth. Esri also notes that Fill can require up to four times the disk space of the input raster, so establish a working-data location before processing a large DEM.

Use the z-limit after examining the sink inventory, not before. A blanket run with no z-limit fills all sinks regardless of depth. That is appropriate only when the analysis objective and evidence support removing all of them. The Virginia Tech comparison offers a caution: its evaluated methods generally produced watershed boundaries differing by less than 1%, yet the TOPAZ algorithm affected 30% fewer cells on average than ArcView and made smaller elevation changes. Similar watershed outlines do not prove that the terrain edits were equally restrained.

USGS provides review thresholds for its own hydroconditioning specifications: examine lidar-derived filled areas larger than 1,011 square meters and at least 0.2 meters deep; for IfSAR-derived data, examine areas larger than 4,050 square meters and at least 1 meter deep. These are review triggers in that specification, not universal z-limits for every student project. Their value is methodological: larger or deeper interventions require stronger scrutiny.

The final product should be two clearly named datasets: the source DEM and the conditioned DEM used for hydrologic derivatives. Then report what changed, rerun the derivatives, and state whether retained sinks remain. That is the shortest path from a raster cleanup operation to a watershed result another analyst can audit.

Frequently Asked Questions

How can I distinguish a data-error pit from a real closed depression?

Start with the pit's depth, area, and position relative to mapped drainage and known sinks. Resolution and elevation rounding are documented causes of erroneous pits, while USGS conditioning guidance explicitly retains real sinks. A large or deep filled area deserves review: USGS identifies thresholds of more than 1,011 square meters and at least 0.2 meters deep for lidar-derived data, and more than 4,050 square meters and at least 1 meter deep for IfSAR-derived data.

Which GIS tools can fill single-cell depressions?

In ArcGIS Pro, the Fill tool raises qualifying sinks to their pour-point elevation, and the Sink tool can identify sink count and depth before you select a z-limit. The Fill tool's z-limit leaves sinks deeper than the chosen elevation difference unchanged. Other workflows can condition DEMs through drainage-network enforcement, but the decision rule remains the same: remove artificial barriers while retaining true sinks.

Does depression filling change the accuracy of my terrain data?

It changes the elevation surface, which is why it should be treated as a hydrologic-analysis product rather than silently replacing the source DEM. HydroSHEDS cautions that conditioning alters original elevation data and may make it unsuitable for uses beyond drainage-direction derivation. The benefit is a surface designed for continuous flow; the cost is that changed cells can alter flow direction, flow accumulation, and slope in additional cells.

Sources