<p>Okay, I spent a while digging into it today but I solved the dual-tree k-means issue.  It turns out the bug was very weird in that it wouldn't fail test cases because the algorithm would properly converge to the correct centers, but it would run until the maximum number of iterations because the residue was being calculated wrong.  This has been fixed in <a href="https://github.com/mlpack/mlpack/commit/a0f1dd5632004b26cd3592e6ceaa455792df8c3a" class="commit-link"><tt>a0f1dd5</tt></a>.</p>

<p>I'm going to go ahead and merge this and then close <a href="https://github.com/mlpack/mlpack/issues/595" class="issue-link js-issue-link" data-url="https://github.com/mlpack/mlpack/issues/595" data-id="143660890" data-error-text="Failed to load issue title" data-permission-text="Issue title is private">#595</a> and <a href="https://github.com/mlpack/mlpack/issues/596" class="issue-link js-issue-link" data-url="https://github.com/mlpack/mlpack/issues/596" data-id="143661029" data-error-text="Failed to load issue title" data-permission-text="Issue title is private">#596</a> as I finish them (those are the other two outstanding tasks here, which I've made issues for).  Thanks again for the fix.  If you like, feel free to add your name to <code>src/mlpack/core.hpp</code> and <code>COPYRIGHT.txt</code> since you have contributed. :)</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 or <a href="https://github.com/mlpack/mlpack/pull/592#issuecomment-201701513">view it on GitHub</a><img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFAnSCrrUXWDQLDkT-tAD3zjwFemqks5pxK8bgaJpZM4H4Wvo.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/592#issuecomment-201701513"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>