igitman commited on
Commit
2a7d010
1 Parent(s): 7b2859d

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +244 -0
README.md CHANGED
@@ -1,3 +1,247 @@
1
  ---
2
  license: cc-by-4.0
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: cc-by-4.0
3
  ---
4
+ language:
5
+ - it
6
+ library_name: nemo
7
+ datasets:
8
+ - facebook/voxpopuli
9
+ - facebook/multilingual_librispeech
10
+ - mozilla-foundation/common_voice_12_0
11
+ thumbnail: null
12
+ tags:
13
+ - automatic-speech-recognition
14
+ - speech
15
+ - audio
16
+ - Transducer
17
+ - FastConformer
18
+ - CTC
19
+ - Transformer
20
+ - pytorch
21
+ - NeMo
22
+ - hf-asr-leaderboard
23
+ license: cc-by-4.0
24
+ model-index:
25
+ - name: stt_it_fastconformer_hybrid_large_pc
26
+ results:
27
+ - task:
28
+ type: Automatic Speech Recognition
29
+ name: speech-recognition
30
+ dataset:
31
+ name: common-voice-12-0
32
+ type: mozilla-foundation/common_voice_12_0
33
+ config: it
34
+ split: test
35
+ args:
36
+ language: it
37
+ metrics:
38
+ - name: Test WER
39
+ type: wer
40
+ value: 5.77
41
+ - task:
42
+ type: Automatic Speech Recognition
43
+ name: automatic-speech-recognition
44
+ dataset:
45
+ name: Multilingual LibriSpeech
46
+ type: facebook/multilingual_librispeech
47
+ config: italian
48
+ split: test
49
+ args:
50
+ language: it
51
+ metrics:
52
+ - name: Test WER
53
+ type: wer
54
+ value: 11.47
55
+ - task:
56
+ type: Automatic Speech Recognition
57
+ name: speech-recognition
58
+ dataset:
59
+ name: VoxPopuli
60
+ type: facebook/voxpopuli
61
+ config: it
62
+ split: test
63
+ args:
64
+ language: it
65
+ metrics:
66
+ - name: Test WER
67
+ type: wer
68
+ value: 15.60
69
+ - task:
70
+ type: Automatic Speech Recognition
71
+ name: speech-recognition
72
+ dataset:
73
+ name: common-voice-12-0
74
+ type: mozilla-foundation/common_voice_12_0
75
+ config: it
76
+ split: test
77
+ args:
78
+ language: it
79
+ metrics:
80
+ - name: Test WER P&C
81
+ type: wer
82
+ value: 8.17
83
+ - task:
84
+ type: Automatic Speech Recognition
85
+ name: automatic-speech-recognition
86
+ dataset:
87
+ name: Multilingual LibriSpeech
88
+ type: facebook/multilingual_librispeech
89
+ config: italian
90
+ split: test
91
+ args:
92
+ language: it
93
+ metrics:
94
+ - name: Test WER P&C
95
+ type: wer
96
+ value: 22.48
97
+ - task:
98
+ type: Automatic Speech Recognition
99
+ name: speech-recognition
100
+ dataset:
101
+ name: VoxPopuli
102
+ type: facebook/voxpopuli
103
+ config: it
104
+ split: test
105
+ args:
106
+ language: it
107
+ metrics:
108
+ - name: Test WER P&C
109
+ type: wer
110
+ value: 19.55
111
+ ---
112
+ # NVIDIA FastConformer-Hybrid Large (it)
113
+
114
+ <style>
115
+ img {
116
+ display: inline;
117
+ }
118
+ </style>
119
+
120
+ | [![Model architecture](https://img.shields.io/badge/Model_Arch-FastConformer--Transducer_CTC-lightgrey#model-badge)](#model-architecture)
121
+ | [![Model size](https://img.shields.io/badge/Params-115M-lightgrey#model-badge)](#model-architecture)
122
+ | [![Language](https://img.shields.io/badge/Language-it-lightgrey#model-badge)](#datasets)
123
+
124
+
125
+ This model transcribes speech in upper and lower case Italian alphabet along with spaces, periods, commas, and question marks.
126
+ It is a "large" version of FastConformer Transducer-CTC (around 115M parameters) model. This is a hybrid model trained on two losses: Transducer (default) and CTC.
127
+ See the [model architecture](#model-architecture) section and [NeMo documentation](https://docs.nvidia.com/deeplearning/nemo/user-guide/docs/en/main/asr/models.html#fast-conformer) for complete architecture details.
128
+
129
+ ## NVIDIA NeMo: Training
130
+
131
+ To train, fine-tune or play with the model you will need to install [NVIDIA NeMo](https://github.com/NVIDIA/NeMo). We recommend you install it after you've installed latest Pytorch version.
132
+ ```
133
+ pip install nemo_toolkit['all']
134
+ ```
135
+
136
+ ## How to Use this Model
137
+
138
+ The model is available for use in the NeMo toolkit [3], and can be used as a pre-trained checkpoint for inference or for fine-tuning on another dataset.
139
+
140
+ ### Automatically instantiate the model
141
+
142
+ ```python
143
+ import nemo.collections.asr as nemo_asr
144
+ asr_model = nemo_asr.models.EncDecHybridRNNTCTCBPEModel.from_pretrained(model_name="nvidia/stt_it_fastconformer_hybrid_large_pc")
145
+ ```
146
+
147
+ ### Transcribing using Python
148
+ First, let's get a sample
149
+ ```
150
+ wget https://dldata-public.s3.us-east-2.amazonaws.com/2086-149220-0033.wav
151
+ ```
152
+ Then simply do:
153
+ ```
154
+ asr_model.transcribe(['2086-149220-0033.wav'])
155
+ ```
156
+
157
+ ### Transcribing many audio files
158
+
159
+ Using Transducer mode inference:
160
+ ```shell
161
+ python [NEMO_GIT_FOLDER]/examples/asr/transcribe_speech.py
162
+ pretrained_name="nvidia/stt_it_fastconformer_hybrid_large_pc"
163
+ audio_dir="<DIRECTORY CONTAINING AUDIO FILES>"
164
+ ```
165
+
166
+ Using CTC mode inference:
167
+ ```shell
168
+ python [NEMO_GIT_FOLDER]/examples/asr/transcribe_speech.py
169
+ pretrained_name="nvidia/stt_it_fastconformer_hybrid_large_pc"
170
+ audio_dir="<DIRECTORY CONTAINING AUDIO FILES>"
171
+ decoder_type="ctc"
172
+ ```
173
+
174
+ ### Input
175
+
176
+ This model accepts 16000 Hz Mono-channel Audio (wav files) as input.
177
+
178
+ ### Output
179
+
180
+ This model provides transcribed speech as a string for a given audio sample.
181
+
182
+ ## Model Architecture
183
+
184
+ FastConformer is an optimized version of the Conformer model [1] with 8x depthwise-separable convolutional downsampling. The model is trained in a multitask setup with joint Transducer and CTC decoder loss. You may find more information on the details of FastConformer here: [Fast-Conformer Model](https://docs.nvidia.com/deeplearning/nemo/user-guide/docs/en/main/asr/models.html#fast-conformer) and about Hybrid Transducer-CTC training here: [Hybrid Transducer-CTC](https://docs.nvidia.com/deeplearning/nemo/user-guide/docs/en/main/asr/models.html#hybrid-transducer-ctc).
185
+
186
+ ## Training
187
+
188
+ The NeMo toolkit [3] was used for training the models for over several hundred epochs. These model are trained with this [example script](https://github.com/NVIDIA/NeMo/blob/main/examples/asr/asr_hybrid_transducer_ctc/speech_to_text_hybrid_rnnt_ctc_bpe.py) and this [base config](https://github.com/NVIDIA/NeMo/blob/main/examples/asr/conf/fastconformer/hybrid_transducer_ctc/fastconformer_hybrid_transducer_ctc_bpe.yaml).
189
+
190
+ The tokenizers for these models were built using the text transcripts of the train set with this [script](https://github.com/NVIDIA/NeMo/blob/main/scripts/tokenizers/process_asr_text_tokenizer.py).
191
+
192
+ ### Datasets
193
+
194
+ The model in this collection are trained on a composite dataset (NeMo PnC IT ASRSET) comprising of 487 hours of Italian speech:
195
+
196
+ - Mozilla Common Voice 12.0 (Italian) - 220 hours after data cleaning
197
+ - Multilingual LibriSpeech (Italian) - 214 hours after data cleaning
198
+ - VoxPopuli transcribed subset (Italian) - 53 hours after data cleaning
199
+
200
+ ## Performance
201
+
202
+ The performance of Automatic Speech Recognition models is measuring using Word Error Rate. Since this dataset is trained on multiple domains and a much larger corpus, it will generally perform better at transcribing audio in general.
203
+
204
+ The following tables summarizes the performance of the available models in this collection with the Transducer decoder. Performances of the ASR models are reported in terms of Word Error Rate (WER%) with greedy decoding.
205
+
206
+
207
+ a) On data without Punctuation and Capitalization
208
+
209
+ | Decoder | MCV 12.0 Dev | MCV 12.0 Test | MLS Dev | MLS Test | VoxPopuli Dev | VoxPopuli Test |
210
+ |------------|--------------|---------------|---------|----------|---------------|----------------|
211
+ | Transducer | 5.14 | 5.68 | 13.83 | 11.71 | 12.80 | 15.72 |
212
+ | CTC | 5.64 | 6.19 | 14.60 | 12.27 | 13.43 | 16.35 |
213
+
214
+
215
+ b) On data with Punctuation and Capitalization
216
+
217
+ | Decoder | MCV 12.0 Dev | MCV 12.0 Test | MLS Dev | MLS Test | VoxPopuli Dev | VoxPopuli Test |
218
+ |------------|--------------|---------------|---------|----------|---------------|----------------|
219
+ | Transducer | 7.75 | 8.17 | 26.37 | 22.48 | 16.78 | 19.55 |
220
+ | CTC | 8.13 | 8.55 | 26.95 | 22.94 | 17.28 | 20.01 |
221
+
222
+
223
+ ## Limitations
224
+ Since this model was trained on publically available speech datasets, the performance of this model might degrade for speech which includes technical terms, or vernacular that the model has not been trained on. The model might also perform worse for accented speech. The model only outputs the punctuations: ```'.', ',', '?' ``` and hence might not do well in scenarios where other punctuations are also expected.
225
+
226
+ ## NVIDIA Riva: Deployment
227
+
228
+ [NVIDIA Riva](https://developer.nvidia.com/riva), is an accelerated speech AI SDK deployable on-prem, in all clouds, multi-cloud, hybrid, on edge, and embedded.
229
+ Additionally, Riva provides:
230
+
231
+ * World-class out-of-the-box accuracy for the most common languages with model checkpoints trained on proprietary data with hundreds of thousands of GPU-compute hours
232
+ * Best in class accuracy with run-time word boosting (e.g., brand and product names) and customization of acoustic model, language model, and inverse text normalization
233
+ * Streaming speech recognition, Kubernetes compatible scaling, and enterprise-grade support
234
+
235
+ Although this model isn’t supported yet by Riva, the [list of supported models is here](https://huggingface.co/models?other=Riva).
236
+ Check out [Riva live demo](https://developer.nvidia.com/riva#demos).
237
+
238
+ ## References
239
+ [1] [Conformer: Convolution-augmented Transformer for Speech Recognition](https://arxiv.org/abs/2005.08100)
240
+
241
+ [2] [Google Sentencepiece Tokenizer](https://github.com/google/sentencepiece)
242
+
243
+ [3] [NVIDIA NeMo Toolkit](https://github.com/NVIDIA/NeMo)
244
+
245
+ ## Licence
246
+
247
+ License to use this model is covered by the [CC-BY-4 License](https://creativecommons.org/licenses/by/4.0/legalcode) unless another License/Terms Of Use/EULA is clearly specified. By downloading the public and release version of the model, you accept the terms and conditions of the [CC-BY-4 License](https://creativecommons.org/licenses/by/4.0/legalcode).