title: What values does the algorithm parametre take in OpenCV's FlannBasedMatcher constructor?
body: <p>In python, OpenCV's <code>FlannBasedMatcher</code> constructor takes a dictionary of parametres, the first of which is <code>algorithm</code>. <a href="http://docs.opencv.org/3.2.0/dc/dc3/tutorial_py_matcher.html" rel="noreferrer">The python tutorial</a> suggests that one can specify different values of <code>algorithm</code> by passing differently named variables, e.g. <code>FLANN_INDEX_KDTREE</code> and <code>FLANN_INDEX_LSH</code>, but the variable <em>name</em> cannot, of course, convey anything to the constructor. One might think that these names should instead be passed as strings, but in the example that follows, <code>FLANN_INDEX_KDTREE</code> is initialised as 0, and so it is entirely unclear how the <code>algorithm</code> parametre works.</p>
  
  <p>OpenCV doesn't really have any python documentation. <a href="http://docs.opencv.org/2.4/modules/flann/doc/flann_fast_approximate_nearest_neighbor_search.html" rel="noreferrer">In C++</a>, the constructor doesn't take a generic dictionary, but an object that instantiates <code>IndexClass</code>, where each subclass of <code>IndexClass</code> corresponds to a different algorithm.</p>