Skip to content

Commit

Permalink
Update run-multi-zh_hans-zipformer.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
JinZr committed Nov 6, 2023
1 parent 72fd8e2 commit 2aab91e
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/scripts/run-multi-zh_hans-zipformer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,53 @@ for method in modified_beam_search fast_beam_search; do
$repo/test_wavs/DEV_T0000000000.wav \
$repo/test_wavs/DEV_T0000000001.wav \
$repo/test_wavs/DEV_T0000000002.wav
done

log "==== Test icefall-asr-multi-zh-hans-zipformer-ctc-streaming-2023-11-05 ===="
repo_url=https://huggingface.co/zrjin/icefall-asr-multi-zh-hans-zipformer-ctc-streaming-2023-11-05/

log "Downloading pre-trained model from $repo_url"
git lfs install
git clone $repo_url
repo=$(basename $repo_url)


log "Display test files"
tree $repo/
ls -lh $repo/test_wavs/*.wav

pushd $repo/exp
ln -s epoch-20.pt epoch-99.pt
popd

ls -lh $repo/exp/*.pt


./zipformer/pretrained.py \
--checkpoint $repo/exp/epoch-99.pt \
--tokens $repo/data/lang_bpe_2000/tokens.txt \
--use-ctc 1 \
--causal 1 \
--chunk-size 32 \
--left-context-frames 256 \
--method greedy_search \
$repo/test_wavs/DEV_T0000000000.wav \
$repo/test_wavs/DEV_T0000000001.wav \
$repo/test_wavs/DEV_T0000000002.wav

for method in modified_beam_search fast_beam_search; do
log "$method"

./zipformer/pretrained.py \
--method $method \
--beam-size 4 \
--use-ctc 1 \
--checkpoint $repo/exp/epoch-99.pt \
--tokens $repo/data/lang_bpe_2000/tokens.txt \
--causal 1 \
--chunk-size 32 \
--left-context-frames 256 \
$repo/test_wavs/DEV_T0000000000.wav \
$repo/test_wavs/DEV_T0000000001.wav \
$repo/test_wavs/DEV_T0000000002.wav
done

0 comments on commit 2aab91e

Please sign in to comment.