Automatic Speech Recognition
pyannote.audio
pyannote
pyannote-audio-pipeline
audio
voice
speech
speaker
speaker-diarization
speaker-change-detection
voice-activity-detection
overlapped-speech-detection
Instructions to use tensorlake/speaker-diarization-3.1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- pyannote.audio
How to use tensorlake/speaker-diarization-3.1 with pyannote.audio:
from pyannote.audio import Pipeline pipeline = Pipeline.from_pretrained("tensorlake/speaker-diarization-3.1") # 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
Update handler.py
Browse files- handler.py +1 -1
handler.py
CHANGED
|
@@ -28,7 +28,7 @@ import torch
|
|
| 28 |
class EndpointHandler:
|
| 29 |
def __init__(self, path=""):
|
| 30 |
# initialize pretrained pipeline
|
| 31 |
-
self._pipeline = Pipeline.from_pretrained("
|
| 32 |
|
| 33 |
# send pipeline to GPU if available
|
| 34 |
if torch.cuda.is_available():
|
|
|
|
| 28 |
class EndpointHandler:
|
| 29 |
def __init__(self, path=""):
|
| 30 |
# initialize pretrained pipeline
|
| 31 |
+
self._pipeline = Pipeline.from_pretrained("tensorlake/speaker-diarization-3.1")
|
| 32 |
|
| 33 |
# send pipeline to GPU if available
|
| 34 |
if torch.cuda.is_available():
|