资源简介
利用Matlab处理图像,使用几种方法进行边缘分割
代码片段和文件信息
clc;
clear;
x=imread(‘zx.bmp‘);
gray=rgb2gray(x);
figure;
imshow(x);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
figure;
imshow(gray[]);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
gray_x=gray;
BW_sobel=edge(gray_x‘sobel‘0.07);
figure;
imshow(BW_sobel);
title(‘sobel‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_sobel=edge(gray_x‘sobel‘0.05);
figure;
imshow(BW_sobel);
title(‘sobel‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_sobel=edge(gray_x‘sobel‘0.03);
figure;
imshow(BW_sobel);
title(‘sobel‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_sobel=edge(gray_x‘sobel‘0);
figure;
imshow(BW_sobel);
title(‘sobel‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_prewitt=edge(gray_x‘prewitt‘);
BW_roberts=edge(gray_x‘roberts‘);
figure;
imshow(BW_sobel);
title(‘sobel‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
figure;
imshow(BW_prewitt);
title(‘prewitt‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
figure;
imshow(BW_roberts);
title(‘roberts‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_log_0=edge(gray_x‘log‘);
figure;
imshow(BW_log_0);
title(‘log []‘);
axis on;
xlabel(‘x/像素‘);
ylabel(‘y/像素‘);
set(findall(gcf‘type‘‘surface‘)‘facealpha‘0.4)
uimenufcn(gcf‘EditCopyFigure‘)
set(gcf‘unit‘‘centimeters‘‘position‘[3 5 8 6])
set(gca‘Position‘[.2 .2 .7 .65]);
BW_log_0=edge
- 上一篇:蚁群算法的特征选取 matlab实现
- 下一篇:matlab 2015a许可文件
相关资源
- 压缩感知图像MATLAB代码美国乔治亚理
- matlab快速傅里叶变换进行数字图像处
- 一种快速灰度校正方法
- IHS图像融合算法
- 图像处理/图像分割实验/(自动)阈值
- 基于matlab的应用图像处理进行癌细胞
- 车牌号识别程序,基于matlab可直接运
- 双边滤波图像处理方法MATLAB程序
- MATLAB:图像旋转与插值
- 皮肤镜图像毛发噪声去除程序
- 开关型矢量中值滤波器matlab
- 低秩表示模型
- 数字图像处理作业
- 数字图像处理维纳滤波Matlab代码分享
- matlab图像边缘检测sobel算子梯度图像
- 基于matlab的指纹识别
- 图像畸变校正
- canny边缘检测算法_代码
- 指针式仪表识别方法,确定指针式仪
- 数字图像处理matlab源代码
- 阿尔法均值滤波函数
- mask与wallis影像图像匀光匀色算法的
- 完美可运行Google net
- 数字图像处理GUI界面设计
-
基于Matlab-Simuli
nk的遥感图像处理 - stucki 半色调 图像处理 二值 matlab
- stevenson 半色调 图像处理 二值 matlab
- burkers 半色调 matlab
- matlab图像处理gui49054
- MATLAB GUI图像处理
评论
共有 条评论