Home - MakiMarko/Projektno-delo-ENDGAME GitHub Wiki

Project: Cyclist and Motorist Detection System

Welcome to the Cyclist and Motorist Detection System documentation. This application uses the YOLO algorithm to detect cyclists and motorcyclists from video feeds, providing real-time alerts for car drivers.

Installation

1. Clone the repository

git clone https://github.com/MakiMarko/Projektno-delo-ENDGAME.git

cd Projektno-delo-ENDGAME

2. Install the required packages

pip install -r requirements.txt

3. Download the YOLO model

Place the yolov8n.pt model file in the project directory.

Usage

1. Run the Application

python main.py

2. Load videos

Click "Load Video 1", "Load Video 2", or "Load Video 3" to select and load the video files you want to process.

3. Start processing

Click the "Start Videos" or the play button to process the loaded videos. The detection results will be displayed with visual markers and status messages.

4. Pause/play videos

Use the play/pause button to toggle the playback of the videos.

Detailed Description

Graphical User Interface (GUI)

  • The GUI is built using Tkinter and provides a straightforward way to load and process video files.
  • It displays the video frames, detection results, and status messages for each loaded video.
  • It includes buttons to load videos, start/pause playback, and display status messages.

Detection and Alerts

  • The YOLO model detects cyclists and motorcyclists in the video frames.
  • Detected objects are marked with bounding boxes.
  • Alerts are generated based on the proximity and position of the detected objects:
  • Side frame: Displays overtaking status.
  • Front and rear frame: Warns if an object gets too close.

Sound Effects

  • Sound effects are played to alert drivers of potential dangers.
  • The sound effect file paths need to be specified correctly in the application code.

User Stories

As a car driver, I want to see the overtaking situation so I can overtake a cyclist who appears in a blind spot more safely.

As a driver, I want to be able to automatically detect less visible road users so that I can be alerted to their presence.

As a driver, I want to receive audible warnings when a subject is too close to a car so that I can react in time to avoid dangerous situations.