Facing issues while using cv2's Hough transform Class

Hi there, fastai community !!!

Could anyone help me with the a task I;m trying to achieve? I suppose it is a object detection problem but doesn’t need the use of Deep learning yet at this stage.

  • I want to detect the circles in a given image and find the radius of the circle. In turn trying to find the

What i have done till now?

  • I have gone through some articles and tried using the Hough transform to detect the circle in the Hough space. Though based on the trail and error, I was able to get a set of parameters which detects one image,still there is one extra circle which appears.(in the image at the end )

What I need to achieve?

  • I want to get 2 circles for o ring.
  • then to find the radius of such circle.
  • i’m using cv2 package, and while processing the image it is bit slow. is there a way to faster the process?
  • is there any other way to approach this problem?