Images segmentation methods in MATLAB

1 回表示 (過去 30 日間)
Memo Remo
Memo Remo 2021 年 1 月 18 日
コメント済み: Memo Remo 2021 年 1 月 18 日
Hi,
I want to convert the attached image #1 to the image #2 in MATLAB. I did this using a photo editing software but would like to do this automatically in MATLAB. Can anyone suggest a way to do this?
Many thanks in advance,
Image #1:
Image #2:

採用された回答

KALYAN ACHARJYA
KALYAN ACHARJYA 2021 年 1 月 18 日
As the region of interest is clearly distinct, you can directly obtain the results by binarization of the input image. You may have to set thrshold limit accordingly. Considering the input as a gray image, if not, please do convert the image to a gray image, using the rgb2gray function.
bwImage=imbinarize(grayImage,0.1);
%Clean all the small blobs connenetd with 100 pixels
bwImage=~bwareaopen(~bwImage,100);
%.............................^Do Modify as per requirements
figure,imshow(bwImage);
  1 件のコメント
Memo Remo
Memo Remo 2021 年 1 月 18 日
Perfect solution! Thanks for you help.

サインインしてコメントする。

その他の回答 (0 件)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by