Customizing Selection in Your Framework
Understand how to implement and customize various selection strategies in your genetic algorithm framework using Elixir. Explore setting selection rates, creating a toolbox for selection methods, and modifying the framework to apply different selection types. This lesson helps you balance population diversity and fitness while preparing for advanced reinsertion strategies.
Incorporating the new selection hyperparameters
In the lesson Understanding Hyperparameters, we briefly learned about hyperparameters and how to pass configuration options to the framework. At the time, the only hyperparameter we could change was population size.
Selection introduces two more hyperparameters: selection strategy and selection rate. In this lesson, we’ll tweak your framework to allow for changes in both.
Creating a selection toolbox
Before beginning, we’ll want a place to store some common selection strategies that we may need to solve some of the problems we encounter. Over here, we will create a new folder called toolbox which will be our toolbox of genetic operators. We ...