Skip to content

Commit

Permalink
egs/aspire : minor changes to decode scripts; does not affect results
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.code.sf.net/p/kaldi/code/trunk@5233 5e6a8d80-dfce-4ca6-a32a-6e07a63d50c8
  • Loading branch information
vijayaditya committed Jul 13, 2015
1 parent d2b1cdd commit 78bb233
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 10 deletions.
6 changes: 4 additions & 2 deletions egs/aspire/s5/local/multi_condition/prep_test_aspire.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ dir=$3 # exp/nnet2_multicondition/nnet_ms_a

model_affix=`basename $dir`
ivector_dir=`dirname $dir`
ivector_affix=${affix:+_$affix}_$model_affix
ivector_affix=${affix:+_$affix}_${model_affix}_iter$iter
affix=_${affix}_iter${iter}
act_data_dir=${data_dir}
if [ "$data_dir" == "test_aspire" ]; then
Expand Down Expand Up @@ -352,5 +352,7 @@ fi

if [ $stage -le 13 ]; then
cat $decode_dir/score_$LMWT/penalty_$word_ins_penalty/ctm.filt | awk '{split($1, parts, "-"); printf("%s 1 %s %s %s\n", parts[1], $3, $4, $5)}' > $out_file
echo "Generated the ctm @ $out_file from the ctm file $decode_dir/score_${LMWT}/penalty_$word_ins_penalty/ctm.filt"
cat data/${segmented_data_dir}_hires/wav.scp | awk '{split($1, parts, "-"); printf("%s\n", parts[1])}' > $decode_dir/score_$LMWT/penalty_$word_ins_penalty/recording_names
local/multi_condition/fill_missing_recordings.py $out_file $out_file.submission $decode_dir/score_$LMWT/penalty_$word_ins_penalty/recording_names
echo "Generated the ctm @ $out_file.submission from the ctm file $decode_dir/score_${LMWT}/penalty_$word_ins_penalty/ctm.filt"
fi
2 changes: 2 additions & 0 deletions egs/aspire/s5/local/multi_condition/run_nnet2_common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
. cmd.sh

stage=1
snrs="20:10:15:5:0"
num_data_reps=3
dest_wav_dir=data/rvb_wavs # directory to store the reverberated wav files
ali_dir=exp/
Expand Down Expand Up @@ -45,6 +46,7 @@ if [ $stage -le 1 ]; then
cur_dest_dir=" data/temp_${data_dir}_${i}"
local/multi_condition/reverberate_data_dir.sh --random-seed $i --log-dir exp/make_reverb/log \
--dest-wav-dir ${dest_wav_dir}/wavs${i}/ \
--snrs "$snrs" --log-dir exp/make_corrupted_wav \
data/${data_dir} data/impulses_noises $cur_dest_dir
reverb_data_dirs+=" $cur_dest_dir"
done
Expand Down
9 changes: 1 addition & 8 deletions egs/aspire/s5/local/multi_condition/run_nnet2_ms_disc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -134,13 +134,6 @@ if [ $stage -le 4 ]; then
fi

if [ $stage -le 5 ]; then
for epoch in $(seq $decode_start_epoch $num_epochs); do
steps/nnet2/adjust_priors.sh --iter epoch${epoch} --out-model epoch${epoch} \
${srcdir}/egs ${srcdir}_${criterion}_${learning_rate}_nj${num_jobs_nnet}
done
fi

if [ $stage -le 6 ]; then
dir=${srcdir}_${criterion}_${learning_rate}_nj${num_jobs_nnet}
#ln -sf $(readlink -f ${srcdir}_multicondition/conf) $dir/conf # so it acts like an online-decoding directory
graph_dir=exp/tri5a/graph
Expand All @@ -154,7 +147,7 @@ if [ $stage -le 6 ]; then
for dir in $dir/decode*; do grep WER $dir/wer_* | utils/best_wer.sh; done
fi

if [ $stage -le 7 ] && $cleanup; then
if [ $stage -le 6 ] && $cleanup; then
# if you run with "--cleanup true --stage 6" you can clean up.
rm ${srcdir}_denlats/lat.*.gz || true
rm ${srcdir}_ali/ali.*.gz || true
Expand Down

0 comments on commit 78bb233

Please sign in to comment.