Campus-wide AI surveillance system with custom YOLOv11 ANPR model, PaddleOCR text extraction, regex-based plate validation, and geospatial trajectory mining via LCS + QGIS.
University campuses process hundreds of vehicle entries daily with zero automated oversight. Security guards manually log license plates onto paper registers — a process prone to human error, impossible to audit, and blind to spatial patterns.
Key problems identified:
This was my first-ever project using YOLO, OCR, and PostgreSQL — built during my 1st year inter-college internship. The core insight was to treat this as a pipeline problem: each stage feeds the next, and each stage must independently validate its output before passing it forward.
The pipeline: Live feed → YOLO plate detection → PaddleOCR text extraction → Regex validation → Character correction → Duplicate check → PostgreSQL logging → QGIS trajectory analysis.
Every detected plate passes through regex validation against Indian number plate formats. If a match fails, the system attempts character substitution from a confusion map (0→O, 8→B, 1→l, ...) and retries. Only finalized plates get logged with a vehicle snapshot captured as identity proof.
Custom YOLO + PaddleOCR pipeline
Full control over training data, model parameters, and OCR post-processing. Allows offline operation with no API costs.
Cloud ANPR APIs (Google Vision, Plate Recognizer)
Per-request pricing is impractical for 3–8 cameras running 24/7. No control over accuracy on regional Indian plates.
Tesseract OCR
Tested extensively but accuracy on distorted, angled plate text was poor. PaddleOCR outperformed it significantly.
Custom YOLOv11 ANPR Model
Trained on a curated Roboflow dataset of Indian license plates with augmentation for varied lighting, angles, and occlusion conditions.
OCR + Regex Validation Pipeline
PaddleOCR extracts text, then regex validates against Indian plate format. A character confusion map handles common OCR misreads.
0↔O, 8↔B, 1↔l, 5↔SDuplicate Detection + Blacklist
Same vehicle detected by the same camera within a 5-minute window is flagged as duplicate. Blacklisted plates trigger immediate alerts.
LCS Trajectory Mining
Longest Common Subsequence algorithm applied to camera-ordered vehicle sightings to find the most-used paths on campus.