So I have performed EdgeDetect and ComponentMeasurements on my images and obtained a pretty good elliptical fit. However, the black shadow of the beads in the image is being picked up by ComponentMeasurement. Is there a way to remove this larger outer (almost concentric ellipse) from the matrix returned by ComponentMeasurement?
This is my current code for ComponentMeasurement. Would it be feasible to implement a filter for what I've described within the code for ComponentMeasurement itself?
pic = Import[...];
picEdge = Image[EdgeDetect[pic, 9]];
params2 = ComponentMeasurements[picEdge, {"Centroid", "SemiAxes","Orientation", "Elongation"}, #Elongation < .5 && #Width > 3 && #Length < 70 &] // Values;
I was thinking of finding Centroid coordinates that are relatively close by, and comparing semi-axis lengths to remove the larger ellipse from the matrix, but I'm still relatively new to Mathematica and I'm not sure how to go about doing this.
Thanks all!
Original Image: