This document describes using genetic algorithms to improve an autonomous fuzzy controller for simulated car racing in TORCS. The controller uses fuzzy logic to map sensor inputs like distance to the front car to speed and steering actuator outputs. Genetic algorithms were used to optimize the fuzzy rules by minimizing damage and maximizing top speed over multiple races. The optimized controllers achieved higher positions and less damage than the original hand-designed controller in races on both familiar and unfamiliar tracks. Future work could involve evaluating controllers on more tracks, combining optimized controllers, and using multi-objective evolutionary algorithms or genetic programming to further improve the fuzzy rule base.
Exploring Sicily Your Comprehensive Ebook Travel Guide
Genetic Algorithms Improve Autonomous Fuzzy Driver for Simulated Car Racing
1. Applying Genetic
Algorithms for the
Improvement of an
Autonomous Fuzzy Driver
for Simulated Car Racing
• Mohammed Salem (University of Mascara, Algeria)
• Antonio Miguel Mora @amoragar and JJ Merelo @jjmerelo
(University of Granada, Spain)
• Pablo García-Sánchez (University of Cádiz, Spain) @fergunet
2. Start your engines!
— What is TORCS?
— Description of our fuzzy controller
— Genetic Algorithms
— Compared fitness functions
— Experimental setup
— Results
— Conclusions
3. What is TORCS?
— The Open Racing Car Simulator
— Used in Competitions and Testbed for AI
— Controllers (Driving bots):
— Sensors: Car and Track sensors
— Actuators: Steer, Accelerator, Break, Gear
8. SPEED Fuzzy
Controller
IF Front = High THEN TargetSpeed is 280
IF Front = Medium THEN TargetSpeed is 240
IF Front = Low AND M5 = High THEN TargetSpeed is 220
IF Front = Low AND M5 = Medium THEN TargetSpeed is 180
IF Front = Low AND M5 = Low AND M10 = High THEN TargetSpeed is 120
IF Front = Low AND M5 = Low AND M10 = Medium THEN TargetSpeed is 60
IF Front = Low AND M5 = Low AND M10 = Low THEN TargetSpeed is 30
IF Front = MAXDISTSPEED OR M5 = MAXDISTSPEED OR M10 =
MAXDISTSPEED
THEN TargetSpeed = 300
9. STEER Fuzzy Controller
IF Front = High THEN steer = 0
IF Front = Medium AND M10 = High THEN steer = 0.25
IF Front = Medium AND M10 = Medium AND M5 = Medium THEN steer =
0.25
IF Front = Medium AND M10 = Medium AND M5 = Low THEN steer = 0.5
IF Front = Low AND M10 = High THEN steer = 0.5
IF Front = Low AND M10 = Medium AND M5 = Medium THEN steer =
0.75
IF Front = Low AND M10 = Medium AND M5 = Low THEN steer = 0.75
12. GA Parameters
— Population size: 20 and 50
— Generations: 50
— Crossover rate: 0.7
— Mutation rate: 0.3
— Runs per configuration: 20
— Circuit used for training: E-track5
— Car used: car1-tbr1
— Real coded individual
13. Post-optimization
experiments
— Practice Race: GFC1 vs GFC2 vs AD (previous hand-
designed fuzzy controller. In E-Track and E-Road
(not used for optimization)
— Real Races (5 laps):
— E-Track
— E-Road
— A-Speedway
14. Final lap! (Results)
— Controller behavior
— more sensitive to middle distances of the inputs
— Late breaking and selection of optimal trajectory
— Practice Race (know and unknown circuits):
— Damage reduced to 0
— GFC2 uses TopSpeed for optimization->TopSpeed
increases
— Real race in know circuit: 2nd position (no damage)
— Real race in unknown circuit: 3rd position (no damage)
— Real race in unknown and difficult circuit: 4th position
15. Finish Line! (Conclusions
and future work)
— Optimized controllers obtained good positions in
real races
— New controllers increase top speed and reduce
damage
— Future work:
— Improve the evaluation using several tracks
— Combine optimized controllers
— MOEAs
— Genetic Programming for the rule base