Ddge detection:2-D operators

Operator with its derivatives

We stress that it is preferable to apply the derivatives to the gaussin operator ,then ,we can convolute the image with it!

The left pic is the Gaussian function and the right one is the gaussian function with its dericatives.

How we set the size of the Gaussian

图片.png
图片.png

smaller sigma to get finer features
larger sigma to get the obvious edges and to smooth the minor edges
So let's conclude the process with the nether pic:

图片.png

Canny edge detector!(非极大值抑制来thin the edge)

图片.png

do the derivatives

图片.png

we threshold the gradient

图片.png

do the nms(非极大值抑制)

图片.png

matlab code are listed below

% For Your Eyes Only
pkg load image;

frizzy = imread('frizzy.png');
froomer = imread('froomer.png');
imshow(frizzy);
imshow(froomer);

% TODO: Find edges in frizzy and froomer images
frizzyg=rgb2gray(frizzy);
froomerg=rgb2gray(froomer);
a1=edge(frizzyg,'canny');
a2=edge(froomerg,'canny');

% TODO: Display common edge pixels
imshow(a1&a2);

The 2D filter

图片.png

Applying this to your imgae ,we take the 0 crossing and we will get the deges.

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容