<p>In <a href="https://github.com/mlpack/mlpack/pull/691#discussion_r67987727">src/mlpack/methods/lsh/lsh_search_impl.hpp</a>:</p>
<pre style='color:#555'>> @@ -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;
> + }
</pre>
<p>Are you sure <code>std::greater</code> will not work here instead of this class? By default for <code>std::pair</code> that will take into account the second element, but I think that in your case ordering based on the second element doesn't really matter.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<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/691/files/fa7f62da6a4cfe7fa45e297d7a4a1491c9c39bb1#r67987727">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe/AJ4bFE0LVtzPEPmLcKemyFnZlKkiTu1Yks5qOKRRgaJpZM4IxQW5">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFOXV52I57mdWIaW5d0OLtIKIdFyOks5qOKRRgaJpZM4IxQW5.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/691/files/fa7f62da6a4cfe7fa45e297d7a4a1491c9c39bb1#r67987727"></link>
<meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>