Inspiration

The inspiration came from a deceptively simple real-world problem: pairing vehicle “in” and “out” events using license plate images at scale. While it sounds trivial, real datasets quickly break naïve solutions—plates are blurry, occluded, duplicated, overexposed, or sometimes not readable at all. We wanted to build a system that doesn’t blindly trust OCR, doesn’t hallucinate missing data, and instead treats uncertainty as a first-class concept. PairGarage was inspired by the idea that robust systems beat clever models when dealing with messy, real-world data.

What it does

PairGarage is a GPU-accelerated vehicle pairing system that automatically identifies correct in-out vehicle image pairs from large sets of camera images. It extracts license plates using a YOLO-based detector and OCR, groups images by plate identity, and then resolves exact pairs, single occurrences, and multi-occurrence ambiguities using confidence gating, metadata signals, and OpenCV-based visual similarity. The system produces high-precision confirmed pairs, ranked outputs, and fully auditable artifacts without fabricating or guessing plate text.

How we built it

We built PairGarage as a multi-stage pipeline optimized for both speed and correctness. Images are ingested using high-throughput multithreading and decoded entirely in memory while extracting lightweight CPU-side metadata such as blur, brightness, and color statistics. Plate detection and OCR are performed on GPU using ONNX Runtime with CUDA, with strict confidence thresholds and zoom-based retries for borderline cases. Detected plates are normalized and grouped: exact pairs are locked immediately, single occurrences go through grid-based refinement, and plates appearing three or more times are resolved using metadata cues and OpenCV visual similarity instead of being discarded. A variance-based filter removes static vehicles and false positives, and all results are ranked and organized into deterministic, inspection-ready outputs.

Challenges we ran into

The biggest challenge was handling ambiguity without introducing false positives. OCR confidence alone was not sufficient, especially for repeated or partially visible plates. We also had to balance GPU throughput with recovery logic—brute-force approaches quickly became too slow or unstable. Another challenge was designing the pipeline to fail safely: deciding when to stop trying to recover information instead of forcing incorrect matches.

Accomplishments that we're proud of

In the very first pass, PairGarage extracted 817 correct pairs out of 817 from a dataset of 2000 images with zero false positives. We built a system that is not just fast, but also conservative and auditable. The pipeline successfully resolves multi-occurrence plates using visual and metadata signals instead of discarding them, and every output can be traced back to its original inputs and decisions.

What we learned

We learned that real-world computer vision systems need layered decision-making, not single-shot predictions. Treating model outputs as probabilistic signals rather than ground truth dramatically improves reliability. We also learned that combining simple metadata with visual similarity can resolve many cases that deep models alone struggle with.

What's next for PairGarage

Next, we plan to add temporal modeling across camera streams, improve visual similarity using learned embeddings, and introduce human-in-the-loop review for flagged edge cases. We also want to benchmark the system on larger, more diverse datasets and explore production deployment with real-time constraints.

Built With

Share this project:

Updates