Views
No views yet
app.py) for interactive use. To run it:1pip install -r requirements.txt
2python app.pyffmpeg, libchromaprint-tools, libsndfile1| Stage | Purpose | Output |
|---|---|---|
| 1 | Fingerprint DJ set every ~30s, identify songs via AcoustID | stage1_fingerprints.json |
| 2 | Download identified songs from YouTube, confirm identity | downloads/ + stage2_confirmed.json |
| 3 | Align original songs with DJ set to find which part is used | stage3_alignments.json |
| 4 | Detect transitions (cue-out → cue-in) using DTW path analysis | stage4_transitions.json |
| 5 | Analyze transition techniques (cut, crossfade, EQ, etc.) | stage5_analysis.json |
| — | Generate final tracklist | tracklist_final.json + tracklist.txt |
1# Clone repository
2git clone https://huggingface.co/rikhoffbauer2/dj-reproducer
3cd dj-reproducer
4
5# System dependencies (Ubuntu/Debian)
6sudo apt-get install -y libchromaprint-tools ffmpeg libsndfile1
7
8# macOS
9brew install chromaprint ffmpeg
10
11# Python dependencies
12pip install -r requirements.txt1python -m dj_reproducer.cli process \
2 --input "my_dj_set.mp3" \
3 --output-dir ./results \
4 --acoustid-key YOUR_ACOUSTID_KEY1python -m dj_reproducer.cli stage1 --input set.mp3 --acoustid-key KEY
2python -m dj_reproducer.cli stage2 --tracklist results/stage1_tracklist_raw.json --acoustid-key KEY
3python -m dj_reproducer.cli stage3 --input set.mp3 --confirmed results/stage2_confirmed.json
4python -m dj_reproducer.cli stage4 --input set.mp3 --alignments results/stage3_alignments.json
5python -m dj_reproducer.cli stage5 --input set.mp3 --transitions results/stage4_transitions.json --alignments results/stage3_alignments.jsonpython app.pylibrosa.sequence.dtw(subseq=True)) on ±30s window| File | Schema |
|---|---|
stage1_fingerprints.json | {timestamp: {offset_seconds, duration_seconds, fingerprint, acoustid_results}} |
stage1_tracklist_raw.json | {track_id: {title, artist, mbid, start_seconds, end_seconds, confidence}} |
stage2_confirmed.json | {track_id: {title, artist, youtube_url, download_path, confirmed}} |
stage3_alignments.json | {track_id: {offset_seconds, confidence, key_shift_semitones, beat_frames_mix, beat_frames_ref}} |
stage4_transitions.json | [{track_id, title, artist, type: cue_out/cue_in, timestamp_seconds, diagonal_ratio}] |
stage5_analysis.json | [{timestamp_seconds, outgoing_track, incoming_track, technique, confidence, ...}] |
tracklist_final.json | {tracks: [{number, artist, title, start, end, start_seconds, end_seconds, key_shift, transition_technique}]} |
tracklist.txt | Human-readable plain text tracklist |
dj_reproducer/
├── __init__.py
├── stage1_fingerprint.py # Windowed fpcalc + AcoustID lookup
├── stage2_acquire.py # yt-dlp download + confirmation
├── stage3_align.py # Beat-sync CENS chroma + subsequence DTW
├── stage4_transitions.py # 32-beat rolling diagonal detection
├── stage5_analyze.py # RMS/spectral comparison for technique classification
└── cli.py # Orchestration CLI
app.py # Gradio UI
requirements.txt
README.md