mirror of
https://github.com/modelscope/FunASR
synced 2025-09-15 14:48:36 +08:00
* multi tokenizer * support fsmn_kws, fsmn_kws_mt, sanm_kws, sanm_kws_streaming training * kws --------- Co-authored-by: pengteng.spt <pengteng.spt@alibaba-inc.com>
21 lines
650 B
Bash
21 lines
650 B
Bash
# Copyright FunASR (https://github.com/alibaba-damo-academy/FunASR). All Rights Reserved.
|
|
# MIT License (https://opensource.org/licenses/MIT)
|
|
|
|
# method1, inference from model hub
|
|
|
|
model="iic/speech_sanm_kws_phone-xiaoyun-commands-offline"
|
|
|
|
# for more input type, please ref to readme.md
|
|
input="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/KWS/pos_testset/kws_xiaoyunxiaoyun.wav"
|
|
|
|
keywords=(小云小云)
|
|
keywords_string=$(IFS=,; echo "${keywords[*]}")
|
|
echo "keywords: $keywords_string"
|
|
|
|
python funasr/bin/inference.py \
|
|
+model=${model} \
|
|
+input=${input} \
|
|
+output_dir="./outputs/debug" \
|
|
+device="cpu" \
|
|
++keywords="\"$keywords_string"\"
|