xref: /aosp_15_r20/external/libopus/dnn/torch/lpcnet/README.md (revision a58d3d2adb790c104798cd88c8a3aff4fa8b82cc)
1# LPCNet
2
3Incomplete pytorch implementation of LPCNet
4
5## Data preparation
6For data preparation use dump_data in github.com/xiph/LPCNet. To turn this into
7a training dataset, copy data and feature file to a folder and run
8
9python add_dataset_config.py my_dataset_folder
10
11
12## Training
13To train a model, create and adjust a setup file, e.g. with
14
15python make_default_setup.py my_setup.yml --path2dataset my_dataset_folder
16
17Then simply run
18
19python train_lpcnet.py my_setup.yml my_output
20
21## Inference
22Create feature file with dump_data from github.com/xiph/LPCNet. Then run e.g.
23
24python test_lpcnet.py features.f32 my_output/checkpoints/checkpoint_ep_10.pth out.wav
25
26Inference runs on CPU and takes usually between 3 and 20 seconds per generated second of audio,
27depending on the CPU.
28