A modern, beautiful web interface for vandalism detection with person and pose estimation using AI.
- 📸 Image Upload & Processing - Upload images and detect vandalism, persons, and poses
- 🎥 Video Upload & Processing - Process videos frame by frame
- 🎨 Modern UI/UX - Beautiful, responsive design with dark theme
- 📊 Confidence Threshold Control - Adjustable detection sensitivity (1-100%)
- 📁 Past Runs Gallery - View all previously processed results
- ⚡ Real-time Processing - Fast inference with YOLOv11 and MediaPipe
- Activate virtual environment:
source env/bin/activate- Install dependencies:
pip install -r requirements.txt- Ensure models are in place:
- Vandalism model:
train/weights/best.pt - Human detection model:
yolo11n.pt
- Vandalism model:
- Start the Flask server:
python app.py- Open your browser:
Navigate to
http://localhost:5000
-
Upload Media:
- Click the upload area or drag & drop an image/video file
- Supported formats: PNG, JPG, JPEG, GIF, BMP, MP4, AVI, MOV, MKV
-
Adjust Settings:
- Use the confidence slider to adjust detection sensitivity
- Lower values = more detections (may include false positives)
- Higher values = fewer detections (more strict)
-
Process:
- Click "Process" to run inference
- Results will appear below
-
View Past Runs:
- Scroll down to see gallery of all previous results
- Click any item to view full size
GET /- Main web interfacePOST /api/upload- Upload and process fileGET /api/past-runs- Get list of past resultsGET /api/results/<filename>- Download result fileGET /api/health- Health check
vandalism/
├── app.py # Flask application
├── templates/
│ └── index.html # Main HTML template
├── static/
│ ├── css/
│ │ └── style.css # Stylesheet
│ └── js/
│ └── app.js # JavaScript
├── uploads/ # Temporary upload storage
└── runs/detect/inference/ # Results storage
Graffiti detected on a brick wall with confidence scores displayed.
Detection of multiple graffiti elements with individual bounding boxes and confidence scores
Complete detection showing vandalism (red boxes), person detection (red boxes), face detection (yellow boxes), and pose estimation (skeleton overlay)
- Models are loaded lazily on first request (may take a moment)
- Uploaded files are automatically cleaned up after processing
- Results are saved in
runs/detect/inference/directory - Maximum file size: 500MB
- Models not loading: Ensure
train/weights/best.ptandyolo11n.ptexist - Port already in use: Change port in
app.py(last line) - Memory issues: Reduce video resolution or process shorter clips