Skip to content

SmartLane AI is an advanced AI-powered traffic management system that analyzes 4-way intersections using YOLOv8 vehicle detection and a CNN-based emergency vehicle classifier. The platform identifies traffic density, detects ambulances through multi-layer emergency recognition (YOLO + Color Pattern + Text + CNN), and automatically adjusts signals.

Notifications You must be signed in to change notification settings

lovnishverma/SMARTLANE-AI

title emoji colorFrom colorTo sdk app_port tags pinned short_description license
SourceCode
πŸ‘€
red
red
streamlit
8501
streamlit
false
Paranox 2.0 Hackathon
mit

image

🚦 SmartLane AI – Intelligent Traffic & Emergency Vehicle Management System

πŸ“… Date: November 16, 2025
🏁 Event: TechXNinjas – PARANOX 2.0 (3-Month National Level Innovation + 24-Hour Build Hackathon)
πŸ‘₯ Team: Team SourceCode
🌍 Live Demo: https://paranox-sourcecode.hf.space
🧠 CNN Model Training Notebook: https://colab.research.google.com/drive/1v-TD755AdnonZuIX0nXLbM2DvF281xiu?usp=sharing


πŸ”₯ About SmartLane AI

SmartLane AI is an AI-powered Traffic Intelligence Platform designed to optimize 4-way traffic intersections using:

🚘 YOLOv8 Object Detection
πŸš‘ Multimodal Ambulance/Emergency Vehicle Detection
🎯 CNN Deep Learning Classification
πŸ“Š Real-Time Traffic Analytics & Signal Time Optimization

It automatically prioritizes emergency vehicles (Ambulance) by extending green light duration and clearing the lane using a multi-method decision model:

Detection Layers (Priority Order)
1️⃣ Manual Override Control
2️⃣ YOLO + Color Signature Analysis
3️⃣ CNN Ambulance Classifier
4️⃣ Red/White Pattern Recognition
5️⃣ Emergency Text/OCR Pattern Detection

πŸ§ͺ Live Demo & Results

πŸ”— Live Web App: https://paranox-sourcecode.hf.space
πŸ“Œ Upload four road images (North, East, South, West) β†’ SmartLane AI detects vehicle density and prioritizes emergency lanes.


🎯 Key Features

Feature Description
πŸš— Vehicle Detection YOLOv8 counts Cars, Buses, Trucks, Motorcycles
πŸš‘ Emergency Recognition CNN + YOLO + Color + Text Pattern Fusion
🚦 Adaptive Traffic Signal Control AI-driven timing & clearance logic
🟒 Emergency Priority Mode Automatically extends green light (35s)
πŸ“Š Traffic Intelligence Dashboard Vehicle matrix, charts, priority rankings
πŸ“₯ Export Reports Download .txt traffic analysis summary

πŸ›  Technology Stack

Category Tools
AI / CV Models YOLOv8, TensorFlow CNN
Framework Streamlit
Language Python
Visualization Matplotlib, Pandas
Image Processing OpenCV, PIL

πŸ“¦ Project Structure


SMARTLANE-AI/
β”‚
β”œβ”€β”€ app.py                      # Main Streamlit Application
β”œβ”€β”€ ambulance_cnn_final.keras   # Trained CNN Model
β”œβ”€β”€ model/                      # Additional model assets (optional)
β”‚   └── classes.txt
β”œβ”€β”€ README.md
└── requirements.txt


βš™οΈ Installation & Setup

1️⃣ Clone the repository

git clone https://github.com/lovnishverma/SMARTLANE-AI.git
cd SMARTLANE-AI

2️⃣ Install dependencies

pip install -r requirements.txt

3️⃣ Run SmartLane AI

streamlit run app.py

🧠 CNN Ambulance Classifier

The system includes a custom-trained CNN for Ambulance vs Non-Ambulance classification.

πŸ“Œ Training Notebook (Google Colab): ➑ https://colab.research.google.com/drive/1v-TD755AdnonZuIX0nXLbM2DvF281xiu?usp=sharing

Model Summary:

  • Input: 192Γ—192 RGB Image
  • Output: Softmax (Ambulance / Non-Ambulance)
  • Accuracy: β‰ˆ 99.2% on Validation

🚦 AI Signal Timing Logic

Condition Green Time
Emergency Vehicle ⏱ 35 seconds
Normal Traffic Base ⏱ 5 seconds
Extra Time βž•1 sec / 2 vehicles
Max Green ⏳ 25 seconds

πŸ“ Hackathon Overview (PARANOX 2.0)

PARANOX 2.0 is a 3-month national-level innovation event + 24-hour build hackathon where students BUILD Β· PITCH Β· WIN by converting their prototypes into real-world products. SmartLane AI was developed in this challenge under TechXNinjas.


πŸ‘¨β€πŸ’» Team SourceCode

Member Role
πŸ‘‘ Lovnish Verma Lead Developer / ML Engineer
🧠 Chandan Saroj Computer Vision & CNN Training
⚑ Prateek Dhar Dwivedi UI/UX & Streamlit Integration
πŸ›° Aman Choudhary Deployment & Optimization

Want to join or collaborate? PRs are welcome!


πŸ›‘ License

This project is licensed under MIT License. You are free to modify and use with attribution.


⭐ Support the Project

If you find this useful, please star the repo:

πŸ‘‰ https://github.com/lovnishverma/SMARTLANE-AI 🌟


πŸ“ž Contact / Connect

For research or collaboration inquiries:

πŸ“§ Email: [email protected] 🌐 GitHub: https://github.com/lovnishverma πŸ”— LinkedIn: https://www.linkedin.com/in/lovnishverma/


🚦 SmartLane AI

Transforming traffic. Saving lives. Intelligent cities start here.

About

SmartLane AI is an advanced AI-powered traffic management system that analyzes 4-way intersections using YOLOv8 vehicle detection and a CNN-based emergency vehicle classifier. The platform identifies traffic density, detects ambulances through multi-layer emergency recognition (YOLO + Color Pattern + Text + CNN), and automatically adjusts signals.

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages