Fill (Raster Analysis)

Titleā€ƒ Fill (Raster Analysis)

Summary

Fills sinks in a surface raster to remove small imperfections in the data.


Illustration

Fill tool illustration Fill tool illustration

Usage

A sink is a cell with an undefined drainage direction; no cells surrounding it are lower. The pour point is the boundary cell with the lowest elevation for the contributing area of a sink. If the sink were filled with water, this is the point where water would pour out.

The z-limit specifies the maximum difference allowed between the depth of a sink and the pour point, and determines which sinks will be filled and which will remain untouched. The z-limit is not the maximum depth to which a sink can be filled.

For example, consider a sink area where the pour point is 210 feet in elevation, and the deepest point within the sink is 204 feet (a difference of 6 feet). If the z-limit is set to 8, this particular sink will be filled. However, if the z-limit is set to 4, this sink will not be filled since the depth of this sink exceeds this difference and would be considered a valid sink.

All sinks that are less than the z-limit, and lower than their lowest adjacent neighbor, will be filled to the height of their pour points.

The number of sinks found with the z-limit will determine the length of processing time. The more sinks there are, the longer the processing time will be.


Syntax

Parameter Explanation
inputSurfaceRaster

The input raster representing a continuous surface.

outputName

The name of the output fill raster service.

The default name is based on the tool name and the input layer name. If the layer already exists, you will be prompted to provide another name.

zLimit (Optional)

Maximum elevation difference between a sink and its pour point to be filled.

Code Samples

Fill example 1 (Python window)

This example fills the sinks of an input elevation surface raster.


import arcpy
arcpy.Fill_ra("https://myserver/rest/services/elevation/ImageServer","outFill1")

                    

Fill example 2 (stand-alone script)

This example fills the sinks of an input elevation surface raster.


#---------------------------------------------------------------------------
# Name: Fill_example02.py
# Requirements: ArcGIS Image Server

# Import system modules
import arcpy

# Set local variables
inSurface = "https://myserver/rest/services/elevation/ImageServer"
outputFill = "outFill2"
zLimit = 3.28

# Execute Fill raster analysis tool
arcpy.Fill_ra(inSurface, outputFill, zLimit)

                    

Tags

Credits

Use limitations