Views
No views yet
whisper-small model on the DarijaTTS-clean dataset. The goal of this project is to improve automatic speech recognition (ASR) for Moroccan Darija (ary).Lyte/Whisper-Small-Darijaopenai/whisper-smallLyte/DarijaTTS-clean| Step | Training Loss | Validation Loss | WER |
|---|---|---|---|
| 200 | 1.0142 | 1.0804 | 129.35 |
| 400 | 0.8288 | 0.9905 | 72.44 |
| 600 | 0.7618 | 0.9656 | 70.41 |
transformers library:1from transformers import WhisperProcessor, WhisperForConditionalGeneration
2import torch
3
4model_id = "Lyte/whisper-small-darija"
5processor = WhisperProcessor.from_pretrained(model_id)
6model = WhisperForConditionalGeneration.from_pretrained(model_id)
7
8# Load an audio file and preprocess
9input_features = processor("path_to_audio.wav", return_tensors="pt").input_features
10
11generated_ids = model.generate(input_features)
12predicted_text = processor.batch_decode(generated_ids, skip_special_tokens=True)
13
14print(predicted_text)