whisper-large-icelandic-62640-steps-967h
The "whisper-large-icelandic-62640-steps-967h" is an acoustic model suitable for Automatic Speech Recognition in Icelandic. It is the result of fine-tuning the model openai/whisper-large for 62,640 steps with 967 hours of Icelandic data collected by the Language and Voice Laboratory through the platform Samrómur.
The specific data that was used to fine-tune the model is the corpus Samrómur Milljón, which is the result of the automatic verification of 1 million of recordings comming from the corpus "Samromur Unverified 22.07". It has to be pointed out that this model was trained with different data than our previous model whisper-large-icelandic-30k-steps-1000h.
The fine-tuning process was performed during June (2023) in the servers of the Language and Voice Laboratory (https://lvl.ru.is/) at Reykjavík University (Iceland) by Carlos Daniel Hernández Mena.
Evaluation
import torch
from transformers import WhisperForConditionalGeneration, WhisperProcessor
#Load the processor and model.
MODEL_NAME="language-and-voice-lab/whisper-large-icelandic-62640-steps-967h"
processor = WhisperProcessor.from_pretrained(MODEL_NAME)
model = WhisperForConditionalGeneration.from_pretrained(MODEL_NAME).to("cuda")
#Load the dataset
from datasets import load_dataset, load_metric, Audio
ds=load_dataset("language-and-voice-lab/samromur_children",split='test')
#Downsample to 16kHz
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
#Process the dataset
def map_to_pred(batch):
audio = batch["audio"]
input_features = processor(audio["array"], sampling_rate=audio["sampling_rate"], return_tensors="pt").input_features
batch["reference"] = processor.tokenizer._normalize(batch['normalized_text'])
with torch.no_grad():
predicted_ids = model.generate(input_features.to("cuda"))[0]
transcription = processor.decode(predicted_ids)
batch["prediction"] = processor.tokenizer._normalize(transcription)
return batch
#Do the evaluation
result = ds.map(map_to_pred)
#Compute the overall WER now.
from evaluate import load
wer = load("wer")
WER=100 * wer.compute(references=result["reference"], predictions=result["prediction"])
print(WER)
Test Result: 7.743795695602924
BibTeX entry and citation info
When publishing results based on these models please refer to:
@misc{mena2023whisperlarge62640icelandic,
title={Acoustic Model in Icelandic: whisper-large-icelandic-62640-steps-967h.},
author={Hernandez Mena, Carlos Daniel},
url={https://huggingface.co/language-and-voice-lab/whisper-large-icelandic-62640-steps-967h},
year={2023}
}
Acknowledgements
Thanks to Jón Guðnason, head of the Language and Voice Lab for providing computational power to make this model possible.
We also want to thank to the "Language Technology Programme for Icelandic 2019-2023" which is managed and coordinated by Almannarómur, and it is funded by the Icelandic Ministry of Education, Science and Culture. This model is an unexpected result of all the resources gathered by the Programme.
Special thanks to Björn Ingi Stefánsson for setting up the configuration of the server where this model was trained.
- Downloads last month
- 7
Dataset used to train language-and-voice-lab/whisper-large-icelandic-62640-steps-967h
Space using language-and-voice-lab/whisper-large-icelandic-62640-steps-967h 1
Evaluation results
- WER on Samrómur (Test)test set self-reported7.762
- WER on Samrómur (Dev)validation set self-reported7.035
- WER on Samrómur Children (Test)test set self-reported7.047
- WER on Samrómur Children (Dev)validation set self-reported4.425
- WER on Malrómur (Test)test set self-reported11.511
- WER on Malrómur (Dev)validation set self-reported11.000
- WER on Althingi (Test)test set self-reported16.189
- WER on Althingi (Dev)validation set self-reported16.007