180 likes | 339 Views
Genetic Algorithms (GA). Vavilin Andrey {andy@ulsan.islab.ac.kr}. What is GA?. GA is an heuristic search algorithm which generates solutions to optimization problems using techniques inspired by natural evolution, such as inheritance, mutation, selection, and crossover. Problem domain
E N D
Genetic Algorithms (GA) Vavilin Andrey {andy@ulsan.islab.ac.kr}
What is GA? • GA is an heuristic search algorithm which generates solutions to optimization problems using techniques inspired by natural evolution, such as inheritance, mutation, selection, and crossover. • Problem domain • graph-based problems (e.g. traveling salesman problem) • global optimization problems • scheduling and task planning problems • artificial intelligence tasks • computer vision • etc
Function minimization example 2 2 -2 -2
Function minimization 2 2 -2 -2 Gradient descent Best point: -3.567 Coordinates: 1.823, 1.549
Function minimization 2 2 -2 -2 Random search Iterations: 5000 Best point: -3,560 Coordinates: -1.899, -1.639
Function minimization 2 2 -2 -2 Genetic algorithm Iterations: 200 Best point: -3,949 Coordinates: -2, -1.960
Typical genetic algorithm initialization Population termination Survivor selection Parent selection Offspring Parents Recombination and mutation
Image processing examples P.W.M. Tsang and Z. Yu, “Genetic algorithm for model-based matching of projected images of three-dimensional objects”, IEE Proceedings on Vision, Image and Signal Processing, vol.150, issue 6, pp.351-359, Dec. 2003
Image processing examples P.W.M. Tsang and Z. Yu, “Genetic algorithm for model-based matching of projected images of three-dimensional objects”, IEE Proceedings on Vision, Image and Signal Processing, vol.150, issue 6, pp.351-359, Dec. 2003
Image processing examples P.W.M. Tsang and Z. Yu, “Genetic algorithm for model-based matching of projected images of three-dimensional objects”, IEE Proceedings on Vision, Image and Signal Processing, vol.150, issue 6, pp.351-359, Dec. 2003
Conclusions • Advantages: • Easy to implement • Better than random search and faster than brute force algorithm • Good for various classes of problems • Easy to use with GPU-based computation • Weak points • Specialized algorithms provide better solutions • GA do not scale well with increasing complexity • Bad implementation may cause algorithm converges to a local optima instead of a global one
Image processing example Initial population
Image processing example Crossover M1 Initial individuals M2 Individuals produced by crossover (changing position) (changing position and angle) (changing all)
Image processing example Mutations Randomly change random number of parameters in randomly select individuals. Number of individuals is 5% of population.
Image processing example Evaluating individuals using NN Pixel values Solid model … Probability what the tested individual is arrowhead Edge model …
Image processing example NN training Training set Pixel values Solid model … Edge model …