sagawatatsuya/BengaliAI_Speech_Recognition_3rd_solution

3

stars

3

commits

Python

primary language

Oct 21, 2023

updated

README

BengaliAI Speech Recognition 3rd place solution

We won 3rd place at the kaggle competition "BengaliAI Speech Recognition", and this is an explanation of our solution. Here, I mainly explain about how to train CTC and LM.

competition data
IndicCorp v2's bengali text data
common voice's bengali audio
fleurs
openslr53
openslr37(bn_bd)
openslr37(bn_in)
oscar

2. preprocess competition csv file

python preprocess_given_data.py

3. train CTC model

We fine-tuned ai4bharat/indicwav2vec_v1_bengali with competition data.
The training process is as follows:

  1. fine-tune ai4bharat/indicwav2vec_v1_bengali with split='valid' data
cd train_CTC
python stage1.py
  1. calculate WER of split='train' data with stage1 model
python calculate_wer_bs1.py
  1. fine-tune ai4bharat/indicwav2vec_v1_bengali with split='valid' data and split='train' data whose WER is lower than 0.75
python stage2.py

4. train kenlm

  1. preprocess external text data
python preprocess_external_data.py
  1. train 5gram lm
cd train_kenlm
python train_5gram_lm.py

5. train punctuation model

please refere to https://github.com/espritmirai/bengali-punctuation-model

6. inference

please refere to https://www.kaggle.com/code/takuji/3rd-place-solution

Contributors

sagawatatsuya

3 commits

sagawatatsuya/BengaliAI_Speech_Recognition_3rd_solution

3

stars

3

commits

Python

primary language

Oct 21, 2023

updated

README

BengaliAI Speech Recognition 3rd place solution

We won 3rd place at the kaggle competition "BengaliAI Speech Recognition", and this is an explanation of our solution. Here, I mainly explain about how to train CTC and LM.

competition data
IndicCorp v2's bengali text data
common voice's bengali audio
fleurs
openslr53
openslr37(bn_bd)
openslr37(bn_in)
oscar

2. preprocess competition csv file

python preprocess_given_data.py

3. train CTC model

We fine-tuned ai4bharat/indicwav2vec_v1_bengali with competition data.
The training process is as follows:

  1. fine-tune ai4bharat/indicwav2vec_v1_bengali with split='valid' data
cd train_CTC
python stage1.py
  1. calculate WER of split='train' data with stage1 model
python calculate_wer_bs1.py
  1. fine-tune ai4bharat/indicwav2vec_v1_bengali with split='valid' data and split='train' data whose WER is lower than 0.75
python stage2.py

4. train kenlm

  1. preprocess external text data
python preprocess_external_data.py
  1. train 5gram lm
cd train_kenlm
python train_5gram_lm.py

5. train punctuation model

please refere to https://github.com/espritmirai/bengali-punctuation-model

6. inference

please refere to https://www.kaggle.com/code/takuji/3rd-place-solution

Contributors

sagawatatsuya

3 commits

Languages

Python

100.0%