Commit
•
80304c9
1
Parent(s):
87207a2
Create README.md
Browse files
README.md
ADDED
@@ -0,0 +1,100 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: cc-by-4.0
|
3 |
+
language:
|
4 |
+
- en
|
5 |
+
pipeline_tag: summarization
|
6 |
+
tags:
|
7 |
+
- speaker embedding
|
8 |
+
- wespeaker
|
9 |
+
- speaker modelling
|
10 |
+
---
|
11 |
+
|
12 |
+
|
13 |
+
Official model provided by Wespeaker project, ResNet34 based r-vector (After large margin finetune)
|
14 |
+
|
15 |
+
![image/png](https://cdn-uploads.huggingface.co/production/uploads/63b7e3814705f0ed5d7a0b00/wXgoQOaS8TLACe85mDqcj.png)
|
16 |
+
|
17 |
+
## Model Sources
|
18 |
+
|
19 |
+
<!-- Provide the basic links for the model. -->
|
20 |
+
|
21 |
+
- **Repository:** https://github.com/wenet-e2e/wespeaker
|
22 |
+
- **Paper:** https://arxiv.org/pdf/2210.17016.pdf
|
23 |
+
- **Demo:** https://huggingface.co/spaces/wenet/wespeaker_demo
|
24 |
+
|
25 |
+
## Uses
|
26 |
+
|
27 |
+
## Results on VoxCeleb
|
28 |
+
| Model | Params | Flops | LM | AS-Norm | vox1-O-clean | vox1-E-clean | vox1-H-clean |
|
29 |
+
|:------|:------:|:------|:--:|:-------:|:------------:|:------------:|:------------:|
|
30 |
+
| ResNet34-TSTP-emb256 | 6.63M | 4.55G | × | × | 0.867 | 1.049 | 1.959 |
|
31 |
+
| | | | × | √ | 0.787 | 0.964 | 1.726 |
|
32 |
+
| | | | √ | × | 0.797 | 0.937 | 1.695 |
|
33 |
+
| | | | √ | √ | 0.723 | 0.867 | 1.532 |
|
34 |
+
|
35 |
+
## Install Wespeaker
|
36 |
+
|
37 |
+
``` sh
|
38 |
+
pip install git+https://github.com/wenet-e2e/wespeaker.git
|
39 |
+
```
|
40 |
+
|
41 |
+
for development install:
|
42 |
+
|
43 |
+
``` sh
|
44 |
+
git clone https://github.com/wenet-e2e/wespeaker.git
|
45 |
+
cd wespeaker
|
46 |
+
pip install -e .
|
47 |
+
```
|
48 |
+
|
49 |
+
|
50 |
+
### Command line Usage
|
51 |
+
|
52 |
+
``` sh
|
53 |
+
$ wespeaker -p ResNet34_download_dir --task embedding --audio_file audio.wav --output_file embedding.txt
|
54 |
+
$ wespeaker -p ResNet34_download_dir --task embedding_kaldi --wav_scp wav.scp --output_file /path/to/embedding
|
55 |
+
$ wespeaker -p ResNet34_download_dir --task similarity --audio_file audio.wav --audio_file2 audio2.wav
|
56 |
+
$ wespeaker -p ResNet34_download_dir --task diarization --audio_file audio.wav
|
57 |
+
```
|
58 |
+
|
59 |
+
### Python Programming Usage
|
60 |
+
|
61 |
+
``` python
|
62 |
+
import wespeaker
|
63 |
+
|
64 |
+
model = wespeaker.load_model_local(ResNet34_download_dir)
|
65 |
+
# set_gpu to enable the cuda inference, number < 0 means using CPU
|
66 |
+
model.set_gpu(0)
|
67 |
+
|
68 |
+
# embedding/embedding_kaldi/similarity/diarization
|
69 |
+
embedding = model.extract_embedding('audio.wav')
|
70 |
+
utt_names, embeddings = model.extract_embedding_list('wav.scp')
|
71 |
+
similarity = model.compute_similarity('audio1.wav', 'audio2.wav')
|
72 |
+
diar_result = model.diarize('audio.wav')
|
73 |
+
|
74 |
+
# register and recognize
|
75 |
+
model.register('spk1', 'spk1_audio1.wav')
|
76 |
+
model.register('spk2', 'spk2_audio1.wav')
|
77 |
+
model.register('spk3', 'spk3_audio1.wav')
|
78 |
+
result = model.recognize('spk1_audio2.wav')
|
79 |
+
```
|
80 |
+
|
81 |
+
## Citation
|
82 |
+
|
83 |
+
|
84 |
+
```bibtex
|
85 |
+
@article{zeinali2019rvector,
|
86 |
+
title={But system description to voxceleb speaker recognition challenge 2019},
|
87 |
+
author={Zeinali, Hossein and Wang, Shuai and Silnova, Anna and Mat{\v{e}}jka, Pavel and Plchot, Old{\v{r}}ich},
|
88 |
+
journal={arXiv preprint arXiv:1910.12592},
|
89 |
+
year={2019}
|
90 |
+
}
|
91 |
+
|
92 |
+
@inproceedings{wang2023wespeaker,
|
93 |
+
title={Wespeaker: A research and production oriented speaker embedding learning toolkit},
|
94 |
+
author={Wang, Hongji and Liang, Chengdong and Wang, Shuai and Chen, Zhengyang and Zhang, Binbin and Xiang, Xu and Deng, Yanlei and Qian, Yanmin},
|
95 |
+
booktitle={IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP)},
|
96 |
+
pages={1--5},
|
97 |
+
year={2023},
|
98 |
+
organization={IEEE}
|
99 |
+
}
|
100 |
+
```
|