mpoyraz commited on
Commit
04e982d
1 Parent(s): 03e1e75

add the model card

Browse files
Files changed (1) hide show
  1. README.md +99 -0
README.md ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-4.0
3
+ language: tr
4
+ tags:
5
+ - automatic-speech-recognition
6
+ - common_voice
7
+ - tr
8
+ - robust-speech-event
9
+ datasets:
10
+ - common_voice
11
+ model-index:
12
+ - name: mpoyraz/wav2vec2-xls-r-300m-cv6-turkish
13
+ results:
14
+ - task:
15
+ name: Automatic Speech Recognition
16
+ type: automatic-speech-recognition
17
+ dataset:
18
+ name: Common Voice 6.1
19
+ type: common_voice
20
+ args: tr
21
+ metrics:
22
+ - name: Test WER
23
+ type: wer
24
+ value: 8.83
25
+ - name: Test CER
26
+ type: cer
27
+ value: 2.37
28
+ - task:
29
+ name: Automatic Speech Recognition
30
+ type: automatic-speech-recognition
31
+ dataset:
32
+ name: Robust Speech Event - Dev Data
33
+ type: speech-recognition-community-v2/dev_data
34
+ args: tr
35
+ metrics:
36
+ - name: Test WER
37
+ type: wer
38
+ value: 32.81
39
+ - name: Test CER
40
+ type: cer
41
+ value: 11.22
42
+ ---
43
+
44
+ # wav2vec2-xls-r-300m-cv6-turkish
45
+
46
+ ## Model description
47
+ This ASR model is a fine-tuned version of [facebook/wav2vec2-xls-r-300m](https://huggingface.co/facebook/wav2vec2-xls-r-300m) on Turkish language.
48
+
49
+ ## Training and evaluation data
50
+ The following datasets were used for finetuning:
51
+ - [Common Voice 6.1 TR](https://huggingface.co/datasets/common_voice) All `validated` split except `test` split was used for training.
52
+ - [MediaSpeech](https://www.openslr.org/108/)
53
+
54
+ ## Training procedure
55
+ To support both of the datasets above, custom pre-processing and loading steps was performed and [wav2vec2-turkish](https://github.com/mpoyraz/wav2vec2-turkish) repo was used for that purpose.
56
+
57
+ ### Training hyperparameters
58
+ The following hypermaters were used for finetuning:
59
+ - learning_rate 2e-4
60
+ - num_train_epochs 10
61
+ - warmup_steps 500
62
+ - freeze_feature_extractor
63
+ - mask_time_prob 0.1
64
+ - mask_feature_prob 0.1
65
+ - feat_proj_dropout 0.05
66
+ - attention_dropout 0.05
67
+ - final_dropout 0.1
68
+ - activation_dropout 0.05
69
+ - per_device_train_batch_size 8
70
+ - per_device_eval_batch_size 8
71
+ - gradient_accumulation_steps 8
72
+
73
+ ### Framework versions
74
+ - Transformers 4.17.0.dev0
75
+ - Pytorch 1.10.1
76
+ - Datasets 1.18.3
77
+ - Tokenizers 0.10.3
78
+
79
+ ## Language Model
80
+ N-gram language model is trained on a Turkish Wikipedia articles using KenLM and [ngram-lm-wiki](https://github.com/mpoyraz/ngram-lm-wiki) repo was used to generate arpa LM and convert it into binary format.
81
+
82
+ ## Evaluation Commands
83
+ Please install [unicode_tr](https://pypi.org/project/unicode_tr/) package before running evaluation. It is used for Turkish text processing.
84
+ 1. To evaluate on `common_voice` with split `test`
85
+ ```bash
86
+ python eval.py --model_id mpoyraz/wav2vec2-xls-r-300m-cv6-turkish --dataset common_voice --config tr --split test
87
+ ```
88
+
89
+ 2. To evaluate on `speech-recognition-community-v2/dev_data`
90
+
91
+ ```bash
92
+ python eval.py --model_id mpoyraz/wav2vec2-xls-r-300m-cv6-turkish --dataset speech-recognition-community-v2/dev_data --config tr --split validation --chunk_length_s 5.0 --stride_length_s 1.0
93
+ ```
94
+ ## Evaluation results:
95
+
96
+ | Dataset | WER | CER |
97
+ |---|---|---|
98
+ |Common Voice 6.1 TR test split| 8.83 | 2.37 |
99
+ |Speech Recognition Community dev data| 32.81 | 11.22 |