Korean version: README.ko.md
This project investigates whether a basketball video clip can be used to verify 3-point shooting information per shooter:
- who took the shot;
- when the shot happened;
- how many 3-point attempts were taken;
- whether each attempt was made or missed;
- how many 3-point points each shooter scored.
This is still a research and clarification project, not a finished video analysis app. A small context-only baseline exists, but it does not read video frames yet.
Status as of 2026-06-14:
| Area | Status | Evidence |
|---|---|---|
| Phase 1: clarify and measure | In progress | PROGRESS.md records the self-resolve replan as mostly complete. The remaining gate is G4 made/missed oracle measurement. |
| Phase 2: decide | Drafted, not ratified | docs/decisions/001-006 are proposed technical decisions. docs/decisions/007-documentation-structure.md is accepted. Phase 2 is still blocked on Phase 1 exit. |
| Phase 3: build | Not started | No production video pipeline, app shell, or stable JSON output schema has been scaffolded. |
| Context-only baseline | Available | simple_context_baseline/ tests shooter attribution and stats from JSON context data, not from raw video. |
The most important open item is G4 made/missed: made/missed means deciding whether the ball went in. The project rule is that G4 may be deferred to v2 only after a measured spike records numbers and an explicit verdict.
- init.agent.md is the runtime source of truth for the project.
- PROGRESS.md tracks milestone and session status.
- todos.md tracks current work and blocked Phase 2/Phase 3 backlog.
- open_questions.md preserves the external-reviewer question set and interim self-resolution notes.
- docs/actives/self-resolve-replan/ contains the active Phase 1 replan, assumptions, probes, oracle design, and handoffs.
- docs/decisions/ contains proposed and accepted decision records.
- experiments/ contains Phase 1 spike code and results.
- learning/ contains the stack-agnostic learning path.
- simple_context_baseline/ contains the only runnable prototype currently in the repo.
Do not edit init.me.md. It is the original user seed and is kept read-only.
The diagram below is the current target shape, not a committed implementation.
Architecture choices still need Phase 2 ratification through docs/decisions/.
flowchart LR
A[Video clip] --> B[Oracle or tracking data]
B --> C[G1: shot event time]
B --> D[G2: shooter identity]
B --> E[G3: 3-point eligibility]
B --> F[G4: made or missed]
C --> G[Per-shooter 3pt stats]
D --> G
E --> G
F --> G
Key terms:
- Oracle: a hand-labeled reference dataset used to judge whether the system is correct.
- Tracking: following a person or object across video frames.
- Re-identification: deciding that a person in one frame is the same person in another frame. This project assumes player re-identification is already perfect.
- Pose estimation: detecting body keypoints such as wrists, knees, and shoulders.
- Homography: a perspective transform that maps court points in the video to a flat court coordinate system.
The current runnable code is a context-only baseline. It accepts JSON context signals and returns per-player 3-point stats. It is useful for testing the data contract before video processing exists.
Run the baseline from the repo root:
python3 simple_context_baseline/context_baseline.py \
simple_context_baseline/sample_context.jsonRun its regression test:
python3 -m unittest simple_context_baseline.test_context_baselineRun the local browser app:
python3 simple_context_baseline/frontapp.pyThen open http://127.0.0.1:8765.
There is no final output schema yet. The shape below is a learning target for Phase 2, not a stable contract.
Input concept:
sample-video.mp4
sample-video.oracle.json
Target output concept:
{
"clip_id": "sample-video",
"shooters": [
{
"player_id": "player_07",
"attempts": [
{
"event_time_s": 12.4,
"frame_range": [360, 388],
"is_three_point": true,
"made": false,
"verdict": {
"g1_event": "pass",
"g2_shooter": "pass",
"g3_three_point": "pass",
"g4_made_missed": "defer-to-v2"
}
}
],
"three_point_attempts": 1,
"three_point_made": 0,
"three_point_points": 0
}
]
}| Topic | Current project position |
|---|---|
| Tracking | Proposed: CAMELTrack plus pre-trained YOLOX, with TrackID3x3 rule-based cleanup. |
| Pose | Proposed: RTMPose-m through rtmlib; it improved multi-player detection over the MediaPipe baseline but remains a measured compromise. |
| Court geometry | Proposed: 4-corner homography from TrackID3x3 court keypoints, avoiding per-clip manual arc annotation. |
| Event detection | Proposed V0 path: use oracle shot timestamps first, then add a pose-release detector later. |
| Shooter attribution | Proposed: 5-feature hand-crafted score and windowed argmax around each shot. |
| Made/missed | Proposed: measure once against the oracle, then either accept a v1 path or explicitly defer to v2. |
| Documentation | Accepted: root README plus the learning/ folder as the pedagogical layer. Current entry points are English README.md plus Korean README.ko.md. |
Read in this order:
- init.agent.md - runtime source of truth for the project.
- PROGRESS.md - current phase and milestone status.
- docs/actives/self-resolve-replan/README.md - current Phase 1 plan.
- docs/actives/self-resolve-replan/assumptions-and-probes.md - how the 12 external-reviewer questions were converted into assumptions or probes.
- docs/actives/self-resolve-replan/oracle-design.md - planned hand-labeled reference data.
- docs/decisions/ - proposed and accepted decision records.
- simple_context_baseline/README.md - the runnable context-only baseline.
- experiments/ - Phase 1 spike code and results.
- learning/README.md - learning path for Python and computer-vision basics.
- Document the problem, decision, or finding before writing implementation code.
- Do not treat spike scripts under
experiments/as accepted architecture. - Do not scaffold a production app before Phase 2 decision records are accepted.
- Keep changes scoped. Existing dirty files may belong to another session.
- Use relative Markdown links.
The following are intentionally not available yet:
- one-command project install;
- one-command video inference;
- production frontend or web UI;
- production deployment;
- stable JSON schema;
- automatic made/missed classifier;
- end-to-end video-to-stats test.
Those belong to Phase 2 and Phase 3 after the current research gates close.