What You Learned
Genetic Algorithms in Elixir — by Sean Moriarity (80 / 101)
👈 Installing and Compiling ALEx | TOC | Chapter 11 Optimizing Your Algorithms 👉
In this chapter, you learned a few different ways to add visualizations to your algorithms.
In the first section, you learned how to create visualizations from the genealogy tree generated over the course of an evolution. You learned how to export the tree to a DOT file and use a third-party tool like Graphviz to view the result.
After that, you learned how to use Gnuplot to generate plots of basic statistics like mean fitness over the course of an evolution. You learned how to use the graph to adjust your termination criteria.
Finally, you learned how to visualize specific solutions to specific problems using a tool like ALEx.
You now have a fully-featured genetic algorithm library with the following features:
- Basic problem definitions
- Customizable hyperparameters
- Customizable selection, crossover, mutation, and reinsertion strategies
- Customizable statistics
- Genealogy tracking
You can customize this library to accomplish any task imaginable. In the next chapter, rather than add new features, you’ll improve your library by learning how to optimize your existing code base.
Footnotes
[7] http://www.webgraphviz.com/
[8] https://github.com/devstopfix/gnuplot-elixir
[12] https://github.com/mgbellemare/Arcade-Learning-Environment/blob/master/ale_py/tests/fixtures/tetris.bin
[13] https://hexdocs.pm/alex/supported-roms.html#content
Copyright © 2021, The Pragmatic Bookshelf.
👈 Installing and Compiling ALEx | TOC | Chapter 11 Optimizing Your Algorithms 👉
Genetic Algorithms in Elixir by Sean Moriarity can be purchased in other book formats directly from the Pragmatic Programmers. If you notice a code error or formatting mistake, please let us know here so that we can fix it.

