How goudatharun30/active-speaker-video-reframing works
This is a local active-speaker detection and smart video-reframing application. A user submits an MP4 and chooses an aspect ratio through the web UI or CLI; orchestration analyzes audio and video, selects speakers, plans and validates crops, then renders a reframed MP4 and an auditable decision timeline. The README also describes strategy comparison, previews, downloads, and job progress. Some internal links reflect documented stages because the relevant source excerpts are incomplete; those edges cite the README.
Main entry points: analyzer.py Analysis Pass · orchestrator.py Pipeline Orchestrator · app.js Web Dashboard · api.py Web API
Components 25
User Interface
- Web Dashboard
app/ui/app.js - Web API
app/api.py - Command Line
app/cli.py
Job Workflow
- Pipeline Config
app/config.py - Job Progress
app/pipeline/job_manager.py - Pipeline Orchestrator
app/pipeline/orchestrator.py
Multimodal Analysis
- Analysis Pass
app/pipeline/analyzer.py - Audio VAD Timeline
app/audio/vad.py - Audio Extraction
app/audio/extractor.py - Video Frames And Metadata
app/video/decoder.py - Face Detection
app/video/face_detector.py - Face Tracking
app/video/face_tracker.py - Mouth Motion
app/video/landmarks.py - Speaker Scoring
app/speaker/strategies.py - Speaker State Machine
app/speaker/state_machine.py
Crop And Render
- Crop Planning
app/rendering/planner.py - Crop Geometry
app/video/crop.py - Crop Smoothing
app/rendering/smoother.py - Crop Safety Validation
app/rendering/validator.py - Render Pass
app/pipeline/renderer.py - FFmpeg Renderer
app/rendering/ffmpeg.py - Decision Timeline
app/pipeline/renderer.py - Reframed MP4
app/rendering/ffmpeg.py
Evaluation
- Strategy Comparison
app/evaluation/comparison.py
Other components
- Video User
Connections 27
- Video User → Web Dashboard: submits video
README.md - Web Dashboard → Web API: starts job
README.md - Video User → Command Line: runs process
README.md - Web API → Job Progress: creates and updates
app/api.py - Web API → Pipeline Orchestrator: runs pipeline
app/api.py - Command Line → Pipeline Orchestrator: runs pipeline
app/cli.py - Pipeline Orchestrator → Analysis Pass: analyzes video
app/pipeline/orchestrator.py - Pipeline Orchestrator → Render Pass: renders timeline
app/pipeline/orchestrator.py - Pipeline Orchestrator → Pipeline Config: uses settings
app/pipeline/orchestrator.py - Analysis Pass → Audio Extraction: extracts audio
app/pipeline/analyzer.py - Analysis Pass → Audio VAD Timeline: analyzes speech
README.md - Analysis Pass → Video Frames And Metadata: decodes frames
README.md - Analysis Pass → Face Detection: detects faces
README.md - Analysis Pass → Face Tracking: tracks faces
README.md - Analysis Pass → Mouth Motion: measures motion
README.md - Analysis Pass → Speaker Scoring: scores candidates
README.md - Analysis Pass → Speaker State Machine: selects speaker
README.md - Analysis Pass → Crop Planning: plans crops
app/pipeline/analyzer.py - Crop Planning → Crop Geometry: calculates geometry
app/rendering/planner.py - Analysis Pass → Crop Smoothing: smooths crops
app/pipeline/analyzer.py - Analysis Pass → Crop Safety Validation: validates crops
app/pipeline/analyzer.py - Render Pass → FFmpeg Renderer: renders video
app/pipeline/renderer.py - Render Pass → Decision Timeline: writes timeline
app/pipeline/renderer.py - FFmpeg Renderer → Reframed MP4: produces MP4
app/rendering/ffmpeg.py - Web Dashboard → Decision Timeline: inspects timeline
README.md - Web Dashboard → Reframed MP4: previews and downloads
README.md - Strategy Comparison → Analysis Pass: compares strategies
app/evaluation/comparison.py