Motivation: Why Stochastic Local Search? Stochastic local search is - - PowerPoint PPT Presentation

motivation why stochastic local search
SMART_READER_LITE
LIVE PREVIEW

Motivation: Why Stochastic Local Search? Stochastic local search is - - PowerPoint PPT Presentation

S TOCHASTIC L OCAL S EARCH F OUNDATIONS AND A PPLICATIONS Holger H. Hoos Thomas St utzle Computer Science FB Informatik University of BC TU Darmstadt Canada Germany Hoos / St utzle Stochastic Local Search: Foundations and


slide-1
SLIDE 1

STOCHASTIC LOCAL SEARCH

FOUNDATIONS AND APPLICATIONS

Holger H. Hoos Computer Science University of BC Canada Thomas St¨ utzle FB Informatik TU Darmstadt Germany

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 1

slide-2
SLIDE 2

Motivation: Why Stochastic Local Search?

Stochastic local search is the method of choice for solving many hard combinatorial problems. Recent Progress & Successes:

  • Ability of solving hard combinatorial problems

has increased significantly – Solution of large propositional satisfiability problems – Solution of large travelling salesman problems

  • Good results in new application areas

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 2

slide-3
SLIDE 3

Reasons & Driving Forces:

  • New algorithmic ideas

– Nature inspired algorithms – New randomisation schemes – Hybrid and mixed search strategies

  • Increased flexibility and robustness
  • Improved understanding of algorithmic behaviour
  • Sophisticated data structures
  • Significantly improved hardware

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 3

slide-4
SLIDE 4

Goals of the Tutorial

Provide answers to these questions:

  • What is stochastic local search and how can it be used

to solve computationally hard problems?

  • Which stochastic local search techniques are available

and what are their features?

  • How should stochastic local search algorithms

be studied and analysed empirically?

  • How are specific problems solved using stochastic search?

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 4

slide-5
SLIDE 5

Outline

  • Introduction
  • Part I: Combinatorial Problems and Search

[ Short Break ]

  • Part II: Stochastic Local Search Methods

[ Short Break ]

  • Part III: Stochastic Search Behaviour

[ Short Break ]

  • Part IV: Applications
  • Conclusions and Issues for Future Research

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 5

slide-6
SLIDE 6

Part I Combinatorial Problems and Search

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 5b

slide-7
SLIDE 7

Combinatorial Problems

Examples for combinatorial problems:

  • finding shortest/cheapest round trips (TSP)
  • finding models of propositional formulae (SAT)
  • planning, scheduling, time-tabling
  • resource allocation
  • protein structure prediction
  • genome sequence assembly

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 6

slide-8
SLIDE 8

Combinatorial problems ...

  • involve finding a grouping, ordering, or assignment of a

discrete set of objects which satisfies certain constraints

  • arise in many domains of computer science

and various application areas

  • have high computational complexity (NP-hard)
  • are solved in practice by searching an exponentially large

space of candidate / partial solutions

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 7

slide-9
SLIDE 9

Combinatorial Decision Problems: For a given problem instance, decide whether a solution (grouping, ordering, or assignment) exists which satisfies the given constraints.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 8

slide-10
SLIDE 10

The Propositional Satisfiability Problem (SAT)

Simple SAT instance (in CNF):

(a ∨ b) ∧ (¬a ∨ ¬b)

❀ satisfiable, two models: a = true, b = false a = false, b = true

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 9

slide-11
SLIDE 11

SAT Problem – decision variant: For a given propositional formula Φ, decide whether Φ has at least one model. SAT Problem – search variant: For a given propositional formula Φ, if Φ is satisfiable, find a model, otherwise declare Φ unsatisfiable.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 10

slide-12
SLIDE 12

SAT ...

  • is a pervasive problem in computer science

(Theory, AI, Hardware, ...)

  • is computationally hard (NP-hard)
  • can encode many other combinatorial problems

(NP-completeness)

  • is one of the conceptually simplest combinatorial

decision problems ❀ facilitates development and evaluation of algorithmic ideas

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 11

slide-13
SLIDE 13

Combinatorial Optimisation Problems: Objective function assigns a numerical value to each candidate solution. For a given problem instance, find a solution (grouping, ordering,

  • r assignment) with maximal (or minimal) value of the objective

function.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 12

slide-14
SLIDE 14

The Traveling Salesperson Problem (TSP)

TSP – optimisation variant: For a given weighted graph G = (V, E, w), find a Hamiltonian cycle in G with minimal weight, i.e., find the shortest round-trip visiting each vertex exactly once. TSP – decision variant: For a given weighted graph G = (V, E, w), decide whether a Hamiltonian cycle with minimal weight ≤ b exists in G.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 13

slide-15
SLIDE 15

TSP instance: shortest round trip through 532 US cities

1000 2000 3000 4000 5000 6000 7000 1000 2000 3000 4000 5000 6000 7000 8000 9000 TSPLIB instance att532 -- optimal solution "att532-opt"

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 14

slide-16
SLIDE 16

TSP ...

  • is one of the most prominent and widely studied

combinatorial optimisation problems in computer science and operations research

  • is computationally hard (NP-hard)
  • is one of the conceptually simplest

combinatorial optimisation problems ❀ facilitates development and evaluation of algorithmic ideas

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 15

slide-17
SLIDE 17

Generalisations of combinatorial problems

  • many combinatorial decision problems naturally generalise to
  • ptimisation problems, e.g. SAT to MAX-SAT
  • many combinatorial problems have practically relevant

dynamic variants (dynamic SAT, dynamic TSP, internet routing, dynamic scheduling)

  • often, algorithms for decision problems can be generalised to
  • ptimisation and / or dynamic variants
  • typically, good solutions to generalised problems require

additional heuristics.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 16

slide-18
SLIDE 18

Complexity Issues

Motivation: Analyse inherent hardness of problems and inherent complexity

  • f algorithms.

Some basic concepts and results:

  • complexity classes: P vs. NP
  • NP-completeness, NP-hardness
  • P = NP not known
  • but: if there were an efficient (polynomial) algorithm for any

NP-complete problem, all NP problems could be solved efficiently

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 17

slide-19
SLIDE 19

Complexity of combinatorial decision problems

  • many combinatorial decision problems are NP-hard
  • this is reflected in search spaces of size

exponential in problem size

  • SAT is the classical example of an NP-complete problem
  • TSP (decision variant) is NP-complete
  • but: not all combinatorial problems with large search spaces

are hard (cf. 2-SAT / Horn-SAT, shortest path, minimal spanning tree)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 18

slide-20
SLIDE 20

Complexity of combinatorial optimisation problems

  • complexity of optimisation vs. decision variants
  • approximation algorithms
  • approximability / inapproximability

Some results for the TSP:

  • general TSP: inapproximable for arbitrary constant bounds
  • n solution quality
  • TSP with triangle inequality: polynomially approximable

to 1.5× optimal solution quality

  • Euclidean TSP: polynomial approximation schema exists

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 19

slide-21
SLIDE 21

Are computationally hard problems really intractable?

  • NP-hardness results apply to the worst case but do not imply

that all instances of a problem are hard to solve

  • approximate solutions are often useful and easier to compute
  • heuristics can often help to solve practically important

classes of instances in reasonable time

  • randomisation can help to find good solutions

reasonably efficient with high probability

  • parallelisation can help to increase size of

practically soluble instances

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 20

slide-22
SLIDE 22

Search Methods

Types of search methods: systematic ← → local search deterministic ← → stochastic sequential ← → parallel

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 21

slide-23
SLIDE 23

Local Search (LS) Algorithms

search space S (SAT: set of all complete truth assignments to propositional variables) solution set S′ ⊆ S (SAT: models of given formula) neighbourhood relation N ⊆ S × S (SAT: neighbouring variable assignments differ in the truth value of exactly one variable) evaluation function g : S → R+ (SAT: number of clauses unsatisfied under given assignment)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 22

slide-24
SLIDE 24

Local Search:

  • start from initial position
  • iteratively move from current position to neighbouring position
  • use evaluation function for guidance

Two main classes:

  • local search on partial solutions
  • local search on complete solutions

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 23

slide-25
SLIDE 25

Local Search

c s

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 23b

slide-26
SLIDE 26

Construction Heuristics

  • specific class of LS algorithms
  • search space: space of partial solutions
  • search steps: extend partial solutions, but never reduce them
  • neighbourhood typically given by individual solution elements
  • solution elements are often ranked according to a greedy

evaluation function

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 24

slide-27
SLIDE 27

Nearest Neighbour heuristic for the TSP:

  • at any city, choose the closest yet unvisited city

– choose an arbitrary initial city π(1) – at the ith step choose city π(i + 1) to be the city j that minimises d(π(i), j); j = π(k), 1 ≤ k ≤ i

  • running time: O(n2)
  • worst case performance:

NN(x)/OPT(x) ≤ 0.5(⌈log2 n⌉ + 1)

  • other construction heuristics for TSP are available

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 25

slide-28
SLIDE 28

Nearest neighbour tour through 532 US cities

1000 2000 3000 4000 5000 6000 7000 1000 2000 3000 4000 5000 6000 7000 8000 9000 NN:att532

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 26

slide-29
SLIDE 29

Construction Heuristics ...

  • can be used iteratively to solve combinatorial problems
  • provide only a limited number of different solutions
  • can be combined with back-tracking to yield systematic search

algorithms (e.g., Davis-Putnam for SAT)

  • are used within some state-of-the-art local search approaches

(e.g., Ant Colony Optimisation)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 27

slide-30
SLIDE 30

Iterative Improvement (Greedy Search):

  • initialise search at some point of search space
  • in each step, move from the current search position

to a neighbouring position with better evaluation function value

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 28

slide-31
SLIDE 31

Iterative Improvement for SAT

  • initialisation: randomly chosen, complete truth assignment
  • neighbourhood: variable assignments are neighbours iff they

differ in truth value of one variable

  • neighbourhood size: O(n) where n = number of variables
  • evaluation function: number of clauses unsatisfied under given

assignment

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 29

slide-32
SLIDE 32

Iterative Improvement for the TSP

  • initialisation: complete tour, e.g., obtained from

nearest neighbour heuristic

  • k-exchange neighbourhood: solutions which differ by

at most k edges

2-exchange

  • neighbourhood size: O(nk) where n = number of cities

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 30

slide-33
SLIDE 33

Stochastic Local Search

Typical problems with local search:

  • getting stuck in local optima
  • being misguided by evaluation/objective function

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 31

slide-34
SLIDE 34

Stochastic Local Search:

  • randomise initialisation step

– random initial solutions – randomised construction heuristics

  • randomise search steps

such that suboptimal/worsening steps are allowed ❀ improved performance & robustness

  • typically, degree of randomisation controlled by noise

parameter

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 32

slide-35
SLIDE 35

Pros:

  • for many combinatorial problems more efficient

than systematic search

  • easy to implement
  • easy to parallelise

Cons:

  • often incomplete (no guarantees for finding existing solutions)
  • highly stochastic behaviour
  • often difficult to analyse theoretically / empirically

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 33

slide-36
SLIDE 36

Simple SLS methods

Random Search (Blind Guessing): In each step, randomly select one element of the search space. (Uninformed) Random Walk: In each step, randomly select one of the neighbouring positions of the search space and move there.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 34

slide-37
SLIDE 37

Randomised Iterative Improvement:

  • initialise search at some point of search space
  • search steps:

– with probability p, move from current search position to a randomly selected neighbouring position – otherwise, move from current search position to neighbouring position with better evaluation function value

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 35

slide-38
SLIDE 38

Part II Stochastic Local Search Methods

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 35b

slide-39
SLIDE 39

Stochastic Local Search Methods – Overview

Parameterised local search extensions: – Simulated Annealing – Tabu Search Hybrid SLS strategies:

  • Iterated Local Search
  • Evolutionary Algorithms
  • Ant Colony Optimization

❀ representation as Generalised Local Search Machines (GLSMs)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 36

slide-40
SLIDE 40

Simulated Annealing

Combinatorial search technique inspired by the physical process of annealing [Kirkpatrick et al. 1983, Cerny 1985] Outline

  • generate a neighbour solution / state
  • probabilistically accept the solution / state

probability of acceptance depends on the objective function (energy function) difference and an additional parameter called temperature

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 37

slide-41
SLIDE 41

Solution generation

  • typically returns a random neighbouring solution

Acceptance criterion

  • Metropolis acceptance criterion

– better solutions are always accepted – worse solutions are accepted with probability ∼ exp g(s) − g(s′) T

  • Annealing
  • parameter T, called temperature, is slowly decreased

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 38

slide-42
SLIDE 42

Generic choices for annealing schedule

  • initial temperature T0

(example: based on statistics of evaluation function)

  • cooling schedule — how to change temperature over time

(example: geometric cooling, Tn+1 = α · Tn, n = 0, 1, . . .)

  • number of iterations at each temperature

(example: multiple of the neighbourhood size)

  • stopping criterion

(example: no improved solution found for a number of temperature values)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 39

slide-43
SLIDE 43

Example application to the TSP [Johnson & McGeoch 1997]

  • baseline implementation:

– start with random initial solution – use 2-exchange neighborhood – simple annealing schedule ❀ relatively poor performance

  • improvements:

– look-up table for acceptance probabilities – neighbourhood pruning – low-temperature starts

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 40

slide-44
SLIDE 44

Simulated Annealing ...

  • is historically important
  • is easy to implement
  • has interesting theoretical properties (convergence),

but these are of very limited practical relevance

  • achieves good performance often at the cost of

substantial run-times

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 41

slide-45
SLIDE 45

Tabu Search

Combinatorial search technique which heavily relies on the use of an explicit memory of the search process [Glover 1989, 1990]

  • systematic use of memory to guide search process
  • memory typically contains only specific attributes of

previously seen solutions

  • simple tabu search strategies exploit only short term memory
  • more complex tabu search strategies exploit long term memory

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 42

slide-46
SLIDE 46

Simple tabu search algorithm – exploiting short term memory

  • in each step, move to best neighbouring solution

although it may be worse than current one

  • to avoid cycles, tabu search tries to avoid revisiting

previously seen solutions

  • avoid storing complete solutions by basing the memory on

attributes of recently seen solutions

  • tabu solution attributes are often defined via local search moves
  • tabu list stores attributes of the tl most recently visited

solutions; parameter tl is called tabu list length or tabu tenure

  • solutions which contain tabu attributes are forbidden

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 43

slide-47
SLIDE 47
  • problem: previously unseen solutions may be tabu

❀ use of aspiration criteria to override tabu status

  • stopping criteria:

– all neighboring solutions are tabu – maximum number of iterations exceeded – number of iterations without improvement

  • appropriate choice of tabu tenure critical for performance

❀ Robust Tabu Search [Taillard 1991], Reactive Tabu Search

[Battiti & Tecchiolli 1994–1997]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 44

slide-48
SLIDE 48

Example: Tabu Search for SAT / MAX-SAT [Hansen & Jaumard 1990; Selman & Kautz 1994] Neighborhood: assignments which differ in exactly

  • ne variable instantiation

Tabu attributes: variables Tabu criterion: flipping a variable is forbidden for a given number of iterations Aspiration criterion: if flipping a tabu variable leads to a better solution, the variable’s tabu status is overridden

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 45

slide-49
SLIDE 49

Tabu search — use of long term memory Long term memory: often based on some measure of frequency, e.g., the frequency of local search moves Intensification strategies: intensify the search in specific regions

  • f the search space
  • recover elite solutions and restart search around such

solutions

  • lock some solution attributes, e.g., in the TSP, edges

contained in several elite solutions may be locked

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 46

slide-50
SLIDE 50

Diversification Strategies: drive the search towards previously unexplored search space regions

  • introduce solution attributes which are not very frequently

used, e.g., by penalizing frequently used solution attributes

  • restarting mechanisms which bias construction heuristics

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 47

slide-51
SLIDE 51

Tabu Search ...

  • performs often astonishingly well even when using only

short term memory strategies

  • can perform considerably better if additional intensification

and diversification strategies are used

  • can be enhanced with several additional strategies

(e.g., strategic oscillation, path relinking, ejection chains, . . .)

  • often achieves very good performance, but may require

time-intensive fine-tuning

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 48

slide-52
SLIDE 52

Hybrid stochastic search techniques

Note: Many of the best-performing SLS algorithms are combinations of various simple search strategies. E.g.: greedy hillclimbing + Random Walk, Ant Colony Optimisation + 3-opt, ... ❀ conceptual separation of simple search strategies and (higher-level) search control

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 49

slide-53
SLIDE 53

GLSMs – Generalised Local Search Machines

  • search control = non-deterministic finite state machine
  • simple search strategies = states
  • change of search strategy = transitions between states

State transition types:

  • deterministic: DET
  • conditional: COND(C)
  • unconditional probabilistic: PROB(p)
  • conditional probabilistic: CPROB(C,p)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 50

slide-54
SLIDE 54

The GLSM model ...

  • allows adequate and uniform represention of local search

algorithms

  • facilitates design, implementation, and analysis
  • f hybrid algorithms
  • provides the conceptual basis for some of the best known

SLS algorithms for various domains (e.g., SAT [Hoos 1999])

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 51

slide-55
SLIDE 55

GLSM representation of Randomised Best Improvement

RP BI RW

CPROB( ) C O N D ( ) C O N D ( ) P R O B ( ) P R O B ( ) CPROB( ) not R, p not R, 1−p p 1 − p R R

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 52

slide-56
SLIDE 56

Iterated Local Search (ILS)

Iterative application of local search to modifications of previously visited local minima

  • basic idea: build a chain of local minima
  • the search space is reduced to the space of local minima
  • simple, but powerful way to improve local search algorithms

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 53

slide-57
SLIDE 57

GLSM representation of Iterated Local Search

COND( ) COND( ) PS LS DET COND( ) COND( ) : t:=pos DET : t:=pos AC(t) RP LS COND( ) COND( ) not CL not CL CP CL CL not CP Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 54

slide-58
SLIDE 58

Issues for Iterated Local Search applications

  • choice of initial solution
  • choice of solution modification

— Too strong: close to random restart — Too weak: insufficient for escaping from local minima

  • choice of local search

— effectiveness versus speed

  • choice of acceptance criterion

— strength of bias towards best found solutions

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 55

slide-59
SLIDE 59

ILS for the TSP

  • local search: 2-opt, 3-opt, Lin-Kernighan, Helsgaun LK
  • solution modification: non-sequential 4-opt move

(double-bridge move)

  • acceptance criterion: apply solution modification to best

solution since start of the algorithm; other acceptance criteria may perform better for long run times Results

  • some of the best algorithms for the TSP are based on ILS

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 56

slide-60
SLIDE 60

Iterated Local Search ...

  • is based on a simple principle
  • is easy to implement (basic versions)
  • has few parameters
  • is highly effective

Related idea:

  • Variable Neighbourhood Search

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 57

slide-61
SLIDE 61

Evolutionary Algorithms

Combinatorial search technique inspired by the evolution of biological species.

  • population of individual solutions represented as strings
  • individuals within population are evaluated based on their

“fitness” (evaluation function value)

  • population is manipulated via evolutionary operators

– mutation – crossover – selection

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 58

slide-62
SLIDE 62

Several types of evolutionary algorithms:

  • Genetic algorithms [Holland 1975; Goldberg 1989]
  • Evolution strategies [Rechenberg 1973; Schwefel 1981]
  • Evolutionary Programming [Fogel et al. 1966]
  • Genetic Programming [Koza 1992]

For combinatorial optimization, genetic algorithms are the most widely used and most effective variant type

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 59

slide-63
SLIDE 63

GLSM representation of a basic Genetic Algorithm

SLC XO PI

COND(R) COND(not R)

Mut

DET DET DET

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 60

slide-64
SLIDE 64

Important issues for Evolutionary Algorithms

  • solution representation

– binary vs. problem specific representation

  • fitness evaluation of solutions

– often defined by objective function of the problem

  • crossover operator

– parent selection scheme – problem specific vs. general purpose crossover – passing of meaningful information from parents to

  • ffspring
  • mutation operator

– background operator vs. driving the search

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 61

slide-65
SLIDE 65
  • selection scheme

– prefer better solutions for survival – elitist strategies – maintenance of population diversity

  • local search

– often useful for improving performance – population based search in the space of local optima ❀ memetic algorithms

  • stopping criteria

– fixed number of generations – convergence of population

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 62

slide-66
SLIDE 66

Evolutionary Algorithms ...

  • use populations, which leads to increased search space

exploration

  • allow for a large number of different implementation choices
  • typically reach best performance when using operators that are

based on problem characteristics

  • achieve good performance on a wide range of problems

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 63

slide-67
SLIDE 67

Ant Colony Optimisation

Combinatorial search technique inspired by the foraging behaviour of real ants: [Dorigo et al. 1991, 1996]

  • population of simple agents (“ants”) communicates indirectly

via similated “pheromone trails”

  • ants follow a local stochastic policy to construct solutions
  • the solution construction is probabilistically biased by

pheromone trail information, heuristic information, and the partial solution of each ant

  • Pheromone trails are modified during the algorithm’s

execution to reflect the search experience

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 64

slide-68
SLIDE 68

GLSM representation of Ant Colony Optimization

COND( ) COND( ) : COND( ) COND( )

CI CI CS LS

DET updateTrails DET : initTrails not CL CL CC not CC

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 65

slide-69
SLIDE 69

Key ideas:

  • Define solution components for the problem to be solved
  • Ants construct solutions by iteratively adding

solution components

  • Possibly improve solutions by applying local search
  • Reinforce solution components of better solutions

more strongly

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 66

slide-70
SLIDE 70

Construction Process in Ant Colony Optimisation

i j k g τij,ηij

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 66b

slide-71
SLIDE 71

Example: ACO for the TSP – tour construction

  • Solution components are edges of given graph
  • ηij = 1/dij: Heuristic information, indicates the

utility of going from city i to city j

  • τij(t): Intensity of the pheromone trail in

iteration t on edge (i, j)

  • Probabilistic selection of the next city according to:

pij(t) ∼ (τij(t))α · (ηij)β if city j not yet visited

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 67

slide-72
SLIDE 72

Example: ACO for the TSP – Update of pheromone trails

  • Parameter 0 < ρ < 1, 1 − ρ represents pheromone evaporation
  • Update of the pheromone trails according to:

τij(t) = ρ · τij(t − 1) +

m

  • k=1

∆τ k

ij

  • ∆τ k

ij = 1/Lk if edge (i, j) is used by ant k on its tour

where Lk = tour length of ant k; m = number of ants (Several improved extensions have been proposed.)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 68

slide-73
SLIDE 73

Ant Colony Optimisation ...

  • has been successfully applied to static and dynamic

combinatorial problems

  • has shown very good performance on a range of problems

including (abstract) protein folding problems [Shmygelska & Hoos 2002–2004] New book:

  • M. Dorigo and T. St¨
  • utzle. Ant Colony Optimization. MIT Press,

2004.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 69

slide-74
SLIDE 74

Characteristics of Various SLS Methods

Feature SA TS ILS GA ACO Single trajectory + + − − − Population − − − + + Memory − + ∃ ∃ ∃ Multiple neighborhoods − − + ∃ −

  • Sol. construction

− − − − + Nature-inspired + − − + + +: feature present, ∃: partially present, −: not present

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 70

slide-75
SLIDE 75

Part III Analysing and Characterising Stochastic Search Behaviour

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 70b

slide-76
SLIDE 76

Analysing Stochastic Search Behaviour

Many SLS algorithms ...

  • perform well in practice
  • are incomplete, i.e., cannot be guaranteed to find

(optimal) solutions

  • are hard to analyse theoretically

❀ empirical methods are used to analyse and characterise SLS behaviour.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 71

slide-77
SLIDE 77

Aspects of stochastic search performance:

  • variability due to randomisation
  • robustness w.r.t. parameter settings
  • robustness across different instance types
  • scaling with problem size

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 72

slide-78
SLIDE 78

Insights into algorithmic performance...

  • help assessing suitability for applications
  • provide basis for comparing algorithms
  • characterise algorithm behaviour
  • facilitate improvements of algorithms

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 73

slide-79
SLIDE 79

RTD-based empirical methodology:

  • run algorithm multiple times on given problem instance(s)
  • estimate empirical run-time distributions (RTDs)
  • get simple descriptive statistics (mean, stddev, percentiles, ...)

from RTD data

  • approximate empirical RTDs with known distribution

functions

  • check statistical significance using goodness-of-fit test

[Hoos & St¨ utzle 1998]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 74

slide-80
SLIDE 80

Raw run-time data (each spike one run)

2 4 6 8 10 12 100 200 300 400 500 600 700 800 900 1000 CPU sec tries Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 75

slide-81
SLIDE 81

RTD graph and approximation with exponential distribution

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 100 1000 10000 100000 1e+06 P(solve) # variable flips RLD for WSAT ed[39225] Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 76

slide-82
SLIDE 82

This methodology facilitates ...

  • precise characterisations of run-time behaviour
  • prognoses for arbitrary cutoff times
  • empirical analysis of asymptotic behaviour
  • fair and accurate comparison of algorithms
  • cleanly separating different sources of randomness

(SLS algorithm / random generation of problem instances)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 77

slide-83
SLIDE 83

Asymptotic run-time behaviour of SLS algorithms

  • complete

— for each problem instance P there is a time bound tmax(P) for the time required to find a solution

  • probabilistic approximate completeness (PAC property)

— for each soluble problem instance a solution is found with probability → 1 as run-time → ∞.

  • essential incompleteness

— for some soluble problem instances, the probability for finding a solution is strictly smaller 1 for run-time → ∞.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 78

slide-84
SLIDE 84

Some results [Hoos 1999]:

  • Until recently, some of the most prominent and

best-performing SLS algorithms for SAT were essentially incomplete.

  • In practice, essential incompleteness often causes stagnation

behaviour which drastically affects the performance of the algorithm.

  • By a simple and generic modification, (Random Walk

Extension) these algorithms can be made PAC in a robust manner.

  • The algorithms thus obtained are among the best-performing

SLS algorithms for SAT known to date.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 79

slide-85
SLIDE 85

Comparative performance analysis on single problem instance:

  • measure RTDs
  • check for probabilistic domination (crossing RTDs)
  • use statistical tests to assess significance of

performance differences (e.g., Mann-Whitney U-test)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 80

slide-86
SLIDE 86

Performance comparison for ACO and ILS algorithm for TSP

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 0.1 1 10 100 1000 p(solve) run-time [CPU sec] MMAS ILS

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 81

slide-87
SLIDE 87

Comparative performance analysis for ensembles of instances:

  • check for uniformity of RTDs
  • partition ensemble according to probabilistic domination
  • analyse correlation for (reasonably stable) RTD statistics
  • use statistical tests to assess significance of

performance differences across ensemble (e.g., Wilcoxon matched pairs signed-rank test)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 82

slide-88
SLIDE 88

Peformance correlation for ACO and ILS algorithm for TSP

0.1 1 10 100 1000 0.1 1 10 100 1000 median run-time ILS [CPU sec] median run-time MMAS [CPU sec]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 83

slide-89
SLIDE 89

RTD-based analysis of randomised optimisation algorithms:

  • additionally, solution quality has to be considered
  • introduce bounds on the desired solution quality

❀ qualified RTDs

  • bounds can be chosen w.r.t. best-known or optimal solutions,

lower bounds of the optimal solution cost etc.

  • estimate run-time distributions for several bounds on the

solution quality

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 84

slide-90
SLIDE 90

Qualified RTDs for TSP instance att532 with ILS

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1 10 100 1000 solution probability CPU time Run-time distributions for iterated 3-opt on att532.tsp "1%" "0.5%" "0.25%" "0.1%" "opt" ed1 ed2

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 85

slide-91
SLIDE 91

SQD-based methodology:

  • run algorithm multiple times on given problem instance(s)
  • estimate empirical solution quality distributions (SQDs) for

different run-times

  • get simple descriptive statistics (mean, stddev, percentiles, ...)

from SQD data

  • approximate empirical SQD with known distribution functions
  • check statistical significance using goodness-of-fit test

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 86

slide-92
SLIDE 92

SQD analysis for Graph Partitioning (GP)

B A

[Martin et al. 1999] studied best performing SLS algorithms for GP

  • n ensemble of randomly generated graphs.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 87

slide-93
SLIDE 93

Results:

  • SQD distributions approach a limiting Gaussian shape,

both for individual graphs and across ensembles.

  • For increasing instance size SQD distributions become

increasingly peaked. ❀ solution quality becomes dominating factor when comparing SLS algorithms on large instances.

  • Similar results also for the TSP.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 88

slide-94
SLIDE 94

Using SQDs for estimating optimum solution qualities Consider sample of k feasible solutions and let x be the extreme value from the sample. ❀ for large k, the distribution of x approaches a Weibull distribution with position parameter µ, where µ is optimal solution quality [Dannenbring 1977] Estimation procedure:

  • generate m independent samples of x
  • estimate parameters of Weibull distribution
  • obtain confidence interval for optimum value

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 89

slide-95
SLIDE 95

Search Space Analysis

Intuition:

  • SLS algorithm moves in a search landscape induced by

the given problem instance and aspects of algorithm

  • search landscape can be imagined as a mountainous

region with peaks, basins, valleys, saddles, ...

  • goal of search process is to find lowest point in this landscape

(for minimization problems) ❀ connection between SLS behaviour and landscape structure

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 90

slide-96
SLIDE 96

Search landscape is defined by:

  • the set of all possible solutions (search space)
  • an evaluation function that assigns to every solution a solution

quality value

  • a neighbourhood relation, which induces a distance measure

between solutions

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 91

slide-97
SLIDE 97

Distance between solutions:

  • defined as the minimum number of search steps needed

to reach one solution from the other

  • often surrogate distance metrics are used

(e.g., for the TSP, distance between tours measured by number of edges contained in one tour, but not the other)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 92

slide-98
SLIDE 98

Important aspects of search landscapes:

  • number of local optima
  • ruggedness
  • distribution of local minima and their relative location to the

global minima

  • size, topology, and location of plateaus and basins
  • connections between plateaus and basins

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 93

slide-99
SLIDE 99

Two widely used types of search space analysis:

  • analysis of search space ruggedness
  • analysis of (linear) correlation between solution fitness and

distance to global optima (fitness-distance correlation) e.g., [Boese 1994, 1996; Jones & Forrest 1995]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 94

slide-100
SLIDE 100

Measures for landscape ruggedness:

  • autocorrelation function [Weinberger 1990; Stadler 1995]
  • correlation length [Stadler 1995]
  • autocorrelation coefficient [Angel & Zissimopoulos 1998,

1999]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 95

slide-101
SLIDE 101

Measure for fitness-distance correlation:

  • correlation coefficient

ρ(F, D) = Cov(F, D)

  • Var(F) ·
  • Var(D)
  • graphical visualization through plots of fitness–distance

relationship

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 96

slide-102
SLIDE 102

Fitness–distance relationship in TSP instance rat783

8950 9000 9050 9100 9150 9200 9250 140 150 160 170 180 190 200 210 220 230 240 "opt-dist.rat783-ls" using 2:1

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 97

slide-103
SLIDE 103

Some results for the TSP:

instance ∆avg avgd−opt avgd−opt/n ρls lin318.tsp 3.56 67.25 0.211 0.469 rat783.tsp 4.85 204.24 0.261 0.624 pcb1173.tsp 5.91 274.34 0.234 0.585 pr2392.tsp 5.71 552.49 0.231 0.538 ∆avg: Percentage deviation from optimum avgd−opt: Average distance from optimum ρls: Correlation coefficient

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 98

slide-104
SLIDE 104

Advanced Search Space Analysis

  • Idea: collapse states on the same plateau or in the same basin

into “macro states” and illustrate connections between these regions ❀ Plateau Connection Graphs (PCG), Basin Partition Trees (BPT)

  • Analysing PCG or BPT properties and structure can give

deeper insights into SLS behaviour and problem hardness than global measures, such as FDC or ACC.

  • But: PCG and BPT analysis is computationally expensive and

requires enumeration of large parts of the search space.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 99

slide-105
SLIDE 105

(Partial) Plateau Connection Graph for hard random 3-SAT instance

8.1 7.1 6.1 5.1

0.27 0.65 0.25 0.69 0.06 0.07 0.40 0.76 0.39 0.08 0.18 0.55 0.22 0.78 0.17 0.74 0.19 0.07 0.28 0.05

.91

0.84 1 1 0.07 0.06 0.43 1.8 1 1 0.11 0.29 1 1 1

4.1 2.4 2.1 2.3 2.8 1.2 1.3 2.5 2.6 2.7 4.2 1.1 2.2 0.1 3.3 3.4 3.1 3.2 3.6 3.5

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 100

slide-106
SLIDE 106

(Partial) Plateau Connection Graph for easy random 3-SAT instance

9.1 8.1 7.1 6.1 5.1

0.09 0.60 0.28 0.63 0.66 0.68 0.07 0.25 0.06 0.74 0.22 0.79 0.2 0.91 0.4 0.35 1 1 1 1 0.2 0.5 0.5 0.25 0.08 0.28

4.1 4.2 3.2 3.4 3.3 2.1 1.2 1.3 3.1 2.3 2.2 1.1 1.4 0.1

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 100b

slide-107
SLIDE 107

Paramaterisation and Tuning

  • performance of stochastic search algorithms depends

very strongly on appropriate parameterisation and tuning

  • tuning can be very time-intensive
  • limited understanding of how performance depends on

parameter settings

  • many stochastic search algorithms leave

important implementation choices to the user

  • experience with stochastic search algorithms is required

to obtain best performance

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 101

slide-108
SLIDE 108

Difficulties with parameterisation

  • SLS algorithms are often highly stochastic

❀ empirical analysis more difficult

  • algorithm parameters are not independent
  • seemingly small implementation choices can have significant

effects on algorithm behaviour and performance Possible remedies

  • use of adequate empirical methodology (statistical techniques)

for analysing behaviour

  • automatic parameter adjustment during search

❀ reactive search

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 102

slide-109
SLIDE 109

Parallelising Stochastic Search

  • randomised algorithms allow extremely easy and scalable

parallelisation: multiple independent tries

  • effectiveness depends on run-time behaviour of underlying

algorithms

  • under certain conditions, optimal speedup can be obtained

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 103

slide-110
SLIDE 110

Analysis of the distribution type of RTDs for various well-performing SLS algorithms for a number of problem classes ❀ Result [Hoos & St¨ utzle 1998]: For optimal parameterisations and applied to hard problem instances, many state-of-the-art SLS algorithms show exponential run-time distributions (EPAC property).

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 104

slide-111
SLIDE 111

Goodness of fit for hard Random-3-SAT instances

100 200 300 400 500 600 100 1000 10000 100000 0.05 acceptance 0.01 acceptance Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 105

slide-112
SLIDE 112

EPAC property implies:

  • search is “memory-less”

❀ “random restart” is ineffective

  • optimal speedup can be achieved through

“multiple independent tries” parallelisation (very easy to implement, almost no communication overhead, arbitrarily scalable)

  • interpretation of SLS behaviour as “random picking”

from “virtual search space” (whose size can be computed from RTD data)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 106

slide-113
SLIDE 113

Simulated Annealing – course-grained parallelisation: independent parallel runs – fine-grained parallelisation: parallel evaluation of moves Tabu Search – exponential run-time distributions (QAP) – cooperative approaches [Crainic et al.] ACO algorithms – course-grained parallelisation more successful than fine-grained Evolutionary Algorithms – fine-grained and coarse-grained parallel implementations

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 107

slide-114
SLIDE 114

Part IV Applications

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 107b

slide-115
SLIDE 115

Applications of Stochastic Search

Some recent successful applications:

  • SAT [e.g., Selman et al. 1992–1997; Hoos et. al. 1994–2004]
  • MAX-SAT [e.g., Hansen and Jaumard 1990; Hoos et al. 2003-2004]
  • TSP [e.g., Johnson & McGeoch 1997–2002; St¨

utzle & Hoos 1997–2004]

  • Scheduling [e.g., Congram et al. 2002, den Besten, St¨

utzle, Dorigo 2001]

  • Time-Tabling [e.g., Rossi-Doria et al. 2003; Chiarandini et al. 2003]
  • Protein Folding (HP model) [e.g., Shmygelska, Hoos,

Aguirre-Hernandez 2002–2004]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 108

slide-116
SLIDE 116

Propositional Satisfiability (SAT)

Progress in SAT solving: classic SAT solvers: based on ‘Davis-Putnam’ algorithm (systematic search based on back-tracking) 1990–1992: successful application of SLS algorithms for solving hard SAT instances [Selman et al.; Gu] 1993–1994: new, hybrid SLS strategies with improved performance and robustness [Selman et al.; Gent & Walsh] 1996–1997: improvements in SLS algorithms [McAllester et al.]; randomised systematic search methods [Gomes et al.]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 109

slide-117
SLIDE 117

1998–2000: further improvements in SLS algorithms, based on GLSM model [Hoos & St¨ utzle] 2001–2004: high-performance dynamic local search algorithms [Schuurmans et al., Hoos et al.], self-tuning /adaptive WalkSAT [Kautz et al., Hoos]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 110

slide-118
SLIDE 118

SLS algorithms for SAT

  • search space: set of all complete variable assignments
  • solutions: models of the given formula
  • two assignments are neighbours if they differ in the value
  • f exactly one variable
  • evaluation function is the number of clauses unsatisfied

under a given assignment

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 111

slide-119
SLIDE 119
  • search initialisation: randomly chosen assignment
  • search steps: algorithm dependent, use random choices

and/or tie-breaking rules

  • most algorithms use random restart if no solution has

been found after a fixed number of search steps

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 112

slide-120
SLIDE 120

The GSAT Algorithm [Selman, Mitchell, Levesque 1992]

  • in each search step, flip the variable which gives

the maximal increase (or minimal decrease) in the number of unsatisfied claused

  • ties are broken randomly
  • if no model found after maxSteps steps, restart from

randomly chosen assignment

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 113

slide-121
SLIDE 121

The GWSAT Algorithm [Selman, Kautz, Cohen 1994]

  • search initialisation: randomly chosen assignment
  • Random Walk step: randomly choose and flip a variable
  • ccurring in a currently unsatisfied clause
  • GWSAT steps: choose probabilistically between a GSAT step

and a Random Walk step with ‘walk probability’ (noise) wp

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 114

slide-122
SLIDE 122

The WalkSAT algorithm family [McAllester et al. 1997]

  • search initialisation: randomly chosen assignment
  • search steps:
  • 1. randomly select a currently unsatisfied clause
  • 2. select a literal from this clause according to a heuristic h
  • if no model found after maxSteps steps, restart from randomly

chosen assignment

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 115

slide-123
SLIDE 123

Some WalkSAT algorithms SKC: Select variable such that minimal number of currently satisfied clauses become unsatisfied by flipping; if ‘zero-damage’ possible, always go for it; otherwise, with probability wp variable is randomly selected Tabu: Select variable that maximises increase in total number

  • f satisfied clauses when flipped; use constant length tabu-list

for flipped variables and random tie-breaking

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 116

slide-124
SLIDE 124

Novelty: Order variables according to increase in total number

  • f satisfied clauses when flipped; if best variable in

this ordering is not most recently flipped, always go for it;

  • therwise, select second-best with probability wp

R-Rovelty: Similar to Novelty, but more complex decision between the variable with best and second-best score

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 117

slide-125
SLIDE 125

Some properties of these algorithms [Hoos & St¨ utzle 1998-1999; Hoos 1999]:

  • SKC, Tabu, Novelty, and R-Novelty: exponential run-time

distributions when applied to hard SAT instances and using

  • ptimal (or greater-than-optimal) noise settings

❀ optimal parallelisation

  • Tabu, Novelty, and R-Novelty: essentially incomplete,

i.e., can get stuck in non-solution areas of search space

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 118

slide-126
SLIDE 126

Novelty+ and R-Novelty+ [Hoos 1998]:

  • extend Novelty, R-Novelty with (unconditional) Random Walk

— simple generic modification of the corresponding GLSM

  • resulting algorithms are probabilistically approximately

complete

  • significantly improved performance & robustness

These algorithms are amongst the best-performing SLS algorithms for SAT known today. (A self-tuning variant of Novelty+ won the random instance category of the SAT Solver Competition 2004!)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 119

slide-127
SLIDE 127

GLSM representations of Novelty vs. Novelty+

Tr

DET

RI Nov

Tn

RW

Tr Tr T Tw

w

RI Nov

Tn Tn

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 120

slide-128
SLIDE 128

Essential Incompleteness vs. PAC behaviour

  • f Novelty vs. Novelty+

0.2 0.4 0.6 0.8 1 1 10 100 1000 10000 100000 1e+006 P(sat) run-time [# search steps] Novelty+(0.7,0.01) Novelty(0.7)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 121

slide-129
SLIDE 129

Some other stochastic search approaches for SAT:

  • simulated annealing [Spears 1993; Beringer et al. 1994]
  • genetic algorithms [Frank 1994]
  • GRASP [Feo & Resende 1996]
  • simple learning strategies for SLS [Selman & Kautz 1993;

Frank 1997; Boyan & Moore 1998]

  • Discrete Lagrangian Methods [Wah et al. 1997–2000]
  • SDF, ESG [Schuurmans et al. 2000–2001]
  • SAPS, RSAPS [Hoos et al. 2002–2003]
  • Satz-Rand, REL SAT-Rand [Gomes et al. 1998]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 122

slide-130
SLIDE 130

Maximum Satisfiability (MAX-SAT)

  • Generalisation of SAT for CNF formulae
  • Prototypical NP-hard combinatorial optimisation problem
  • Widely studied in algorithmics, artificial intelligence,

computational theory, operations research

  • conceptually simple

❀ facilitates development and analysis of general algorithmic techniques for combinatorial problem solving

  • close relationship with SAT facilitates study of differences in

the structure of typical decision and optimisation problems

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 123

slide-131
SLIDE 131

Example: A Simple MAX-SAT Instance F := (¬x1) ∧ (¬x2 ∨ x1) ∧ (¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x1 ∨ x2) ∧ (¬x4 ∨ x3) ∧ (¬x5 ∨ x3)

  • minimum number of unsatisfied clauses? 1

(e.g., x1 := x2 := x3 := x4 := x5 := ⊥)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 124

slide-132
SLIDE 132

Example: A Simple Weighted MAX-SAT Instance F := (¬x1) w = 2 ∧ (¬x2 ∨ x1) w = 1 ∧ (¬x1 ∨ ¬x2 ∨ ¬x3) w = 7 ∧ (x1 ∨ x2) w = 3 ∧ (¬x4 ∨ x3) w = 7 ∧ (¬x5 ∨ x3) w = 7

  • minimum total weight of unsatisfied clauses? 1

(e.g., x1 := ⊥, x2 := x3 := x4 := x5 := ⊤)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 125

slide-133
SLIDE 133

Unweighted MAX-SAT: Given: Propositional formula F in conjunctive normal form (CNF) Goal: Find truth assignment a∗ that minimises the number of unsatisfied clauses in F, i.e., a∗ ∈ argmina∈Assign(F) #CU(F, a), where CU(F, a) := set of unsatisfied clauses in F under a.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 126

slide-134
SLIDE 134

Weighted MAX-SAT: Given: Propositional formula F in conjunctive normal form (CNF), weights w(c) for each clause c in F Goal: Find truth assignment a∗ that minimises the total weight

  • f unsatisfied clauses in F, i.e.,

a∗ ∈ argmina∈Assign(F)

  • c∈CU(F,a) w(c),

where CU(F, a) := set of unsatisfied clauses in F under a.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 127

slide-135
SLIDE 135

Note: instances of other combinatorial problems can be encoded into and solved as MAX-SAT, e.g.:

  • (Weighted) Set Covering
  • Most Probable Explanation Finding in Bayes Nets
  • Spin Glass Ground State Determination

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 128

slide-136
SLIDE 136

State-of-the-art SLS algorithms for MAX-SAT fall into three categories:

  • WalkSAT algorithms (Novelty+/wcs+we)
  • Iterated local search algorithms (IRoTS)
  • Dynamic local search algorithms (GLSSAT, SAPS)

SLS algorithms for MAX-SAT also play a major role as components in high-performance branch & bound algorithms for MAX-SAT [Alsinet et al., 2003]

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 129

slide-137
SLIDE 137

Weighted WalkSAT / Novelty+ [Hoos, Smyth, St¨ utzle, 2003]: weighted evaluation (we): Evaluate variable flips using

  • c∈CU w(c) instead of

c∈CU 1 = #CU

weighted clause selection (wcs): Select unsatisfied clauses with probability proportional to their weight (roulette wheel selection) ❀ Three weighted variants of each WalkSAT algorithms: wcs, we, wcs+we

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 130

slide-138
SLIDE 138

Performance of Novelty+/wcs+we on Structured Instances

Test-set GLSSAT2 Novelty+/wcs+we t = 0.1s t = 1s t = 10s t = 0.1s t = 1s t = 10s scp4 1.33 0.02 0.01 0.02 0.01 0.00 gcp-yi 11.24 0.22 0.15 0.12 0.05 0.01 lgcmp75 8.1 · 106 49.3 0.20 3.27 0.09 0.00 lgcmp100 1.1 · 106 248.82 0.25 10.02 1.39 0.51

Performance measure = median relative solution quality for fixed cut-off times

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 131

slide-139
SLIDE 139

Novelty+/wcs+we vs. GLSSAT: Solution Quality Over Time

1 10 100 1000 0.1 1 10 100

  • emp. approximation ratio

run-time [CPU sec] Novelty+/wcs+we GLSSAT2

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 132

slide-140
SLIDE 140

Note:

  • Different algorithms define state-of-the-art for various types of

MAX-SAT instances

  • Some types of MAX-SAT instances are solved very well by

straightforward generalisations of high-performance, others require different SLS methods.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 133

slide-141
SLIDE 141

Scheduling

Scheduling: allocation of limited resources to tasks over time Resources: examples are machines in a workshop, runways at airport, . . . Tasks: examples are operations in a production process, take-offs and landings at an airport, . . . Objectives: usually depending on the tasks completion time, shipping dates to be met, . . .

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 134

slide-142
SLIDE 142

Airport example Resources: runways available for starts and landings Tasks: a number of flights with

  • processing times
  • time windows for allowable take-off and landing times
  • minimium time distance between successive take-offs and

landings

  • weight indicating importance

Objectives: minimize the total weighted delay over all flights

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 135

slide-143
SLIDE 143

The Single Machine Total Weighted Tardiness Problem Often, a single machine is the bottleneck in production environment. Given (for each job):

  • due date dj
  • weight (importance) wj
  • processing time pj

Objective: minimise sum of weighted tardiness (tardiness = surtime a job is completed after its due date) The SMTWTP is NP-hard.

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 136

slide-144
SLIDE 144

Local search algorithms for SMTWTP

  • initialisation:

several con- struction heuristics available

  • search space: all possible task

sequences

  • neighbourhoods:

transpose, exchange, insert

A B C D E F A C B D E F φ φ' A B C D E F A E C D B F φ transpose neighbourhood φ' A B C D E F A C D B E F φ exchange neighbourhood insert neighbourhood φ'

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 137

slide-145
SLIDE 145

Variable Neighbourhood Search Observation: local optimum w.r.t. one neighbourhood need not be a local optimum for another neighbourhood relation Idea: systematically change neighbourhood during local search process [Mladenovic & Hansen 1995–2003] Tests: effectiveness of concatenating interchange and insert neighbourhood with different construction heuristics Instances: 125 randomly generated benchmark instances with 100 jobs; results are averaged over the benchmark instances

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 138

slide-146
SLIDE 146

constr. no local search interchange insert heuristic ∆avg nopt tavg ∆avg nopt tavg ∆avg nopt tavg EDD 135 24 0.001 0.62 33 0.140 1.19 38 0.64 MDD 61 24 0.002 0.65 38 0.078 1.31 36 0.77 AU 21 21 0.008 0.92 28 0.040 0.56 42 0.26 constr. interchange+insert insert+interchange heuristic ∆avg nopt tavg ∆avg nopt tavg EDD 0.24 46 0.20 0.47 48 0.67 MDD 0.40 46 0.14 0.44 42 0.79 AU 0.59 46 0.10 0.21 49 0.27 ∆avg: avg. deviation from best known, nopt: # of best known candidate solutions found tavg: avg. computation in seconds on Pentium II 266MHz

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 139

slide-147
SLIDE 147

Results:

  • concatenated local search significantly more effective
  • final solution quality depends strongly on

initial candidate solution

  • other local search extension:

Dynasearch [Congram, Potts, van de Velde 2002]

  • further improvements can be achieved by using

hybrid SLS methods, e.g. ILS algorithms

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 140

slide-148
SLIDE 148

ILS for SMTWTP

  • local search: several possibilities examined, best results with

interchange+insert

  • perturbation: variable number of

random left-insert moves

  • acceptance criterion: Apply candidate solution modification to

best candidate solution since start of the algorithm

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 141

slide-149
SLIDE 149

Summary results for ILS

  • finds best-known candidate solutions on all known benchmark

instances in reasonable time (few CPU seconds up to some minutes)

  • reasons for good performance were identified by

search space analysis (FDC)

  • most other high-performance algorithms for SMTWTP are

ILS-based (Iterated Dynasearch)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 142

slide-150
SLIDE 150

Timetabling

Timetabling concerns the placement of a set of events to time slots and resources.

  • highly application-relevant research area
  • many research efforts (PATAT conference series, . . .)
  • wide class of resource allocation problems

– employee timetabling, academic timetabling, transportation timetables (railways, buses), . . .

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 143

slide-151
SLIDE 151

Academic timetabling

  • classes of problems

– school timetabling – course timetabling – examination timetabling

  • wide variety of models and constraints
  • SLS based approaches are becoming

increasingly important

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 144

slide-152
SLIDE 152

Example: A course timetabling problem

  • problem

– given is a set of events visited by a set of students – goal: assign events to time-slots and rooms subject to hard constraints and optimisation criteria

  • hard constraints

– no student attends more than one event at the same time – room is big enough and satisfies all features required by the event – at any time-slot, there is at most one event in a room

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 145

slide-153
SLIDE 153
  • optimisation criteria defined by soft constraints

– student should not have an event in last slot of a day – student should not have more than two events in a row – student should have only a single class per day

  • soft constraint violations are penalised
  • optimisation objective:

– find a feasible solution with minimum number of soft constraint violations

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 146

slide-154
SLIDE 154
  • models real-world problem at Napier University, Edinburgh
  • was tackled in the Metaheuristics Network
  • was part of the International Timetabling Competition
  • various SLS methods tested on this problem

– Ant Colony Optimisation – Iterated Local Search – Simulated Annealing – Tabu Search – Evolutionary Algorithms

  • all SLS methods were implemented by the expert labs and

extensively tested on a set of benchmark instances

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 147

slide-155
SLIDE 155
  • implementations were done in two phases
  • first phase

– all labs were given the same local search procedure – all labs were given one month of development time – then all algorithms had to be submitted and were evaluated

  • experimental tests run across various instance sizes
  • the computational results were extensively analysed with

non-parametric statistical tests

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 148

slide-156
SLIDE 156

small size instance

100 events, 80 students, 5 rooms, 5 features; 500 trials run per instance

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 149

slide-157
SLIDE 157

medium size instance

400 events, 200 students, 10 rooms, 5 features; 50 trials run per instance

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 150

slide-158
SLIDE 158

large size instance

400 events, 400 students, 10 rooms, 10 features; 20 trials run per instance

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 151

slide-159
SLIDE 159
  • main observations

– SA very good for optimising soft constraint violations but poor for hard constraints – tabu search based approaches good for solving hard constraints but poor for soft constraints

  • new SLS algorithm developed based on results of first phase

– various SLS techniques (TS, SA, VNS) in dependence of problem solving stage (hard, soft constraints, etc.) – configuration of hybrid technique using semi-automatic statistical procedures

  • this new SLS algorithm was the (unofficial) winner of the

International Timetabling Competition!

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 152

slide-160
SLIDE 160

Conclusions and Future Research

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 152b

slide-161
SLIDE 161

Conclusions

  • Stochastic search is one of the most efficient approaches

for solving combinatorial problems in practice

  • Studying stochastic search algorithms for conceptually simple

domains, such as SAT or TSP, facilitates development, analysis, and understanding of algorithms

  • Advanced empirical methodology helps to characterise

and exploit stochastic search behaviour based on computational experiments

  • Lots of potential application areas, lots of interesting

research questions

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 153

slide-162
SLIDE 162

Future Work

  • further advance understanding of stochastic search behaviour

(❀ search space analysis, new theoretical & empirical results)

  • further improvements in stochastic search algorithms

(❀ hybrid algorithms, adaptive algorithms)

  • application to real-world problems

(e.g., intelligent systems, e-commerce, bioinformatics; dynamic, stochastic, multi-objective problems)

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 154

slide-163
SLIDE 163

Take-Home Message:

  • Stochastic search is one of the most successful

and most widely used methods for solving combinatorial problems (but certainly no panacea)

  • Many open problems, significant research

and practical potential

  • SLS research is fun!

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 155

slide-164
SLIDE 164

Want to learn more about Stochastic Local Search?

  • New book:

Holger H. Hoos & Thomas St¨ utzle: Stochastic Local Search: Foundations and Applications Morgan Kaufmann Publishers, Summer 2004.

  • New website:

www.stochastic-local-search.net

Hoos / St¨ utzle Stochastic Local Search: Foundations and Applications (MA2) 156