1

I have been trying to find two keypoints (head and tail) in arrows I have drawn, I was wondering is there a simpler approach than training a CNN, such as a using a classic approach (opencv). I have used this simple approach:

bi = cv2.bilateralFilter(gray, 5, 75, 75)
dst = cv2.cornerHarris(bi, 2, 3, 0.02)

Here are the images, before:

enter image description here

After some simple image processing I get:

enter image description here

I could pick the two red dots with the longest euclidean distance (checking all combinations of pairs), but sadly for the self loop case it won't give me the correct result. can someone suggest me a better approach?

Any suggestion is highly appreciated, thank you all!

JammingThebBits
  • 732
  • 11
  • 31

1 Answers1

0

The image is quasi-binary. Consider binarization followed by thinning. You can find the tips and junctions. You can also follow the arcs.