Lecture 22. Introduction to Genetic Algorithms

Similar documents
[Read Chapter 9] [Exercises 9.1, 9.2, 9.3, 9.4]

Individual learning and population evolution

Evolutionary Computation

Chapter 8: Introduction to Evolutionary Computation

V. Evolutionary Computing. Read Flake, ch. 20. Genetic Algorithms. Part 5A: Genetic Algorithms 4/10/17. A. Genetic Algorithms

Lecture 15: Genetic Algorithms

V. Evolutionary Computing. Read Flake, ch. 20. Assumptions. Genetic Algorithms. Fitness-Biased Selection. Outline of Simplified GA

Lecture 9 Evolutionary Computation: Genetic algorithms

Fundamentals of Genetic Algorithms

IV. Evolutionary Computing. Read Flake, ch. 20. Assumptions. Genetic Algorithms. Fitness-Biased Selection. Outline of Simplified GA

Evolutionary Computation. DEIS-Cesena Alma Mater Studiorum Università di Bologna Cesena (Italia)

Evolutionary computation

Genetic Algorithms. Donald Richards Penn State University

Genetic Algorithm. Outline

Evolutionary Algorithms: Introduction. Department of Cybernetics, CTU Prague.

Evolutionary computation

Genetic Algorithms & Modeling

Mechanisms of Evolution

Scaling Up. So far, we have considered methods that systematically explore the full search space, possibly using principled pruning (A* etc.).

CSC 4510 Machine Learning

Evolution. Just a few points

Lecture 3: Decision Trees

Learning Decision Trees

1 Errors in mitosis and meiosis can result in chromosomal abnormalities.

Evolutionary Algorithms

Evolutionary Algorithms: Introduction. The Czech Institute of Informatics, Robotics and Cybernetics CTU Prague

Data Warehousing & Data Mining

Reproduction- passing genetic information to the next generation

Statistical Models in Evolutionary Biology An Introductory Discussion

Computational statistics

Learning Decision Trees

Evolutionary Design I

Intelligens Számítási Módszerek Genetikus algoritmusok, gradiens mentes optimálási módszerek

Bounding the Population Size in XCS to Ensure Reproductive Opportunities

Adaptive Generalized Crowding for Genetic Algorithms

The Story So Far... The central problem of this course: Smartness( X ) arg max X. Possibly with some constraints on X.

Development. biologically-inspired computing. lecture 16. Informatics luis rocha x x x. Syntactic Operations. biologically Inspired computing

Decision Tree Learning Mitchell, Chapter 3. CptS 570 Machine Learning School of EECS Washington State University

Computer Simulations on Evolution BiologyLabs On-line. Laboratory 1 for Section B. Laboratory 2 for Section A

Bayesian Learning. Artificial Intelligence Programming. 15-0: Learning vs. Deduction

Search. Search is a key component of intelligent problem solving. Get closer to the goal if time is not enough

Genetic Algorithms and Genetic Programming Lecture 17

Crossover Techniques in GAs

Lecture 25 of 42. PAC Learning, VC Dimension, and Mistake Bounds

Introduction to Evolutionary Computation

EECS 349:Machine Learning Bryan Pardo

Exercise 3 Exploring Fitness and Population Change under Selection

Outline. Training Examples for EnjoySport. 2 lecture slides for textbook Machine Learning, c Tom M. Mitchell, McGraw Hill, 1997

CC283 Intelligent Problem Solving 28/10/2013

Genetic Algorithm for Solving the Economic Load Dispatch

Artificial Intelligence Methods (G5BAIM) - Examination

Moving Average Rules to Find. Confusion Matrix. CC283 Intelligent Problem Solving 05/11/2010. Edward Tsang (all rights reserved) 1

Geometric Semantic Genetic Programming (GSGP): theory-laden design of semantic mutation operators

CS 6375 Machine Learning

Machine Learning 2nd Edi7on

Computational intelligence methods

The Science of Biology. Chapter 1

Decision Trees.

What is Natural Selection? Natural & Artificial Selection. Answer: Answer: What are Directional, Stabilizing, Disruptive Natural Selection?

Chapter 2 Section 1 discussed the effect of the environment on the phenotype of individuals light, population ratio, type of soil, temperature )

Darwin s Theory of Evolution. The Puzzle of Life s Diversity

Evolution (Chapters 15 & 16)

The Role of Crossover in Genetic Algorithms to Solve Optimization of a Function Problem Falih Hassan

CSC 421: Algorithm Design & Analysis. Spring 2018

Theory a well supported testable explanation of phenomenon occurring in the natural world.

Stochastic Search: Part 2. Genetic Algorithms. Vincent A. Cicirello. Robotics Institute. Carnegie Mellon University

Darwin s Observations & Conclusions The Struggle for Existence

Bounded Approximation Algorithms

EQ: How are genetic variations caused and how do they lead to natural selection?

EVOLUTION. HISTORY: Ideas that shaped the current evolutionary theory. Evolution change in populations over time.

CSCE 478/878 Lecture 6: Bayesian Learning

APES C4L2 HOW DOES THE EARTH S LIFE CHANGE OVER TIME? Textbook pages 85 88

15 Darwin's Theory of Natural Selection. Publication of The Origin of Species

Regents Biology REVIEW 6: EVOLUTION. 1. Define evolution:

DETECTING THE FAULT FROM SPECTROGRAMS BY USING GENETIC ALGORITHM TECHNIQUES

Evolutionary Computation Theory. Jun He School of Computer Science University of Birmingham Web: jxh

Objectives for Chapter: 22

Evolutionary Computation: introduction

Genetic Changes Lesson 2 HW

Determination of Optimal Tightened Normal Tightened Plan Using a Genetic Algorithm

Local Search & Optimization

Evolution & Natural Selection

Along his journey, Darwin kept notes on the variation in different species. His book, Origin of Species, outlined his findings & theories in 1859.

Zebo Peng Embedded Systems Laboratory IDA, Linköping University

EVOLUTION change in populations over time

Ecology and evolution. Limnology Lecture 2

Other Organisms (Part 3)

Artificial Neural Networks Examination, June 2005

Introduction to population genetics & evolution

Decision Trees.

An Analysis of Diploidy and Dominance in Genetic Algorithms

Machine Learning Recitation 8 Oct 21, Oznur Tastan

Properties of Life. Levels of Organization. Levels of Organization. Levels of Organization. Levels of Organization. The Science of Biology.

Local Search (Greedy Descent): Maintain an assignment of a value to each variable. Repeat:

EVOLUTION change in populations over time

Theory of Evolution. Chapter 15

Evidence of evolution

Warm Up. Explain how a mutation can be detrimental in one environmental context and beneficial in another.

CS6375: Machine Learning Gautam Kunapuli. Decision Trees

Biology Slide 1 of 41

Transcription:

Lecture 22 Introduction to Genetic Algorithms Thursday 14 November 2002 William H. Hsu, KSU http://www.kddresearch.org http://www.cis.ksu.edu/~bhsu Readings: Sections 9.1-9.4, Mitchell Chapter 1, Sections 6.1-6.5, Goldberg Section 3.3.4, Shavlik and Dietterich (Booker, Goldberg, Holland)

Lecture Outline Readings Sections 9.1-9.4, Mitchell Suggested: Chapter 1, Sections 6.1-6.5, Goldberg Paper Review: Genetic Algorithms and Classifier Systems, Booker et al Evolutionary Computation Biological motivation: process of natural selection Framework for search, optimization, and learning Prototypical (Simple) Genetic Algorithm Components: selection, crossover, mutation Representing hypotheses as individuals in GAs An Example: GA-Based Inductive Learning (GABIL) GA Building Blocks (aka Schemas) Taking Stock (Course Review): Where We Are, Where We re Going

Evolutionary Computation Perspectives Computational procedures patterned after biological evolution Search procedure that probabilistically applies search operators to the set of points in the search space Applications Solving (NP NP-)hard problems Search: finding Hamiltonian cycle in a graph Optimization: traveling salesman problem (TSP) Learning: hypothesis space search

Biological Evolution Lamarck and Others Species transmute over time Learning in single individual can increase its fitness (survivability) Darwin and Wallace Consistent, heritable variation among individuals in population Natural selection of the fittest Mendel on Genetics Mechanism for inheriting traits Genotype phenotype mapping Genotype: functional unit(s) of heredity (genes) that an organism posesses Phenotype: overt (observable) features of living organism

Simple Genetic Algorithm (SGA) Algorithm Simple-Genetic-Algorithm (Fitness, Fitness-Threshold, p, r, m) // p: population size; r: replacement rate (aka generation gap width), m: string size P p random hypotheses // initialize population FOR each h in P DO f[h] Fitness(h) // evaluate Fitness: hypothesis R WHILE (Max(f) < Fitness-Threshold) DO 1. Select: Probabilistically select (1 - r)p members of P to add to P S 2. Crossover: P ( h ) i f = p j = 1 [ hi ] f [ h ] Probabilistically select (r p)/2 pairs of hypotheses from P FOR each pair <h 1, h 2 > DO P S += Crossover (<h 1, h 2 >) // P S [t+1] = P S [t] + <offspring 1, offspring 2 > 3. Mutate: Invert a randomly selected bit in m p random members of P S 4. Update: P P S 5. Evaluate: FOR each h in P DO f[h] Fitness(h) RETURN the hypothesis h in P that has maximum fitness f[h] j

Representing Hypotheses Individuals (aka Genes, Strings): What Can We Represent? Hypothesis Single classification rule Bit String Encodings Representation: implicit disjunction Q: How many bits per attribute? A: Number of values of the attribute Example: hypothesis Hypothesis: (Outlook = Overcast Rain) (Wind = Strong) Representation: Outlook [011]. Wind [10] 01110 Example: classification rule Rule: (Outlook = Overcast Rain) (Wind = Strong) PlayTennis = Yes Representation: Outlook [011]. Wind [10]. PlayTennis [10] 1111010

Crossover Operator Operators for Genetic Algorithms: Crossover Combines individuals (usually 2) to generate offspring (usually 2) Crossover mask: bit mask, indicates membership in first or second offspring Single-Point Initial strings: 11101001000 00001010101 Crossover mask: 11111000000 Offspring: 11101010101 00001001000 Two-Point Initial strings: 11101001000 00001010101 Crossover mask: 00111110000 Offspring: 11001011000 00101000101 Uniform (Choose Mask Bits Randomly ~ I.I.D. Uniform) Initial strings: 11101001000 00001010101 Crossover mask: 10011010011 Offspring: 10001000100 01101011001

Intuitive Idea Operators for Genetic Algorithms: Mutation Random changes to structures (gene strings) generate diversity among h P Compare: stochastic search in hypothesis space H Motivation: global search from good, randomly selected starting points (in P S ) Single-Point Initial string: 11101001000 Mutated string: 11101011000 (randomly selected bit is inverted) Similar to Boltzmann machine Recall: type of constraint satisfaction network +1, -1 activations (i.e., bit string) Flip one randomly and test whether new network state is accepted Stochastic acceptance function (with simulated annealing) Multi-Point Flip multiple bits (chosen at random or to fill prespecified quota) Similar to: some MCMC learning algorithms

Selecting Most Fit Hypotheses Fitness-Proportionate Selector aka proportionate reproduction, aka roulette wheel Representation share of total fitness (used in Simple-Genetic-Algorithm) Can lead to crowding (loss of diversity when fittest individuals dominate) Tournament Selection Intuitive idea: eliminate unfit individuals through direct competition Pick h 1, h 2 at random with uniform probability With probability p, select the most fit Rank Selection P ( h ) i = p j = 1 [ hi ] f [ h ] Like fitness-proportionate (key difference: non-uniform weighting wrt fitness) Sort all hypotheses by fitness Probability of selection is proportional to rank f j

GA-Based Inductive Learning (GABIL( GABIL) GABIL System [Dejong et al, 1993] Given: concept learning problem and examples Learn: disjunctive set of propositional rules Goal: results competitive with those for current decision tree learning algorithms (e.g., C4.5) Fitness Function: Fitness(h) = (Correct(h)) 2 Representation Rules: IF a 1 = T a 2 = F THEN c = T; IF a 2 = T THEN c = F Bit string encoding: a 1 [10]. a 2 [01]. c [1]. a 1 [11]. a 2 [10]. c [0] = 10011 11100 Genetic Operators Want variable-length rule sets Want only well-formed bit string hypotheses

Basic Representation Crossover: Variable-Length Bit Strings Start with a 1 a 2 c a 1 a 2 c h 1 1[0 01 1 11 1]0 0 h 2 0[1 1]1 0 10 01 0 Idea: allow crossover to produce variable-length offspring Procedure 1. Choose crossover points for h 1, e.g., after bits 1, 8 2. Now restrict crossover points in h 2 to those that produce bitstrings with welldefined semantics, e.g., <1, 3>, <1, 8>, <6, 8> Example Suppose we choose <1, 3> Result h 3 11 10 0 h 4 00 01 1 11 11 0 10 01 0

GABIL Extensions New Genetic Operators Applied probabilistically 1. AddAlternative: generalize constraint on a i by changing a 0 to a 1 2. DropCondition: generalize constraint on a i by changing every 0 to a 1 New Field Add fields to bit string to decide whether to allow the above operators a 1 a 2 c a 1 a 2 c AA DC 01 11 0 10 01 0 1 0 So now the learning strategy also evolves! aka genetic wrapper

GABIL Results Classification Accuracy Compared to symbolic rule/tree learning methods C4.5 [Quinlan, 1993] ID5R AQ14 [Michalski, 1986] Performance of GABIL comparable Average performance on a set of 12 synthetic problems: 92.1% test accuracy Symbolic learning methods ranged from 91.2% to 96.6% Effect of Generalization Operators Result above is for GABIL without AA and DC Average test set accuracy on 12 synthetic problems with AA and DC: 95.2%

Building Blocks (Schemas) Problem How to characterize evolution of population in GA? Goal Identify basic building block of GAs Describe family of individuals Definition: Schema String containing 0, 1, * ( don t care ) Typical schema: 10**0* Instances of above schema: 101101, 100000, Solution Approach Characterize population by number of instances representing each possible schema m(s, t) number of instances of schema s in population at time t

Selection and Building Blocks Restricted Case: Selection Only f t average fitness of population at time t m(s, t) number of instances of schema s in population at time t û s, t average fitness of instances of schema s at time t Quantities of Interest Probability of selecting h in one selection step f ( h) P h = n f h i = 1 Probability of selecting an instance of s in one selection step f ( h) uˆ ( s, t ) P h s = = m( s, t ) n f t n f t ( s ) Expected number of instances of s after n selections uˆ [ ] ( s, t ) E m s, t + 1 = m( s, t ) f t h p t i

Schema Theorem Theorem ( s, t ) f ( t ) uˆ d E[ m( s, t + 1) ] m s, c 1- l -1 s ( t ) 1- p ( p ) o( s ) m m(s, t) number of instances of schema s in population at time t f t average fitness of population at time t û s, t average fitness of instances of schema s at time t p c probability of single point crossover operator p m probability of mutation operator l length of individual bit strings o(s) number of defined (non * ) bits in s d(s) distance between rightmost, leftmost defined bits in s Intuitive Meaning The expected number of instances of a schema in the population tends toward its relative fitness A fundamental theorem of GA analysis and design

Terminology Evolutionary Computation (EC): Models Based on Natural Selection Genetic Algorithm (GA) Concepts Individual: single entity of model (corresponds to hypothesis) Population: collection of entities in competition for survival Generation: single application of selection and crossover operations Schema aka building block: descriptor of GA population (e.g., 10**0*) Schema theorem: representation of schema proportional to its relative fitness Simple Genetic Algorithm (SGA) Steps Selection Proportionate reproduction (aka roulette wheel): P(individual) f(individual) Tournament: let individuals compete in pairs or tuples; eliminate unfit ones Crossover Single-point: 11101001000 00001010101 { 11101010101, 00001001000 } Two-point: 11101001000 00001010101 { 11001011000, 00101000101 } Uniform: 11101001000 00001010101 { 10001000100, 01101011001 } Mutation: single-point ( bit flip ), multi-point

Summary Points Evolutionary Computation Motivation: process of natural selection Limited population; individuals compete for membership Method for parallelizing and stochastic search Framework for problem solving: search, optimization, learning Prototypical (Simple) Genetic Algorithm (GA) Steps Selection: reproduce individuals probabilistically, in proportion to fitness Crossover: generate new individuals probabilistically, from pairs of parents Mutation: modify structure of individual randomly How to represent hypotheses as individuals in GAs An Example: GA-Based Inductive Learning (GABIL) Schema Theorem: Propagation of Building Blocks Next Lecture: Genetic Programming, The Movie