EdgeExtraction - Edge Feature Extraction

This application computes edge features on every pixel of the input image selected channel

Detailed description

This application computes edge features on a selected channel of the input.It uses different filter such as gradient, Sobel and Touzi


This section describes in details the parameters available for this application. Table [1] presents a summary of these parameters and the parameters keys to be used in command-line and programming languages. Application key is EdgeExtraction .

[1]Table: Parameters table for Edge Feature Extraction.
Parameter Key Parameter Name Parameter Type
in Input Image Input image
channel Selected Channel Int
ram Available RAM (Mb) Int
filter Edge feature Choices
filter gradient Gradient Choice
filter sobel Sobel Choice
filter touzi Touzi Choice
filter.touzi.xradius The X radius of the neighborhood. Int
filter.touzi.yradius The Y radius of the neighborhood. Int
out Feature Output Image Output image
inxml Load otb application from xml file XML input parameters file
outxml Save otb application to xml file XML output parameters file

Input Image: The input image on which the features are computed.

Selected Channel: The selected channel index.

Available RAM (Mb): Available memory for processing (in MB).

Edge feature: Choice of edge feature. Available choices are:

  • Gradient: This filter computes the gradient magnitude of the image at each pixel.
  • Sobel: This filter uses the Sobel operator to calculate the image gradient and then finds the magnitude of this gradient vector.
  • Touzi: This filter is more suited for radar images. It has a spatial parameter to avoid speckle noise perturbations. The larger the radius is, less sensible to the speckle noise the filter is, but micro edge will be missed.
  • The X radius of the neighborhood.
  • The Y radius of the neighborhood.

Feature Output Image: Output image containing the edge features.

Load otb application from xml file: Load otb application from xml file.

Save otb application to xml file: Save otb application to xml file.


To run this example in command-line, use the following:

otbcli_EdgeExtraction -in qb_RoadExtract.tif -channel 1 -out Edges.tif

To run this example from Python, use the following code snippet:


# Import the otb applications package
import otbApplication

# The following line creates an instance of the EdgeExtraction application
EdgeExtraction = otbApplication.Registry.CreateApplication("EdgeExtraction")

# The following lines set all the application parameters:
EdgeExtraction.SetParameterString("in", "qb_RoadExtract.tif")

EdgeExtraction.SetParameterInt("channel", 1)

EdgeExtraction.SetParameterString("out", "Edges.tif")

# The following line execute the application




This application has been written by OTB-Team.

See Also

These additional resources can be useful for further information:
otb class