From 2904395c21ba31d2d36ad55ef77433dde3a61558 Mon Sep 17 00:00:00 2001
From: 嘉渊 <wangjiaming.wjm@alibaba-inc.com>
Date: 星期三, 24 五月 2023 16:25:50 +0800
Subject: [PATCH] update repo
---
egs/aishell/paraformer/run.sh | 18 ++++++++++++------
1 files changed, 12 insertions(+), 6 deletions(-)
diff --git a/egs/aishell/paraformer/run.sh b/egs/aishell/paraformer/run.sh
index 9723426..373c119 100755
--- a/egs/aishell/paraformer/run.sh
+++ b/egs/aishell/paraformer/run.sh
@@ -28,7 +28,7 @@
nj=64
# data
-raw_data=
+raw_data=../raw_data
data_url=www.openslr.org/resources/33
# exp tag
@@ -85,7 +85,7 @@
if [ ${stage} -le 1 ] && [ ${stop_stage} -ge 1 ]; then
echo "stage 1: Feature and CMVN Generation"
- utils/compute_cmvn.sh --cmd "$train_cmd" --nj $nj --feats_dim ${feats_dim} ${feats_dir}/data/${train_set}
+ utils/compute_cmvn.sh ${feats_dir}/data/${train_set} --cmd "$train_cmd" --nj $nj --feats_dim ${feats_dim} --config $asr_config --scale 1.0
fi
token_list=${feats_dir}/data/${lang}_token_list/char/tokens.txt
@@ -103,13 +103,13 @@
echo "<unk>" >> ${token_list}
fi
-# ASR Training Stage
+# LM Training Stage
world_size=$gpu_num # run on one machine
if [ ${stage} -le 3 ] && [ ${stop_stage} -ge 3 ]; then
echo "stage 3: LM Training"
fi
-# Training Stage
+# ASR Training Stage
world_size=$gpu_num # run on one machine
if [ ${stage} -le 4 ] && [ ${stop_stage} -ge 4 ]; then
echo "stage 4: ASR Training"
@@ -132,11 +132,12 @@
--use_preprocessor true \
--token_type char \
--token_list $token_list \
+ --dataset_type small \
--data_dir ${feats_dir}/data \
--train_set ${train_set} \
--valid_set ${valid_set} \
--data_file_names "wav.scp,text" \
- --cmvn_file ${feats_dir}/data/${train_set}/cmvn/cmvn.mvn \
+ --cmvn_file ${feats_dir}/data/${train_set}/cmvn/am.mvn \
--speed_perturb ${speed_perturb} \
--resume true \
--output_dir ${exp_dir}/exp/${model_dir} \
@@ -186,7 +187,7 @@
--njob ${njob} \
--gpuid_list ${gpuid_list} \
--data_path_and_name_and_type "${_data}/${scp},speech,${type}" \
- --cmvn_file ${feats_dir}/data/${train_set}/cmvn/cmvn.mvn \
+ --cmvn_file ${feats_dir}/data/${train_set}/cmvn/am.mvn \
--key_file "${_logdir}"/keys.JOB.scp \
--asr_train_config "${asr_exp}"/config.yaml \
--asr_model_file "${asr_exp}"/"${inference_asr_model}" \
@@ -207,4 +208,9 @@
tail -n 3 ${_dir}/text.cer > ${_dir}/text.cer.txt
cat ${_dir}/text.cer.txt
done
+fi
+
+# Prepare files for ModelScope fine-tuning and inference
+if [ ${stage} -le 6 ] && [ ${stop_stage} -ge 6 ]; then
+ echo "stage 6: ModelScope Preparation"
fi
\ No newline at end of file
--
Gitblit v1.9.1