Automatic Speech Recognition
Transformers
PyTorch
TensorBoard
Safetensors
Norwegian
whisper
whisper-event
norwegian
Eval Results (legacy)
Instructions to use NbAiLab/whisper-small-nob with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use NbAiLab/whisper-small-nob with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="NbAiLab/whisper-small-nob")# Load model directly from transformers import AutoProcessor, AutoModelForSpeechSeq2Seq processor = AutoProcessor.from_pretrained("NbAiLab/whisper-small-nob") model = AutoModelForSpeechSeq2Seq.from_pretrained("NbAiLab/whisper-small-nob", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| deepspeed --master_port 29501 run_speech_recognition_seq2seq_streaming.py \ | |
| --deepspeed="ds_config.json" \ | |
| --model_name_or_path="openai/whisper-small" \ | |
| --resume_from_checkpoint="checkpoint-17000" \ | |
| --ignore_data_skip \ | |
| --dataset_name="NbAiLab/NCC_S" \ | |
| --language="Norwegian" \ | |
| --train_split_name="train" \ | |
| --eval_split_name="validation" \ | |
| --model_index_name="Whisper Small Norwegian" \ | |
| --max_steps="100000" \ | |
| --output_dir="./" \ | |
| --per_device_train_batch_size="128" \ | |
| --per_device_eval_batch_size="32" \ | |
| --gradient_accumulation_steps="2" \ | |
| --logging_steps="25" \ | |
| --learning_rate="3e-6" \ | |
| --warmup_steps="1000" \ | |
| --evaluation_strategy="steps" \ | |
| --eval_steps="1000" \ | |
| --save_strategy="steps" \ | |
| --save_steps="1000" \ | |
| --generation_max_length="225" \ | |
| --length_column_name="duration" \ | |
| --max_duration_in_seconds="30" \ | |
| --text_column_name="text" \ | |
| --freeze_feature_encoder="False" \ | |
| --report_to="tensorboard" \ | |
| --metric_for_best_model="wer" \ | |
| --greater_is_better="False" \ | |
| --load_best_model_at_end \ | |
| --gradient_checkpointing \ | |
| --fp16 \ | |
| --overwrite_output_dir \ | |
| --do_train \ | |
| --do_eval \ | |
| --predict_with_generate \ | |
| --do_normalize_eval \ | |
| --use_auth_token \ | |
| --push_to_hub \ | |
| --hub_model_id="NbAiLab/whisper-small-nob" | |