<p>In <a href="https://github.com/mlpack/mlpack/pull/686#discussion_r71090227">src/mlpack/methods/ne/neat.hpp</a>:</p>
<pre style='color:#555'>> + childGenomes.push_back(lastBestGenome);
> + ssize_t currentNumGenome = childGenomes.size() + aPopulation.PopulationSize();
> + while (currentNumGenome < aPopulationSize) {
> + ssize_t speciesIndex = mlpack::math::RandInt(0, aPopulation.aSpecies.size());
> + Genome genome;
> + bool hasBaby = BreedChild(aPopulation.aSpecies[speciesIndex], genome, aCrossoverRate);
> + if (hasBaby) {
> + childGenomes.push_back(genome);
> + ++currentNumGenome;
> + }
> + }
> +
> + // Speciate genomes into new species.
> + std::vector<Genome> populationGenomes;
> + AggregateGenomes(aPopulation, populationGenomes);
> + aPopulation.aSpecies.clear();
</pre>
<p>If we clear all species, we lose the information about the species age, also I'm not sure, why we have to reassign the genomes.</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/686/files/66b0f4171ab0c6810cf3058e653e48d18c4913be#r71090227">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AJ4bFDacDBGzAiOWGMEdzqaOfyzCqV_jks5qWqPxgaJpZM4IwJa6">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AJ4bFCFdOJF0G4c9hBtvCkZeP9f_QOsZks5qWqPxgaJpZM4IwJa6.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/66b0f4171ab0c6810cf3058e653e48d18c4913be#r71090227"></link>
<meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>