How rscmasword/haircut-counterpre2 works
This repository’s apparent product is a barber-shop haircut counter that analyzes video with YOLO pose tracking and chair zones, then produces counts and annotated output. It contains two Python counter versions; the newer excerpt also shows CCTV timestamp OCR and a SQLite summary store. The Next.js page is only a starter placeholder, and api.py is a separate OpenRouter example rather than part of the counting workflow. Processing orchestration and several output details are only partially excerpted, so uncertain links are omitted or marked dashed.
Main entry points: haircut_counter_v2.py Pose counter · page.tsx Starter page · api.py Reasoning API example · haircut_counter.py Legacy counter
Components 17
Video analysis
- Legacy counter
haircut_counter.py - Pose counter
haircut_counter_v2.py - Chair occupancy
haircut_counter_v2.py - Chair zones
zones.json - Tracker config
botsort_reid.yaml - Tracker config
bytetrack_no_confidence.yaml - Door zone
door_box.json - CCTV timestamp OCR
haircut_counter_v2.py
Counting and results
- Video annotation
haircut_counter_v2.py - Daily summary store
haircut_counter_v2.py - SQLite database
output/haircut_daily.db - Output files
output
Web placeholder
- Starter page
app/page.tsx - Page layout
app/layout.tsx
Other components
- Operator
- Reasoning API example
api.py - OpenRouter API
Connections 10
- Operator → Legacy counter: runs
- Operator → Pose counter: runs
- Pose counter → Chair occupancy: evaluates occupancy
haircut_counter_v2.py - Pose counter → CCTV timestamp OCR: reads timestamps
haircut_counter_v2.py - Pose counter → Video annotation: draws annotations
haircut_counter_v2.py - Pose counter → Daily summary store: stores summaries
haircut_counter_v2.py - Daily summary store → SQLite database: writes
haircut_counter_v2.py - Pose counter → Output files: writes results
- Starter page → Page layout: renders within
app/layout.tsx - Reasoning API example → OpenRouter API: calls
api.py