This repository contains the research code for LC-beating, a low-latency beat and downbeat activation estimation framework. It includes the training pipeline, evaluation utilities, neural network definitions, and reference inference code used for the corresponding paper.
The repository is released as source code only. Training datasets, generated checkpoints, logs, and audio examples are not included. Please prepare licensed beat/downbeat datasets separately and point the code to your local data directory.
.
├── networks/ # CRNN, TCN, and Transformer variants
├── param_file/ # Dataset and training configuration
├── train.py # Training / testing entry point
├── trainer.py # Training loop
├── simple_test.py # Evaluation wrapper
├── eval.py # Beat/downbeat metrics
├── inference.py # Reference realtime inference interface
└── network_infer.py # Frame-wise inference wrapper
The code was developed with Python 3.7 and PyTorch. A minimal environment can be installed with:
pip install -r requirements.txtSome legacy CRNN utilities depend on BeatNet-style log-spectrogram code. If you use those modules, set:
export BEATNET_PATH=/path/to/BeatNetThe training code expects HDF5 beat/downbeat datasets. Set the dataset root with:
export LC_BEATING_DATA_ROOT=/path/to/beat_chord_hdf5Dataset names are configured in param_file/params.py.
Example command:
python train.py \
--mode train \
--network lc42_dt_1 \
--mark round4_device1 \
--eval_mode online \
--peak_type simpleCheckpoints and TensorBoard logs are written to local output directories such as model/, model_pp/, vis_scalar/, and vis_scalar_pp/.
Use test mode with a checkpoint number:
python train.py \
--mode test \
--network lc42_dt_1 \
--mark round4_device1 \
--check_num 135 \
--eval_mode onlineinference.py provides a reference realtime interface. The public repository does not include pretrained checkpoints or demo audio; load your own trained checkpoint and licensed audio files.
If you use this code, please cite the corresponding LC-beating paper. Citation metadata will be added after publication.
This source code is released under the MIT License. See LICENSE.