Anybody help me with measure asymmetry an irregular object

조회 수: 3 (최근 30일)
Marlon Damaceno
Marlon Damaceno 2017년 11월 18일
댓글: Image Analyst 2022년 6월 8일
What's the best method to sort the asymmetry?
basically, I need the result of the ratio between the perpendicular segment and the largest diagonal, where the score is quantified in (0 to 2 points): if the proportion is greater than 40.01%: 0 point, symmetric lesion. If the proportion is between 20.01% to 40%: 1 point, little asymmetric lesion. If the proportion is less than 20%: 2 points, very unbalanced lesion.
I need to define 'percent' and apply in the results
%%Reads the original image and performs the conversion to binary.
A = imread('IRREGULAROBJECT.jpg'); % this image already is grayscale.
imshow(A);
BW = im2bw(A);
imshow(BW);
%%Extract the Asymmetry Value of the object.
% AREA VALUE
s = regionprops(BW,'area');
area = cat(1, s.Area)
imshow(area)
title('Value AREA image', 'FontSize', fontSize);
%%CONDITIONS
%If the proportion is greater than 40.01%: 0 point, symmetrical lesion.
if (percent > 40.01)
asymmetry = 0;
end
% If the proportion is between 20.01% to 40%: 1 point, little asymmetric lesion.
if (percent > 20.01 & percent < 40.00)
asymmetry = 1;
end
% If the proportion is less than 20%: 2 points, very unbalanced lesion.
if (percent < 20.00)
asymmetry = 2;
end
  댓글 수: 4
Aishwarya Udhayakumar
Aishwarya Udhayakumar 2020년 5월 13일
How can I define the percent value??can u help me with this
Image Analyst
Image Analyst 2020년 5월 13일
I have no idea. Is it the solidity like you get from reginoprops(), which is the area divided by the area of the convex hull? Since it now appears that you did not write that code, why don't you ask whomever wrote the code?

댓글을 달려면 로그인하십시오.

답변 (1개)

Image Analyst
Image Analyst 2017년 11월 19일
편집: Image Analyst 2017년 11월 19일
You might want to try the Dice-Sorensen coefficient. See attached demo.
Alternatively you can find the bounding rectangle by using the radon transform. No demo for that (yet). Simply find the widest width and the narrowest width. Or you could use John's function: https://www.mathworks.com/matlabcentral/fileexchange/34767-a-suite-of-minimal-bounding-objects
  댓글 수: 8
JovanS
JovanS 2022년 6월 8일
Hello Image Analyst ,
As you said before in order to find the percentage of asymmetry we have to flip the blob about its major axis of symmetry and count pixels that are common to both the flipped and unflipped blob, and count pixels that are different. could you share matlab code with us ?
Image Analyst
Image Analyst 2022년 6월 8일
I don't have code for that but you'd call regionprops to get orientation, then call imrotate to put the major axis vertical, then call dice.

댓글을 달려면 로그인하십시오.

Community Treasure Hunt

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

Start Hunting!

Translated by