当前位置: 首页 > 工具软件 > things.sh > 使用案例 >

kaldi中thchs关于path.sh和cmd.sh

洪飞白
2023-12-01
export KALDI_ROOT=`pwd`/../../..
# 告诉外面kaldi_root在哪里
[ -f $KALDI_ROOT/tools/env.sh ] && . $KALDI_ROOT/tools/env.sh
#是否存在正常文件并且执行这个文件
export PATH=$PWD/utils/:$KALDI_ROOT/tools/openfst/bin:$PWD:$PATH
# :代表路径分隔符,将上述变量都加入到环境变量
[ ! -f $KALDI_ROOT/tools/config/common_path.sh ] && echo >&2 "The standard file $KALDI_ROOT/tools/config/common_path.sh is not present -> Exit!" && exit 1
#不存在正常文件并且打印""中的这一段话
. $KALDI_ROOT/tools/config/common_path.sh #执行 公共的环境变量
export LC_ALL=C
#去除所有本地化的设置

 设置环境变量

# you can change cmd.sh depending on what type of queue you are using.
# If you have no queueing system and want to run on a local machine, you
# can change all instances 'queue.pl' to run.pl (but be careful and run
# commands one by one: most recipes will exhaust the memory on your
# machine).  queue.pl works with GridEngine (qsub).  slurm.pl works
# with slurm.  Different queues are configured differently, with different
# queue names and different ways of specifying things like memory;
# to account for these differences you can create and edit the file
# conf/queue.conf to match your queue's configuration.  Search for
# conf/queue.conf in http://kaldi-asr.org/doc/queue.html for more information,
# or search for the string 'default_config' in utils/queue.pl or utils/slurm.pl.

export train_cmd=queue.pl
export decode_cmd="queue.pl --mem 4G"
export mkgraph_cmd="queue.pl --mem 8G"
export cuda_cmd="queue.pl --gpu 1"

把queue,pl换成run.pl

 类似资料: