Authors: Rishab Bohra, Shashank Shashidhar, Ebin Royce, Suhas Ungarala, Muhammed Shahbas V S
State-of-the-art object detectors such as Deformable DETR achieve high accuracy but are computationally expensive and memory-heavy. This limits deployment on edge devices and real-time systems.
This project explores pruning techniques (structured filter pruning and unstructured weight pruning) to compress Deformable DETR while analyzing the trade-off between accuracy, speed, and model size.
- Faster convergence vs. DETR
- Better handling of small objects
- Key innovation: Multi-Scale Deformable Attention
- Architecture: ResNet-50 + FPN backbone, Transformer Encoder/Decoder, prediction heads
- Structured Filter Pruning – removes filters based on L1-norm
- Unstructured Weight Pruning – removes individual low-magnitude weights
Dataset: KITTI Object Detection (Cars, Pedestrians, Cyclists)
Preprocessing: Converted KITTI .txt
annotations → COCO JSON format
Baseline Model: Deformable DETR (ResNet-50 backbone) trained in MMDetection
Pruning Experiments:
- Filter pruning (10–50%)
- Weight pruning (10–90%)
Accuracy: mAP, mAP50, per-class AP
Efficiency: Inference latency (CPU/GPU), FLOPs
Model Size: Parameters, checkpoint size, compression ratio
- mAP ≈ 0.117
- Latency ~205 ms
- ~205 GFLOPs
- Severe accuracy collapse (>20%)
- ~24% FLOP reduction at 50% pruning
- Minor runtime gain
- Better robustness at 30–40% sparsity
- Sharp collapse beyond 50–70%
- Reduced storage but no speedup
Filter Pruning → Least robust, fast accuracy collapse
Weight Pruning → Good storage reduction, no latency gain
Pruning Deformable DETR is challenging due to its sensitivity.
- Structured Filter Pruning → Poor trade-off
- Unstructured Weight Pruning → Storage benefit only
The analysis reveals that while both pruning methods achieve compression, each comes with distinct limitations. Filter pruning shows rapid accuracy degradation, while weight pruning provides storage benefits without inference speedup.
torch_filter_pruning_final.ipynb
→ Structured Filter Pruning experimentstraining+unstructured_weight_pruning.ipynb
→ Unstructured Weight Pruning experimentsREADME.md
→ Project summary (this file)