January 2020
Intermediate to advanced
346 pages
9h 8m
English
To identify the best set of features to be used for our Zoo classification task using a genetic algorithm, we've created the Python program 02-solve-zoo.py, which is located at https://github.com/PacktPublishing/Hands-On-Genetic-Algorithms-with-Python/blob/master/Chapter07/02-solve-zoo.py.
As in the previous section, the chromosome representation that's being used here is a list of integers with the values of 0 or 1, denoting whether a feature should be used or dropped.
The following steps highlight the main parts of the program:
zoo = zoo.Zoo(RANDOM_SEED)
Read now
Unlock full access