[mlpack-git] [mlpack/mlpack] Implementation of Multiprobe LSH (#691)
Yannis Mentekidis
notifications at github.com
Wed Jun 22 11:02:02 EDT 2016
> @@ -339,12 +340,301 @@ void LSHSearch<SortPolicy>::BaseCase(const size_t queryIndex,
> referenceIndex, distance);
> }
>
> +
> +// Compare class for <double, size_t> pair, used in GetAdditionalProbingBins.
> +class CompareGreater
> +{
> + public:
> + bool operator()(
> + std::pair<double, size_t> p1,
> + std::pair<double, size_t> p2){
> + //only compare the double values
> + return p1.first > p2.first;
> + }
You are right - I started implementing that, but then somewhere in the middle found a bug with my initial code so I never got around to throwing CompareGreater away.
Yes, in the very unlikely event where two scores are exactly the same, it doesn't really matter which one gets priority anyway - so ordering the second element is as arbitrary as anything else.
---
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/691/files/fa7f62da6a4cfe7fa45e297d7a4a1491c9c39bb1#r68069618
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.cc.gatech.edu/pipermail/mlpack-git/attachments/20160622/ffc1bf81/attachment.html>
More information about the mlpack-git
mailing list