optimisation strategies for modelling and simulation …

47
OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION Jean LOUCHET Evol'Tech, Paris and INRIA, Complex team, Rocquencourt (France) [email protected] ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 1 / 47

Upload: others

Post on 04-May-2022

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

OPTIMISATION STRATEGIES FOR MODELLING ANDSIMULATION

Jean LOUCHETEvol'Tech, Paris

andINRIA, Complex team, Rocquencourt (France)

[email protected]

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 1 / 47

Page 2: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION

1 Introduction: exploring parameter spaces using Evolutionary Programming3

2 Retrieving patterns: revisiting the Hough Transform 11Evolutionarising the Hough transform 16Generalised Houghvolution 20

3 Parisian Evolution - how to split optimisation: the Fly algorithm 22An application to mobile robotics 26An application to medical imaging 32

4 From phenomena to processes: identifying hidden internal parameters36

5 Conclusion 42

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 2 / 47

Page 3: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

1 Introduction: exploring parameter spaces using EvolutionaryProgramming

Parallel operators looking for a global maximum

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 3 / 47

Page 4: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

calculationfitness

selection

genetic operators

mutationcrossover

sharing

labelled population

...

new population

...

random process

heavy calculation load creationinitial

One possible general scheme for evolutionary algorithms

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 4 / 47

Page 5: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

DARWIN

• the fittest survive longer • heredity

Coding - genotype and phenotype

Fitness function

f itness F : E → R: search space; : real numbersE R

x = Argmax (f ) ⇔ [x′ ≠ x ⇒ f (x′) < f (x)]

Create and evolve a population (subset) in the search space, following nature's lawsMultiple local maximaOther approachesCost function vs. fitness functionSharing?

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 5 / 47

Page 6: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Genetic operators:

• selection

• ranking• roulette• tournament

• mutation• crossover

• exchange segments• barycentric (ES only!)

• sharing• refinements:

• mating preferences• niching• co-evolution• diploids, sexual, dominant/recessive genes, etc.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 6 / 47

Page 7: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

A useless example of crossover.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 7 / 47

Page 8: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Hans-Paul Schwefel (“Evolutionsstrategie”)

Real numbers - an engineering culture?

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 8 / 47

Page 9: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Riccardo Poli, David Goldberg (“Genetic algorithms”)

Booleans - a computing culture?

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 9 / 47

Page 10: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Other pioneers of Artificial Evolution: Wolfgang Banzhaf, William Langdon, MichèleSebag.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 10 / 47

Page 11: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

2 Retrieving patterns: revisiting the Hough Transform

y = ax + b

In the co-ordinate system , the set of lines containing a given pixel is a straight line,the equation of which is:

(a, b) (x, y)

b = (−x) a + yThe original image co-ordinate system is often called theplane, and the co-ordinatesystem the dual plane.

(x, y) (a, b)

WHAT ABOUT ISOTROPY?

a good equation is:

ρ = x cosθ + y sinθ

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 11 / 47

Page 12: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Algorithm:______________________________________________________________Initialise array H (θ, ρ) = 0For each pixel (x, y)

if pixel meets criteria (value, contrast, etc.) thenfor each : θ ∈ [0,2π] H (θ, x cosθ + y sinθ) + = 1

// Each "interesting pixel'' creates an arch of a sinusoid in the Hough accumulation space.

(θ, ρ) = Argmax H

// gives the equation of the most important alignment._______________________________________________________________

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 12 / 47

Page 13: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Archaeological data: map of Palaeolithic monuments in South-West England (PeterBrough)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 13 / 47

Page 14: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

The Hough accumulator

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 14 / 47

Page 15: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Alignments detected

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 15 / 47

Page 16: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Evolutionarising the Hough transform

Idea: directly explore the parameter space rather than using it as an accumulator

Algorithm:__________________________________________________________________Create a population of individuals with chromosomes (θ, ρ)Randomly initialise population, with and θ ∈ [0, 2π] ρ ≤ ρmax

Launch a standard Evolution Strategy with the following fitness function:

Fitness(θ, ρ) = number of pixels meeting the criteria on the corresponding li ne.Mutation: GaussianCrossover: barycentricNo sharingSelection: tournament

Refinement: poll-based fast fitness function //non-deterministic fitness function__________________________________________________________________

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 16 / 47

Page 17: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Detecting alignments the classical way: Mr Cheng

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 17 / 47

Page 18: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Hough transform of the Cheng image.(θ, ρ)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 18 / 47

Page 19: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Evolutionary Hough: The two dominant individuals in the population.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 19 / 47

Page 20: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Generalised Houghvolution

The original Hough approach cannot cope with more than 2 (sometimes 3 ..) parametersEvolutionary Hough can directly explore virtually any search space to find a pattern.Algorithm:Image I (x, y)Pattern defined by parameters :n (x1, x2, ...xn)

P((x, y) (x1, x2, ...xn)) ∈ {0,1}__________________________________________________________________Create a population of individuals with chromosomes (x1, x2, ...xn)Randomly initialise population, with each xi ∈ [Li, U i]Launch a standard Evolution Strategy with the following fitness function:

Fitness(x1, x2, ...xn) = number of pixels (x, y) such that

P((x, y) (x1, x2, ...xn)) = 1Mutation: GaussianCrossover: barycentricNo sharingSelection: tournament__________________________________________________________________ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 20 / 47

Page 21: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Dynamic 3-D ball tracking (apparent diameter is unknown) using the Louchoughtransform

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 21 / 47

Page 22: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

3 Parisian Evolution - how to split optimisation: the Fly algorithm

Left camera

Right camera

A

Bb

1

a

1

b

2

a

2

.

.

..

Bad fly A and good fly B

The fitness function evaluates the degree of consistency of the fly (the hypothesis) with thedifferent sensor data (here the similarity of their projections into the two cameras),

G = ∑(i ,j) ∈N

(L (xL + i , yL + j) − L (xL, yL))2

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 22 / 47

Page 23: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

z-axis (depth)

clipping line

cameraleft

truncated vision cone

x-axis

cameraright

The initial fly population inside the intersection of the camera fields of view.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 23 / 47

Page 24: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

A (synthetic) stereo pair

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 24 / 47

Page 25: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Convergence after 10 , 50 and 100 generations(flies seen from above).

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 25 / 47

Page 26: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

An application to mobile robotics

Flies calculated in real-time on a French highway

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 26 / 47

Page 27: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Flies detected on a pedestrian.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 27 / 47

Page 28: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Alarm values (pedestrian sequence)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 28 / 47

Page 29: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

A robot facing a door and a wall (in a synthetic world). The bright dots represent theflies memorised from the preceding positions.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 29 / 47

Page 30: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

A direct trajectory, without blockage situations (target is a circle on the right).

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 30 / 47

Page 31: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

An example of secondary targets after a difficult blockage.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 31 / 47

Page 32: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

An application to medical imaging

searchzone

air

exterior

cristalTomography sensor system

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 32 / 47

Page 33: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Bonus fitness

each fly is a photon emittereach time one of the simulated photons from the current fly lands onto a bright pixel inthe (real) image, increment the fly's fitness

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 33 / 47

Page 34: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Marginal evaluation

Rather than evaluating a fly independently of its context, we introduce marginal evaluation:the fitness of a particulat fly is defined as its contribution (positive or negative) to the wholepopulation's Fitness:

f itness(i) = Fitness(population − {i}) − Fitness(population)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 34 / 47

Page 35: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Comparison of bonus fitness and marginal fitness

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 35 / 47

Page 36: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

8 original images (projections into 8 photon detector screens)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 36 / 47

Page 37: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

3-D reconstruction using Flies: skeleton reconstructed from 2 views (without takinginto account the Compton effect).

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 37 / 47

Page 38: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Two slices of the pelvis, reconstructed from the side views using the Fly algorithm(view from above).

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 38 / 47

Page 39: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

4 From phenomena to processes: identifying hidden internal parameters

Mass and spring models[CORDIS-ANIMA system, Acroe Grenoble - C. Cadoz, J.L. Florens, A. Luciani]Creating physical models in discrete time.

M- and L- elements:

• M-element (mass):

• input: force (f x, f y, f z)• output: position , speed (x, y, z) (x•, y

•, z

•)• parameter: mass m

• laws: , etc.; , etc.x• ← x

•+ f x / m x ← x + x

• L-element (bond):

• input: distance , elongation speed d d•

• output: force value f• parameters: length at rest , stiffness , viscosity , other parameters if requiredL0 S V

• each instance of an L-element connects two M-elements

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 39 / 47

Page 40: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Reverse engineering mass and spring models

C = ∑time

∑particles

((xpredt,i − xreal t,i)2 + (ypredt,i − yreal t,i)2 + (zpredt,i − zreal t,i)2)

To be stabilised...:

• locality and short-term cost/fitness function• one global and many local fitness functions• use generic bonds (prototype)• hybridise with local search (not too much!)

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 40 / 47

Page 41: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Evolution of Log(precision), for different noise levels on trajectories.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 41 / 47

Page 42: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

A piece of fabric falling into equilibrium (left: original sequence)ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 42 / 47

Page 43: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

Simulated turbulent interference of a jet with a viscous fluid(frames nos. 100, 200, 300, 400 from a simulated sequence)

Viscosity parameters recovery

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 43 / 47

Page 44: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

(x 10)

12.0 13.0 14.0 15.0 16.0 17.01.20

1.30

1.40

1.50

1.60

1.70

1.80

(x 100)

Detection of necrosis on a human heart from MR image sequencesusing mass and spring model identification.

Linear springs and dampers - high stiffness values on necrotic places.

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 44 / 47

Page 45: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

5 Conclusion

• Optimise to fit a model to experiments• ES allow search into large, high-dimensional parameter spaces• GP builds logical rules (production rules)• Split problems as much as necessary• No universal evolutionary scheme: don't rely on `canonic' algorithms• Adequate coding is essential - (epistasy)• No Administratium: too much refinement may kill efficiency• Create one's own autonomous physics

• physical laws• measuring instruments and reference (primary) units• finding dependence laws - towards physical regression• an automated physicist?

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 45 / 47

Page 46: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

6 AcknowledgementsAmine BoumazaAurélie BousquetClaude CadozLionel CastillonPierre ColletAnders EckmanJiang LiAnnie LucianiEvelyne LuttonOlivier PauplinXavier ProvotJean-Marie RocchisaniMaria Rodriguez LopezBogdan Stanciulescu

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 46 / 47

Page 47: OPTIMISATION STRATEGIES FOR MODELLING AND SIMULATION …

ERICE Conference on Data Analysis for Astronomy, April 2007 Jean Louchet page 47 / 47