Downloads · 30 days
86
7% of all-time downloads
derkar00/mms-tuk-latin-asr
mms-tuk-latin-asr is a automatic speech recognition model from derkar00. Use it when you need speech turned into text. The card lists the license as cc-by-nc-4.0.
This model performs Automatic Speech Recognition (ASR) for the Turkmen language using the Latin script (tuk-scriptlatin).
Downloads · 30 days
86
7% of all-time downloads
All-time downloads
1.2K
Public
Parameters
965M
3.9 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors3.9 GB · 100%
From the Hugging Face model README
This model performs Automatic Speech Recognition (ASR) for the Turkmen language
using the Latin script (tuk-script_latin).
It is based on facebook/mms-1b-all, Meta's Massively Multilingual Speech model covering 1000+ languages.
import librosa
import torch
from transformers import Wav2Vec2ForCTC, AutoProcessor
processor = AutoProcessor.from_pretrained("derkar00/mms-tuk-latin-asr")
model = Wav2Vec2ForCTC.from_pretrained("derkar00/mms-tuk-latin-asr")
processor.tokenizer.set_target_lang("tuk-script_latin")
model.load_adapter("tuk-script_latin")
# Load audio (must be 16kHz mono)
audio, rate = librosa.load("your_audio.wav", sr=16000, mono=True)
inputs = processor(audio, sampling_rate=16000, return_tensors="pt")
with torch.no_grad():
logits = model(**inputs).logits
predicted_ids = torch.argmax(logits, dim=-1)
print(processor.decode(predicted_ids[0]))
tuk)