Skip to content

Mostafa23/AI-Cheating-Detection-System

Repository files navigation

VisionGuard AI 👁️🛡️

A Real-Time Exam Cheating Detection System

Welcome to my project! I'm Mostafa (GitHub: Mostafa23), and I developed VisionGuard AI to solve the challenge of automated exam monitoring. This system uses computer vision to track students during exams, detect suspicious behavior, and immediately log alerts to the cloud.

The core detection runs on a custom YOLOv10 model, wrapped in a modern desktop interface built with CustomTkinter.

🚀 Features

  • Temporal Threshold Smoothing: A smart system that escalates warnings (Green ➔ Orange ➔ Red) to filter out false positives.
  • Fast-Motion ByteTrack: Customized tracking to maintain student IDs even during rapid movements.
  • Automated Evidence Collection: Saves screenshots of suspicious activities locally with timestamps.
  • Firebase Integration: Automatically uploads evidence to Firebase Storage and logs metadata in Firestore.
  • Playback Controls: Supports reviewing video footage at multiple speeds (0.25x, 0.5x, 1x, 2x).
  • Hardware Acceleration: Seamlessly utilizes CUDA GPUs if available, falling back to CPU otherwise.

📸 Demo

Here is a quick preview of the system in action:

Demo GIF

📂 Project Structure

AI-Cheating-Detection-System/
├── alerts/                 # Local evidence storage (Screenshots & Logs)
├── assets/                 # UI icons and video demo
├── core/
│   └── detector.py         # YOLOv10 object detection and tracking logic
├── db/
│   └── firebase_manager.py # Firebase Storage & Firestore upload logic
├── models/
│   └── weights/
│       └── best.pt         # Pre-trained YOLO weights
├── notebooks/
│   └── kaggle_binary_training.ipynb # Model training code
├── ui/
│   └── app.py              # CustomTkinter Desktop GUI
├── dist/
│   └── VisionGuard/
│       └── VisionGuard.exe # Pre-built standalone application (No Python needed!)
├── main.py                 # Main entry point for the application
├── record_test.py          # Script to generate demo videos
├── requirements.txt        # Python dependencies
└── README.md

🛠️ Getting Started

1. Clone the repository

git clone https://github.com/Mostafa23/AI-Cheating-Detection-System.git
cd AI-Cheating-Detection-System

2. Install Dependencies

Make sure you have Python 3.8+ installed, then run:

pip install -r requirements.txt

3. Setup Firebase

If you want the cloud upload feature to work, you need to link your own Firebase project:

  1. Go to your Firebase Console -> Project Settings -> Service Accounts.
  2. Click "Generate new private key".
  3. Place the downloaded .json file in the root folder of this project.

4. Run the Application

Option A: Standalone EXE (Easiest) If you are on Windows, you don't even need Python! Just navigate to dist/VisionGuard/ and double-click VisionGuard.exe.

Option B: Run from Source If you prefer running the code directly:

python main.py

🧠 Model Training

I trained the YOLO model on Kaggle using a Dual GPU (Tesla T4 x2) setup. It was trained specifically to classify behaviors into Normal vs. Cheating.


Developed by Mostafa Abdallah (2026).

About

A real-time AI desktop application that monitors students during exams, detects cheating behaviors using YOLO26, and uploads automated evidence to Firebase.

Topics

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors