Lane Keeping with AI: Unterschied zwischen den Versionen

Aus HSHL Mechatronik
Zur Navigation springen Zur Suche springen
Zeile 58: Zeile 58:
'''Feature Extraction:''' Edge detection and Hough transforms (with morphological closing) are applied to detect lane markings robustly, especially in challenging scenarios such as dotted or faded lines.
'''Feature Extraction:''' Edge detection and Hough transforms (with morphological closing) are applied to detect lane markings robustly, especially in challenging scenarios such as dotted or faded lines.


These steps ensure that the extracted features are robust against variations in real-world conditions.
These techniques enhance model training, leading to more reliable lane detection.


= Task =
= Task =

Version vom 1. April 2025, 23:48 Uhr

Abb. 1: Syncronous recording of video an steering angle
Autor: Moye Nyuysoni Glein Perry
Art: Project Work
Starttermin: 14.11.2024
Abgabetermin: 31.03.2025
Betreuer: Prof. Dr.-Ing. Schneider

Introduction

This project focuses on developing an autonomous lane-keeping system for a 1:20 scale model car equipped with a camera. The system’s goal is to train an artificial intelligence (AI) Model to drive autonomously on the track using image processing and signal processing techniques. In this work, steering angle data and video recordings are employed to train an artificial intelligence (AI) model. Two main approaches are explored:

  • Training a Convolutional Neural Network (CNN) from scratch
  • Using Transfer Learning (with ResNet-50 and integrated PID/MPC control)

These methods are compared using a morphological (Zwicky) box framework that considers various design parameters. Signal processing plays a key role in preprocessing the visual data and augmenting the training dataset.

Lane-keeping refers to the ability of a vehicle to detect and maintain its position within a designated lane on the road. It is a critical function for autonomous driving, helping to enhance road safety and reduce driver workload. Our target location is the mechatronics lab at HSHl. below are videos recorded using videos from a JetRacer

Visualized Data of Sample01

Visualized Data of Sample02

System Requirements

The lane-keeping system must fulfill the following requirements:

Autonomous Operation: Detect lane markings and maintain the vehicle in the right lane.

Real-Time Processing: Process video data in real time to generate accurate steering commands.

Data Synchronization: Synchronize steering angle measurements with video frames.

Robustness: Handle varying lighting conditions, noise, and occlusions using signal processing techniques.

Scalability & Adaptability: Provide flexibility to incorporate different AI training strategies (from-scratch CNN vs. transfer learning).

Visualization & Analysis: Use MATLAB® scripts (e.g., zeigeMessdaten.m) to visualize and verify data and performance.

Documentation & Reproducibility: Maintain thorough scientific documentation including code, parameters, and evaluation criteria.

3. Research and Methodological Approach

3.1 Solution Alternatives and Morphological Box

The morphological box is used to systematically explore and compare various solutions based on design parameters and their possible values. The following table summarizes the alternatives:

3.2 Signal Processing in Lane Detection

Signal processing is central to the project:

Preprocessing: Frames are converted to grayscale, contrast-adjusted, resized, and noise-filtered (using Gaussian filters and morphological operations) to enhance lane features.

Data Augmentation: Multiple versions of each frame (e.g., flipped, brightness-adjusted) are created to increase dataset diversity and improve model generalization.

Feature Extraction: Edge detection and Hough transforms (with morphological closing) are applied to detect lane markings robustly, especially in challenging scenarios such as dotted or faded lines.

These techniques enhance model training, leading to more reliable lane detection.

Task

  1. Set up requirements for a lane keeping system.
  2. Research on solutions for the task (morphological box with technical creteria).
  3. Implementation in MATLAB®. Teach a AI to drive in the right lane.
  4. Use the Video data here.
  5. Use the recorded steering angle here.
  6. The data can be visualized with zeigeMessdaten.m (see fig. 1).
  7. Verify the results with Rundkurs01.avi and Rundkurs02.avi.
  8. Evaluation of the solutions using a morphological box (Zwicky box) based on technical creteria
  9. Discussion of the results
  10. Testing of the system requirements - proof of functionality
  11. Scientific documentation of every step as a wiki article with an animated gif



→ zurück zum Hauptartikel: Signalverarbeitung mit MATLAB und Künstlicher_Intelligenz