drmeeseeks commited on
Commit
15e190c
1 Parent(s): ac52c50

update model card README.md

Browse files
Files changed (1) hide show
  1. README.md +38 -93
README.md CHANGED
@@ -1,61 +1,53 @@
1
  ---
2
  license: apache-2.0
3
  tags:
4
- - whisper-event
5
  - generated_from_trainer
6
  datasets:
7
- - google/fleurs
8
  metrics:
9
  - wer
10
  model-index:
11
- - name: Whisper Small Amharic FLEURS
12
  results:
13
  - task:
14
  name: Automatic Speech Recognition
15
  type: automatic-speech-recognition
16
  dataset:
17
- name: google/fleurs am_et
18
- type: google/fleurs
19
  config: am_et
20
- split: test+validation
21
  args: am_et
22
  metrics:
23
  - name: Wer
24
  type: wer
25
- value: 160.99
26
- language:
27
- - amh
28
  ---
29
 
30
  <!-- This model card has been generated automatically according to the information the Trainer had access to. You
31
  should probably proofread and complete it, then remove this comment. -->
32
 
 
33
 
34
- # Whisper Small Tamil FLEURS
35
-
36
- This model is a fine-tuned version of [openai/whisper-small](https://huggingface.co/openai/whisper-small) on the google/fleurs am_et dataset.
37
  It achieves the following results on the evaluation set:
38
- - Loss: -
39
- - Wer: 160.99
40
 
41
  ## Model description
42
 
43
- - The main Whisper Small Hugging Face page: [Hugging Face - Whisper Small](https://huggingface.co/openai/whisper-small)
44
 
45
  ## Intended uses & limitations
46
 
47
- - For experimentation and curiosity.
48
- - Based on the paper [AXRIV](https://arxiv.org/abs/2212.04356) and [Benchmarking OpenAI Whisper for non-English ASR - Dan Shafer](https://blog.deepgram.com/benchmarking-openai-whisper-for-non-english-asr/), there is a performance bias towards certain languages and curated datasets.
49
- - From the Whisper paper, am_et is a low resource language (Table E), with the WER results ranging from 120-229, based on model size. Whisper small WER=120.2, indicating more training time may improve the fine tuning.
50
 
51
  ## Training and evaluation data
52
 
53
- - This model was trained/evaluated on "test+validation" data from google/fleurs [google/fluers - HuggingFace Datasets](https://huggingface.co/datasets/google/fleurs).
54
 
55
  ## Training procedure
56
 
57
- - The training was done in Lambda Cloud GPU on A100/40GB GPUs, which were provided by OpenAI Community Events [Whisper Fine Tuning Event - Dec 2022](https://github.com/huggingface/community-events/tree/main/whisper-fine-tuning-event#fine-tune-whisper). The training was done using [HuggingFace Community Events - Whisper - run_speech_recognition_seq2seq_streaming.py](https://github.com/huggingface/community-events/blob/main/whisper-fine-tuning-event/run_speech_recognition_seq2seq_streaming.py) using the included [whisper_python_am_et.ipynb](https://huggingface.co/drmeeseeks/whisper-small-am_et/blob/main/am_et_fine_tune_whisper_streaming_colab_RUNNING-evalerrir.ipynb) to setup the Lambda Cloud GPU/Colab environment. For Colab, you must reduce the train batch size to the recommended amount mentioned at , as the T4 GPUs have 16GB of memory [Whisper Fine Tuning Event - Dec 2022](https://github.com/huggingface/community-events/tree/main/whisper-fine-tuning-event#fine-tune-whisper). The notebook sets up the environment, logs into your huggingface account, and generates a bash script. The bash script generated in the IPYNB, `run.sh` was run from the terminal to train `bash run.sh`, as described on the Whisper community events GITHUB page. Num Examples = 446, Num Epochs = 715, Number of trainable parameters = 241734912.
58
-
59
  ### Training hyperparameters
60
 
61
  The following hyperparameters were used during training:
@@ -63,88 +55,41 @@ The following hyperparameters were used during training:
63
  - train_batch_size: 64
64
  - eval_batch_size: 32
65
  - seed: 42
66
- - gradient_accumulation_steps: 1
67
- - total_train_batch_size: 64
68
  - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
69
  - lr_scheduler_type: linear
70
  - lr_scheduler_warmup_steps: 500
71
- - training_steps: 1000
72
  - mixed_precision_training: Native AMP
73
- - do_eval=False
74
-
75
 
76
  ### Training results
77
 
78
- 5000 Steps
79
-
80
- | Training Loss | Epoch | Step | Learning Rate |
81
- |:-------------:|:-----:|:-----:|:-----:|
82
- | 3.0968 | 0.05 | - | 4.2e-7 |
83
- | 1.178 | 28.57 | - | 3.92e-6 |
84
- | 0.03 | 53.57 | - | 7.42e-6 |
85
- | 0.0002 | 217.86 | - | 7.73e-6 |
86
- | 0.0001 | 378.57 | ~ 2000 | 5.23e-6 |
87
- | 0.0000 | 382.14 | - | 5.14e-6 |
88
- | 0.0000 | 467.86 | 3300 | 3.84e-6|
89
- | 0.0000 | 614.29 | 4300 | 1.56e-6|
90
- | 0.0000 | 685.71 | 4812 | 4.53e-7|
91
- | 0.0000 | 710.71 | 4997 | 6.44e-8|
92
-
93
- 3000 Steps
94
-
95
- | Training Loss | Epoch | Step | Learning Rate |
96
- |:-------------:|:-----:|:-----:|:-----:|
97
- | 3.0968 | 0.05 | - | 4.2e-7 |
98
- | 0.0017 | 96.43 | 687 | 9.316e-6 |
99
-
100
-
101
- ### Recommendations
102
-
103
- Limit training duration for smaller datasets to ~ 2000 to 3000 steps to avoid overfitting. 5000 steps using the [HuggingFace - Whisper Small](https://huggingface.co/openai/whisper-small) takes ~ 5hrs on A100 GPUs (1hr/1000 steps). Encountered `RuntimeError: The size of tensor a (504) must match the size of tensor b (448) at non-singleton dimension 1` which is related to [Trainer RuntimeError](https://discuss.huggingface.co/t/trainer-runtimeerror-the-size-of-tensor-a-462-must-match-the-size-of-tensor-b-448-at-non-singleton-dimension-1/26010) as some languages datasets have input lengths that have non-standard lengths. The link did not resolve my issue, and appears elsewhere too [Training languagemodel – RuntimeError the expanded size of the tensor (100) must match the existing size (64) at non singleton dimension 1](https://hungsblog.de/en/technology/troubleshooting/training-languagemodel-runtimeerror-the-expanded-size-of-the-tensor-100-must-match-the-existing-size-64-at-non-singleton-dimension-1/). To circumvent this issue, `run.sh` only trains and saves the model (if you make changes to `run.sh` be sure to clear/rm the contents as piping appends). Then run `python run_eval_whisper_streaming.py --model_id="openai/whisper-small" --dataset="google/fleurs" --config="am_et" --batch_size=32 --max_eval_samples=64 --device=0 --language="am"` to find the WER score. Erroring out during evaluation prevents the trained model from loading to HugginFace. Based on the paper [AXRIV](https://arxiv.org/abs/2212.04356) and [Benchmarking OpenAI Whisper for non-English ASR - Dan Shafer](https://blog.deepgram.com/benchmarking-openai-whisper-for-non-english-asr/), there is a performance bias towards certain languages and curated datasets. The OpenAI fintuning community event provided ample _free_ GPU time to help develop the model further and improve WER scores.
104
-
105
- ### Environmental Impact
106
-
107
- Carbon emissions were estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700). In total roughly 100 hours were used primarily in US East/Asia Pacific (80%/20%), with AWS as the reference. Additional resources are available at [Our World in Data - CO2 Emissions](https://ourworldindata.org/co2-emissions)
108
-
109
- - __Hardware Type__: AMD EPYC 7J13 64-Core Processor (30 core VM) 197GB RAM, with NVIDIA A100-SXM 40GB
110
- - __Hours Used__: 100 hrs
111
- - __Cloud Provider__: Lambda Cloud GPU
112
- - __Compute Region__: US East/Asia Pacific
113
- - __Carbon Emitted__: 12 kg (GPU) + 13 kg (CPU) = 25 kg (the weight of 3 gallons of water)
114
-
115
-
116
- ### Citation
117
-
118
- - [Whisper - GITHUB](https://github.com/openai/whisper)
119
- - [Whisper - OpenAI - BLOG](https://openai.com/blog/whisper/)
120
- - [Model Card - HuggingFace Hub - GITHUB](https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/templates/modelcard_template.md)
121
-
122
- ```bibtex
123
- @misc{https://doi.org/10.48550/arxiv.2212.04356,
124
- doi = {10.48550/ARXIV.2212.04356},
125
- url = {https://arxiv.org/abs/2212.04356},
126
- author = {Radford, Alec and Kim, Jong Wook and Xu, Tao and Brockman, Greg and McLeavey, Christine and Sutskever, Ilya},
127
- keywords = {Audio and Speech Processing (eess.AS), Computation and Language (cs.CL), Machine Learning (cs.LG), Sound (cs.SD), FOS: Electrical engineering, electronic engineering, information engineering, FOS: Electrical engineering, electronic engineering, information engineering, FOS: Computer and information sciences, FOS: Computer and information sciences},
128
- title = {Robust Speech Recognition via Large-Scale Weak Supervision},
129
- publisher = {arXiv},
130
- year = {2022},
131
- copyright = {arXiv.org perpetual, non-exclusive license}
132
- }
133
-
134
- @article{owidco2andothergreenhousegasemissions,
135
- author = {Hannah Ritchie and Max Roser and Pablo Rosado},
136
- title = {CO₂ and Greenhouse Gas Emissions},
137
- journal = {Our World in Data},
138
- year = {2020},
139
- note = {https://ourworldindata.org/co2-and-other-greenhouse-gas-emissions}
140
- }
141
-
142
- ```
143
 
144
 
145
  ### Framework versions
146
 
147
  - Transformers 4.26.0.dev0
148
- - Pytorch 1.13.0+cu117
149
- - Datasets 2.7.1.dev0
150
  - Tokenizers 0.13.2
 
1
  ---
2
  license: apache-2.0
3
  tags:
 
4
  - generated_from_trainer
5
  datasets:
6
+ - fleurs
7
  metrics:
8
  - wer
9
  model-index:
10
+ - name: whisper-small-amet
11
  results:
12
  - task:
13
  name: Automatic Speech Recognition
14
  type: automatic-speech-recognition
15
  dataset:
16
+ name: fleurs
17
+ type: fleurs
18
  config: am_et
19
+ split: validation
20
  args: am_et
21
  metrics:
22
  - name: Wer
23
  type: wer
24
+ value: 100.0
 
 
25
  ---
26
 
27
  <!-- This model card has been generated automatically according to the information the Trainer had access to. You
28
  should probably proofread and complete it, then remove this comment. -->
29
 
30
+ # whisper-small-amet
31
 
32
+ This model is a fine-tuned version of [openai/whisper-small](https://huggingface.co/openai/whisper-small) on the fleurs dataset.
 
 
33
  It achieves the following results on the evaluation set:
34
+ - Loss: 6.8012
35
+ - Wer: 100.0
36
 
37
  ## Model description
38
 
39
+ More information needed
40
 
41
  ## Intended uses & limitations
42
 
43
+ More information needed
 
 
44
 
45
  ## Training and evaluation data
46
 
47
+ More information needed
48
 
49
  ## Training procedure
50
 
 
 
51
  ### Training hyperparameters
52
 
53
  The following hyperparameters were used during training:
 
55
  - train_batch_size: 64
56
  - eval_batch_size: 32
57
  - seed: 42
 
 
58
  - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
59
  - lr_scheduler_type: linear
60
  - lr_scheduler_warmup_steps: 500
61
+ - training_steps: 2000
62
  - mixed_precision_training: Native AMP
 
 
63
 
64
  ### Training results
65
 
66
+ | Training Loss | Epoch | Step | Validation Loss | Wer |
67
+ |:-------------:|:------:|:----:|:---------------:|:--------:|
68
+ | 0.9013 | 100.0 | 100 | 2.7051 | 276.0 |
69
+ | 0.0002 | 200.0 | 200 | 3.7415 | 334.6667 |
70
+ | 0.0001 | 300.0 | 300 | 3.8402 | 117.3333 |
71
+ | 0.0001 | 400.0 | 400 | 3.8931 | 340.0 |
72
+ | 0.0001 | 500.0 | 500 | 4.0671 | 397.3333 |
73
+ | 0.0001 | 600.0 | 600 | 4.2844 | 137.3333 |
74
+ | 0.0 | 700.0 | 700 | 4.4697 | 289.3333 |
75
+ | 0.0 | 800.0 | 800 | 4.6278 | 449.3333 |
76
+ | 0.0 | 900.0 | 900 | 4.7794 | 678.6667 |
77
+ | 0.0405 | 1000.0 | 1000 | 4.6769 | 261.3333 |
78
+ | 0.0002 | 1100.0 | 1100 | 5.4995 | 100.0 |
79
+ | 0.0002 | 1200.0 | 1200 | 6.0033 | 100.0 |
80
+ | 0.0002 | 1300.0 | 1300 | 6.2884 | 100.0 |
81
+ | 0.0002 | 1400.0 | 1400 | 6.4744 | 100.0 |
82
+ | 0.0002 | 1500.0 | 1500 | 6.5964 | 100.0 |
83
+ | 0.0001 | 1600.0 | 1600 | 6.6792 | 100.0 |
84
+ | 0.0001 | 1700.0 | 1700 | 6.7370 | 100.0 |
85
+ | 0.0001 | 1800.0 | 1800 | 6.7735 | 100.0 |
86
+ | 0.0001 | 1900.0 | 1900 | 6.7958 | 100.0 |
87
+ | 0.0001 | 2000.0 | 2000 | 6.8012 | 100.0 |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
88
 
89
 
90
  ### Framework versions
91
 
92
  - Transformers 4.26.0.dev0
93
+ - Pytorch 1.13.1+cu117
94
+ - Datasets 2.8.1.dev0
95
  - Tokenizers 0.13.2