How visual-mellow/youtube_dataset_generation_pipeline works
This is a YouTube video dataset-generation pipeline. A user supplies links through the CLI or link CSV; the batch runner acquires and segments videos, publishes clips, then extracts VideoMAE features, computes DSP perception anchors, and generates Gemini cue annotations. Results include per-clip artifacts and merged grounding queries. The graph preserves documented high-level stages and sampled module relationships; some implementation details are based on README descriptions because their source was not excerpted.
Main entry points: build_dataset.py Feature builder · dataset_generating_pipepline/orchestrator.py Video orchestrator · anchors.py Anchor fusion · annotate/orchestrator.py Annotation orchestrator
Components 23
Intake and segmentation
- Link batch runner
dataset_generating_pipepline/run_youtube_links.py - Video orchestrator
dataset_generating_pipepline/orchestrator.py - Download and clip
dataset_generating_pipepline/video_helpers/download_and_clip.py
Feature extraction
- Clip extraction
dataset_generating_pipepline/video_helpers/video_extraction.py - Feature builder
dataset_generating_pipepline/build_dataset.py - Pipeline configuration
dataset_generating_pipepline/core/config.py
DSP perception
- Anchor fusion
dataset_generating_pipepline/perception/anchors.py - Audio onset DSP
dataset_generating_pipepline/perception/onsets_v2.py - Sound event detection
dataset_generating_pipepline/perception/sed/infer.py - Video cues
dataset_generating_pipepline/perception/video_cues.py
Cue annotation
- Annotation orchestrator
dataset_generating_pipepline/annotate/orchestrator.py - Cue proposer
dataset_generating_pipepline/annotate/proposer.py - Cue verifier
dataset_generating_pipepline/annotate/verifier.py - DSP timestamp snap
dataset_generating_pipepline/annotate/snap.py - LLM client
Utils/llm.py
Dataset outputs
- Published clips
dataset_generating_pipepline/utils/loaders.py - Clip feature artifacts
dataset_generating_pipepline/build_dataset.py - Grounding query export
dataset_generating_pipepline/video_helpers/video_extraction.py - Grounding queries
dataset_generating_pipepline/core/constants.py - Gold labels and metrics
dataset_generating_pipepline/eval
Other components
- Dataset user
- Pipeline CLI
run.py - Gemini API
Connections 21
- Dataset user → Pipeline CLI: supplies links
- Pipeline CLI → Link batch runner: starts batch
- Link batch runner → Video orchestrator: processes links
dataset_generating_pipepline/run_youtube_links.py - Video orchestrator → Download and clip: acquires video
dataset_generating_pipepline/orchestrator.py - Video orchestrator → Published clips: publishes clips
dataset_generating_pipepline/orchestrator.py - Video orchestrator → Clip extraction: extracts clips
dataset_generating_pipepline/orchestrator.py - Clip extraction → Feature builder: runs builder
dataset_generating_pipepline/video_helpers/video_extraction.py - Feature builder → Pipeline configuration: loads settings
dataset_generating_pipepline/build_dataset.py - Feature builder → Clip feature artifacts: writes features
dataset_generating_pipepline/build_dataset.py - Feature builder → Anchor fusion: computes anchors
dataset_generating_pipepline/build_dataset.py - Feature builder → Annotation orchestrator: runs annotation
dataset_generating_pipepline/build_dataset.py - Anchor fusion → Audio onset DSP: detects onsets
dataset_generating_pipepline/perception/anchors.py - Anchor fusion → Sound event detection: infers sound events
dataset_generating_pipepline/perception/anchors.py - Anchor fusion → Video cues: collects visual cues
dataset_generating_pipepline/perception/anchors.py - Annotation orchestrator → Cue proposer: requests proposals
dataset_generating_pipepline/annotate/orchestrator.py - Annotation orchestrator → Cue verifier: verifies cues
dataset_generating_pipepline/annotate/orchestrator.py - Cue verifier → DSP timestamp snap: snaps timestamps
dataset_generating_pipepline/annotate/verifier.py - Annotation orchestrator → LLM client: calls client
dataset_generating_pipepline/annotate/orchestrator.py - LLM client → Gemini API: sends requests
- Clip extraction → Grounding query export: exports queries
dataset_generating_pipepline/video_helpers/video_extraction.py - Grounding query export → Grounding queries: writes queries
dataset_generating_pipepline/video_helpers/video_extraction.py