G5BAIM Artificial Intelligence Methods Dr. Rong Qu Evolutionary Algorithms.

Slides:



Advertisements
Similar presentations
© Glenn Rowe AC Lab 2 A simple card game (twenty- one)
Advertisements

G5BAIM Artificial Intelligence Methods Graham Kendall Evolutionary Algorithms.
Biologically Inspired Computing: Operators for Evolutionary Algorithms
Using Parallel Genetic Algorithm in a Predictive Job Scheduling
Tetris – Genetic Algorithm Presented by, Jeethan & Jun.
Parameter control Chapter 8. A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Parameter Control in EAs 2 Motivation 1 An EA has many.
Parameter Control A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Chapter 8.
Lecture 10. Simplified roulette European roulette has numbers 0,1,…36. xD0s
Rene Plowden Joseph Libby. Improving the profit margin by optimizing the win ratio through the use of various strategies and algorithmic computations.
CHAPTER 9 E VOLUTIONARY C OMPUTATION I : G ENETIC A LGORITHMS Organization of chapter in ISSO –Introduction and history –Coding of  –Standard GA operations.
Genetic Algorithms1 COMP305. Part II. Genetic Algorithms.
1 Lecture 8: Genetic Algorithms Contents : Miming nature The steps of the algorithm –Coosing parents –Reproduction –Mutation Deeper in GA –Stochastic Universal.
Estimation of Distribution Algorithms Let’s review what have done in EC so far: We have studied EP and found that each individual searched via Gaussian.
Fast Evolutionary Optimisation Temi avanzati di Intelligenza Artificiale - Lecture 6 Prof. Vincenzo Cutello Department of Mathematics and Computer Science.
Artificial Intelligence Genetic Algorithms and Applications of Genetic Algorithms in Compilers Prasad A. Kulkarni.
Intro to AI Genetic Algorithm Ruth Bergman Fall 2002.
Tutorial 1 Temi avanzati di Intelligenza Artificiale - Lecture 3 Prof. Vincenzo Cutello Department of Mathematics and Computer Science University of Catania.
Evolutionary Computational Intelligence Lecture 8: Memetic Algorithms Ferrante Neri University of Jyväskylä.
Introduction to Computational Intelligence (Evolutionary Computation) Evolutionary Computation is the field of study devoted to the design, development,
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.
Genetic Programming.
Slides are based on Negnevitsky, Pearson Education, Lecture 10 Evolutionary Computation: Evolution strategies and genetic programming n Evolution.
Prepared by Barış GÖKÇE 1.  Search Methods  Evolutionary Algorithms (EA)  Characteristics of EAs  Genetic Programming (GP)  Evolutionary Programming.
Genetic Algorithm.
Evolutionary Intelligence
© Negnevitsky, Pearson Education, CSC 4510 – Machine Learning Dr. Mary-Angela Papalaskari Department of Computing Sciences Villanova University.
Introduction to AI Michael J. Watts
Slides are based on Negnevitsky, Pearson Education, Lecture 12 Hybrid intelligent systems: Evolutionary neural networks and fuzzy evolutionary systems.
Introduction to Genetic Algorithms and Evolutionary Computation
Evolution Strategies Evolutionary Programming Genetic Programming Michael J. Watts
© Negnevitsky, Pearson Education, Lecture 10 Evolutionary Computation: Evolution strategies and genetic programming Evolution strategies Evolution.
Intro. ANN & Fuzzy Systems Lecture 36 GENETIC ALGORITHM (1)
Schemata Theory Chapter 11. A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Theory Why Bother with Theory? Might provide performance.
Zorica Stanimirović Faculty of Mathematics, University of Belgrade
Boltzmann Machine (BM) (§6.4) Hopfield model + hidden nodes + simulated annealing BM Architecture –a set of visible nodes: nodes can be accessed from outside.
Neural and Evolutionary Computing - Lecture 6
Computational Complexity Jang, HaYoung BioIntelligence Lab.
Genetic Algorithms Siddhartha K. Shakya School of Computing. The Robert Gordon University Aberdeen, UK
1 Chapter 14 Genetic Algorithms. 2 Chapter 14 Contents (1) l Representation l The Algorithm l Fitness l Crossover l Mutation l Termination Criteria l.
GENETIC ALGORITHM A biologically inspired model of intelligence and the principles of biological evolution are applied to find solutions to difficult problems.
EE459 I ntroduction to Artificial I ntelligence Genetic Algorithms Kasin Prakobwaitayakit Department of Electrical Engineering Chiangmai University.
© Negnevitsky, Pearson Education, Lecture 9 Evolutionary Computation: Genetic algorithms Introduction, or can evolution be intelligent? Introduction,
Evolutionary Programming
Edge Assembly Crossover
Genetic Algorithms What is a GA Terms and definitions Basic algorithm.
Evolution strategies Chapter 4. A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Evolution Strategies ES quick overview Developed: Germany.
Chapter 12 FUSION OF FUZZY SYSTEM AND GENETIC ALGORITHMS Chi-Yuan Yeh.
EE749 I ntroduction to Artificial I ntelligence Genetic Algorithms The Simple GA.
D Nagesh Kumar, IIScOptimization Methods: M8L5 1 Advanced Topics in Optimization Evolutionary Algorithms for Optimization and Search.
In the name of ALLAH Presented By : Mohsen Shahriari, the student of communication in Sajad institute for higher education.
The Standard Genetic Algorithm Start with a “population” of “individuals” Rank these individuals according to their “fitness” Select pairs of individuals.
Genetic Algorithm Dr. Md. Al-amin Bhuiyan Professor, Dept. of CSE Jahangirnagar University.
Selection and Recombination Temi avanzati di Intelligenza Artificiale - Lecture 4 Prof. Vincenzo Cutello Department of Mathematics and Computer Science.
Ch 20. Parameter Control Ch 21. Self-adaptation Evolutionary Computation vol. 2: Advanced Algorithms and Operators Summarized and presented by Jung-Woo.
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal Evolutionary Computation.
1 Comparative Study of two Genetic Algorithms Based Task Allocation Models in Distributed Computing System Oğuzhan TAŞ 2005.
Evolutionary Programming A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Chapter 5.
A.E. Eiben and J.E. Smith, Introduction to Evolutionary Computing Evolutionary Programming.
Breeding Swarms: A GA/PSO Hybrid 簡明昌 Author and Source Author: Matthew Settles and Terence Soule Source: GECCO 2005, p How to get: (\\nclab.csie.nctu.edu.tw\Repository\Journals-
Genetic Algorithm. Outline Motivation Genetic algorithms An illustrative example Hypothesis space search.
March 1, 2016Introduction to Artificial Intelligence Lecture 11: Machine Evolution 1 Let’s look at… Machine Evolution.
 Negnevitsky, Pearson Education, Lecture 12 Hybrid intelligent systems: Evolutionary neural networks and fuzzy evolutionary systems n Introduction.
Chapter 14 Genetic Algorithms.
Evolution Strategies Evolutionary Programming
Evolution strategies Can programs learn?
G5BAIM Artificial Intelligence Methods
Dr. Unnikrishnan P.C. Professor, EEE
Boltzmann Machine (BM) (§6.4)
Presentation transcript:

G5BAIM Artificial Intelligence Methods Dr. Rong Qu Evolutionary Algorithms

Learning in Computer Programs How Computer Program Learn? Another aspect of AI This lecture is only an introduction This techniques can be used as an optimisation strategy but we are going to look at a learning example

Evolutionary Algorithms Population based algorithm Genetic algorithm Ant algorithm Evolutionary strategies

Evolutionary Algorithms Chapter 8 of Michalewicz, Z. (1996). Genetic Algorithms + Data Structures = Evolution Programs, Springer-Verlag, ISBN Good description of EA History of ES GA vs. ES

Evolutionary Algorithms Almost anything by David Fogel Fogel, D. B. (1994) IEEE Transactions on Neural Networks, Vol 5:1, pp3-14 Fogel, D.B. (1998) Evolutionary Computation The Fossil Record, IEEE Press, ISBN , pp 3-14 Michalewicz, Z. and Fogel, D. (2000). How to Solve It : Modern Heuristics. Springer-Verlag, ISBN

Learning in Computer Programs There are other ways that we could design computer programs so that they “learn” For example, knowledge based on some suitable logic symbolism Use inference rules Learning by remembering and forgetting Using memory

Learning in Computer Programs Look at how Evolutionary Strategies (ES’s) can be used as evolving learning strategies Easily convert to optimisation tools

Learning in Computer Programs ES’s vs EP not confuse evolutionary strategies (ES’s) with evolutionary programming (EP) EP is about writing programs that write programs

Evolutionary Algorithms vs. GA’s GA’s Population of chromosomes Reproduction operators (more details in GAs section) Mutation Crossover Selection strategy Generations

Evolutionary Algorithms vs. GA’s ES’s are an algorithm that only uses mutation and does not use crossover This is not a formal definition and there is no reason why we cannot incorporate crossover (as Michalewicz, 1996 shows)

Evolutionary Algorithms vs. GA’s ES’s are normally applied to real numbers (continuous variables) rather than discrete values. Again, this is not a strict definition and work has been done on using ES’s for discrete problems (Bäck, 1991) and (Herdy, 1991)

Evolutionary Algorithms vs. GA’s ES’s are a population based approach Originally only a single solution was maintained and this was improved upon.

Evolutionary Algorithms vs. GA’s In summary ES’s are Like genetic algorithms but only use mutation and not crossover They operate on real numbers They are a population based approach But we can break any, or all, of these rules if we wish!

Evolutionary Algorithms - How They Work An individual in an ES is represented as a pair of real vectors, v = (x,σ) x, represents a point in the search space and consists of a number of real valued variables The second vector, σ, represents a vector of standard deviations how spread out the values in a data set are

Evolutionary Algorithms - How They Work Mutation is performed by replacing x by x t+1 = x t + N(0, σ) N(0, σ) is a random Gaussian number with a mean of zero and standard deviations of σ changing value by adding random noise drawn from normal distribution

Evolutionary Algorithms - How They Work This mimics the evolutionary process that small changes occur more often than larger ones An algorithm (in C++) that produces Gaussian random numbers is supplied in the handout

Evolutionary Algorithms - How They Work Set t = 0 Create initial point x t =  x 1 t,…,x n t  REPEAT Draw n i from a normal distribution for all i = 1,…,n y i t = x i t + n i New generation Set t = t+1 UNTIL (stopping condition)

Evolutionary Algorithms - How They Work In the earliest ES’s (where only a single solution was maintained), the new individual replaced its parent if it had a higher fitness Two-numbered evolution scheme Compete upon two individuals Survival become new parent

Evolutionary Algorithms - How They Work In addition, these early ES’s, maintained the same value for σ throughout the duration of the algorithm It has been proven that if this vector remains constant throughout the run then the algorithm will converge to the optimal solution

Evolutionary Algorithms - How They Work Problem Although the global optimum can be proved to be found with a probability of one, it also states that the theorem holds for sufficiently long search time The theorem tells us nothing about how long that search time might be

Evolutionary Algorithms - How They Work To try and speed up convergence Rechenberg has proposed the “1/5 success rule.” It can be stated as follows The ratio, , of successful mutations to all mutations should be 1/5. Increase the variance of the mutation operator if  is greater than 1/5; otherwise, decrease it

Evolutionary Algorithms - How They Work Motivation behind 1/5 rule If we are finding lots of successful moves then we should try larger steps in order to try and improve the efficiency of the search If we not finding many successful moves then we should proceed in smaller steps

Evolutionary Algorithms - How They Work The 1/5 rule is applied as follows if  (k) < 1/5 then σ = σc d if  (k) > 1/5 then σ = σc i if  (k) = 1/5 then σ = σ

Evolutionary Algorithms - How They Work if  (k) < 1/5 then σ = σc d if  (k) > 1/5 then σ = σc i if  (k) = 1/5 then σ = σ k dictates how many generations should elapse before the rule is applied c d and c i determine the rate of increase or decrease for σ c i must be greater than one and c d must be less than one Schwefel (1981) used c d = 0.82 and c i = 1.22 (=1/0.82)

Evolutionary Algorithms - How They Work Problem with the applying the 1/5 rule It may lead to premature convergence for some problems premature convergence Increase the population size, which now turns ES’s into a population based approach search mechanism

Evolutionary Algorithms - How They Work Increase population size The population size is now (obviously) > 1. All members of the population have an equal probability of mating - compare with GA’s We could now introduce the possibility of crossover

Evolutionary Algorithms - How They Work Increase population size As we have more than one individual we have the opportunity to alter σ independently for each member We have more options with regards to how we control the population (discussed next)

Evolutionary Algorithms - How They Work In evolutionary computation there are two variations as to how we create the new generation

Evolutionary Algorithms - How They Work (  + ), uses  parents and creates offspring After mutation, there will be  + members in the population All these solutions compete for survival, with the  best selected as parents for the next generation

Evolutionary Algorithms - How They Work ( , ), works by the  parents producing offspring (where >  ) Only the compete for survival. Thus, the parents are completely replaced at each new generation Or, to put it another way, a single solution only has a life span of a single generation

Evolutionary Algorithms - How They Work The original work on evolution strategies (Schwefel, 1965) used a (1 + 1) strategy This took a single parent and produced a single offspring Both these solutions competed to survive to the next generation

Evolutionary Algorithms - Case Study Develop agent that knows how to play poker learns to adapt its play when faced with different playing styles

Evolutionary Algorithms - Case Study Barone (1999) Calculate the probability x of winning at any position By enumerating all possible hands that can be held by the opponents

Evolutionary Algorithms - Case Study Barone (1999) Learning how to play Poker fold(x) = exp(-eval(b) * (x – a)) call(x) = eval(c) * exp(-eval(b) 2 * (x-a) 2 ) raise(x) = exp(eval(b) * (x + a – 1.0)) a, b, c: constants that shape the functions, which need to be learnt

Evolutionary Algorithms - Case Study Barone (1999) (1+1) strategy Mean of zero Pre-defined standard deviation Using the above model Evolve a poker player Adapt to player styles of four different players

Evolutionary Algorithms - Case Study Simplified Blackjack Blackjack is a two player game comprising of a dealer and a player. The dealer deals two cards (from a normal pack of 52 cards) to the player and one card to himself. All cards are dealt face up. All cards take their face value, except Jack, Queen and King which count as 10 and Aces which can count as one or eleven

Evolutionary Algorithms - Case Study Simplified Blackjack The aim for the player is to draw as many cards as he/she wishes (zero if they wish) in order to get as close as possible to 21 without exceeding 21 Other concepts (doubling down)

Evolutionary Algorithms - Case Study Simplified Blackjack Known good strategies Thorp (1966) – basic strategy What to do for every possible pair of cards Based on what the dealer’s “up card” is As more cards, what to do when approaching 21

Evolutionary Algorithms - Case Study Simplified Blackjack How might we write an agent that learns how to play blackjack? Specify rules exactly Make it be able to learn new set of rules Without re-writing program

Evolutionary Algorithms - Case Study Simplified Blackjack Identify each possible situation How many potential hands we may have Taking into account doubling down Assign each of these hands the same probability what to do Agent learn the probabilities by playing many (millions) of times of hands

Evolutionary Algorithms - Your Go Questions  Do you think this would work?  Should we use a single candidate for each probability or should we have a population greater than one?  What sort of evolutionary scheme should we use; (  + ) or ( , ); and what values should we give  and ?  Can you come up with a better representation; other than trying to learn probabilities?

Evolutionary Algorithms - Finally Evolutionary algorithms can be used as search methods as well as a learning mechanism It just needs saying!

Summary Learning in computer program Evolutionary strategies Knowledge based systems ES’s vs. GA’s Mutation and Crossover Real and discrete variables Probability of selecting parents

Summary How ES’s work? v = (x,σ) x t+1 = x t + N(0, σ) 1/5 success rule Population: (  + ), ( , ) Case study Poker blackjack

G5BAIM Artificial Intelligence Methods Dr. Rong Qu End of Evolutionary Algorithms