<p>I spent a long time thinking about it.  First, I thought, how can we make right children have <code>FirstPointIsCentroid = false</code> and left children have <code>FirstPointIsCentroid = true</code> but have both children be of the same type?  But I don't think that is possible.</p>

<p>The second option is to have left and right children have different type.  This could work because all of the classes only hold pointers to the root of the tree, which in this case would have the type of the left children.  But there would need to be some refactoring of the rules, so that the <code>Score()</code> and <code>Rescore()</code> methods could take two different types of trees, and so that the <code>TreeType</code> template parameter was at the method level, not the class level.  I think that is possible and not too difficult, though there might be a gotcha or two with the <code>TraversalInfoType</code>.  Whatever we changed, we would have to document in the TreeType API page.</p>

<p>The third option is to find a way so that <code>FirstPointIsCentroid</code> is a static compile-time constant for some trees, but is a runtime constant for others.  I have not thought about this much so I am not sure if it is completely feasible, but I think it is possible.</p>

<p>The fourth option, from earlier, is to just leave <code>FirstPointIsCentroid = false</code> for vantage point trees.</p>

<p>What do you think is the best approach here?</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">&mdash;<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/mlpack/mlpack/pull/708#issuecomment-232046825">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe/AJ4bFMnXhoFe7ekyigDgciU9gSQVuz9mks5qU5ZlgaJpZM4I_COp">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFDGE2ID5stb0RLJNpSuW72eVbhJqks5qU5ZlgaJpZM4I_COp.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/mlpack/mlpack/pull/708#issuecomment-232046825"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>