DigitalUmuganda/ASR_Fellowship_Challenge_Dataset
Viewer • Updated • 190k • 33 • 1
How to use ElvisTata2024/Kinyarwanda-Health-ASR with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("automatic-speech-recognition", model="ElvisTata2024/Kinyarwanda-Health-ASR") # Load model directly
from transformers import AutoProcessor, AutoModelForCTC
processor = AutoProcessor.from_pretrained("ElvisTata2024/Kinyarwanda-Health-ASR")
model = AutoModelForCTC.from_pretrained("ElvisTata2024/Kinyarwanda-Health-ASR")This model is a fine-tuned version of Wav2Vec2-BERT 2.0 for Kinyarwanda automatic speech recognition (ASR) Health. The model is has a WER of 5.95% in the health domain
from transformers import Wav2Vec2BertProcessor, Wav2Vec2BertForCTC
import torch
import torchaudio
# load the model and processor
processor = AutoProcessor.from_pretrained("ElvisTata2024/Kinyarwanda-Health-ASR")
model = AutoModelForCTC.from_pretrained("ElvisTata2024/Kinyarwanda-Health-ASR")
# load audio
audio_input, sample_rate = torchaudio.load("path/to/audio.wav")
# preprocess
inputs = processor(audio_input.squeeze(), sampling_rate=sample_rate, return_tensors="pt")
# inference
with torch.no_grad():
logits = model(**inputs).logits
# decode
predicted_ids = torch.argmax(logits, dim=-1)
transcription = processor.batch_decode(predicted_ids)[0]
print(transcription)
-DigitalUmuganda/ASR_Fellowship_Challenge_Dataset
| Setup | Greedy WER ⬇ | WER + KenLM (2-gram) ⬇ | KenLM Improvement ⬆ |
|---|---|---|---|
| Base Model | 6.51% | 6.03% | 0.48% |
| Adapted Model | 6.45% | 5.98% | 0.47% |
| Net Reduction | 0.06% | 0.04% | 0.02% |
@misc{w2v_bert_kinyarwanda_asr,
author = {Badr M. Abdullah},
title = {Adapting Wav2Vec2-BERT 2.0 for Kinyarwanda ASR},
year = {2025},
publisher = {Hugging Face},
url = {https://huggingface.co/badrex/w2v-bert-2.0-kinyarwanda-asr-1000h}
}
@misc{Kinyarwanda-Health-ASR,
author = {Elvis Tata Tanghang},
title = {Adapting Wav2Vec2-BERT 2.0 for Kinyarwanda ASR Health},
year = {2025},
publisher = {Hugging Face},
url = {https://huggingface.co/ElvisTata2024/Kinyarwanda-Health-ASR}
}
Base model
facebook/w2v-bert-2.0