title: How to match two sets of points?How to find those points that have similar positions (close enough) in python?
body: <p>I have two sets of extracted points (each element of points set include (x,y) coordinates) in two different image (d:database image, q:query image), each set may have a different number of points <code>(d={(xj,yj)}, where j=1:n) and (q={(xi,yi)}, where i=1:m)</code>. I have to check those points that they are spatially consistent between two sets. Your help is appreciated. 
  This is the representation of two point sets:</p>
  
  <p>This is d, and red point in the center is object center:</p>
  
  <p><a href="https://i.stack.imgur.com/fKKWJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fKKWJ.png" alt="enter image description here"></a></p>
  
  <p>and this is q:</p>
  
  <p><a href="https://i.stack.imgur.com/AxLqH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/AxLqH.png" alt="enter image description here"></a></p>
  
  <p>How to find (the indices of matched points in two sets) those points that they have similar positions relative to the center of <code>d</code>? How to match these two sets of points and find those that they are spatially consistent (similar position) relative to the center? </p>