How to Remove Blobs from Image using morphological operations
조회 수: 4 (최근 30일)
이전 댓글 표시
I am doing a project for doing a project for digits recognition using morphological image processing. Here I need to remove Blobs of digits like 9 or 6. I got a link of matlab as http://www.mathworks.in/matlabcentral/fileexchange/20114-removing-blobs-from-a-binary-image But the method bwremove not found error occurs. Can any one help me PLZ. I did as
I=imread('I.tif')
I=imcomplement(I)
I2=imfill(I,'holes');
I3=I2-I
I5=I2-I3
I6=imcomplement(I3)
In I5 I tried to get stem by subtracting the blob from filled image. Since I3 is inside of Blobs It gives the origin image. If I could increase size of I3 keeping the dimension same i.e. like adding pixels repeatedly on boundary of I3 until I get it large enough to outer boundary of the Blobs it would be OK. Any proper logic for this PLZ
댓글 수: 0
답변 (3개)
Image Analyst
2013년 11월 15일
It's hard to visualize. Can you attach your image so we can try your code? What criteria are you applying to the blobs to determine if a blob represents a number 6 or number 9? The Euler number? That's what I'd use assuming that the blobs have the holes completely surrounded (no breaks in the circle around them). You can get the Euler number from regionprops().
댓글 수: 0
Kalyanbrat
2013년 11월 18일
댓글 수: 1
Image Analyst
2023년 4월 24일
You can tell the difference between a 6 and a 9 just from the centroid. If the centroid of the blob is in the upper half of the bounding box, it's a 9. Otherwise it's a 6 because the centroid is in the lower half of the bounding box.
참고 항목
카테고리
Help Center 및 File Exchange에서 Read, Write, and Modify Image에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!