<p>In <a href="https://github.com/mlpack/mlpack/pull/686#discussion_r70905626">src/mlpack/methods/ne/neat.hpp</a>:</p>
<pre style='color:#555'>&gt; +      for (ssize_t j=0; j&lt;speciesSize; ++j) {
&gt; +        averageRank += genomes.size() - GetGenomeIndex(genomes, population.aSpecies[i].aGenomes[j].Id());
&gt; +      }
&gt; +      averageRank = averageRank / speciesSize;
&gt; +      speciesAverageRank.push_back(averageRank);
&gt; +    }
&gt; +  }
&gt; +
&gt; +  // Remove weak species.
&gt; +  void RemoveWeakSpecies(Population&amp; population) {
&gt; +    std::vector&lt;double&gt; speciesAverageRank;
&gt; +    CalcSpeciesAverageRank(population, speciesAverageRank);
&gt; +    double totalAverageRank = std::accumulate(speciesAverageRank.begin(), speciesAverageRank.end(), 0);
&gt; +
&gt; +    for (ssize_t i=0; i&lt;population.aSpecies.size(); ++i) {
&gt; +      double weak = (std::floor(speciesAverageRank[i] * population.NumSpecies() / totalAverageRank)
</pre>
<p>Wait, that's the wrong position.</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/686/files/48e15c45ab1a9c65dbd8fe3fe6f07e368c965883#r70905626">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AJ4bFM_Dwdy7nUOTA5RPAvRS6B6qwd92ks5qVtJRgaJpZM4IwJa6">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFM69lNn4THpKsGSbmgaJ2udUv6xjks5qVtJRgaJpZM4IwJa6.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/686/files/48e15c45ab1a9c65dbd8fe3fe6f07e368c965883#r70905626"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>