Evolutionary Computing A Practical Introduction Presented by Ben Paechter Napier University with thanks to the EvoNet Training Committee and its “Flying.

Slides:



Advertisements
Similar presentations
Genetic Algorithms Chapter 3. A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Genetic Algorithms GA Quick Overview Developed: USA in.
Advertisements

Biologically Inspired Computing: Operators for Evolutionary Algorithms
Genetic Algorithms Contents 1. Basic Concepts 2. Algorithm
Evolutionary Computation (EC)
Tuesday, May 14 Genetic Algorithms Handouts: Lecture Notes Question: when should there be an additional review session?
21-May-15 Genetic Algorithms. 2 Evolution Here’s a very oversimplified description of how evolution works in biology Organisms (animals or plants) produce.
Genetic Algorithms Representation of Candidate Solutions GAs on primarily two types of representations: –Binary-Coded –Real-Coded Binary-Coded GAs must.
EvoNet Flying Circus Introduction to Evolutionary Computation Brought to you by (insert your name) The EvoNet Training Committee The EvoNet Flying Circus.
1 Lecture 8: Genetic Algorithms Contents : Miming nature The steps of the algorithm –Coosing parents –Reproduction –Mutation Deeper in GA –Stochastic Universal.
EvoNet Flying Circus Introduction to Evolutionary Computation Brought to you by (insert your name) The EvoNet Training Committee The EvoNet Flying Circus.
Evolutionary Computational Intelligence
Introduction to Genetic Algorithms Yonatan Shichel.
Intro to AI Genetic Algorithm Ruth Bergman Fall 2002.
Evolutionary Computational Intelligence Lecture 8: Memetic Algorithms Ferrante Neri University of Jyväskylä.
How to Build an Evolutionary Algorithm
Genetic Algorithms Nehaya Tayseer 1.Introduction What is a Genetic algorithm? A search technique used in computer science to find approximate solutions.
CS 447 Advanced Topics in Artificial Intelligence Fall 2002.
How to Build an Evolutionary Algorithm
Intro to AI Genetic Algorithm Ruth Bergman Fall 2004.
Chapter 6: Transform and Conquer Genetic Algorithms The Design and Analysis of Algorithms.
Genetic Algorithms Overview Genetic Algorithms: a gentle introduction –What are GAs –How do they work/ Why? –Critical issues Use in Data Mining –GAs.
Evolutionary Computation Instructor: Shu-Mei Guo Nature Inspired Algorithmic Techniques.
Prepared by Barış GÖKÇE 1.  Search Methods  Evolutionary Algorithms (EA)  Characteristics of EAs  Genetic Programming (GP)  Evolutionary Programming.
Evolutionary algorithms
Genetic Algorithm.
SOFT COMPUTING (Optimization Techniques using GA) Dr. N.Uma Maheswari Professor/CSE PSNA CET.
Genetic algorithms Prof Kang Li
Lecture 8: 24/5/1435 Genetic Algorithms Lecturer/ Kawther Abas 363CS – Artificial Intelligence.
Artificial Intelligence Lecture No. 31 Dr. Asad Ali Safi ​ Assistant Professor, Department of Computer Science, COMSATS Institute of Information Technology.
What is Genetic Programming? Genetic programming is a model of programming which uses the ideas (and some of the terminology) of biological evolution to.
Genetic algorithms Charles Darwin "A man who dares to waste an hour of life has not discovered the value of life"
L ECTURE 3 Notes are modified from EvoNet Flying Circus slides. Found at: www2.cs.uh.edu/~ceick/ai/EC1.ppt.
Introduction to GAs: Genetic Algorithms How to apply GAs to SNA? Thank you for all pictures and information referred.
An Introduction to Genetic Algorithms Lecture 2 November, 2010 Ivan Garibay
Artificial Intelligence Chapter 4. Machine Evolution.
2005MEE Software Engineering Lecture 11 – Optimisation Techniques.
EvoNet Flying Circus Introduction to Evolutionary Computation Brought to you by (insert your name) The EvoNet Training Committee The EvoNet Flying Circus.
Introduction to Genetic Algorithms. Genetic Algorithms We’ve covered enough material that we can write programs that use genetic algorithms! –More advanced.
Genetic Algorithms What is a GA Terms and definitions Basic algorithm.
Genetic Algorithms. 2 Overview Introduction To Genetic Algorithms (GAs) GA Operators and Parameters Genetic Algorithms To Solve The Traveling Salesman.
Chapter 12 FUSION OF FUZZY SYSTEM AND GENETIC ALGORITHMS Chi-Yuan Yeh.
EE749 I ntroduction to Artificial I ntelligence Genetic Algorithms The Simple GA.
Genetic Algorithms. The Basic Genetic Algorithm 1.[Start] Generate random population of n chromosomes (suitable solutions for the problem) 2.[Fitness]
GENETIC ALGORITHM Basic Algorithm begin set time t = 0;
D Nagesh Kumar, IIScOptimization Methods: M8L5 1 Advanced Topics in Optimization Evolutionary Algorithms for Optimization and Search.
Genetic Algorithms MITM613 (Intelligent Systems).
1 Autonomic Computer Systems Evolutionary Computation Pascal Paysan.
An Introduction to Genetic Algorithms Lecture 2 November, 2010 Ivan Garibay
Genetic Algorithms. Underlying Concept  Charles Darwin outlined the principle of natural selection.  Natural Selection is the process by which evolution.
Genetic Algorithm Dr. Md. Al-amin Bhuiyan Professor, Dept. of CSE Jahangirnagar University.
Introduction to Evolutionary Computing II A.E. Eiben Free University Amsterdam with thanks to the EvoNet Training Committee.
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal Evolutionary Computation.
Overview Last two weeks we looked at evolutionary algorithms.
EvoNet Flying Circus Introduction to Evolutionary Computation Brought to you by (insert your name) The EvoNet Training Committee The EvoNet Flying Circus.
Genetic Algorithms And other approaches for similar applications Optimization Techniques.
Genetic Algorithm(GA)
Genetic Algorithm. Outline Motivation Genetic algorithms An illustrative example Hypothesis space search.
 Presented By: Abdul Aziz Ghazi  Roll No:  Presented to: Sir Harris.
Introduction to Genetic Algorithms
Genetic Algorithms.
Introduction to Evolutionary Computing
Evolutionary Algorithms Jim Whitehead
Evolutionary Computation
CSC 380: Design and Analysis of Algorithms
Artificial Intelligence Chapter 4. Machine Evolution
Genetic Algorithms Chapter 3.
Artificial Intelligence Chapter 4. Machine Evolution
Genetic Algorithm Soft Computing: use of inexact t solution to compute hard task problems. Soft computing tolerant of imprecision, uncertainty, partial.
CSC 380: Design and Analysis of Algorithms
Presentation transcript:

Evolutionary Computing A Practical Introduction Presented by Ben Paechter Napier University with thanks to the EvoNet Training Committee and its “Flying Circus”

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Contents Natural Evolution Evolutionary Algorithms A Simple Example Simple Demonstrations How to Build an Evolutionary Algorithm

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Natural Genetics The information required to build a living organism is coded in the DNA and other genetic material found in the cells of that organism Within a species, most of the genetic material is the same Small changes in the genetic material give rise to small changes in the organism E.g height, hair colour

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School DNA and Genes DNA is a large molecule made up of fragments. There are several fragment types, each one acting like a letter in a long coded message: -A-B-A-D-C-B-B-C-C-A-D-B-C-C-A- Certain groups of letters are meaningful together - a bit like words. These groups are called genes The DNA is made up of genes and rubbish

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Example: Human Reproduction Human DNA is organised into chromosomes Most human cells contains 23 pairs of chromosomes which together define the physical attributes of the individual:

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Reproductive Cells Sperm and egg cells contain 23 individual chromosomes rather than 23 pairs Reproductive cells are formed by one cell splitting into two During this process the pairs of chromosome undergo an operation called crossover

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Crossover During crossover the chromosome pairs link up and swap parts of themselves: Before After After crossover one of each pair goes into each cell

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Fertilisation Sperm cell from Father Egg cell from Mother New person cell

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Mutation Occasionally some of the genetic material changes very slightly during this process This means that the child might have genetic material information not inherited from either parent This is most likely to be catastrophic

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Theory of Evolution Mutation, Crossover =>New genetic material or new combinations. Usually less able to to survive and so reproduce Occasionally more able to survive and so reproduce More reproduction leads to more of the “new improved” genetic “Good” sets of genes get reproduced more “Bad” sets of genes get reproduce less Organisms as a whole get better and better at surviving in their environment Evolutionists claim that this slow changing of genetic material through reproduction, mutation and possibly crossover has produced all the species of plants and animals

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Evolution as Search Evolution - search through the enormous genetic parameter space for the best genetic make-up Borrow ideas from nature to help us solve problems that have an equally large search spaces or similarly changing environment

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Evolutionary Computing The Metaphor Natural Evolution Individual Fitness Environment Evolutionary Computation Candidate Solution Quality Problem

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School The Evolutionary Cycle Recombination Mutation Population OffspringParents Selection Replacement

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Simple Example The Knapsack Problem The problem is to choose which items to take in a knapsack. Each item has a weight and a value We want to maximise the value of the items in the knapsack, without exceeding some maximum weight. Note: This is not the best way to solve this problem with an evolutionary algorithm and an evolutionary algorithm is not the best way to solve this problem!

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Chromosome Representation An array of bits - one for each item in the knapsack A “1” means - take the item A “0” mean don’t take the itemCHROMOSOMEGENE Create 100 random bit strings for the initial population

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Chromosome Fitness Evaluation Add up the value of the items in the knapsack to give the fitness. If the knapsack is overweight, then subtract from the fitness the amount overweight.

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Choosing Parents to Reproduce To choose one parent: Choose two chromosomes randomly from the population. Whichever has the highest fitness is the parent.

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School To make a child - Recombination For each gene choose randomly whether to take it from one chromosome or the other Parents Child

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Mutation Give each gene a small chance of flipping - say 1/(length of string)

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Replacement When inserting a new child into the population, choose a existing member to kill by: Choosing two chromosomes randomly from the population. Whichever has the lowest fitness is killed.

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School The Evolutionary Cycle Recombination Mutation Population OffspringParents Selection Replacement

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School The Evolution Mechanism Increasing diversity by genetic operators mutation recombination Decreasing diversity by selection of parents things to kill

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Real World EC Tends to include: More complex representations and operators Use of problem specific knowledge for seeding the initial population and creating heuristic operators Hybridisation with other methods

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Advantages Handles huge search spaces Balances exploration and exploitation Easy to try - not knowledge intensive Easy to combine with other methods Provides many alternative solutions Can continually evolve solutions to fit with a continually changing problem

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Disadvantages No guarantee for optimal solution within finite time - lacks the killer instinct Weak theoretical basis May need extensive parameter tuning Often computationally expensive, i.e. slow

Demos

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School How to Build an Evolutionary Algorithm

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School The Steps Design a representation Decide how to initialise a population Design a way of mapping a genotype to a phenotype Design a way of evaluating an individual Design suitable mutation operator(s) Design suitable recombination operator(s) Decide how to select individuals to be parents Decide how to manage the population Decide when to stop the algorithm

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Designing a Representation How to represent an individual as a genotype. Should be relevant to the problem that we are solving. Consider at same time How genotype is evaluated Possible genetic operators

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Possible Representations Binary string String of integers String of reals Trees Much more complicated things

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Initialization uniformly on the search space, e.g.: Binary strings: 0 or 1 with probability 0.5 Real-valued representations: Uniformly on a given interval Seed with previous results or those from heuristics, or the user. With care: Possible loss of genetic diversity Possible unrecoverable local optimum

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Getting a Phenotype from our Genotype Sometimes producing the phenotype from the genotype is a simple and obvious process. Other times the genotype might be a set of parameters to some algorithm, which works on the problem data to produce the phenotype Genotype Problem Data Phenotype Growth Function

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Evaluating an Individual This is by far the most costly step for real applications simple calculation, a black-box simulator, external process ( e.g. robot experiment) Could use approximate fitness - but not for too long

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School More on Evaluation Constraint handling - what if the phenotype breaks some constraint of the problem: penalize the fitness specific evolutionary methods Multi-objective evolutionary optimization Special methods for dealing with multi-objective optimisation - give a set of compromise solutions.

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Mutation Operators One or more mutation operators for our representation: At least one mutation operator should allow every part of the search space to be reached The size of mutation is important and should be controllable The recombination operator(s) should be designed in conjunction with the representation so that mutation is not always catastrophic Mutation should produce valid chromosomes Heuristic mutations might be used

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Recombination Operators One or more recombination operators for our representation. The child should inherit something from each parent. If this is not the case then the operator is a mutation operator. The recombination operator(s) should be designed in conjunction with the representation so that recombination is not always catastrophic Recombination should produce valid chromosomes Heuristic recombination might be used

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Selection Strategy We want: better individuals to have a better chance of being parents than less good individuals. This will give us selection pressure which will drive the population forward. We must be careful: less good individuals must have some chance of being parents - they may include some useful genetic material.

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Population Strategy The selection pressure is also affected by the way in which we manage the population: How do we decide which individuals to kill to make way for new ones? Is the population size fixed? Do we allow duplicates in the population? Should we always keep the best in the population? (Elitism) Should we replace the whole population at once? (generational) Or just one individual at a time? (steady-state), Or something else? Do we select between the children? Do we compare parents and children?

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Stopping criterion The optimum is reached! Limit on CPU resources: Maximum number of fitness evaluations Limit on the user’s patience: After some generations without improvement

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Algorithm performance Never draw any conclusion from a single run use statistical measures (averages, medians) from a sufficient number of independent runs From the application point of view design perspective: find a very good solution at least once production perspective: find a good solution at almost every run

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Maintaining Genetic Diversity We must try to maintain genetic diversity: loss of genetic diversity = all individuals in the population look alike snowball effect convergence to the nearest local optimum

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Balancing Exploration and Exploitation We should try to balance exploration and exploitation: Exploration =sample unknown regions Too much exporation = random search, no convergence Exploitation = try to improve the best-so-far individuals Too much expoitation = local search only … convergence to a local optimum

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Summary Evolutionary Computation: is a method, based on biological metaphors, of breeding solutions to problems has been shown to be useful in a number of areas could be useful for your problem its easy to give it a try

Evolutionary Computing - A Practical Introduction by Ben Paechter, Napier University, for the EvoNet Summer School Further Information and Demos The EvoNet Flying Circus : evonet.dcs.napier.ac.uk/evoweb/resources/flying_circus/index.html