[mlpack-git] [mlpack/mlpack] Vantage point tree (#708)

Ryan Curtin notifications at github.com
Tue Jul 12 15:22:33 EDT 2016


There shouldn't be too much duplication in the second option.  We would say that the left child would have type `VantagePointTree<BallBound>` and the right child would have type `VantagePointTree<HollowBallBound>`, then we could just specialize `TreeTraits` for each of those classes with different values for the left and right children.  But, the real difficulty there, which I did not think about earlier, is that what is returned when I call `Child(i)` is unclear, and there is no way to preserve the type fully.  I can think of some ways, maybe, but it would be a bit backhanded.

The checks for `FirstPointIsCentroid` are actually used pretty often; at least once in every `Score()` call.  So it is of some importance that those remain static compile-time constants.  If we were to make those supported as runtime checks in some cases, we would need to

 * change the boolean constants to constexpr functions that take TreeTypes as a parameter
 * for VP-trees, the function can't be constexpr, but instead looks at whether the TreeType parameter is true or false

We already have the fourth option implemented, so it is easy to test. :)

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/mlpack/mlpack/pull/708#issuecomment-232151726
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.cc.gatech.edu/pipermail/mlpack-git/attachments/20160712/fc926bb2/attachment-0001.html>


More information about the mlpack-git mailing list