--- title: FencingScoreDetector emoji: ⚡ colorFrom: pink colorTo: yellow sdk: gradio sdk_version: 5.49.0 app_file: app.py pinned: false license: mit --- # 🤺 Fencing Score Detector This Space detects scoring touches in fencing bout videos using: - **YOLOv8** for scoreboard detection - **AutoGluon Tabular** for illuminated light classification - **Gradio** for a clean web UI - Automatic video clipping of ~4s highlight reels around each detected touch --- ## How it Works 1. Upload a fencing bout video. 2. The system splits it into frames and uses YOLOv8 to detect the scoreboard. 3. Frames are masked to grayscale except for the scoreboard region. 4. AutoGluon classifies whether the scoreboard light is illuminated. 5. When a touch is detected, the app cuts a short video clip (2s before and after the event). 6. All clips are displayed in a gallery. --- ## Demo Features - Smooth progress bar with a 🤺 fencer marching along while processing. - Debugging mode available to save masked frames and predictor scores. - Clips labeled with event timestamp. --- ## Running Locally Clone the repo and install dependencies: ```bash git clone cd pip install -r requirements.txt Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference