Skip to main content

Detect Drainage Crossings (Spatial Analyst Tools)

Summary

Detects the locations of drainage crossings using a deep learning model.

Learn more about how Detect Drainage Crossings works

Usage

  • Drainage crossings are locations where drainage structures, such as culverts or bridges, route water underneath roads.

  • You must install the deep learning framework Python API in the ArcGIS Pro Python environment; otherwise, an error will occur when you try to run the tool. To set up your machine to use deep learning frameworks in ArcGIS Pro, see Install deep learning frameworks for ArcGIS.

  • By default the pretrained Culvert Detection model will be used for drainage crossing detection unless a pretrained model is specified for the Input Pretrained Model (in_pretrained_model in Python) parameter value.

    The default culvert detection model must use graphics processing unit (GPU) processing to detect drainage crossings. See GPU processing with Spatial Analyst for details about compatible GPUs, configuring and working with GPU devices, as well as troubleshooting tips.

  • The Input Surface Raster (in_surface_raster in Python) parameter value must be a high-resolution digital elevation model (DEM). It is recommended that the specified raster has the same cell size as the data used to train the deep learning model. The default culvert detection model was trained using data with a 1-meter cell size. Using a different cell size can cause poor results.

  • Only drainage crossings that meet the Confidence Threshold (threshold in Python) value of the Model Arguments (model_arguments in Python) parameter will be included in the tool outputs.

  • The Batch Size (batch_size in Python) value of the Model Arguments parameter controls the number of image tiles that will be processed in each step of the model inference. Batch sizes are square numbers, such as 1, 4, 9, 16, 25, 64 and so on. If the input value is not a perfect square, the highest possible square value is used. For example, if a value of 6 is specified, the batch size will be set to 4 when the tool is run.

    Increasing the batch size can improve tool performance. However, as the batch size increases, more memory is used. If an out of memory error occurs, try running the tool with a smaller batch size.

  • Be default, this tool requires GPU processing to complete detections. If an Input Pretrained Model parameter value is specified, the tool may use GPU or CPU processing depending on the model's architecture and capabilities.

    In general, GPU processing is recommended for deep learning tasks as it offers enhanced performance. See GPU processing with Spatial Analyst for details about compatible GPUs, configuring and working with GPU devices, as well as troubleshooting tips.

  • See Analysis environments and Spatial Analyst for additional details about the geoprocessing environments that apply to this tool.

Parameters

Label Explanation Data type

Input Surface Raster

The input surface raster that will be used for detection of drainage crossings.

This must be a high-resolution DEM.

Raster Layer

Output Drainage Crossing Points

The output point features that will define the locations of the approximate centroid of the detected drainage crossings. Each point will have a unique ID.

An additional field will be added to the attribute table. The Confidence field records the value of the confidence score that the location has a drainage crossing present. The minimum score that can be found here is controlled by the Confidence Threshold setting in the Model Arguments parameter.

Feature Class

Input Pretrained Model

(Optional)

The pretrained model that will be used to detect drainage crossings within the specified input surface raster.

By default, the tool will download a pretrained model created for this task from ArcGIS Online and Living Atlas. An internet connection is required to download the model. This model requires that GPU (graphics processing unit) hardware is installed on your computer.

Alternatively, a different pretrained model can be specified as an Esri model definition JSON file (.emd), a JSON file, or a deep learning model package (.dlpk).

File; String

Output Bounding Polygons

(Optional)

The optional output polygon features that will contain the bounding polygons around the detected drainage crossings. This is the direct output of the deep learning model. Each polygon will have a unique ID.

An additional field will be added to the attribute table. The Confidence field records the value of the confidence score that the location has a drainage crossing present. The minimum score that can be found here is controlled by the Confidence Threshold setting in the Model Arguments parameter.

Feature Class

Model Arguments

(Optional)

Specifies configuration settings for the deep learning model.

The options determine such things as how the data will be passed to the model, or which of the detected objects will be recorded in the output.

If an Input Pretrained Model parameter value is specified, it will be used to populate this parameter. These arguments will vary depending on the architecture of the specified model.

The following are supported model arguments for the default pretrained model:

  • Confidence Threshold—The detections that have a confidence score higher than this threshold will be included in the result. The allowed values range from 0 to 1.0. The default is 0.4.

  • NMS Overlap—The maximum overlap ratio for two overlapping detections, which is defined as the ratio of intersection area over union area. The default is 0.1. Value ranges from 0.1 to 1.

  • Batch Size—The number of image tiles that will be processed in each step of the model inference. This depends on the memory of your graphics card. The default is 9.

Value table columns:

  • Name—The name of the function argument.

  • Value—The value of the function argument.

Value Table

Environments

Cell Size, Cell Size Projection Method, Current Workspace, Extent, Geographic Transformations, GPU ID, Mask, Output CONFIG Keyword, Output Coordinate System, Processor Type, Scratch Workspace, Snap Raster

Licensing information

  • Basic: Requires Spatial Analyst
  • Standard: Requires Spatial Analyst
  • Advanced: Requires Spatial Analyst