Spaces:
Sleeping
Sleeping
update
Browse files- examples.py +1 -382
- main.py +13 -0
examples.py
CHANGED
|
@@ -3,393 +3,12 @@
|
|
| 3 |
|
| 4 |
|
| 5 |
examples = [
|
| 6 |
-
[
|
| 7 |
-
"Chinese+English",
|
| 8 |
-
"csukuangfj/sherpa-onnx-streaming-zipformer-bilingual-zh-en-2023-02-20",
|
| 9 |
-
"greedy_search",
|
| 10 |
-
4,
|
| 11 |
-
"Yes",
|
| 12 |
-
"./data/test_wavs/tal_csasr/0.wav",
|
| 13 |
-
],
|
| 14 |
-
[
|
| 15 |
-
"Chinese+English+Cantonese",
|
| 16 |
-
"csukuangfj/sherpa-onnx-paraformer-trilingual-zh-cantonese-en",
|
| 17 |
-
"greedy_search",
|
| 18 |
-
4,
|
| 19 |
-
"Yes",
|
| 20 |
-
"./data/test_wavs/cantonese/2.wav",
|
| 21 |
-
],
|
| 22 |
-
[
|
| 23 |
-
"Cantonese",
|
| 24 |
-
"zrjin/icefall-asr-mdcc-zipformer-2024-03-11",
|
| 25 |
-
"greedy_search",
|
| 26 |
-
4,
|
| 27 |
-
"Yes",
|
| 28 |
-
"./data/test_wavs/cantonese/1.wav",
|
| 29 |
-
],
|
| 30 |
-
[
|
| 31 |
-
"English",
|
| 32 |
-
"whisper-base.en",
|
| 33 |
-
"greedy_search",
|
| 34 |
-
4,
|
| 35 |
-
"Yes",
|
| 36 |
-
"./data/test_wavs/librispeech/1089-134686-0001.wav",
|
| 37 |
-
],
|
| 38 |
-
[
|
| 39 |
-
"Chinese",
|
| 40 |
-
"csukuangfj/sherpa-onnx-paraformer-zh-2024-03-09",
|
| 41 |
-
"greedy_search",
|
| 42 |
-
4,
|
| 43 |
-
"Yes",
|
| 44 |
-
"./data/test_wavs/paraformer-zh/四川话.wav",
|
| 45 |
-
],
|
| 46 |
-
[
|
| 47 |
-
"Russian",
|
| 48 |
-
"alphacep/vosk-model-ru",
|
| 49 |
-
"greedy_search",
|
| 50 |
-
4,
|
| 51 |
-
"No",
|
| 52 |
-
"./data/test_wavs/russian/russian-i-love-you.wav",
|
| 53 |
-
],
|
| 54 |
-
[
|
| 55 |
-
"Russian",
|
| 56 |
-
"alphacep/vosk-model-ru",
|
| 57 |
-
"greedy_search",
|
| 58 |
-
4,
|
| 59 |
-
"No",
|
| 60 |
-
"./data/test_wavs/russian/test.wav",
|
| 61 |
-
],
|
| 62 |
-
[
|
| 63 |
-
"German",
|
| 64 |
-
"csukuangfj/wav2vec2.0-torchaudio",
|
| 65 |
-
"greedy_search",
|
| 66 |
-
4,
|
| 67 |
-
"No",
|
| 68 |
-
"./data/test_wavs/german/20170517-0900-PLENARY-16-de_20170517.wav",
|
| 69 |
-
],
|
| 70 |
-
[
|
| 71 |
-
"Arabic",
|
| 72 |
-
"AmirHussein/icefall-asr-mgb2-conformer_ctc-2022-27-06",
|
| 73 |
-
"greedy_search",
|
| 74 |
-
4,
|
| 75 |
-
"No",
|
| 76 |
-
"./data/test_wavs/arabic/a.wav",
|
| 77 |
-
],
|
| 78 |
-
[
|
| 79 |
-
"Tibetan",
|
| 80 |
-
"syzym/icefall-asr-xbmu-amdo31-pruned-transducer-stateless7-2022-12-02",
|
| 81 |
-
"greedy_search",
|
| 82 |
-
4,
|
| 83 |
-
"No",
|
| 84 |
-
"./data/test_wavs/tibetan/a_0_cacm-A70_31117.wav",
|
| 85 |
-
],
|
| 86 |
-
[
|
| 87 |
-
"French",
|
| 88 |
-
"shaojieli/sherpa-onnx-streaming-zipformer-fr-2023-04-14",
|
| 89 |
-
"greedy_search",
|
| 90 |
-
4,
|
| 91 |
-
"No",
|
| 92 |
-
"./data/test_wavs/french/common_voice_fr_19364697.wav",
|
| 93 |
-
],
|
| 94 |
-
[
|
| 95 |
-
"Chinese",
|
| 96 |
-
"desh2608/icefall-asr-alimeeting-pruned-transducer-stateless7",
|
| 97 |
-
"greedy_search",
|
| 98 |
-
4,
|
| 99 |
-
"Yes",
|
| 100 |
-
"./data/test_wavs/alimeeting/R8003_M8001-8004-165.wav",
|
| 101 |
-
],
|
| 102 |
-
[
|
| 103 |
-
"Chinese",
|
| 104 |
-
"csukuangfj/sherpa-onnx-paraformer-zh-2024-03-09",
|
| 105 |
-
"greedy_search",
|
| 106 |
-
4,
|
| 107 |
-
"Yes",
|
| 108 |
-
"./data/test_wavs/paraformer-zh/天津话.wav",
|
| 109 |
-
],
|
| 110 |
[
|
| 111 |
"Chinese",
|
| 112 |
"csukuangfj/sherpa-onnx-paraformer-zh-2024-03-09",
|
| 113 |
"greedy_search",
|
| 114 |
4,
|
| 115 |
"Yes",
|
| 116 |
-
"./data/test_wavs/paraformer-zh
|
| 117 |
-
],
|
| 118 |
-
[
|
| 119 |
-
"Chinese",
|
| 120 |
-
"desh2608/icefall-asr-alimeeting-pruned-transducer-stateless7",
|
| 121 |
-
"greedy_search",
|
| 122 |
-
4,
|
| 123 |
-
"Yes",
|
| 124 |
-
"./data/test_wavs/alimeeting/R8008_M8013-8049-74.wav",
|
| 125 |
-
],
|
| 126 |
-
[
|
| 127 |
-
"Chinese",
|
| 128 |
-
"desh2608/icefall-asr-alimeeting-pruned-transducer-stateless7",
|
| 129 |
-
"greedy_search",
|
| 130 |
-
4,
|
| 131 |
-
"Yes",
|
| 132 |
-
"./data/test_wavs/alimeeting/R8009_M8020_N_SPK8026-8026-209.wav",
|
| 133 |
-
],
|
| 134 |
-
[
|
| 135 |
-
"English",
|
| 136 |
-
"videodanchik/icefall-asr-tedlium3-conformer-ctc2",
|
| 137 |
-
"greedy_search",
|
| 138 |
-
4,
|
| 139 |
-
"Yes",
|
| 140 |
-
"./data/test_wavs/tedlium3/DanBarber_2010-219.wav",
|
| 141 |
-
],
|
| 142 |
-
[
|
| 143 |
-
"English",
|
| 144 |
-
"whisper-base.en",
|
| 145 |
-
"greedy_search",
|
| 146 |
-
4,
|
| 147 |
-
"Yes",
|
| 148 |
-
"./data/test_wavs/tedlium3/DanielKahneman_2010-157.wav",
|
| 149 |
-
],
|
| 150 |
-
[
|
| 151 |
-
"English",
|
| 152 |
-
"videodanchik/icefall-asr-tedlium3-conformer-ctc2",
|
| 153 |
-
"greedy_search",
|
| 154 |
-
4,
|
| 155 |
-
"Yes",
|
| 156 |
-
"./data/test_wavs/tedlium3/RobertGupta_2010U-15.wav",
|
| 157 |
-
],
|
| 158 |
-
# librispeech
|
| 159 |
-
# https://huggingface.co/csukuangfj/icefall-asr-librispeech-pruned-transducer-stateless5-2022-05-13/tree/main/data/test_wavs
|
| 160 |
-
[
|
| 161 |
-
"English",
|
| 162 |
-
"csukuangfj/icefall-asr-librispeech-pruned-transducer-stateless3-2022-05-13",
|
| 163 |
-
"greedy_search",
|
| 164 |
-
4,
|
| 165 |
-
"Yes",
|
| 166 |
-
"./data/test_wavs/librispeech/1089-134686-0001.wav",
|
| 167 |
-
],
|
| 168 |
-
[
|
| 169 |
-
"English",
|
| 170 |
-
"csukuangfj/icefall-asr-librispeech-pruned-transducer-stateless3-2022-05-13",
|
| 171 |
-
"greedy_search",
|
| 172 |
-
4,
|
| 173 |
-
"Yes",
|
| 174 |
-
"./data/test_wavs/librispeech/1221-135766-0001.wav",
|
| 175 |
-
],
|
| 176 |
-
[
|
| 177 |
-
"English",
|
| 178 |
-
"csukuangfj/icefall-asr-librispeech-pruned-transducer-stateless3-2022-05-13",
|
| 179 |
-
"greedy_search",
|
| 180 |
-
4,
|
| 181 |
-
"Yes",
|
| 182 |
-
"./data/test_wavs/librispeech/1221-135766-0002.wav",
|
| 183 |
-
],
|
| 184 |
-
# gigaspeech
|
| 185 |
-
[
|
| 186 |
-
"English",
|
| 187 |
-
"wgb14/icefall-asr-gigaspeech-pruned-transducer-stateless2",
|
| 188 |
-
"greedy_search",
|
| 189 |
-
4,
|
| 190 |
-
"Yes",
|
| 191 |
-
"./data/test_wavs/gigaspeech/1-minute-audiobook.opus",
|
| 192 |
-
],
|
| 193 |
-
[
|
| 194 |
-
"English",
|
| 195 |
-
"wgb14/icefall-asr-gigaspeech-pruned-transducer-stateless2",
|
| 196 |
-
"greedy_search",
|
| 197 |
-
4,
|
| 198 |
-
"Yes",
|
| 199 |
-
"./data/test_wavs/gigaspeech/100-seconds-podcast.opus",
|
| 200 |
-
],
|
| 201 |
-
[
|
| 202 |
-
"English",
|
| 203 |
-
"wgb14/icefall-asr-gigaspeech-pruned-transducer-stateless2",
|
| 204 |
-
"greedy_search",
|
| 205 |
-
4,
|
| 206 |
-
"Yes",
|
| 207 |
-
"./data/test_wavs/gigaspeech/100-seconds-youtube.opus",
|
| 208 |
-
],
|
| 209 |
-
# wenetspeech
|
| 210 |
-
# https://huggingface.co/luomingshuang/icefall_asr_wenetspeech_pruned_transducer_stateless2/tree/main/data/test_wavs
|
| 211 |
-
[
|
| 212 |
-
"Chinese",
|
| 213 |
-
"luomingshuang/icefall_asr_wenetspeech_pruned_transducer_stateless2",
|
| 214 |
-
"greedy_search",
|
| 215 |
-
4,
|
| 216 |
-
"Yes",
|
| 217 |
-
"./data/test_wavs/wenetspeech/DEV_T0000000000.opus",
|
| 218 |
-
],
|
| 219 |
-
[
|
| 220 |
-
"Chinese",
|
| 221 |
-
"luomingshuang/icefall_asr_wenetspeech_pruned_transducer_stateless2",
|
| 222 |
-
"greedy_search",
|
| 223 |
-
4,
|
| 224 |
-
"Yes",
|
| 225 |
-
"./data/test_wavs/wenetspeech/DEV_T0000000001.opus",
|
| 226 |
-
],
|
| 227 |
-
[
|
| 228 |
-
"Chinese",
|
| 229 |
-
"luomingshuang/icefall_asr_wenetspeech_pruned_transducer_stateless2",
|
| 230 |
-
"greedy_search",
|
| 231 |
-
4,
|
| 232 |
-
"Yes",
|
| 233 |
-
"./data/test_wavs/wenetspeech/DEV_T0000000002.opus",
|
| 234 |
-
],
|
| 235 |
-
# aishell2-A
|
| 236 |
-
# https://huggingface.co/yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-A-2022-07-12/tree/main/data/test_wavs
|
| 237 |
-
[
|
| 238 |
-
"Chinese",
|
| 239 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-A-2022-07-12",
|
| 240 |
-
"greedy_search",
|
| 241 |
-
4,
|
| 242 |
-
"Yes",
|
| 243 |
-
"./data/test_wavs/aishell2/ID0012W0030.wav",
|
| 244 |
-
],
|
| 245 |
-
[
|
| 246 |
-
"Chinese",
|
| 247 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-A-2022-07-12",
|
| 248 |
-
"greedy_search",
|
| 249 |
-
4,
|
| 250 |
-
"Yes",
|
| 251 |
-
"./data/test_wavs/aishell2/ID0012W0162.wav",
|
| 252 |
-
],
|
| 253 |
-
[
|
| 254 |
-
"Chinese",
|
| 255 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-A-2022-07-12",
|
| 256 |
-
"greedy_search",
|
| 257 |
-
4,
|
| 258 |
-
"Yes",
|
| 259 |
-
"./data/test_wavs/aishell2/ID0012W0215.wav",
|
| 260 |
-
],
|
| 261 |
-
# aishell2-B
|
| 262 |
-
# https://huggingface.co/yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-A-2022-07-12/tree/main/data/test_wavs
|
| 263 |
-
[
|
| 264 |
-
"Chinese",
|
| 265 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-B-2022-07-12",
|
| 266 |
-
"greedy_search",
|
| 267 |
-
4,
|
| 268 |
-
"Yes",
|
| 269 |
-
"./data/test_wavs/aishell2/ID0012W0030.wav",
|
| 270 |
-
],
|
| 271 |
-
[
|
| 272 |
-
"Chinese",
|
| 273 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-B-2022-07-12",
|
| 274 |
-
"greedy_search",
|
| 275 |
-
4,
|
| 276 |
-
"Yes",
|
| 277 |
-
"./data/test_wavs/aishell2/ID0012W0162.wav",
|
| 278 |
-
],
|
| 279 |
-
[
|
| 280 |
-
"Chinese",
|
| 281 |
-
"yuekai/icefall-asr-aishell2-pruned-transducer-stateless5-B-2022-07-12",
|
| 282 |
-
"greedy_search",
|
| 283 |
-
4,
|
| 284 |
-
"Yes",
|
| 285 |
-
"./data/test_wavs/aishell2/ID0012W0215.wav",
|
| 286 |
-
],
|
| 287 |
-
# aishell2-B
|
| 288 |
-
# https://huggingface.co/luomingshuang/icefall_asr_aidatatang-200zh_pruned_transducer_stateless2/tree/main/data/test_wavs
|
| 289 |
-
[
|
| 290 |
-
"Chinese",
|
| 291 |
-
"luomingshuang/icefall_asr_aidatatang-200zh_pruned_transducer_stateless2",
|
| 292 |
-
"greedy_search",
|
| 293 |
-
4,
|
| 294 |
-
"Yes",
|
| 295 |
-
"./data/test_wavs/aidatatang_200zh/T0055G0036S0002.wav",
|
| 296 |
-
],
|
| 297 |
-
[
|
| 298 |
-
"Chinese",
|
| 299 |
-
"luomingshuang/icefall_asr_aidatatang-200zh_pruned_transducer_stateless2",
|
| 300 |
-
"greedy_search",
|
| 301 |
-
4,
|
| 302 |
-
"Yes",
|
| 303 |
-
"./data/test_wavs/aidatatang_200zh/T0055G0036S0003.wav",
|
| 304 |
-
],
|
| 305 |
-
[
|
| 306 |
-
"Chinese",
|
| 307 |
-
"luomingshuang/icefall_asr_aidatatang-200zh_pruned_transducer_stateless2",
|
| 308 |
-
"greedy_search",
|
| 309 |
-
4,
|
| 310 |
-
"Yes",
|
| 311 |
-
"./data/test_wavs/aidatatang_200zh/T0055G0036S0004.wav",
|
| 312 |
-
],
|
| 313 |
-
# tal_csasr
|
| 314 |
-
[
|
| 315 |
-
"Chinese+English",
|
| 316 |
-
"ptrnull/icefall-asr-conv-emformer-transducer-stateless2-zh",
|
| 317 |
-
"greedy_search",
|
| 318 |
-
4,
|
| 319 |
-
"Yes",
|
| 320 |
-
"./data/test_wavs/tal_csasr/210_36476_210_8341_1_1533271973_7057520_132.wav",
|
| 321 |
-
],
|
| 322 |
-
[
|
| 323 |
-
"Chinese+English",
|
| 324 |
-
"ptrnull/icefall-asr-conv-emformer-transducer-stateless2-zh",
|
| 325 |
-
"greedy_search",
|
| 326 |
-
4,
|
| 327 |
-
"Yes",
|
| 328 |
-
"./data/test_wavs/tal_csasr/210_36476_210_8341_1_1533271973_7057520_138.wav",
|
| 329 |
-
],
|
| 330 |
-
[
|
| 331 |
-
"Chinese+English",
|
| 332 |
-
"ptrnull/icefall-asr-conv-emformer-transducer-stateless2-zh",
|
| 333 |
-
"greedy_search",
|
| 334 |
-
4,
|
| 335 |
-
"Yes",
|
| 336 |
-
"./data/test_wavs/tal_csasr/210_36476_210_8341_1_1533271973_7057520_145.wav",
|
| 337 |
-
],
|
| 338 |
-
[
|
| 339 |
-
"Tibetan",
|
| 340 |
-
"syzym/icefall-asr-xbmu-amdo31-pruned-transducer-stateless7-2022-12-02",
|
| 341 |
-
"greedy_search",
|
| 342 |
-
4,
|
| 343 |
-
"No",
|
| 344 |
-
"./data/test_wavs/tibetan/a_0_cacm-A70_31116.wav",
|
| 345 |
-
],
|
| 346 |
-
[
|
| 347 |
-
"Tibetan",
|
| 348 |
-
"syzym/icefall-asr-xbmu-amdo31-pruned-transducer-stateless7-2022-12-02",
|
| 349 |
-
"greedy_search",
|
| 350 |
-
4,
|
| 351 |
-
"No",
|
| 352 |
-
"./data/test_wavs/tibetan/a_0_cacm-A70_31118.wav",
|
| 353 |
-
],
|
| 354 |
-
# arabic
|
| 355 |
-
[
|
| 356 |
-
"Arabic",
|
| 357 |
-
"AmirHussein/icefall-asr-mgb2-conformer_ctc-2022-27-06",
|
| 358 |
-
"greedy_search",
|
| 359 |
-
4,
|
| 360 |
-
"No",
|
| 361 |
-
"./data/test_wavs/arabic/b.wav",
|
| 362 |
-
],
|
| 363 |
-
[
|
| 364 |
-
"Arabic",
|
| 365 |
-
"AmirHussein/icefall-asr-mgb2-conformer_ctc-2022-27-06",
|
| 366 |
-
"greedy_search",
|
| 367 |
-
4,
|
| 368 |
-
"No",
|
| 369 |
-
"./data/test_wavs/arabic/c.wav",
|
| 370 |
-
],
|
| 371 |
-
[
|
| 372 |
-
"German",
|
| 373 |
-
"csukuangfj/wav2vec2.0-torchaudio",
|
| 374 |
-
"greedy_search",
|
| 375 |
-
4,
|
| 376 |
-
"No",
|
| 377 |
-
"./data/test_wavs/german/20120315-0900-PLENARY-14-de_20120315.wav",
|
| 378 |
-
],
|
| 379 |
-
[
|
| 380 |
-
"French",
|
| 381 |
-
"shaojieli/sherpa-onnx-streaming-zipformer-fr-2023-04-14",
|
| 382 |
-
"greedy_search",
|
| 383 |
-
4,
|
| 384 |
-
"No",
|
| 385 |
-
"./data/test_wavs/french/common_voice_fr_19738183.wav",
|
| 386 |
-
],
|
| 387 |
-
[
|
| 388 |
-
"French",
|
| 389 |
-
"shaojieli/sherpa-onnx-streaming-zipformer-fr-2023-04-14",
|
| 390 |
-
"greedy_search",
|
| 391 |
-
4,
|
| 392 |
-
"No",
|
| 393 |
-
"./data/test_wavs/french/common_voice_fr_27024649.wav",
|
| 394 |
],
|
| 395 |
]
|
|
|
|
| 3 |
|
| 4 |
|
| 5 |
examples = [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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
|
|
| 137 |
language_radio.change(
|
| 138 |
update_model_dropdown,
|
| 139 |
inputs=language_radio,
|
|
|
|
| 134 |
fn=process_uploaded_file,
|
| 135 |
)
|
| 136 |
|
| 137 |
+
upload_button.click(
|
| 138 |
+
process_uploaded_file,
|
| 139 |
+
inputs=[
|
| 140 |
+
language_radio,
|
| 141 |
+
model_dropdown,
|
| 142 |
+
decoding_method_radio,
|
| 143 |
+
num_active_paths_slider,
|
| 144 |
+
punct_radio,
|
| 145 |
+
uploaded_file,
|
| 146 |
+
],
|
| 147 |
+
outputs=[uploaded_output, uploaded_html_info],
|
| 148 |
+
)
|
| 149 |
+
|
| 150 |
language_radio.change(
|
| 151 |
update_model_dropdown,
|
| 152 |
inputs=language_radio,
|