Anybody help me with measure asymmetry an irregular object
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
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 comentarios
Aishwarya Udhayakumar
el 13 de Mayo de 2020
How can I define the percent value??can u help me with this
Image Analyst
el 13 de Mayo de 2020
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?
Respuestas (1)
Image Analyst
el 19 de Nov. de 2017
Editada: Image Analyst
el 19 de Nov. de 2017
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 comentarios
JovanS
el 8 de Jun. de 2022
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
el 8 de Jun. de 2022
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.
Ver también
Categorías
Más información sobre Image Segmentation and Analysis en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!