How jawon02/ai works
This repository is a single-file traffic-monitoring simulator. Its workflow reads a looping video, runs YOLO detection in a background worker, filters accident detections by box overlap, overlays results for local display, and asynchronously posts an encoded frame and traffic status to a backend when available. The graph separates video/display, detection, and backend reporting responsibilities within the one source file. There is no README content; all shown relationships are supported by the excerpt from ai_simulator.py.
Main entry points: ai_simulator.py Video and Display
Components 6
Simulation
- Video and Display
ai_simulator.py
Detection
- YOLO Inference
ai_simulator.py - Overlap Filter
ai_simulator.py
Backend Reporting
- Network Sender
ai_simulator.py
Other components
- Operator
- Backend API
Connections 7
- Operator → Video and Display: starts or quits
ai_simulator.py - Video and Display → YOLO Inference: supplies frames
ai_simulator.py - YOLO Inference → Overlap Filter: filters detections
ai_simulator.py - Overlap Filter → Video and Display: updates detection state
ai_simulator.py - Video and Display → Network Sender: queues frame and status
ai_simulator.py - Network Sender → Backend API: posts telemetry
ai_simulator.py - Video and Display → Backend API: checks availability
ai_simulator.py