title: Template Matching for Coins with OpenCV
body: <p>I am undertaking a project that will automatically count values of coins from an input image. So far I have segmented the coins using some pre-processing with edge detection and using the Hough-Transform.</p>
  
  <p>My question is how do I proceed from here? I need to do some template matching on the segmented images based on some previously stored features. How can I go about doing this.</p>
  
  <p>I have also read about something called <a href="http://docs.opencv.org/modules/ml/doc/k_nearest_neighbors.html" rel="noreferrer">K-Nearest Neighbours</a> and I feel it is something I should be using. But I am not too sure how to go about using it.</p>
  
  <p>Research articles I have followed:</p>
  
  <ul>
  <li><p><a href="http://www.inf.u-szeged.hu/~ssip/2006/projects/team6/coin.pdf" rel="noreferrer">Coin
  Detector</a></p></li>
  <li><p><a href="https://scholar.google.co.za/scholar?hl=en&amp;q=Chinese+Coin+Recognition+Based+on+Unwrapped+Image+and+Rotation+Invariant+Template+Matching&amp;btnG=&amp;as_sdt=1%2C5&amp;as_sdtp=" rel="noreferrer">Coin
  Recognition</a></p></li>
  </ul>