Aller au contenu principal

Convolve Raster by Kernel

Overview

This tool applies convolution or statistical replacement to cell values within a neighborhood window. It is suitable for smoothing noise, enhancing edges, or extracting texture. Different kernels and boundary modes can significantly affect the output.

Use Cases

  • Detect edges in raster imagery using Sobel, Scharr, Prewitt, or Roberts kernels.
  • Enhance texture or gradients before visual interpretation and feature extraction.
  • Use as an intermediate step in a longer raster processing workflow.

Parameters

ParameterDescriptionNotes
Input raster fileRaster file to process with convolutionRequired
Kernel typeConvolution kernel type to useRequired; default: sobel_x; options include Sobel X edge detection (sobel_x), Sobel Y edge detection (sobel_y), Scharr X edge detection (scharr_x), Scharr Y edge detection (scharr_y), Prewitt X edge detection (prewitt_x), Prewitt Y edge detection (prewitt_y), Roberts X edge detection (roberts_x), Roberts Y edge detection (roberts_y), and others
Boundary modeBoundary handling mode used during convolutionRequired; default: reflect; options: reflect (reflect), constant fill (constant), nearest fill (nearest), mirror (mirror), wrap (wrap)
Boundary fill valueFill value used when Boundary mode is constantOptional; default: 0.0
Convolution factorFactor used to adjust kernel weightsRequired; default: 1.0
Output raster fileOutput raster file after convolutionRequired

Steps

  1. Start the tool: Open Geoprocessing Toolbox → Spatial Analysis Tools > Visual Enhancement, then start the Convolve Raster by Kernel tool pane.
  2. Prepare input: Select the Input raster file and confirm that the data is complete and readable.
  3. Set core parameters: Configure Kernel type, Boundary mode, Boundary fill value, and Convolution factor based on the enhancement goal.
  4. Set output: Specify the Output raster file and confirm that the output path, format, and naming rules meet downstream requirements.
  5. Run and inspect the result: Click Run, then check whether the value range, edge response, and spatial position meet expectations.

Notes

  • Convolution changes cell values and can amplify noise. Use the result cautiously for quantitative analysis.
  • Boundary mode affects edge cells significantly; choose a mode that matches the data background and analysis goal.
  • For multiband rasters, confirm that the same kernel behavior is appropriate for every band.