Matlab图像边缘检测--梯度算子--Roberts、Prewitt、Sobel、LOG、Canny算子边缘检测

xiaoxiao2021-03-01  39

Matlab图像边缘检测–梯度算子–Roberts、Prewitt、Sobel、LOG、Canny算子边缘检测 I = imread('0.jpg'); I =rgb2gray(I); % edge()函数:边缘检测,门限值采用默认值 % Roberts算子边缘检测 BW1=edge(I,'roberts'); % Prewitt算子边缘检测 BW2=edge(I,'prewitt'); % Sobel算子边缘检测 BW3=edge(I,'sobel'); % LOG算子边缘检测 BW4=edge(I,'log'); % Canny算子边缘检测 BW5=edge(I,'canny'); figure,imshow(BW1,[]); figure,imshow(BW2,[]); figure,imshow(BW3,[]); figure,imshow(BW4,[]); figure,imshow(BW5,[]);
转载请注明原文地址: https://www.6miu.com/read-4050320.html

最新回复(0)