Run this model with HF Jobs
Run hbredin/utter-project-diarization on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/hbredin/utter-project-diarization. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/hbredin/utter-project-diarization on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use hbredin/utter-project-diarization with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- pyannote.audio
How to use hbredin/utter-project-diarization with pyannote.audio:
from pyannote.audio import Pipeline pipeline = Pipeline.from_pretrained("hbredin/utter-project-diarization") # inference on the whole file pipeline("file.wav") # inference on an excerpt from pyannote.core import Segment excerpt = Segment(start=2.0, end=5.0) from pyannote.audio import Audio waveform, sample_rate = Audio().crop("file.wav", excerpt) pipeline({"waveform": waveform, "sample_rate": sample_rate}) - Notebooks
- Google Colab
- Kaggle
# load pretrained pipeline
from pyannote.audio import Pipeline
pipeline = Pipeline.from_pretrained('hbredin/utter-project-diarization')
# send it to MPS device (on Apple Silicon)
import torch
mps = torch.device('mps')
pipeline.to(mps)
# apply it on sample file
from pyannote.audio.sample import SAMPLE_FILE
diarization = pipeline(SAMPLE_FILE)
# print output
print(diarization)
# [ 00:00:06.730 --> 00:00:07.185] A 1
# [ 00:00:07.590 --> 00:00:08.316] B 1
# [ 00:00:08.316 --> 00:00:09.852] C speaker90
# [ 00:00:09.852 --> 00:00:09.902] D 1
# [ 00:00:09.902 --> 00:00:10.982] E speaker91
# [ 00:00:10.459 --> 00:00:10.527] F 1
# [ 00:00:10.527 --> 00:00:14.729] G speaker90
# [ 00:00:14.307 --> 00:00:17.884] H speaker91
# [ 00:00:18.019 --> 00:00:21.495] I 3
# [ 00:00:18.239 --> 00:00:18.374] J speaker91
# [ 00:00:21.765 --> 00:00:28.515] K speaker91
# [ 00:00:27.824 --> 00:00:29.984] L speaker90
# compute diarization error rate
from pyannote.metrics.diarization import DiarizationErrorRate
metric = DiarizationErrorRate()
metric(SAMPLE_FILE['annotation'], diarization, detailed=True)
# {'missed detection': 0.6146562499999995,
# 'correct': 19.108875,
# 'false alarm': 0.48028125,
# 'confusion': 4.626468749999998,
# 'total': 24.349999999999998,
# 'diarization error rate': 0.23496534907597527}
- Downloads last month
- 5
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support