Downloads · 30 days
34
40% of all-time downloads
mohas8/wav2vec2-xlsr300m-shobdotori-ctc-lexicore
wav2vec2-xlsr300m-shobdotori-ctc-lexicore is a machine learning model from mohas8. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This model is a fine-tuned version of arijitx/wav2vec2-xls-r-300m-bengali for the “শব্দতরী: Where Dialects Flow into Bangla” competition.
Downloads · 30 days
34
40% of all-time downloads
All-time downloads
84
Public
Parameters
316M
6.1 GB on disk
Likes
0
Public
Click a slice to open those files.
.bin3.5 GB · 72%
From the Hugging Face model README
This model is a fine-tuned version of
arijitx/wav2vec2-xls-r-300m-bengali
for the “শব্দতরী: Where Dialects Flow into Bangla” competition.
pyctcdecode) + small punctuation rulefrom transformers import Wav2Vec2Processor, AutoModelForCTC
import torch, torchaudio
processor = Wav2Vec2Processor.from_pretrained("your-username/your-repo")
model = AutoModelForCTC.from_pretrained("your-username/your-repo").to("cuda").eval()
waveform, sr = torchaudio.load("example.wav")
# resample to 16k if needed...
inputs = processor(waveform.squeeze().numpy(), sampling_rate=16000, return_tensors="pt")
with torch.no_grad():
logits = model(inputs.input_values.to("cuda")).logits
pred_ids = torch.argmax(logits, dim=-1)
transcript = processor.batch_decode(pred_ids)[0]
print(transcript)