Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

One way would be to use adaptiveThreshold instead of equalizing and blurring. But I don't think it will always work :(

Try this:

adaptiveThreshold(src_gray,bw,255, 0,0,51,-15); HoughCircles( bw, circles, CV_HOUGH_GRADIENT, 2, 10, 100, 25, 9, 16 );

Experiment with threshold parameters to find the most robust set.

One way would be to use adaptiveThreshold instead of equalizing and blurring. But I don't think it will always work :(

Try this:

adaptiveThreshold(src_gray,bw,255, 0,0,51,-15); adaptiveThreshold(src_gray, bw, 255, 0, 0, 51, -15); HoughCircles( bw, circles, CV_HOUGH_GRADIENT, 2, 10, 100, 25, 9, 16 );

Experiment with threshold parameters to find the most robust set.

One way would be to use adaptiveThreshold instead of equalizing and blurring. But I don't think it will always work :(

Try this:

adaptiveThreshold(src_gray, bw, 255, 0, 0, 51, -15); 
 HoughCircles( bw, circles, CV_HOUGH_GRADIENT, 2, 10, 100, 25, 9, 16 );

);

Experiment with threshold parameters to find the most robust set.

One way would be to use adaptiveThreshold instead of equalizing and blurring. But I don't think it will always work :(

Try this:

adaptiveThreshold(src_gray, bw, 255, 0, 0, 51, -15); -25); 
HoughCircles( bw, circles, CV_HOUGH_GRADIENT, 2, 10, 100, 25, 9, 16 );

Experiment with threshold parameters to find the most robust set.

image description

One way would be to use adaptiveThreshold instead of equalizing and blurring. But I don't think it will always work :(

Try this:

adaptiveThreshold(src_gray, bw, 255, 0, 0, 51, -25); 
HoughCircles( bw, circles, CV_HOUGH_GRADIENT, 2, 10, 100, 25, 9, 16 );

Experiment with threshold parameters to find the most robust set.

image description

If this fails too often, I would give up Hough and go for contour analysis.