How the AI Actually Counts Cars
Four systems work together every round: detection, tracking, streaming, and fairness. Here's what happens in those 55 seconds — frame by frame.
1. Computer Vision Pipeline
Detection — What's on the road?
Every frame from the CCTV camera — 30 of them per second — gets fed through a Convolutional Neural Network. Think of it as a pattern-matching brain trained on millions of traffic images from every condition: sunny afternoons, rainy nights, foggy mornings, and glare-blasted sunsets.
The model classifies what it sees: car, truck, bus, motorbike, bicycle, pedestrian. Each object type gets a bounding box — a rectangle drawn around it in the frame. This happens in under 100 milliseconds per frame on GPU clusters, fast enough to keep up with real-time traffic.
30 fps
Frame rate
Every frame analyzed
<100ms
Inference time
Per frame on GPU
6+
Object classes
Cars, trucks, buses, bikes, pedestrians
2. Object Tracking
Counting — How many crossed the line?
Detection tells you what's in the frame. Tracking tells you where it's going. Rush Hour uses Kalman filtering — a mathematical prediction model that estimates where each vehicle will be in the next frame based on its speed and direction.
Why does this matter? Because a car moving at 40 km/h appears in ~15 consecutive frames. Without tracking, the AI would count that car 15 times. Kalman filters assign each object a unique ID and follow it across frames. The count increments only once — when the object crosses a virtual counting line drawn across the road.
When vehicles overlap (a bus blocking a car behind it), deep learning Re-Identification (ReID) kicks in. It recognizes the car by its visual features even after temporary occlusion. Same car before the bus, same car after — one count, not two.
3. Edge Cases
What happens when conditions aren't perfect?
Night Time
Headlights create glare and shadows. The model is trained on night footage from all 6 cities. Infrared-capable cameras in some locations provide additional data. Accuracy drops ~3% at night.
Rain & Fog
Water droplets on the lens, reduced visibility, headlight reflections on wet roads. The AI uses temporal consistency — if an object was tracked for 10 frames before rain blur, it maintains the ID.
Heavy Traffic (Gridlock)
When vehicles are bumper-to-bumper, occlusion is constant. The system relies on ReID and partial detections. If less than 30% of a vehicle is visible, it trusts the Kalman prediction.
Road Works / Accidents
Unusual patterns (stopped traffic, emergency vehicles) trigger the outlier detection system. Rounds flagged as anomalous are reviewed. The threshold adjusts or the round is voided.
4. Live Streaming
Delivery — Getting the feed to your screen
What good is real-time counting if the video arrives 5 seconds late? Rush Hour uses Dolby Millicast — a WebRTC-based streaming platform that delivers sub-second latency worldwide. When you see a car cross the zone on your screen, it's happening now, not 3 seconds ago.
Adaptive bitrate adjusts video quality based on your connection speed. Slow mobile data? You get a lower resolution stream that still plays smoothly. Fast WiFi? Full HD. The counting overlay is synchronized server-side, so even if your video buffers momentarily, the count displayed is always the true real-time count.
5. Fairness Engine
Normalization — Keeping the game balanced
Tokyo rush hour sees 40+ vehicles per minute. Sydney at 3 AM sees 2. Without normalization, betting on "over 5" would be trivial in Tokyo and nearly impossible in late-night Sydney. The fairness engine fixes this.
Historical density data — millions of data points per camera per hour — sets dynamic thresholds. The Over/Under line for Tokyo 8:00 AM is very different from Sydney 2:00 AM. This is how the house edge is built: not by manipulating the count, but by calibrating the threshold so that Over and Under are close to 50/50 with a slight mathematical advantage to the house.
The key insight:
The house edge in Rush Hour comes from threshold math — not outcome manipulation. The AI counts what it sees. The fairness engine decides what number you're betting against. Nobody controls the traffic. The math controls the game.
6. Accuracy & Audit
How precise is the count?
In controlled testing, the AI achieves 97-99% accuracy in daytime clear conditions. Night accuracy drops to ~94-96%. Heavy rain or fog: ~92-95%. These numbers come from comparing AI counts to manual human counts on the same footage.
Every round generates a full audit log: camera ID, city, timestamp, threshold, AI count, all bet outcomes. These logs are retained and can be reviewed. Rounds flagged by the outlier detection system (unusual patterns like road closures or accidents) are marked and may be voided if the count is unreliable.
97-99%
Daytime, clear
94-96%
Night
92-95%
Rain / fog