[关闭]
@iStarLee 2018-10-26T15:22:07.000000Z 字数 4020 阅读 295

Edge and Lines

cv


1 what is Edge

An edge is a place of rapid change in the image intensity funciton.

2 Edge Operator Properties

3 Image Gradient

the gradient is:


diretion is:

magnitudeis:

4 Theory of Edge Detection

Laplacian


捕获.PNG-18.9kB

5 Discrete Edge Operators

5.1 Laplacian Operators

image_1cqnrakel12k12pdbfk74a5b9.png-145.4kB
The key to understand how the Laplacian generate Laplacian mask, acturally, it is a convolution(nine element of two matrix do convolution = vector dot).

Two kinds of Laplacian kernel

and

The sencond kernel is more accurate.

5.2 Sobel Opterators

Better approximations of the gradients exist. The Sobel operators below are commonly used.
and

5.3 Comparing Edge Operators

image_1cqo8hnqr173q4n11jdq13ca32j13.png-124.9kB

6 Effects of noise

Image noise results in pixels that look very different from their neighbors, Generally, the larger the noise the stronger the response.
image_1cqo8tc601oq7ois1agehs1bhn1t.png-54.5kB

Smoothing the image should help –it forces pixels to look more like their neighbors.

these two methods have the same effect, because we have Differentiation property of convolution

Smoothing tradeoffs(平滑权衡). Smoothed derivative removes noise, but blurs edge. Also finds edges at different “scales”.

image_1cqoabvc01kk83lu10sf1qvd163l55.png-127.3kB
image_1cqoaem1ro0g4i7nngs171t6v5v.png-3.3kB

7 2D edge detection filters(总结)

image_1cqoalsuq1pcu9l51u0h13is1nhk7j.png-86.3kB

7.1 Derivative of Gaussian filter(高斯一阶导)

image_1cqoa1atr1fuu174q16nl1fiq1ltq3h.png-65.1kB

image_1cqoafius81j1p71hct7ur1i3n6c.png-182.5kB

7.2 Laplacian of Gaussian (LoG filter, 高斯二阶导)

image_1cqoahosv13b07hl1pgo1f8c27276.png-71.9kB
Step of LoG

The last step is needed to suppress the weak zero-crossings most likely caused by noise.(需要采取最后一步来抑制最有可能由噪声引起的弱过零点)

7.3 Difference of Gaussians(DoG)

分别用两次高斯filter做差来近似LoG,减少计算量。
image_1cqobcqcb18b2l7s165dhh5qv69a.png-10kB

Example 1:
image_1cqobh7pc1961b751qef11nf1mria4.png-56.5kB
Example 2:
image_1cqobegct1moocqq1q7i164911r29n.png-474.2kB

8 Parameters(Scale, Threshold)

8.1 scale

8.2 Threshold

Choose a threshold value
(1)Set any pixels less than thresh to zero (off)
(2)Set any pixels greater than or equal to thresh to one (on)
image_1cqoc02896b0h6k14gi28p1pndau.png-222.1kB

9 Canny edge detector

Probably the most widely used edge detector in computer vision.

9.1 Canny边缘检测基本原理:

(1)图象边缘检测必须满足两个条件:一能有效地抑制噪声;二必须尽量精确确定边缘的位置。
(2)根据对信噪比与定位乘积进行测度,得到最优化逼近算子。这就是Canny边缘检测算子。
(3)类似与Marr(LoG)边缘检测方法,也属于先平滑后求导数的方法。

9.2 Canny 的目标是找到一个最优的边缘检测算法

最优边缘检测的含义是:
(1)好的检测 - 算法能够尽可能多地标识出图像中的实际边缘。
(2)好的定位 - 标识出的边缘要尽可能与实际图像中的实际边缘尽可能接近。
(3)最小响应 - 图像中的边缘只能标识一次,并且可能存在的图像雜訊不应标识为边缘。

9.3 Canny Edge Detect Algorithm:

添加新批注
在作者公开此批注前,只有你和作者可见。
回复批注