Function arrayfire::canny
[−]
[src]
pub fn canny(
input: &Array,
threshold_type: CannyThresholdType,
low: f32,
hight: f32,
sobel_window: u32,
is_fast: bool
) -> Array
Canny edge detection operator
The Canny edge detector is an edge detection operator that uses a multi-stage algorithm to detect a wide range of edges in images. A more in depth discussion on it can be found here.
Parameters
input
is the input imagethreshold_type
helps determine if user set high threshold is to be used or not. It can take values defined by the enum CannyThresholdTypelow
is the lower threshold % of the maximum or auto-derived highhight
is the higher threshold % of maximum value in gradient image used in hysteresis procedure. This value is ignored if CannyThresholdType::OTSU is chosen.sobel_window
is the window size of sobel kernel for computing gradient direction and magnitude.is_fast
indicates if L1 norm(faster but less accurate) is used to compute image gradient magnitude instead of L2 norm.
Return Values
An Array of binary type DType::B8 indicating edges(All pixels with non-zero values are edges).