patrickvonplaten commited on
Commit
d28dee6
1 Parent(s): 9dec1ac

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +70 -0
README.md ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: en
3
+ datasets:
4
+ - librispeech_asr
5
+ tags:
6
+ - audio
7
+ - automatic-speech-recognition
8
+ license: apache-2.0
9
+ widget:
10
+ - label: Librispeech sample 1
11
+ src: https://cdn-media.huggingface.co/speech_samples/sample1.flac
12
+ - label: Librispeech sample 2
13
+ src: https://cdn-media.huggingface.co/speech_samples/sample2.flac
14
+ ---
15
+
16
+ # UniSpeech-SAT-Base-Finetuned-100h-Libri
17
+
18
+ [Microsoft's UniSpeech](https://www.microsoft.com/en-us/research/publication/unispeech-unified-speech-representation-learning-with-labeled-and-unlabeled-data/)
19
+
20
+ A [unispeech-sat-base model]( ) that was fine-tuned on 100h hours of Librispeech on 16kHz sampled speech audio. When using the model
21
+ make sure that your speech input is also sampled at 16Khz.
22
+
23
+ The model was fine-tuned on:
24
+
25
+ - 100 hours of [LibriSpeech](https://huggingface.co/datasets/librispeech_asr)
26
+
27
+ [Paper: UNISPEECH-SAT: UNIVERSAL SPEECH REPRESENTATION LEARNING WITH SPEAKER
28
+ AWARE PRE-TRAINING](https://arxiv.org/abs/2110.05752)
29
+
30
+ Authors: Sanyuan Chen, Yu Wu, Chengyi Wang, Zhengyang Chen, Zhuo Chen, Shujie Liu, Jian Wu, Yao Qian, Furu Wei, Jinyu Li, Xiangzhan Yu
31
+
32
+ **Abstract**
33
+ *Self-supervised learning (SSL) is a long-standing goal for speech processing, since it utilizes large-scale unlabeled data and avoids extensive human labeling. Recent years witness great successes in applying self-supervised learning in speech recognition, while limited exploration was attempted in applying SSL for modeling speaker characteristics. In this paper, we aim to improve the existing SSL framework for speaker representation learning. Two methods are introduced for enhancing the unsupervised speaker information extraction. First, we apply the multi-task learning to the current SSL framework, where we integrate the utterance-wise contrastive loss with the SSL objective function. Second, for better speaker discrimination, we propose an utterance mixing strategy for data augmentation, where additional overlapped utterances are created unsupervisely and incorporate during training. We integrate the proposed methods into the HuBERT framework. Experiment results on SUPERB benchmark show that the proposed system achieves state-of-the-art performance in universal representation learning, especially for speaker identification oriented tasks. An ablation study is performed verifying the efficacy of each proposed method. Finally, we scale up training dataset to 94 thousand hours public audio data and achieve further performance improvement in all SUPERB tasks..*
34
+
35
+ The original model can be found under https://github.com/microsoft/UniSpeech/tree/main/UniSpeech-SAT.
36
+
37
+ # Usage
38
+
39
+ # Usage
40
+
41
+ To transcribe audio files the model can be used as a standalone acoustic model as follows:
42
+
43
+ ```python
44
+ from transformers import Wav2Vec2Processor, UniSpeechSatForCTC
45
+ from datasets import load_dataset
46
+ import torch
47
+
48
+ # load model and tokenizer
49
+ processor = Wav2Vec2Processor.from_pretrained("microsoft/unispeech-sat-base-100h-libri-ft")
50
+ model = UniSpeechSatForCTC.from_pretrained("microsoft/unispeech-sat-base-100h-libri-ft")
51
+
52
+ # load dummy dataset
53
+ ds = load_dataset("patrickvonplaten/librispeech_asr_dummy", "clean", split="validation")
54
+
55
+ # tokenize
56
+ input_values = processor(ds[0]["audio"]["array], return_tensors="pt", padding="longest").input_values # Batch size 1
57
+
58
+ # retrieve logits
59
+ logits = model(input_values).logits
60
+
61
+ # take argmax and decode
62
+ predicted_ids = torch.argmax(logits, dim=-1)
63
+ transcription = processor.batch_decode(predicted_ids)
64
+ ```
65
+
66
+ # License
67
+
68
+ The official license can be found [here](https://github.com/microsoft/UniSpeech/blob/main/LICENSE)
69
+
70
+ ![design](https://raw.githubusercontent.com/patrickvonplaten/scientific_images/master/UniSpeechSAT.png)