78
Advanced Advanced Examples and Examples and Ideas Ideas

Advanced Examples and Ideas

  • Upload
    kami

  • View
    42

  • Download
    0

Embed Size (px)

DESCRIPTION

Advanced Examples and Ideas. Evolutionary Programming. Neural Net. EXPERT SYSTEM. Fuzzy System. Neuro -Fuzzy System. UNIVERSAL SEARCH SYSTEM. Three Layer Evolutionary Approach. Local perceptions, such as “bald head” or “long beard”. Encoded behaviors or internal states. Time intervals. - PowerPoint PPT Presentation

Citation preview

Page 1: Advanced Examples and Ideas

Advanced Advanced Examples and Examples and

IdeasIdeas

Page 2: Advanced Examples and Ideas

EXPERT SYSTEM

Neural Net Neural Net Evolutionary Evolutionary ProgrammingProgramming

Fuzzy SystemFuzzy System Neuro-Fuzzy Neuro-Fuzzy SystemSystem

UNIVERSAL UNIVERSAL SEARCH SEARCH SYSTEMSYSTEM

Page 3: Advanced Examples and Ideas

Three Layer Evolutionary Approach

Evolve Behaviors

Evolve Motions

Evolve Perceptions

Global perceptions, possibly encoded such as “narrow Corridor” or “beautiful Princess”

Local perceptions, such as “bald head” or “long beard”

Behaviors such as “go forward until you find a wall, else turn randomly right or left

Encoded behaviors or internal states

Time intervals

Motions as timed sequences of encoded actions, for instance RFRFLL

Page 4: Advanced Examples and Ideas

Evolve in hierarchyEvolve in hierarchy

1. Together or separately2. Feedback from model or from real world3. First evolve motions and encode them.4. Then evolve behaviors.5. Finally develop perceptions.

If you see a beautiful

princess go to her and bow low.

If you see a dragon escape

Go to the end of the corridor and

then look for food

Page 5: Advanced Examples and Ideas

Evolve in hierarchyEvolve in hierarchyavoid

obstacles

Execute optimal motions

Save energy

Look for energy sources in advance

Execute actions that you enjoy

What if robot likes to play soccer and sees the ball but is low on energy?

Page 6: Advanced Examples and Ideas

Optimizing a motion

Parking a Parking a TruckTruck

Page 7: Advanced Examples and Ideas

Find the control

Solving this analytically would be very difficult

Page 8: Advanced Examples and Ideas

Question; How to represent the chromosomes?

Here you see several snapshots of a “movie” about parking a truck, stages of the solution process.

Page 9: Advanced Examples and Ideas

• t is time u

Page 10: Advanced Examples and Ideas

Another example

Learning Learning Obstacle Obstacle AvoidingAvoiding

Page 11: Advanced Examples and Ideas

Similar to Braitenberg Vehicle but has 8 sensors

Page 12: Advanced Examples and Ideas

how• How would you

represent chromosomes?

• Design Crossovers?

Input and output data are some form of MV logic

1. Robot can move freely but has to avoid obstacles

2. This can be like the lowest level of behaviors in subsumption or other behavioral architecture for all your robots

Page 13: Advanced Examples and Ideas

The key to success is often in fitness function

Remember the goal when you create the fitness function

Page 14: Advanced Examples and Ideas

Number of collisions

• Time of learning

When you train longer you decrease the number of collisions

Page 15: Advanced Examples and Ideas

Applications Applications and and

ProblemsProblems

Page 16: Advanced Examples and Ideas

General GA SchemaInitialize the population

Compute Fitness

Selection

Crossover

Mutation

Compute Fitness

Stop Conditions?

Solution

Yes

No

Page 17: Advanced Examples and Ideas

Evolutionary Methods• Optimization problems:

– Single objective optimization problems– Multi-Objective optimization Problems

• Combine with other approaches.

Page 18: Advanced Examples and Ideas

• Search Problems (Path search)• Optimal multi-robot coordination• Multi-task optimization• Optimal motion planning of robot arms (Trajectory planning of

manipulators )• Motion optimization Motion optimization (optimization of controller parameters -

morphology in different control schemas)– PID (PI)– FuzzyFuzzy– NeuralNeural– Hybrid (neuro-fuzzy)Hybrid (neuro-fuzzy)

• Path planning and tracking (mobile robots)• Optimal motion planning of robot arms

– Trajectory planning of manipulators• Vision – computational optimization

More examples of problems in which we use evolutionary algorithms, neuro-fuzzy, and similar

methods.

Page 19: Advanced Examples and Ideas

• Evolutionary Algorithms - Related techniques:– Ant colony optimization (ACO) – Particle swarm optimization – Differential evolution– Memetic algorithm (MA)– Simulated annealing – Stochastic optimization – Tabu search – Reactive search optimization (RSO) – Harmony search (HS) – Non-Tree Genetic programming (NT GP) – Artificial Immune Systems (AIS)– Bacteriological Algorithms (BA)

What are these “other algorithm”?

1. You can try them in your homework 1 if GA or GP is too easy for you.

2. Using them gives you higher possibility of creating a successful superior method for a new problem

Page 20: Advanced Examples and Ideas

GA-operators• Selection

– Roulette– Tournament– Stochastic sampling– Rank based selection– Boltzmann selection– Nonlinnear ranking selection

• Crossover– One point– Multiple points

• MutationRead in Auxiliary Slides about

these methods. Or invent your own operators

for your problem.

Page 21: Advanced Examples and Ideas

Your design parameters to be decided

• Genotype length– Fixed length genotype– Variable-length genotype

• Population– Fixed population– Variable population– Species inside population– Geometrical separation

Page 22: Advanced Examples and Ideas

Drawbacks of GA

• time-consuming when dealing with a large population

• premature convergence • Dealing with multiple objective problems

Solutions• Niches• Islands• Pareto approach• Others

Page 23: Advanced Examples and Ideas

More examples of using GA in robotics

Trajectory Trajectory Planning Planning ProblemsProblems

Page 24: Advanced Examples and Ideas

GA and Trajectory Planning1. GA techniques for robot arm to identify the optimal

trajectory based on minimum joint torque requirements (P. Garg and M. Kumar, 2002)

2. path planning method based on a GA while adopting the direct kinematics and the inverse dynamics (Pires and Machado, 2000)

3. point-to-point trajectory planning of flexible redundant robot manipulator (FRM) in joint space (S. G. Yue et al., 2002)

4. point-to-point trajectory planning for a 3-link (redundant) robot arm, objective function is to minimizing traveling time and space (Kazem, Mahdi, 2008)

Projects last years

Page 25: Advanced Examples and Ideas

Optimal path generation of robot manipulators

1. Control Schema 2. Robotic arm – kinematic model3. Controller type4. Objective function - optimal path 5. Optimization algorithm (method)6. GA use smooth operators and avoids sharp

jumps in the parameter values.

Page 26: Advanced Examples and Ideas

• Adaptive Control Schema Adaptive Control Schema – Track Control error function between outputs of a real system and mathematical model

• What we optimize?• Which parameters must be optimized?• How many objectives (single –objective or multiobjective)?• Collision free? (How to model collision in GA?)

Page 27: Advanced Examples and Ideas

EXAMPLE: EXAMPLE: Combining kinematics, Combining kinematics, control, evolutionary control, evolutionary

and neuraland neural

Page 28: Advanced Examples and Ideas

• Three join ManipulatorThree join Manipulator

• A three-joint robotic manipulator system has three inputs and three outputs.

• The inputs are the torques applied to the joints and the outputs are the velocities of the joints

Page 29: Advanced Examples and Ideas

• For n-DOF we will have n inputs ui, i=1…n, (ui ↔ i)• Controller

– PID (PI)– Neural network (multilayer perceptron, recurrent NN, RBF

based NN)– Fuzzy – Neuro-Fuzzy (hybrid)

Design of robotic Design of robotic controllerscontrollers

Page 30: Advanced Examples and Ideas

• NN: We must to adapt the weights and eventually the bias The chromosome:

• Adapt the weights kijw

Use of Neural NetworksUse of Neural Networks

Page 31: Advanced Examples and Ideas

FUZZY LOGICFUZZY LOGIC• Fuzzy Logic

• Aggregation of rules• defuzzification• free-of-obstacles workspace (Mucientes, et. al, 2007)• wall-following behavior in a mobile robot

1 1 1 1:i i i i i i i i iN N M MR if x is A and x is A then y is B and y is B

Page 32: Advanced Examples and Ideas

• Learning of fuzzy rule-based controllers• Find a rule for the system

Step 1: evaluate population;Step 2: eliminate bad rules and fill up population;Step 3: scale the fitness values;Step 4: repeat NI iterations for Step 4 to Step 9

Step 5: select the individuals of the population; Step 6: crossover and mutate the individuals; Step 7: evaluate population; Step 8: eliminate bad rules and fill up population;

Step 9: scale the fitness values. Step 10: Add the best rule to the final rule set.

Step 11: Penalize the selected rule. Step 12: If the stop conditions are not fulfilled go to Step 1

Learning FUZZY LOGIC ControllersLearning FUZZY LOGIC Controllers

Page 33: Advanced Examples and Ideas

Encoding fuzzy controls

• The chromosome encode the rules:

• Sn is constant in this application but it can be also variable to be optimized

• wall-following behavior of the robot– the robot is exploring an unknown area– moving between two points in a map

• Requirements– maintain a suitable distance from the wall that is being followed– to move at a high velocity whenever the layout of the environment is permitting– avoid sharp movements (progressive turns and changes in velocity)

1 1 2 2( , , , , , )i i i i i i iNV NVC b c b c b c

Page 34: Advanced Examples and Ideas

Path-based robot behaviors

• The requirements are “encoded” in Universes of discourse and precisions of the variables– right-hand distance (RD)– the distances quotient (DQ), based on left-hand

distance– Orientation– linear velocity of the robot (LV)– Linear acceleration– Angular velocity

• Path of the robot (simulated environments)

Page 35: Advanced Examples and Ideas

Fast, reliable, no harm to robot or to environment

• This is useful for out PSU Guide Robot1. Do not harm humans2. Do not harm robot

Page 36: Advanced Examples and Ideas

• Fixed points: the desired Cartesian path Pt is given the problem is to find the set of joint paths P in order to minimize the cumulative error between desire and real path during trajectory

Pk is the kinematic model

• Free end points case

1 1

2 1 2

( , ) ( , ) ( )j jN NN

t ri j i

E P i j P i j E i

( )r kP F P

Minimize the cumulative error

Find the set of joint paths, next smooth it

Page 37: Advanced Examples and Ideas

Weighted Global Fitness• fitness function (minimization)

• Global fitness: Linear function of individual objectives

Fot – excessive driving (sum of all maximum torques), fq – the total joint

traveling distance of the manipulator, fc - total Cartesian trajectory length, tT

- total consumed time for robot motion

• Penalty function• Population initialization (probability distribution)

– Random uniform– Gaussian

1 2 3 4total ot q c TF f f f t

1

1F

E

Page 38: Advanced Examples and Ideas

exampleexample

Drug Drug Delivery Delivery ProblemProblem

Page 39: Advanced Examples and Ideas

Drug delivery using microrobots (Tao, et. al, 2005)

1. (GA)–based area coverage approach for robot path planning.

2. Drawbacks of most currently available drug delivery methods are that the drug target area, delivery amount, and– release speed are hard to be precisely controlled.

3. It is very difficult or impossible to eliminate side effects.4. Open issues

1. actively control the delivery process2. Access to appropriate areas that cannot be reached using traditional

devices5. Current Issues

1. On-line path planning (solve unexpected obstacles problem)2. Optimal path planning (efficiency, path planning)

Page 40: Advanced Examples and Ideas

• microcontroller is used to guide the robot movement• GA-based approach uses fine grid cell decomposition

for area coverage• Because the robot will move cell by cell, the start point

of chromosomes has to be changed dynamically whenever the robot reaches the center of a cell

• The end point of a chromosome is not fixed and needs to be determined by applying GA operators.

• The robots may move from the center of a cell to its 8 adjacent cells along 8 directions.

• some obstacles are unknown before drug delivery (the robot discover these obstacles during the motion)

Page 41: Advanced Examples and Ideas

• Expandable chromosomes• Deleting the path• Crossover operator

Page 42: Advanced Examples and Ideas

• New mutation operators– Travel further– Delete– Reverse delete– Stretch– Shortcut

• The algorithm keep mind the visited nodes• Extension to operational research?

Page 43: Advanced Examples and Ideas

Other applications using evolutionary algorithms

• Autonomous mobile robot navigation - Path planning using ant colony optimization and fuzzy cost function evaluation (Garcia, et. al, 2009).

• Legged Robots and Evolutionary Design• Optimal path and gait generations (Pratihar, Debb,

and Gosh, 2002) – 0/1 absence or presence of rule

• six-legged robot• collision-free coordination of multiple robots

(Peng and Akela, 2005)

Page 44: Advanced Examples and Ideas

What if you want to optimize two parameters at the same time?

Pareto Pareto OptimizationOptimization

Page 45: Advanced Examples and Ideas

Definitions

ophelimity

noun economic, Economic satisfaction. The ability to please another.

Pareto Evolutionary

Methods

Page 46: Advanced Examples and Ideas

• We want to optimize both functions f1 and f2

What is better this or this?

Page 47: Advanced Examples and Ideas

Biobjective means two

objectives to reach

• We have x and y, two objectives here

Pareto solutions for different algorithms

Pareto Pareto FrontFront

Page 48: Advanced Examples and Ideas

Pareto frontPareto front• The single objective optimisation problem (SOP)

conduct to a minimization (or maximization) of one cost function, less or more complex, that is a single objective is taken into account.

• Conversely, the multi-objective optimization problem takes into account two or more objective that has to be minimized (or maximized) simultaneously.

• Some objectives can be in competition, so a simultaneous minimization is not possible, but only a trade-off among them. • Some time, the number of objectives can be high, like 16

objectives or more that make the multi-objective optimization problem (MOP) and interesting and challenging area of research

Page 49: Advanced Examples and Ideas

Example of Pareto Optimization of two parameters

Optimization Optimization of Airplane of Airplane

WingsWings

Page 50: Advanced Examples and Ideas

• Two objectives: Two objectives: Maximize lift, and minimize drag

Page 51: Advanced Examples and Ideas

• Two objectives: Two objectives: Maximize lift, and minimize drag

* In most of the design space the red method is better than the blue method* It is good to use many Pareto methods and modify parameters

Page 52: Advanced Examples and Ideas

Multi-Pareto1. We optimize many

parameters, 2. We may switch between

subsets of them.3. Subsets can have two

elements each.

Page 53: Advanced Examples and Ideas
Page 54: Advanced Examples and Ideas
Page 55: Advanced Examples and Ideas
Page 56: Advanced Examples and Ideas
Page 57: Advanced Examples and Ideas

Three-dimensionalThree-dimensional Minimization Minimization

ProblemProblem

Page 58: Advanced Examples and Ideas
Page 59: Advanced Examples and Ideas

Pareto Pareto FrontFront

Page 60: Advanced Examples and Ideas

General multiobjective General multiobjective optimization problemoptimization problem

• The multiobjective optimization problem could be generally formulated as minimization of vector objectives Jt(x) subject to a number of constraints and bounds:

Page 61: Advanced Examples and Ideas

Pareto-optimal set Pareto-optimal set 1. In the case of competing objectives a trade-off is involved

such a problem usually has no unique solution. – Instead, we can admit a set of solutions, equally valid non-

dominated as a set of alternative solutions known as Pareto-optimal set

2. In what follows we assume without loss of generality that all the function objectives must be minimized.– If we have a maximization case fi we simply minimize the

function -fi.

3. For any two points that are usually named candidate solutions V1,V2, V1 dominates V2 in the Pareto sense (P-dominance) if and only if the following condition hold

},...,{),()(

},...,{),()(

121

121

1

1

mjoneleastatforVfVf

miVfVf

jj

ii

Page 62: Advanced Examples and Ideas

The Pareto setThe Pareto set

1. The Pareto set is the set of PO (Pareto-Optimal) solution in design domain and the Pareto Front (PF) is the set of PO solutions in the objective domain.

2. The most popular way to solving the MOP (Multi Objective Optimization Problem) is to reduce the minimization problem to a scalar form by aggregating the objectives in weighted sum, with the sum of weights constant:

3. The weighted sum method has a serious drawback, the method usually fail in the case of nonconvex PF.

n

ii

n

iiit wJwJ

11

1,min

Page 63: Advanced Examples and Ideas

Example of a clear picture of Pareto points

Page 64: Advanced Examples and Ideas

Nice properties

1. GA can provide an elegant solution for tradeoff among different minimization of cost function for each variable versus total cost or other variable.

2. Non-convex solutions

3. “Immigrants”, possible solution for jump from local minima.

4. Dealing with many variables (e.g. 16 variables)

Page 65: Advanced Examples and Ideas

Multi-Robots

• Pareto optimal multi-robot coordination with acceleration constraints (Jung and Ghrist, 2008)1. collection of robots sharing a common environment 2. each robot constrained to move on a roadmap in its

configuration space3. each robot wishes to travel to a goal while

optimizing elapsed time considering vector-valued (Pareto) optima

4. all illegal or collision sets are removed.

Page 66: Advanced Examples and Ideas

ConclusionsConclusions1. GA is not a universal panacea to optimization problems.

2. Coding the problem into a genotype is the most important challenge!

3. The best selection schema of individuals for crossover operator is difficult to be chosen apriori (tournament selection seems to be more promising)

4. A number of parameters are determined empirically:1. Size of population2. pc and pm even often values inspired from biology are given3. Other parameters in hybrid or more sophisticated GA

Page 67: Advanced Examples and Ideas

Good properties1. One of the most important element in the design of a decoder-based

evolutionary algorithm is its genotypic representation.

2. The genotype-decoder pair must exhibit efficiency, locality, and heritability to enable effective evolutionary search

3. locality, and heritability: 1. small changes in genotypes should correspond to small changes in

the solutions they represent, and 1. solutions generated by crossover should combine features of their

parents

Page 68: Advanced Examples and Ideas
Page 69: Advanced Examples and Ideas

SourcesSources

Dragos Arotaritei

Page 70: Advanced Examples and Ideas
Page 71: Advanced Examples and Ideas
Page 72: Advanced Examples and Ideas
Page 73: Advanced Examples and Ideas
Page 74: Advanced Examples and Ideas
Page 75: Advanced Examples and Ideas

exampleexample

Page 76: Advanced Examples and Ideas
Page 77: Advanced Examples and Ideas
Page 78: Advanced Examples and Ideas