MahmoudAshraf_mms-300m-1130-forced-aligner
MahmoudAshraf · View on Hugging Face ↗
Forced aligner (MMS 300M, 1,130 languages) that maps audio to word-level timestamps — subtitles and dataset alignment.
✓ verified · rehash-vs-hf-metadata at 2026-08-24T02:12:57Z
cc-by-nc-4.0non-commercial use only2.35 GB (2,523,955,946 bytes)transformerspytorchsafetensorswav2vec2automatic-speech-recognitionmmsaudiovoicespeechforced-alignmentendpoints_compatible129 languages (ab, af, ak …)
Get this model
Download MahmoudAshraf_mms-300m-1130-forced-aligner.torrent
Recommended — the .torrent carries the webseed url-list, so your client can fall back to plain HTTPS if the swarm is thin. See/verify for the full download + verification walkthrough.
Model card
The complete upstream card, rendered from this payload's README.md — the same hash-verified bytes the torrent distributes. Images and off-site links are removed; the original card on Hugging Face carries them.
language:
- ab
- af
- ak
- am
- ar
- as
- av
- ay
- az
- ba
- bm
- be
- bn
- bi
- bo
- sh
- br
- bg
- ca
- cs
- ce
- cv
- ku
- cy
- da
- de
- dv
- dz
- el
- en
- eo
- et
- eu
- ee
- fo
- fa
- fj
- fi
- fr
- fy
- ff
- ga
- gl
- gn
- gu
- zh
- ht
- ha
- he
- hi
- sh
- hu
- hy
- ig
- ia
- ms
- is
- it
- jv
- ja
- kn
- ka
- kk
- kr
- km
- ki
- rw
- ky
- ko
- kv
- lo
- la
- lv
- ln
- lt
- lb
- lg
- mh
- ml
- mr
- ms
- mk
- mg
- mt
- mn
- mi
- my
- zh
- nl
- 'no'
- 'no'
- ne
- ny
- oc
- om
- or
- os
- pa
- pl
- pt
- ms
- ps
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- qu
- ro
- rn
- ru
- sg
- sk
- sl
- sm
- sn
- sd
- so
- es
- sq
- su
- sv
- sw
- ta
- tt
- te
- tg
- tl
- th
- ti
- ts
- tr
- uk
- ms
- vi
- wo
- xh
- ms
- yo
- ms
- zu
- za license: cc-by-nc-4.0 tags:
- mms
- wav2vec2
- audio
- voice
- speech
- forced-alignment pipeline_tag: automatic-speech-recognition
Forced Alignment with Hugging Face CTC Models
This Python package provides an efficient way to perform forced alignment between text and audio using Hugging Face's pretrained models. it also features an improved implementation to use much less memory than TorchAudio forced alignment API.
The model checkpoint uploaded here is a conversion from torchaudio to HF Transformers for the MMS-300M checkpoint trained on forced alignment dataset
Installation
pip install git+https://github.com/MahmoudAshraf97/ctc-forced-aligner.git
Usage
import torch
from ctc_forced_aligner import (
load_audio,
load_alignment_model,
generate_emissions,
preprocess_text,
get_alignments,
get_spans,
postprocess_results,
)
audio_path = "your/audio/path"
text_path = "your/text/path"
language = "iso" # ISO-639-3 Language code
device = "cuda" if torch.cuda.is_available() else "cpu"
batch_size = 16
alignment_model, alignment_tokenizer = load_alignment_model(
device,
dtype=torch.float16 if device == "cuda" else torch.float32,
)
audio_waveform = load_audio(audio_path, alignment_model.dtype, alignment_model.device)
with open(text_path, "r") as f:
lines = f.readlines()
text = "".join(line for line in lines).replace("\n", " ").strip()
emissions, stride = generate_emissions(
alignment_model, audio_waveform, batch_size=batch_size
)
tokens_starred, text_starred = preprocess_text(
text,
romanize=True,
language=language,
)
segments, scores, blank_token = get_alignments(
emissions,
tokens_starred,
alignment_tokenizer,
)
spans = get_spans(tokens_starred, segments, blank_token)
word_timestamps = postprocess_results(text_starred, spans, stride, scores)
Magnet link (secondary — no webseeds)
Opens the swarm directly, but carries no webseed url-list. Prefer the.torrent download above — HTTP fallback seeds ride inside it.
magnet:?xt=urn:btih:ce3a106fb66edafe5178fcb8274142c7244fa07f&dn=MahmoudAshraf_mms-300m-1130-forced-alignerOpen magnet in torrent client · infohash ce3a106fb66edafe5178fcb8274142c7244fa07f
Files & hashes
| Path | Size | Method | Hash |
|---|---|---|---|
| README.md | 2.6 KB (2,690 B) | sha1-git-blob | 3acea9720ea7e9ccc27fd7a63f05c8c3fc774adf |
| config.json | 2.0 KB (2,076 B) | sha1-git-blob | 28eb7322eda1d24b6f83fe9758dfaf0be3067085 |
| model.safetensors | 1.18 GB (1,261,930,388 B) | sha256-lfs | 9aa5229a1af4d7714285cfa14bcaab6af2a39a9e810b475722b24975d5cb1dab |
| preprocessor_config.json | 211 B (211 B) | sha1-git-blob | 15dafdfb87082ed17f859f7620759a95d5d62af2 |
| pytorch_model.bin | 1.18 GB (1,262,019,174 B) | sha256-lfs | 41f8ceea323a46161f63ef6e0a2bf5773129f775f8e4aaa2e6a1727d7311921e |
| special_tokens_map.json | 74 B (74 B) | sha1-git-blob | 79ae7ea5bf033de69d0055820c57885e3d377bbb |
| tokenizer_config.json | 1.0 KB (1,047 B) | sha1-git-blob | cec751d226b084233b9551c06acf09cf37fc8903 |
| vocab.json | 286 B (286 B) | sha1-git-blob | 15a79af668d11a63401c049870a25f7836537c16 |
Provenance
| Upstream repository | MahmoudAshraf/mms-300m-1130-forced-aligner |
|---|---|
| Revision (pinned) | 49402e9577b1158620820667c218cd494cc44486 |
| Fetched at | 2026-08-24T02:11:41Z |
| License at fetch | cc-by-nc-4.0 |
| Snapshot tool | huggingface · seedbank 0.1.0 |
Trackers
- udp://announce.aitorrent.org:6969/announce
- http://announce.aitorrent.org:7070/announce
- udp://announce2.aitorrent.org:6970/announce
- http://announce2.aitorrent.org:7071/announce
- udp://tracker.opentrackr.org:1337/announce
- udp://open.demonii.com:1337/announce
- udp://open.stealth.si:80/announce
- udp://exodus.desync.com:6969/announce
- udp://tracker.torrent.eu.org:451/announce