Artificial Intelligence Techniques applied to Engineering
Part 2. Genetic Fuzzy Systems Enrique Onieva Caracuel
@EnriqueOnieva
1.Fuzzy Logic
2.Genetic Algorithms
3.Genetic Fuzzy Systems
4.Applications to Intelligent Transportation Systems: My Experience
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 2
Intelligent Transportation Systems
Intelligent Transportation Systems integrate information and communication technologies with transportation of passengers and goods
Mobility
Safety
Productivity
Energy consumption
Capacity
1
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 3
Intelligent Transportation Systems
Common services
Information Systems
Route planning
Air transport
Maritime transport
Road transport Intelligent infrastructure
Intelligent vehicles Active assistances
Pasive assistances
2
Autonomous Driving?
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 4
Motivation
Fuzzy Logic
IF the vehicle is derived through the right, steer to the left
IF the vehicle is derived through the left, steer to the right
IF the vehicle is slow, press the throttle
IF the vehicle is fast, press the brake
1
Control System Driver
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 5
Motivation 2
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 6
AUTOPIA Program 1 1998
2012
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 7
AUTOPIA Program
Throttle Pedal signals commuted Orders communicated by an
Analog Card
Brake Intervention on the ABS Electro-hydraulic system
Motor Deposit 3 valves: Limiter, Proportional,
Nothing-All
Orders communicated by a CAN controller
2 WLAN
Antenna
Power Supply
GPS Receiver
Computer
IMU
GPS Antenna
CAN-USB converter
Auxiliary Battery
CAN Module
Electro-hydraulic
system
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 8
Speed Control for Cities
Inputs
Speed error(km/h)
Acceleration (km/h/s)
Outputs
Throttle [0,1] Throttle [0,0.4]
Brake [0,1] Brake [0,0.2]
1
Comfort acceleration ≤ 2.5 m/s2
Ac+ Ac0 Ac-
EV+ B02 B01 B01
EV0 T00 t01 T01
EV- T01 T02 t04
E. Onieva, et al., Throttle and Brake Pedals Automation for Populated Areas, Robotica, vol. 28, n. 4, pp 509-516.
Speed Error (km/h)
Acceleration (km/h/s)
Negative Negative Zero Positive
Negative Zero Positive
T00 T01 T02 T04
B00 B01 B02
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 9
Speed Control for Cities
First gear (speed > 16 km/h) Error measured after transitory
state (5 s) Bigger error at 15 km/h
(1st to 2nd gear)
Similar results (speed≤ 20 km/h) Better results at 25 km/h
2
E. Onieva, et al., Throttle and Brake Pedals Automation for Populated Areas, Robotica, vol. 28, n. 4, pp 509-516.
Human System
10km/h ±0.63 ±0.71
15km/h ±0.88 ±0.98
20km/h ±0.72 ±0.84
25km/h ±1.22 ±0.9
Speed Target
Speed Target
Speed Target
Speed Target
Speed Target
Time (s)
Spee
d (
km/h
)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 10
Speed Control on-line Learning
1. Rules’ consequents modification in real time Speed error
Acceleration
Rule activation
9 cased reward
Positive or Negative error
Acceleration and comfort acceleration
Acceleration decreases when error 0
1
E. Onieva et al., On-Line Learning of a Fuzzy Controller for a Precise Vehicle Cruise Control System, Expert Systems with Applications. 40 (4) , pp. 1046-1053.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 11
Speed Control on-line Learning
1. Rules’ consequents modification in real time
2
E. Onieva et al., On-Line Learning of a Fuzzy Controller for a Precise Vehicle Cruise Control System, Expert Systems with Applications. 40 (4) , pp. 1046-1053.
Spee
d (
km/h
)
Time (s)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 12
Speed Control on-line Learning
2. Trapezoids’ modification
After a certain time (100 seconds)
Input values histogram analysis
A trapezoid is added if it is low-covered
A trapezoid is narrowed if covers several frequent values
3
E. Onieva et al., On-Line Learning of a Fuzzy Controller for a Precise Vehicle Cruise Control System, Expert Systems with Applications. 40 (4) , pp. 1046-1053.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 13
Speed Control on-line Learning 4 Test with 40 vehicles in TORCS
Different dynamics
Different behaviors
Simple initial controller 2x2 membership functions
All the singletons = 0 (do nothing)
E. Onieva et al., On-Line Learning of a Fuzzy Controller for a Precise Vehicle Cruise Control System, Expert Systems with Applications. 40 (4) , pp. 1046-1053.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 14
Speed Control on-line Learning
1. Speed change test
2. Fixed speed test (15 km/h)
3. Fixed speed test (5 km/h)
5
E. Onieva et al., On-Line Learning of a Fuzzy Controller for a Precise Vehicle Cruise Control System, Expert Systems with Applications. 40 (4) , pp. 1046-1053.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 15
Information capture
Information Processing
Simplification Extension
Steering control by Genetic Algorithms 1
E. Onieva, et al., Genetic fuzzy-based steering wheel controller using a mass-produced car, Int. J. of Innovative Computing, Information and Control. vol. 8, n. 5B, pp. 77-94. E. Onieva, et al., Automatic lateral control for unmanned vehicles via genetic algorithms. Applied Soft Computing Journal. 11 - 1, pp. 1303 - 1309, 2011
Lateral Error Angular Error
Stee
rin
g
Lateral Error Angular Error
Stee
rin
g
Lateral Error
Angular Error
Reference Line
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 16
Steering control by Genetic Algorithms
Membership functions Representation
Rule base representation Integer coding
Length = Number of rules
21 Singletons in [-1,1]
2
LAT/ ANG
θ
{Ve
ryLeft}
Left
No
Righ
t
{Ve
ryRigth
}
Θ M M M M M
{VeryLeft} M C C C C C
Left M C C C C C
No M C C C C C
Right M C C C C C
{VeryRigth} M C C C C C
E. Onieva, et al., Genetic fuzzy-based steering wheel controller using a mass-produced car, Int. J. of Innovative Computing, Information and Control. vol. 8, n. 5B, pp. 77-94. E. Onieva, et al., Automatic lateral control for unmanned vehicles via genetic algorithms. Applied Soft Computing Journal. 11 - 1, pp. 1303 - 1309, 2011
Left NO Right VeryLeft VeryRight Left NO Right
R10, R9, R8, R7, … R1 L1, L2, L3, L4, … L10 NO
Right (Clockwise) Left
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 17
Steering control by Genetic Algorithms
Genetic fuzzy system in 2 stages Membership function
optimization Real coding BLX-𝛼 crossover
Rule base optimization Integer coding One point crossover
Steady state Genetic Algorithm Binary Tournament Uniform Mutation Worse individual replacement
3
E. Onieva, et al., Genetic fuzzy-based steering wheel controller using a mass-produced car, Int. J. of Innovative Computing, Information and Control. vol. 8, n. 5B, pp. 77-94. E. Onieva, et al., Automatic lateral control for unmanned vehicles via genetic algorithms. Applied Soft Computing Journal. 11 - 1, pp. 1303 - 1309, 2011
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 18
Steering control by Genetic Algorithms
Objective function
Mean squared error (MSE)
Highest jump in the control surface (Dist)
Fitness Function (Min): 0.75·MSE + 0.25·Dist
4
E. Onieva, et al., Genetic fuzzy-based steering wheel controller using a mass-produced car, Int. J. of Innovative Computing, Information and Control. vol. 8, n. 5B, pp. 77-94. E. Onieva, et al., Automatic lateral control for unmanned vehicles via genetic algorithms. Applied Soft Computing Journal. 11 - 1, pp. 1303 - 1309, 2011
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 19
Steering control by Genetic Algorithms
5
E. Onieva, et al., Genetic fuzzy-based steering wheel controller using a mass-produced car, Int. J. of Innovative Computing, Information and Control. vol. 8, n. 5B, pp. 77-94. E. Onieva, et al., Automatic lateral control for unmanned vehicles via genetic algorithms. Applied Soft Computing Journal. 11 - 1, pp. 1303 - 1309, 2011
Controllers Speeds
Labels Rule Base Average Maximum
3x3 Marginal 12.8 22.4
3x3 Central 14.6 22.1
3x3 Total 13.5 24
5x5 Marginal 14.9 22.1
5x5 Central 14.8 28.6
5x5 Total 14.8 27.9
Lateral error Angular error Honorable Mention to
best student work
ESTYLF 2008
East (m)
No
rth
(m
)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 20
Intersection decision by genetic algorithms
Decision making in non-cooperative intersections
Non yielding always strategy
Safe and efficient maneuver Slightly accelerate to pass
before the manual one
Slightly brake to yield
Without stopping
1
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Accidents at intersections
Intelligent Trasnportation Systems
Intersections
Manual Manual Autonomous
Autonomous Autonomous Autonomous
Coordination
Accidents
Roads
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 21
Intersection decision by genetic algorithms
1. Check if the vehicle is going to cross and by where Fuzzy rule based system 3 inputs Manually adjusted
2. Decide the autonomous vehicle’s speed to finish the maneuver Without risk As soon as possible Fuzzy rule based system 4 inputs
Coded with {2,3,4} membership functions 81 Granularities
2 types of outputs Relative / Absolute Speed
162 controllers adjusted by a Genetic Algorithm
3. Move the pedals to reach the desires speed Vehicle’s longitudinal dynamics model Flat surface
2
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Manual
Autonomous
Time Sp
eed
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 22
Intersection decision by genetic algorithms
Evaluation in a variable number of scenarios Nsc=1+19·(g/G)
2 Executions Free (EF) (Keep SA)
What happens if speed does not vary?
Controlled (EC) Does the fuzzy system avoid the
collision
3 possible results No collision Lateral collision Frontal collision
3
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
No Collision Lateral Collision Frontal Collision
Keep Speed
up Slow Down
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 23
Intersection decision by genetic algorithms
Partial fitness depending on:
Result in free execution
Result in controlled execution
How much has been the speed varied
Fitness function Minimize the sum of partial fitnesses
4
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Description Meaning Partial fitness
No collision (EF=EC=NO) |∫SAc-∫SA
l|
A lateral collision is avoided (EF=LA & EC=NO) •|∫SA
c-∫SAl|, if speeds up
•2.500, if brakes down
A frontal collision is avoided (EF=FR & EC=NO) •|∫SA
c-∫SAl|, if brakes down
•2.500, if speeds up
Collision is not avoided (EF≠NO & EC ≠ NO) 5.000
Collision is caused (EF=NO & EC ≠ NO) 10.000
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 24
Intersection decision by genetic algorithms
Safety vs Number of rules
Safety > 90%
Some relatives are worse that a ‘do nothing’ system
Absolute ones are safer
ABS4423, ABS3433, ABS3344 y ABS2442 100%
Is the safety dependent on the type (absolute / relative) of controller?
5
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Relative Controllers
Absolute Controllers
Number of Rules
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 25
Intersection decision by genetic algorithms
Granularities correlation
Most systems are near the diagonal
54% vs 46% of structures are safer with a specific model
Safe structures are both when relative and absolute output
6
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Safety for Relative FRBS
Safe
ty f
or
Ab
solu
te F
RB
S
Structures with higher safety in Absolute
mode (46%) Structures with higher safety in Relative mode
(54%)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 26
Intersection decision by genetic algorithms
A ‘stop always’ policy safety 100 %
No efficient, neither intelligent
Fitness function measures the efficiency of the systems
Lineal relationship
Safety comes with efficiency
7
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Relative Controllers Absolute Controllers
Safety
Fitn
ess
Fun
ctio
n
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 27
Intersection decision by genetic algorithms
Both vehicles start at same speed Free execution Frontal collision System must brake
All of them do ABS4242 brake less REL3344 speeds up once the risk disappear
Autonomous one starts slightly faster Free execution Lateral collision System must speed up
All of them avoid the collision REL3344 does it by speeding up
Autonomous one starts much faster Free execution No collision System must maintain speed
All of them avoid the collision REL3344 varies less the speed
8
E. Onieva, et al., Genetic Optimization of a Vehicle Fuzzy Decision System for Intersections, Expert Systems with Applications. 39 (18) , pp. 13148-13157
Time (s)
Spee
d
(km
/h)
Dis
tan
ce
(m)
Time (s)
Spee
d
(km
/h)
Dis
tan
ce
(m)
Time (s)
Spee
d
(km
/h)
Dis
tan
ce
(m)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 28
Videos
Learning to steer in an autonomous vehicle
Self-Archive
Autonomous Driving Citroën C3 Pluriel
https://www.youtube.com/watch?v=qm-nh7_fJvY
Grand Cooperative Driving Challenge (GCDC) - Technische Universiteit Eindhoven
https://www.youtube.com/watch?v=BprHHm5j_hA
Other Applications
Composition: https://www.youtube.com/user/GrupoAUTOPIA/videos
Autonomous Driving @ High Speed
https://www.youtube.com/watch?v=1zoTg_Pnxbg
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 29
2009 Simulated Car Racing Championship 1
Gears Change current gear Rule system (RPM)
Use reverse gear Angle + Deviation
Steer
Centered vehicle Laser Sensors
Reverse gear Angle
Go back to track Angle + Deviation
Pedals Adequate speed Speed error
ABS / TCL Filters Speed-Wheels
Objective Desires Speed Fuzzy System
Learning
Off track
Decision system Borders crashs
Long straights
Opponents
Overtaking
Rule System Avoid collisions
Emergency braking
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 30
2009 Simulated Car Racing Championship
Gear Control
Change current gear according with RPM
[1ª-3ª] ↑ if RPM>9000
[4ª-5ª] ↑ if RPM>9500
[2ª-4ª] ↓ if RPM<3000
[5ª-6ª] ↓ if RPM<3500
Reverse gear?
Continue race
2
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 31
2009 Simulated Car Racing Championship
Pedals control
Throttle and brake
Pedal [-1,1]
Speed and wheels’ speed based filters
[ABS Brake]
[TCS Throttle]
Special case: Reverse Gear
Pedal = 0.25
3
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Speed – Target (km/h)
Ped
al
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 32
2009 Simulated Car Racing Championship
Steer control
Reverse gear
Off-track
Inside track
4
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Stee
r
Angle (rad)
Angle (rad)
Stee
r
Deviation (m)
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 33
2009 Simulated Car Racing Championship
Objective speed IF FRONT is High 200 km/h
IF FRONT is Medium 175 km/h
IF FRONT is Low Y MAX10 is High 150 km/h
IF FRONT is Low Y MAX10 is Medium 125 km/h
IF FRONT is Low Y MAX10 is Low Y MAX20 is High 100 km/h
IF FRONT is Low Y MAX10 is Low Y MAX20 is Medium 75 km/h
IF FRONT is Low Y MAX10 is Low Y MAX20 is Low 50 km/h
Non-Fuzzy rule:
IF FRONT = 100 300 km/h
5
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Fro
nt
Max
10
Max
20
Low Medium High
Low Medium High
Low Medium High
Front = P0
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 34
2009 Simulated Car Racing Championship
Opponents
Modify the steer to overtake Sensors at {±90º} SI (measure/speed)<Tolerance (steer+=Increment)
Modify the steer to avoid collisions Sensors at {±30º} SI (measure<10) (steer±=0.25)
Emergency breaking Sensors at {±20º} SI (measure<10) (VELobj *=0.8)
6
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 35
2009 Simulated Car Racing Championship
3 International Conferences
Rules
3 unknown tracks
Classification phase race alone: 200 seconds
Race among the 8 classified. 10 races, 10 laps, different starting
F1 punctuation scheme:
Fastest lap +2
Less damage +2
Final score Median over 10 races
7
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 36
2009 Simulated Car Racing Championship 8
CEC GECCO CIG FINAL
Proposal 22 32 29 83
Cobostar 28.5 16.5 30 75
Champ2008 20 23 12.5 55.5
Perez &Saez 16 11 12.5 36.5
Best student work award ESTYLF 2010
E. Onieva, et al., A Fuzzy Based Driving Architecture for Non-player Characters in a Car Racing Game, Soft Computing vol. 15, n. 8, pp. 1617-1629, 2011.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 37
2010 Simulated Car Racing Championship
Similar architecture Punctual modifications in certain modules
Removing of the fuzzy system in charge of determining the desired speed
Optimized Steer and target speed: Generational Genetic
Algorithm
Controller evaluation in 4 tracks
Maximize the sum of distances coverted
1
E. Onieva, et al., An evolutionary tuned driving system for virtual car racing games: The AUTOPIA driver, Int. Journal of Intelligent Systems, vol. 27, n. 3, pp. 217–241, 2012.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 38
2010 Simulated Car Racing Championship
Real optimization
10 component vector
Steer control
Target speed
BLX-𝛼 Crossover
Uniform mutation
2
E. Onieva, et al., An evolutionary tuned driving system for virtual car racing games: The AUTOPIA driver, Int. Journal of Intelligent Systems, vol. 27, n. 3, pp. 217–241, 2012.
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 39
2010 Simulated Car Racing Championship
Winner in 2010
System to beat at 2011, 2012 y 2013
Not beaten until now
3
E. Onieva, et al., An evolutionary tuned driving system for virtual car racing games: The AUTOPIA driver, Int. Journal of Intelligent Systems, vol. 27, n. 3, pp. 217–241, 2012.
Proposal Muñoz Mr. Racer Polimi
GECCO_1 12 5.5 9 6
GECCO_2 12 8 4 4.5
GECCO_3 10 9 3 5.5
WCCI_1 10 10 4 5
WCCI_2 8 10 3 5
WCCI_3 6 8 2 6
CIG_1 8 4 3 10
CIG_2 12 2 4 6
CIG_3 5 6 8 8
Proposal Muñoz Mr. Racer Polimi
GECCO 34 17 16 6
WCCI 24 28 9 16
CIG 25 12 15 24
TOTAL 83 57 40 46
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 40
Racing overtakes
Opponents that oppose to be overtaken are implemented.
They try to reach the position of the overtaker
3 types: Limited
Slow
Complete
Opponent must be overtaken
1
E. Onieva, et al., Overtaking Opponents with Blocking Strategies Using Fuzzy Logic, IEEE Conference on Computational Intelligence in Games, 2010
Limited
Slow
Complete
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 41
Racing overtakes
Fuzzy Rule Based System 4 inputs:
Longitudinal distance (Dx) Lateral distance (Dy) Lateral deviation (DL) Time to Collision (TtC)
2 outputs Required lateral position Pedal (Emergency braking)
Manually tuned rule base 600 potential rules 3·8·5·5 Labels
Common sense If the maneuver is finished go back to the center Grouping If lateral distance is long, do not move
81 rules in the final rule base
2
E. Onieva, et al., Overtaking Opponents with Blocking Strategies Using Fuzzy Logic, IEEE Conference on Computational Intelligence in Games, 2010
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 42
Racing overtakes
They were tested: The proposal Controllers included in TORCS
Against: Slow at 12 different speeds Limited at 12 different speeds Complete at 12 different speeds
It is measured: % of finished maneuvers % of maneuvers without frontal damage
(system’s fault) % of maneuvers without lateral damage
(opponent’s fault)
3
Proposal Berniw Bt Inferno Lliaw Olethros Simplix Tita
%S 100 34.4 21.9 37.5 37.5 31.3 25 37.5
%BfD 90.6 75 87.5 78.1 78.1 100 100 81.3
%LfD 87.5 62.5 96.9 65.6 65.6 93.8 100 65.6
E. Onieva, et al., Overtaking Opponents with Blocking Strategies Using Fuzzy Logic, IEEE Conference on Computational Intelligence in Games, 2010
2º Best Work IEEE-CIG 2010
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 43
Videos
Highlight from the Simulated Car Racing Competition at CEC-2009 - Driver by Onieva and Pelta
https://www.youtube.com/watch?v=k5FgzAmJdzs
2010 Simulated Car Racing Championship - First Leg @ GECCO-2010
https://www.youtube.com/watch?v=SXDJMXpiRs0
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 44
We collect traffic data from the
California Department of Transportation
About 15 km long 14 (actually more) loops detectors
6 loops detectors which give us flow, speed and density
8 loops detectors which give us only flow
Congestion Prediction 1
Objective: When congestion is going
to occur here ?
X. Zhang, E. Onieva, et al., Hierarchical Fuzzy Rule Based System Optimized with Genetic Algorithms for Short Term Traffic Congestion Prediction. Transportation Research Part C: Emerging Technologies. 43, pp. 127-142. 2014
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 45
Congestion Prediction
We group the information in 14 possible input variables 3 flows in the main highway F1 F2 F3
3 densities in the main highway D1 D2 D3
3 speeds in the main highway S1 S2 S3
2 input flows from the entrances iF1 iF2
2 output flows from the exits oF1 oF2
2
X. Zhang, E. Onieva, et al., Hierarchical Fuzzy Rule Based System Optimized with Genetic Algorithms for Short Term Traffic Congestion Prediction. Transportation Research Part C: Emerging Technologies. 43, pp. 127-142. 2014
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 46
Congestion Prediction
We define a hierarchical fuzzy system structure to predict congestions at desired
Example: 4 input variables with 3 membership functions per variable
3
X. Zhang, E. Onieva, et al., Hierarchical Fuzzy Rule Based System Optimized with Genetic Algorithms for Short Term Traffic Congestion Prediction. Transportation Research Part C: Emerging Technologies. 43, pp. 127-142. 2014
The same example with N input variables : 3N rules in the non-hierarchical system 9·(N-1) rules in the hierarchical system
14 variables: 4.782.969 Vs 117 Rules
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 47
Congestion Prediction
The systems is optimized by a Genetic Algorithm:
3-part coding
Input variables’ order Variable selection
Membership Functions
Rules’ consequents
2 operator groups:
Permutation
Real Coding
4
X. Zhang, E. Onieva, et al., Hierarchical Fuzzy Rule Based System Optimized with Genetic Algorithms for Short Term Traffic Congestion Prediction. Transportation Research Part C: Emerging Technologies. 43, pp. 127-142. 2014
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 48
Congestion Prediction
3 experiments:
97% 5 minutes ahead 9 variables
94% 15 minutes ahead 7 variables
93% 30 minutes ahead 10 variables
5
X. Zhang, E. Onieva, et al., Hierarchical Fuzzy Rule Based System Optimized with Genetic Algorithms for Short Term Traffic Congestion Prediction. Transportation Research Part C: Emerging Technologies. 43, pp. 127-142. 2014
Técnicas de Inteligencia Artificial aplicadas a la Ingeniería @EnriqueOnieva 2014/2015 49
Assignment
Write an abstract of your thesis work (max. 250 words)
Look for 2-3 works that applies fuzzy logic to your thesis’ topic. Write a brief summary (max. 100 words/each)
Look for 2-3 works that applies genetic algorithms to your thesis’ topic . Write a brief summary (max. 100 words/each)
Look for 2-3 works that applies genetic fuzzy system to your thesis’ topic . Write a brief summary (max. 100 words/each)