Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On Genetic Algorithms with Python

You're reading from   Hands-On Genetic Algorithms with Python Applying genetic algorithms to solve real-world deep learning and artificial intelligence problems

Arrow left icon
Product type Paperback
Published in Jan 2020
Publisher Packt
ISBN-13 9781838557744
Length 346 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Eyal Wirsansky Eyal Wirsansky
Author Profile Icon Eyal Wirsansky
Eyal Wirsansky
Arrow right icon
View More author details
Toc

Table of Contents (18) Chapters Close

Preface 1. Section 1: The Basics of Genetic Algorithms
2. An Introduction to Genetic Algorithms FREE CHAPTER 3. Understanding the Key Components of Genetic Algorithms 4. Section 2: Solving Problems with Genetic Algorithms
5. Using the DEAP Framework 6. Combinatorial Optimization 7. Constraint Satisfaction 8. Optimizing Continuous Functions 9. Section 3: Artificial Intelligence Applications of Genetic Algorithms
10. Enhancing Machine Learning Models Using Feature Selection 11. Hyperparameter Tuning of Machine Learning Models 12. Architecture Optimization of Deep Learning Networks 13. Reinforcement Learning with Genetic Algorithms 14. Section 4: Related Technologies
15. Genetic Image Reconstruction 16. Other Evolutionary and Bio-Inspired Computation Techniques 17. Other Books You May Enjoy

Limitations of genetic algorithms

To get the most out of genetic algorithms, we need to be aware of their limitations and potential pitfalls.

The limitations of genetic algorithms are as follows:

  • The need for special definitions
  • The need for hyperparameter tuning
  • Computationally-intensive operations
  • The risk of premature convergence
  • No guaranteed solution

We will cover each of these in the upcoming sections.

Special definitions

When applying genetic algorithms to a given problem, we need to create a suitable representation for them – define the fitness function and the chromosome structure, as well as the selection, crossover, and mutation operators that will work for this problem. This can often prove to be challenging and time-consuming.

Luckily, genetic algorithms have already been applied to countless different types of problems, and many of these definitions have been standardized. This book covers numerous types of real-life problems and the way they can be solved using genetic algorithms. Use this as guidance whenever you are challenged by a new problem.

Hyperparameter tuning

The behavior of genetic algorithms is controlled by a set of hyperparameters, such as the population size and mutation rate. When applying genetic algorithms to the problem at hand, there are no exact rules for making these choices.

However, this is the case for virtually all search and optimization algorithms. After going over the examples in this book and doing some experimentation of your own, you will be able to make sensible choices for these values.

Computationally-intensive

Operating on (potentially large) populations and the repetitive nature of genetic algorithms can be computationally intensive, as well as time consuming before a good result is reached.

These can be alleviated with a good choice of hyperparameters, implementing parallel processing, and in some cases, caching the intermediate results.

Premature convergence

If the fitness of one individual is much higher than the rest of the population, it may be duplicated enough that it takes over the entire population. This can lead to the genetic algorithm getting prematurely stuck in a local maximum, instead of finding the global one.

To prevent this from occurring, it is important to maintain the diversity of the population. Various ways to maintain diversity will be discussed in the next chapter.

No guaranteed solution

The use of genetic algorithms does not guarantee that the global maximum for the problem at hand will be found.

However, this is almost the case for any search and optimization algorithm, unless it is an analytical solution for a particular type of problem.

Generally, genetic algorithms, when used appropriately, are known to provide good solutions within a reasonable amount of time. Now, let's look at a few use cases of genetic algorithms.

You have been reading a chapter from
Hands-On Genetic Algorithms with Python
Published in: Jan 2020
Publisher: Packt
ISBN-13: 9781838557744
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image