How do I detect the approximate radius of a rough, unclear circular object?

1 vue (au cours des 30 derniers jours)
Rachel
Rachel le 6 Août 2023
I am trying to detect the radius of a series of images as they change to then plot the changing radius. I am having trouble detecting the exact radius due to the images being unclear. Certain images have glares while others have dots throughout the center, contributing to an inexact radius. I am wondering if there is a way to remove the dots from the center of the image to get a more exact radius. Thanks!
  1 commentaire
Matt J
Matt J le 6 Août 2023
Much of this is not going to be clear to the community without being shown sample images and the approach you are taking. In particular, it is not at all clear why "dots throughout the center" would contribute to an inexact radius. It is only the boundary points of a circle that define the radius.

Connectez-vous pour commenter.

Réponses (2)

Matt J
Matt J le 6 Août 2023
Modifié(e) : Matt J le 6 Août 2023
If you can find a substantial number of the boundary points of the circle with reasonable accuracy, you can fit a circle to them with circularFit() from this FEX download,

Image Analyst
Image Analyst le 7 Août 2023
It's a generic, general purpose demo of how to threshold an image to find blobs, and then measure things about the blobs, and extract certain blobs based on their areas or diameters.
To get the Equivalent Circular Diameter of any blob, segment the image and then use regionprops on the binary image
% Get blob centroids and equivalent circular diameters.
props = regionprops(mask, 'EquivDiameter', 'Centroid');
allECD = [props.EquivDiameter]
xyCentroids = vertcat(props.Centroid)
% Display circles over the blobs.
viscircles(xyCentroids, allECD/2);
The equivalent circular diameter is the diameter you'd have if you smooshed your blob into a circular shape while keeping the number of pixels the same. In other words, it's the diameter of a circle having the same number of pixels as your irregularly shaped blob.
Attach your image if you need help segmenting it, and tell us which are the valid blobs you want and which are bogus ones you don't want, and how to distinguish the two classes.

Catégories

En savoir plus sur Image Segmentation and Analysis dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by