<p>I think that the offsets have a maximum, right?  So every point from, e.g., the lower left cluster will fall not in the lower-leftmost bin, but instead in (I think) the 4 (or 9?) bins closest to the center of the lower-leftmost bin.  (Or something like that.)  If that's the case, we could then put the query point outside of the furthest possible bin, and then set a higher number of probes to ensure that at least one of the 4 (or 9) bins are checked.</p>

<p>My thought there isn't complete, but I hope it is coherent enough to make sense.  Let me know if I can explain further.</p>

<p>The rest of the code itself looks good, so when you decide what to do with <code>std::vector&lt;bool&gt;</code> or the previous implementation and figure out this test, I think it's good to go---unless there is something else I overlooked.</p>

<p>I'll go through and point out the style, but it will be a lot of comments, so remember, you asked for it. :)</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/691#issuecomment-228853434">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe/AJ4bFLGVQ7c3_GMG72HR4PCg8Wmjug9Tks5qQCgNgaJpZM4IxQW5">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFHVp6iNw61y5JwMMivR7cEnq_mLZks5qQCgNgaJpZM4IxQW5.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#issuecomment-228853434"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>