Upload 2 files
Browse files- README.md +50 -0
- config.yaml +7 -0
README.md
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
tags:
|
| 3 |
+
- pyannote
|
| 4 |
+
- pyannote-audio
|
| 5 |
+
- pyannote-audio-pipeline
|
| 6 |
+
- audio
|
| 7 |
+
- voice
|
| 8 |
+
- speech
|
| 9 |
+
- speaker
|
| 10 |
+
- speaker-diarization
|
| 11 |
+
- speaker-change-detection
|
| 12 |
+
- voice-activity-detection
|
| 13 |
+
- overlapped-speech-detection
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
# `Precision-2` speaker diarization (cloud)
|
| 17 |
+
|
| 18 |
+
This pipeline runs `Precision-2` speaker diarization on [pyannoteAI](https://www.pyannote.ai) cloud.
|
| 19 |
+
[Read the announcement blog post](https://www.pyannote.ai/blog/precision-2).
|
| 20 |
+
|
| 21 |
+
This pipeline is a stripped down version of pyannoteAI SDK that provides much more features:
|
| 22 |
+
* speaker diarization optimized for speech-to-text
|
| 23 |
+
* speaker voiceprinting and identification
|
| 24 |
+
* confidence scores
|
| 25 |
+
* and more...
|
| 26 |
+
|
| 27 |
+
Visit [`docs.pyannote.ai`](https://docs.pyannote.ai) to know more.
|
| 28 |
+
|
| 29 |
+
## Setup
|
| 30 |
+
|
| 31 |
+
1. `pip install pyannote.audio`
|
| 32 |
+
2. Create an API key on [`pyannoteAI` dashboard](https://dashboard.pyannote.ai) (free credits included)
|
| 33 |
+
|
| 34 |
+
## Usage
|
| 35 |
+
|
| 36 |
+
```python
|
| 37 |
+
# initialize speaker diarization pipeline
|
| 38 |
+
from pyannote.audio import Pipeline
|
| 39 |
+
pipeline = Pipeline.from_pretrained(
|
| 40 |
+
'pyannote/speaker-diarization-precision-2',
|
| 41 |
+
token="{pyannoteAI-api-key}")
|
| 42 |
+
|
| 43 |
+
output = pipeline("/path/to/audio.wav") # runs on pyannoteAI cloud
|
| 44 |
+
for turn, _, speaker in output.speaker_diarization.itertracks(yield_label=True):
|
| 45 |
+
print(f"start={turn.start:.1f}s stop={turn.end:.1f}s speaker_{speaker}")
|
| 46 |
+
```
|
| 47 |
+
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
|
config.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
dependencies:
|
| 2 |
+
pyannote.audio: 4.0.0
|
| 3 |
+
|
| 4 |
+
pipeline:
|
| 5 |
+
name: pyannote.audio.pipelines.pyannoteai.sdk.SDK
|
| 6 |
+
params:
|
| 7 |
+
model: precision-2
|