How sathurshan03/swaratone works
SwaraTone is a lightweight audio decomposition and source-separation toolkit. Its visible entry flow accepts a file path, parses command-line options, and invokes core processing; the README identifies decomposition as the product goal. The source tree also contains WAV/MP3 handling, spectral transforms, HPSS and REPET features, reconstruction, and visualization. Several processing and format implementations are unsampled, so their connections to core processing are shown as unverified rather than asserted; edges reflect only visible calls, indexed references, or README claims.
Main entry points: coreLogic.cpp Core processing · main.cpp Application main · hpss.cpp HPSS separation · repet.cpp REPET separation
Components 23
Application entry
- Application main
src/main.cpp - Argument parsing
src/core/argParser.cpp - Core processing
src/core/coreLogic.cpp - Sample data
src/core/sampleData.cpp
Audio input
- MP3 decoding
src/audio_file/mp3/mp3.cpp - MP3 codec
src/audio_file/mp3/minimp3.h - WAV encoding
src/audio_file/wav/wav_encoding.cpp
Signal analysis
- Spectrum analysis
src/features/spectrum.cpp - Forward FFT
src/fft/fft.cpp
Separation methods
- HPSS separation
src/features/hpss.cpp - HPSS masks
src/mask/hpssMask.cpp - REPET separation
src/features/repet/repet.cpp - Beat spectrum
src/features/repet/beat_spectrum.cpp - Repeating period
src/features/repet/repeating_period.cpp - Beat soft mask
src/features/repet/beat_soft_mask.cpp
Reconstruction and display
- Signal reconstruction
src/features/signalReconstruction.cpp - Inverse FFT
src/fft/ifft.cpp - Plots and graphs
src/viz/graphs/plot.cpp - Heat-map graph
src/viz/graphs/heatMapGraph.cpp - Line graph
src/viz/graphs/lineGraph.cpp
Shared foundations
- Matrix operations
src/helper/math/matrix.hpp - Statistics helpers
src/helper/math/stats.h
Other components
- CLI user
Connections 23
- CLI user → Application main: runs
src/main.cpp - Application main → Argument parsing: parses options
src/main.cpp - Application main → Core processing: invokes processing
src/main.cpp - Application main → Sample data: imports
src/main.cpp - Core processing → MP3 decoding: uses decoder
- Core processing → WAV encoding: may decode WAV
- Core processing → Spectrum analysis: analyzes audio
- Spectrum analysis → Forward FFT: uses transform
- Core processing → HPSS separation: may separate sources
- HPSS separation → HPSS masks: applies masks
src/features/hpss.cpp - HPSS separation → Statistics helpers: computes medians
src/features/hpss.cpp - Core processing → REPET separation: may run REPET
- REPET separation → Beat spectrum: uses beat analysis
- REPET separation → Repeating period: uses period estimate
- REPET separation → Beat soft mask: uses soft mask
- Core processing → Signal reconstruction: may reconstruct
- Signal reconstruction → Inverse FFT: calls inverse transform
src/features/signalReconstruction.cpp - Core processing → Plots and graphs: may display results
- Plots and graphs → Heat-map graph: uses graph
- Plots and graphs → Line graph: uses graph
- HPSS separation → Matrix operations: operates on matrices
src/features/hpss.cpp - HPSS masks → Matrix operations: operates on matrices
- MP3 decoding → MP3 codec: uses codec