Views
No views yet
AsrModel by extracting every weight directly from the deployed ONNX
(GilgameshWind/X-ASR-zh-en,
deployment/models/chunk-480ms-model) — so the community can fine-tune the real model.⚠️ Note: thestreaming_exp/pretrained.ptin the upstream repo is an unrelated checkpoint (its weights are uncorrelated with the deployed ONNX, Pearson r ≈ 0.01, and it decodes to garbage). This reconstruction is taken from the deployment ONNX, which is the only faithful X-ASR.
| forward config | zh-CER | en-WER (punct-stripped) |
|---|---|---|
chunk_size=24, left_context=256 (deployed 480 ms streaming) | 0.0685 | 0.040 |
chunk_size=-1 (offline / full-context) | 0.0500 | 0.033 |
chunk_scale
reproduces the ONNX with maxdiff 0.0.xasr_native.pt — {"model": state_dict}, fp32, trainable (159.7M params).tokens.txt, bpe.model — the X-ASR 5000-token SentencePiece tokenizer.load_xasr.py — builds the exact AsrModel and loads the checkpoint (+ a decode demo).xasr_from_onnx.py — the full, reproducible ONNX→PyTorch extractor.1git clone https://github.com/k2-fsa/icefall
2export PYTHONPATH=icefall/egs/librispeech/ASR/zipformer:icefall:$PYTHONPATH
3python load_xasr.py xasr_native.pt audio_16k_mono.wav # offline greedy decode1from load_xasr import load_xasr
2model = load_xasr("xasr_native.pt", device="cuda") # ready to train or evaltokens.txt/bpe.model); X-ASR emits punctuation, so strip punctuation before scoring WER/CER.
Use the deployed streaming geometry (chunk_size=24, left_context_frames=256) or train multi-chunk.
Re-export to streaming ONNX with icefall's export-onnx-streaming.py for deployment.simple_am_proj / simple_lm_proj are training-only (absent from the inference ONNX). They are
analytically seeded from the joiner here so the pruned-transducer loss starts sane and training
is stable; they refine during fine-tuning.layers.*.bypass_scale parameters are unused by the forward (the layers use the
bypass/bypass_mid modules) and are left at init.snip_edges=False, dither=0.0.GilgameshWind/X-ASR-zh-en (X-ASR authors) using
k2-fsa/icefall. Please credit the original X-ASR authors and icefall.