Summary
In this chapter, you were introduced to DEAP – a versatile evolutionary computation framework that will be used in the rest of this book to solve real-life problems using genetic algorithms. You learned about DEAP’s creator
and toolbox
modules, and how to use them to create the various components needed for the genetic algorithm’s flow. DEAP was then used to write two versions of a Python program that solves the OneMax problem, the first with full implementation of the genetic algorithm flow, and the other – more concise – taking advantage of the built-in algorithms of the framework. A third version of the program introduced the HOF feature offered by DEAP. We then experimented with various settings of the genetic algorithm and discovered the effects of changing the population size, as well as modifying the selection, crossover, and mutation operators.
In the next chapter, expanding on what we learned in this chapter, we will start solving...