Skip to content

pengzhendong/pyannote-onnx

Repository files navigation

Speaker Diarization

pyannote-audio is an open-source toolkit written in Python for speaker diarization.

pyannote-onnx is used to convert the pretrained model defined in PyTorch into the ONNX format and then run it with ONNX Runtime (in C++ or Python).

Only Python 3.8+ is supported.

Usage

  1. Download the pretrained model from Hugging Face pyannote/segmentation-3.0.
  2. Export the pretrained model to ONNX model.
  3. Run the ONNX model with ONNX Runtime in C++ or Python.
$ pip install torch onnx https://github.com/pyannote/pyannote-audio/archive/refs/heads/develop.zip
$ python export_onnx.py pytorch_model.bin segmentation-3.0.onnx

$ pip install -r requirements.txt
$ python main.py data/test_16k.wav

About

ONNX Inference of Pyannote Segmentation

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages