Software framework for metaheuristics Parallel Cooperative Optimization Research Group Laboratoire d’Informatique Fondamentale de Lille

Slides:



Advertisements
Similar presentations
Population-based metaheuristics Nature-inspired Initialize a population A new population of solutions is generated Integrate the new population into the.
Advertisements

CS6800 Advanced Theory of Computation
1 An Adaptive GA for Multi Objective Flexible Manufacturing Systems A. Younes, H. Ghenniwa, S. Areibi uoguelph.ca.
Multi-Objective Optimization NP-Hard Conflicting objectives – Flow shop with both minimum makespan and tardiness objective – TSP problem with minimum distance,
Tabu Search Strategy Hachemi Bennaceur 5/1/ iroboapp project, 2013.
CSM6120 Introduction to Intelligent Systems Evolutionary and Genetic Algorithms.
Spie98-1 Evolutionary Algorithms, Simulated Annealing, and Tabu Search: A Comparative Study H. Youssef, S. M. Sait, H. Adiche
1 Wendy Williams Metaheuristic Algorithms Genetic Algorithms: A Tutorial “Genetic Algorithms are good at taking large, potentially huge search spaces and.
Nature’s Algorithms David C. Uhrig Tiffany Sharrard CS 477R – Fall 2007 Dr. George Bebis.
Introduction to Artificial Intelligence Local Search (updated 4/30/2006) Henry Kautz.
Imagine that I am in a good mood Imagine that I am going to give you some money ! In particular I am going to give you z dollars, after you tell me the.
EAs for Combinatorial Optimization Problems BLG 602E.
D Nagesh Kumar, IIScOptimization Methods: M1L4 1 Introduction and Basic Concepts Classical and Advanced Techniques for Optimization.
Ant Colony Optimization: an introduction
Metaheuristics The idea: search the solution space directly. No math models, only a set of algorithmic steps, iterative method. Find a feasible solution.
Elements of the Heuristic Approach
GAlib A C++ Library of Genetic Algorithm Components Vanessa Herves Gómez Department of Computer Architecture and Technology,
Genetic Algorithms: A Tutorial
Genetic Algorithms and Ant Colony Optimisation
Swarm Intelligence 虞台文.
An Introduction to Artificial Life Lecture 4b: Informed Search and Exploration Ramin Halavati In which we see how information.
Zorica Stanimirović Faculty of Mathematics, University of Belgrade
Search Methods An Annotated Overview Edward Tsang.
Heuristic Optimization Methods
Design & Analysis of Algorithms Combinatory optimization SCHOOL OF COMPUTING Pasi Fränti
Optimization Problems - Optimization: In the real world, there are many problems (e.g. Traveling Salesman Problem, Playing Chess ) that have numerous possible.
Introduction to GAs: Genetic Algorithms How to apply GAs to SNA? Thank you for all pictures and information referred.
1 “Genetic Algorithms are good at taking large, potentially huge search spaces and navigating them, looking for optimal combinations of things, solutions.
FINAL EXAM SCHEDULER (FES) Department of Computer Engineering Faculty of Engineering & Architecture Yeditepe University By Ersan ERSOY (Engineering Project)
C OMPARING T HREE H EURISTIC S EARCH M ETHODS FOR F UNCTIONAL P ARTITIONING IN H ARDWARE -S OFTWARE C ODESIGN Theerayod Wiangtong, Peter Y. K. Cheung and.
A Simple Example The Traveling Salesman Problem: Find a tour of a given set of cities so that each city is visited only once the total distance traveled.
G5BAIM Artificial Intelligence Methods
Single-solution based metaheuristics. Outline Local Search Simulated annealing Tabu search …
1 Genetic Algorithms and Ant Colony Optimisation.
Genetic Algorithms Przemyslaw Pawluk CSE 6111 Advanced Algorithm Design and Analysis
Genetic Algorithms CSCI-2300 Introduction to Algorithms
Probabilistic Algorithms Evolutionary Algorithms Simulated Annealing.
Tutorial on ParadisEO: Parallel Models for the TSP
D Nagesh Kumar, IIScOptimization Methods: M8L5 1 Advanced Topics in Optimization Evolutionary Algorithms for Optimization and Search.
1 ParadisEO-MOEO for a Bi-objective Flow-Shop Scheduling Problem May 2007 E.-G. Talbi and the ParadisEO team
Gerstner Lab, CTU Prague 1Motivation Typically,  an evolutionary optimisation framework considers the EA to be used to evolve a population of candidate.
Reusable Design of Evolutionary Algorithms. Parallel Cooperative Optimization Research Group Laboratoire d’Informatique Fondamentale de Lille.
Intro. ANN & Fuzzy Systems Lecture 37 Genetic and Random Search Algorithms (2)
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal Evolutionary Computation.
Genetic Algorithms. Solution Search in Problem Space.
EVOLUTIONARY SYSTEMS AND GENETIC ALGORITHMS NAME: AKSHITKUMAR PATEL STUDENT ID: GRAD POSITION PAPER.
Genetic Algorithms An Evolutionary Approach to Problem Solving.
Genetic Algorithms And other approaches for similar applications Optimization Techniques.
School of Computer Science & Engineering
Parallel Cooperative Optimization Research Group
Example: Applying EC to the TSP Problem
Artificial Intelligence (CS 370D)
Subject Name: Operation Research Subject Code: 10CS661 Prepared By:Mrs
Comparing Genetic Algorithm and Guided Local Search Methods
metaheuristic methods and their applications
Example: Applying EC to the TSP Problem
Genetic Algorithms: A Tutorial
`Biologically Inspired Computing’
Example: Applying EC to the TSP Problem
Metaheuristic methods and their applications. Optimization Problems Strategies for Solving NP-hard Optimization Problems What is a Metaheuristic Method?
Multi-Objective Optimization
Genetic Algorithms CSCI-2300 Introduction to Algorithms
Design & Analysis of Algorithms Combinatorial optimization
Artificial Intelligence CIS 342
This is additional material for week 2 of
Traveling Salesman Problem by Genetic Algorithm
Beyond Classical Search
Population Based Metaheuristics
Genetic Algorithms: A Tutorial
Simulated Annealing & Boltzmann Machines
Presentation transcript:

Software framework for metaheuristics Parallel Cooperative Optimization Research Group Laboratoire d’Informatique Fondamentale de Lille

Outline framework. ParadisEO-EO (population-based metaheuristics). ParadisEO-MO (solution-based metaheuristics). EO & MO  hybridized metaheuristics. Conclusions and perspectives

Framework and tutorial application  Framework dedicated to metaheuristics   Tutorial application  The Traveling Salesman Problem (TSP) Parallel and Distributed Evolving Objects

ParadisEO (1/2)  A templates-based, ANSI-C++ compliant Metaheuristic Computation Framework.  GForge Project by INRIA Dolphin Team.  Paradigm Free (genetic algorithms, genetic programming, particle swarm optimization, local searches …).  Hybrid, distributed and cooperative models.

 Flexible / a considered problem.  Generic components (variation operators, selection, replacement, termination, particle behaviors …).  Many services (visualization, managing command-line parameters, saving/restarting, …). ParadisEO (2/2)

Evolutionary computation, Swarm intelligence : population- based metaheuristics Tabu Search, Simulated Annealing, Hill Climbing: single solution based metaheuristics Multi-objective metaheuristics Parallel and distributed metaheuristics ParadisEO: Module-based architecture

Evolutionary computation, Swarm intelligence: population-based metaheuristics Tabu Search, Simulated Annealing, Hill Climbing: single solution based metaheuristics Multi-objective metaheuristics Parallel and distributed metaheuristics ParadisEO: Module-based architecture

ParadisEO-EO (Evolving Object)

Available approaches Genetic algorithm (GA). Genetic programming (GP). Evolution strategies (ES). Evolutionary algorithm (EA). Evolutionary programming (EG). Particle Swarm Optimization (PSO). Estimation of Distribution Algorithm (EDA).

Design concepts Each metaheuristic has: – generic parts  not dedicated to one problem. –dedicated parts  linked to the problem to solve. The user: –can directly use the available generic boxes, –has only to code the information dedicated to his problem.

Needed task: designing a representation  Maybe several ways to do this. The representation must be relevant regards the tackled problem.  The user needs to have:  basic representations available.  the possibility to use his specific representation.

Existent basic representations

Scheme of one available algorithm: the evolutionary algorithm

The Traveling Salesman Problem (TSP)  “Given a collection of N cities and the distance between each pair of them, the TSP aims at finding the shortest route visiting all of the cities”.  Symmetric TSP:candidate solutions.  Example: v0v0 v4v4 v2v2 v1v Length: 26 v3v3

Representation and evaluation  We aim at minimizing the total length of the path: v5v5 v3v3 v4v4 v2v2 v1v

Application to the TSP  Path encoding:  Every node is assigned a number (e.g. from 0 up to n - 1) and solutions are represented by the ordered sequence of visited nodes.

Scheme of one available algorithm: the evolutionary algorithm

Implementation of an EA (1/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (2/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (3/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (4/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (5/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (6/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (7/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (8/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Implementation of an EA (9/9) RouteInit route_init; RouteEval full_route_eval; eoPop pop (POP_SIZE, route_init); eoGenContinue continue (NUM_GEN); OrderXover crossover; CitySwap mutation; eoStochTournamentSelect select_one; eoSelectNumber select (select_one, POP_SIZE); eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop);

Other features Checkpointing system. Configuration file creation and management. Visualization tools (link with gnuplot). Automatic design tool. …

ParadisEO-MO (Moving Object)

Design concepts Single solution metaheurisitcs  neighbourhood exploration. How can another solution be generated ?  disturbing the current solution  make a movement. Base of ParadisEO-MO = moMove.

Available algorithms Hill Climbing Tabu Search Simulated Annealing

Design a move for the TSP Reminding the chosen coding.  Ordered sequence of visited vertices Some relevant moves: – Two-opt, City-swap, LK, etc…

Two-Opt Two points within the string are selected and the segment between them is inverted. This operator put in two new edges in the tour Delta = - d(2,1) – d (5,3) + d(2, 5) + d(1, 3)

Hill Climbing

How can a Hill Climbing be built ? Designing a move operator, its features. Designing/implementing the operator to build the first move (and implicitly the first neighboring candidate). Designing/implementing the operator to update a given move to its successor. Designing/implementing the incremental evaluation function. Choosing the neighbour selection strategy. No continuation criterion (stopping as a local optimum is reached).

Hill Climbing class To build the first move To build the next move To compute the fitness delta Full evaluation function Move selection strategies

Two-Opt features (1/2) TwoOpt  a two-opt move is a couple of positions in the sequence of visited nodes. TwoOptInit  it initializes both positions to zero !

Two-Opt features (2/2) TwoOptNext  i t increments the second position if possible. Else, it increments the first position, and reinitializes the second position. TwoOptIncrEval  It computes the new length from the costs of the added/removed edges.

Neighbour selection strategy Deterministic/full: choosing the best neighbor (i.e. that improves the most the cost function). Deterministic/partial: choosing the first processed neighbour that is better than the current solution. Stochastic/full: processing the whole neighborhood and applying a random better one.

Implementation of a Hill Climbing Route route; /* One solution */ RouteInit route_init; /* Its builds random routes */ route_init (route); /* Building a random starting solution */ RouteEval full_route_eval; /* Full route evaluator */ TwoOptInit two_opt_init; /* Initializing the first couple of edges to swap */ TwoOptNext two_opt_next; /* Updating a movement */ TwoOptIncrEval two_opt_incr_eval; /* Efficiently evaluating a given neighbor */ moBestImprSelect two_opt_move_select; /* Movement selection strategy (elitist) */ /* Building the Hill Climbing from those components */ moHC hill_climbing (two_opt_init, two_opt_next, two_opt_incr_eval, two_opt_move_select, full_route_eval); /* It applies the HC to the solution */ hill_climbing (route);

Simulated Annealing

How can a Simulated Annealing be built ? Designing a move operator, its features. Designing/implementing the operator to build a random candidate move. Designing/implementing the incremental evaluation function. Choosing the cooling schedule strategy. Independent of the tackled problem Could be reused from Hill Climbing

Simulated Annealing class To compute the fitness delta Cooling schedule strategy Random move generator Full evaluation function

The Two-Opt random move generator It randomly determines a couple of random positions ! class TwoOptRand : public moMoveRand { public : void operator () (TwoOpt & __move, const Route & __route) ; } ; To be implemented

Cooling Schedule Two (basic) strategies are already implemented: linear and exponential: –Linear  temp = temp – x. –Exponential  temp = temp * x.

Route route; /* One solution */ RouteInit route_init; /* Its builds random routes */ route_init (route); /* Building a random starting solution */ RouteEval full_route_eval; /* Full route evaluator */ TwoOptRand two_opt_rand; /* It builds random candidate movements */ TwoOptIncrEval two_opt_incr_eval; /* Efficiently evaluating a given neighbor */ moExponentialCoolingSchedule cool_scheme (0.99, 1); /*Cooling schedule and associated parameters */ /* Building the Simulated Annealing from those components */ moSA simulated_annealing (two_opt_init, two_opt_incr_eval, 100, 100, cool_scheme, full_route_eval); /* It applies the SA to the solution */ simulated_annealing (route); Implementation of Simulated Annealing Factor and threshold Initial temperature and number of iterations at any step

Tabu Search

How can Tabu Search be built ? Design a move operator, its features. Design/implement the operator to build the first move (and implicitly the first neighboring candidate). Design/implement the operator to update a given move to its successor. Design/implement the incremental evaluation function. Design/implement the Tabu List. Choosing the aspiration criterion. Choosing the continuation criterion. Could be reused from Hill Climbing Independent of the tackled problem

Tabu Search class To build the first move To build the next move To compute the fitness delta Full evaluation function Tabu List Aspiration criterion Continuation criterion

Tabu List Predefined structures: –List of tabu solutions or tabu moves storing the tenure (short term memory).

Choosing an aspiration criterion (Basic) implemented strategies: –No aspiration criterion, –A tabu move builds a new solution that updates the best solution found during the search.

Choosing a stopping criterion Use strategies equivalent to those in ParadisEO-EO EA: –An optimum is reached, –A given total number of iterations, –A given number of gen. without improvement, –…

Implementing a Tabu Search Route route; /* One solution */ RouteInit route_init; /* Its builds random routes */ route_init (route); /* Building a random starting solution */ RouteEval full_route_eval; /* Full route evaluator */ TwoOptInit two_opt_init; /* Initializing the first couple of edges to swap */ TwoOptNext two_opt_next; /* Updating a movement */ TwoOptIncrEval two_opt_incr_eval; /* Efficiently evaluating a given neighbor */ moNoAspirCrit two_opt_aspir_crit; /* Aspiration criterion */ moSimpleMoveTabuList two_opt_tabu_list; /* Tabu List */ moGenContinue continue (10000); /* A fixed number of iter. */ /* Building the Tabu Search from those components */ moTS tabu_search (two_opt_init, two_opt_next, two_opt_incr_eval, two_opt_aspir_crit, two_opt_tabu_list, continue, full_route_eval); /* It applies the TS to the solution */ tabu_search (route);

EO & MO  Hybridizing Hybridizing allows to combine: –The exploration power of population-based metaheuristics. –The intensification power of single solution- based metaheurisitcs.

Scheme of an EA in ParadisEO-EO

ParadisEO-EO/ParadisEO-MO link

Implementation of an EA RouteInit route_init; /* Its builds random routes */ RouteEval full_route_eval; /* Full route evaluator */ eoPop pop (POP_SIZE, route_init); /* Population */ eoGenContinue continue (NUM_GEN); /* A fixed number of iterations */ OrderXover crossover; /* Recombination */ CitySwap mutation; /* Mutation */ eoStochTournamentSelect select_one; /* Stoch. Tournament selection */ eoSelectNumber select (select_one, POP_SIZE); /* Standard SGA Transformation */ eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; /* replacement */ eoEasyEA ea (continue, full_route_eval, select, transform, replace); ea (pop); /* Application on the given population */

Implementation of an EA hybridized with a hill climbing RouteInit route_init; /* Its builds random routes */ RouteEval full_route_eval; /* Full route evaluator */ eoPop pop (POP_SIZE, route_init); /* Population */ eoGenContinue continue (NUM_GEN); /* A fixed number of iterations */ OrderXover crossover; /* Recombination */ moHC mutation (two_opt_init, two_opt_next, two_opt_incr_eval, two_opt_move_select, full_route_eval); eoStochTournamentSelect select_one; /* Stoch. Tournament selection */ eoSelectNumber select (select_one, POP_SIZE); /* Standard SGA Transformation */ eoSGATransform transform (cross, CROSS_RATE, mutation, MUT_RATE); eoPlusReplacement replace; /* replacement */ eoEA ea (continue, full_route_eval, select, transform, replace); ea (pop); /* Application on the given population */

Conclusions and Perspectives (1/2) ParadisEO-EO/MO is a powerful platform to design high quality optimization methods. It can be used by beginners and experts. It can be easily extended to suit to the user needs. It can be used on Unix and Windows systems

Conclusions and Perspectives (2/2) Improving the platform: – adding generic algorithm: Variable Neighbourhood Search (VNS), Iterative Local Search (ILS), Guided Local Search (GLS), … –Adding generic boxes: Other cooling schedule, stopping criteria, … Proposing complete methods for classical problems.

Any questions ? Thank you for your attention Multi-objective metaheuristics ???  ParadisEO-MOEO. Parallel and distributed metaheuristics ???  ParadisEO-PEO. ParadisEO web site: OPAC team web site: