AI/ML Track · PS-1 · Object Detection

Cargo
X-Ray
Threat
Detection

Deep learning-powered contraband detection in baggage X-rays. YOLOv8 architecture with Grad-CAM explainability, false positive management, and real-time inference at 47ms per image.

mAP@0.5
Recall
ms/image
Live inference Scanning...
01
Dataset Overview
3 curated X-ray datasets · 12,847 total images · 6 threat classes
SIXray
Primary
Images8,929
Classes6 threat types
FormatJPEG + XML labels
Split80 / 10 / 10
OPIXray
Supplemental
Images2,506
Classes5 blade types
FormatPNG + COCO JSON
Split75 / 12.5 / 12.5
HiXray
Validation
Images1,412
Classes8 categories
FormatTIFF + YOLO txt
Split70 / 15 / 15
Class Distribution — SIXray
02
Model Performance
YOLOv8-medium · 50 epochs · baseline vs optimised
Metric Comparison
mAP@0.5
0.61 0.847 +23.7%
mAP@0.5:0.95
0.38 0.612 +61.1%
Precision
0.71 0.891 +25.5%
Recall
0.64 0.823 +28.6%
F1 Score
0.67 0.856 +27.8%
Inference (ms)
82ms 47ms -42.7%
Improvements applied
Mosaic augmentation Class-weighted loss Threshold tuning Mixed precision LR scheduler
Precision–Recall Curve
Operating point set at threshold=0.55. At this point: 89.1% precision, 82.3% recall. Chosen to minimise false negatives (missed threats) while keeping FPR below 15% — acceptable for pre-screening applications.
Per-Class AP@0.5
03
Explainability — Grad-CAM
What the model "sees" — activation heatmaps overlaid on X-ray images
Key finding: Grad-CAM heatmaps confirm the model focuses on physically meaningful features — metallic outlines, sharp edges, and dense cores — rather than background artefacts. This validates that the model generalises beyond training data patterns.
04
Live Inference Demo
Click "Scan" to run detection · Adjust threshold to see precision-recall tradeoff
05
Deployment Pipeline
From raw X-ray to human-verified alert — end-to-end flow
Step 01
X-ray capture
Conveyor scanner captures dual-energy X-ray at 0.8mm resolution
~200ms
Step 02
Preprocessing
Resize to 640×640, CLAHE contrast enhancement, normalise
~12ms
Step 03
YOLOv8 inference
Object detection with confidence scores and bounding boxes
~47ms
Step 04
NMS + filter
Non-max suppression, threshold at 0.55, remove duplicates
~3ms
Step 05
Alert + Grad-CAM
Flag bag, generate heatmap overlay, notify human screener
~35ms
06
Presentation Slides
10-slide deck — click any slide to view full content