facebook/wav2vec2-base (95 M parameters) fine-tuned with a character-level CTC head for English speech
recognition, from a study of noise-robust ASR with word-level error flagging (Group 9, DS & AI Lab project,
Nov 2026). Same as Model B but with peak learning rate 1e-4 (the best value of our hyper-parameter sweep).
import torch, soundfile as sf
from transformers import Wav2Vec2Processor, Wav2Vec2ForCTC
repo = "kumargulshan/wav2vec2-base-ls100-noise-aug-lr1e-4"
processor = Wav2Vec2Processor.from_pretrained(repo)
model = Wav2Vec2ForCTC.from_pretrained(repo).eval()
audio, sr = sf.read("speech.wav") # mono, 16 kHz (resample first if needed)
inputs = processor(audio, sampling_rate=16000, return_tensors="pt")
with torch.no_grad():
ids = model(inputs.input_values).logits.argmax(-1)
print(processor.batch_decode(ids)[0]) # upper-case letters, apostrophe, spaces
Output vocabulary: the same 32 symbols as facebook/wav2vec2-base-960h (A–Z, apostrophe, | word delimiter).
For the best accuracy, decode the logits with a 4-gram LibriSpeech KenLM via pyctcdecode
(we used alpha 0.8, beta 2.0, beam 50).
| Training | from facebook/wav2vec2-base, LibriSpeech train-clean-100 (100.6 h), 36k steps (≈ 59.5 epochs), peak lr 1e-4, 8 % warm-up, linear decay, seed 42 |
| Augmentation | 80 % of utterances mixed with noise at SNR 0–20 dB (white, pink, MUSAN noise, MUSAN music), 20 % kept clean |
| Regularisation | SpecAugment-style masking (time p 0.4 / span 10, feature p 0.1 / span 64), LayerDrop 0.1, frozen CNN feature encoder |
| Optimiser | AdamW (β 0.9/0.98, weight decay 0.005), gradient clipping 1.0, bf16, duration-bucketed batches of ≤ 640 s of audio |
| Selection | checkpoint with the lowest mean dev WER (dev-clean + dev-other, clean and noisy): step 36000, dev WER 13.06 % |
| Hardware | 1 × NVIDIA L40S |
LibriSpeech test-clean + test-other (5,559 utterances) under 17 conditions: clean, and white / pink / brown noise and ESC-50 environmental sounds at 0, 5, 10, 15, 20 dB SNR (94,503 utterance-conditions, 182.7 h). Brown noise and ESC-50 were never used in training. Noise was mixed with fixed seeds per utterance, so all models see identical audio.
| WER (%) | greedy | + 4-gram LM |
|---|---|---|
| test-clean | 5.89 | 3.67 |
| test-other | 13.11 | 9.18 |
| all noisy conditions, pooled | – | 11.61 |
| white noise, 0–5 dB | 28.56 | 22.57 |
| pink noise, 0–5 dB | 22.81 | 17.44 |
| brown noise, 0–5 dB (unseen type) | 9.99 | 6.70 |
| ESC-50 sounds, 0–5 dB (unseen type) | 19.56 | 14.82 |
| Model | Description |
|---|---|
| B960_rev | best single model: 960 h, noise + reverb + speed + telephone augmentation |
| B960_rev_s2 | same as B960_rev, seed 7 (ensemble member) |
| B460 | 464 h + noise augmentation |
| B_noisy | Model B: 100 h + noise augmentation |
| A_clean | Model A: 100 h, clean training baseline |
Apache-2.0, as the base model facebook/wav2vec2-base. Training data: LibriSpeech (CC BY 4.0) and MUSAN.
facebook/wav2vec2-base