ee.Algorithms.CannyEdgeDetector

Applies the Canny edge detection algorithm to an image. The output is an image whose bands have the same names as the input bands, and in which non-zero values indicate edges, and the magnitude of the value is the gradient magnitude.

UsageReturns
ee.Algorithms.CannyEdgeDetector(image, threshold, sigma)Image
ArgumentTypeDetails
imageImage

The image on which to apply edge detection.

thresholdFloat

Threshold value. The pixel is only considered for edge detection if the gradient magnitude is higher than this threshold.

sigmaFloat, default: 1

Sigma value for a gaussian filter applied before edge detection. 0 means apply no filtering.

Examples

JavaScript

// Your example goes here!

Python

# Your example goes here!