Canny edge dector 由 John F. Canny 在1986年提出。
- Canny 算法的发展
- Canny算法的步骤
2.1 降噪
2.2 寻找图像的亮度梯度
2.3 非极大值抑制
2.4 在图像中追踪边缘、滞后阈值法 - Canny边缘检测器的不同的几何公式
- Haralick-Canny边缘检测器
理想的边缘检测器特点:
- good detection
- good localization
- minimal response
Canny edge detection is a four step process.
- A Gaussian blur is applied to clear any speckles and free the image of
noise.- A gradient operator is applied for obtaining the gradients' intensity and
direction.- Non-maximum suppression determines if the pixel is a better candidate for
an edge than its neighbours.- Hysteresis thresholding finds where edges begin and end.
Canny边缘检测器的检测步骤
- 高斯滤波:去除斑点(speckles)和噪声(noise)
- 使用梯度算子获得梯度的值和方位角
- 非极大值抑制抑制确定像素点在邻域中是好的候选点
- 滞后阈值法去寻找边缘的起始和终止
图像降噪:采用7×7、5×5等模板的归一化的高斯核与图形进行卷积。
如5×5的高斯尺度因子为σ=1.4,1/159
图像灰度灰度化:Gray=0.299R+0.587G+0.114B
图像亮度的梯度:
分别检测水平和竖直方向的梯度Gx、Gy,然后可以求出G幅度G(勾股定理)和方位角θ(atan2)
非极大值抑制:
在梯度方向上,如果不是极大值,则过滤掉