Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gmm-latgen-simple is broken #4870

Closed
csukuangfj opened this issue Aug 29, 2023 · 0 comments · Fixed by #4879
Closed

gmm-latgen-simple is broken #4870

csukuangfj opened this issue Aug 29, 2023 · 0 comments · Fixed by #4879
Labels

Comments

@csukuangfj
Copy link
Contributor

diff --git a/egs/wsj/s5/steps/decode.sh b/egs/wsj/s5/steps/decode.sh
index 8c85724c0..ab12bdcc4 100755
--- a/egs/wsj/s5/steps/decode.sh
+++ b/egs/wsj/s5/steps/decode.sh
@@ -122,7 +122,7 @@ if [ $stage -le 0 ]; then
       { echo "$0: Error: Mismatch in number of pdfs with $model"; exit 1; }
   fi
   $cmd --num-threads $num_threads JOB=1:$nj $dir/log/decode.JOB.log \
-    gmm-latgen-faster$thread_string --max-active=$max_active --beam=$beam --lattice-beam=$lattice_beam \
+    gmm-latgen-simple --beam=$beam --lattice-beam=$lattice_beam \
     --acoustic-scale=$acwt --allow-partial=true --word-symbol-table=$graphdir/words.txt $decode_extra_opts \
     $model $graphdir/HCLG.fst "$feats" "ark:|gzip -c > $dir/lat.JOB.gz" || exit 1;
 fi

With the above changes, the following code breaks

cd egs/yesno/s5
./run.sh

with the following error logs:

steps/decode.sh --nj 1 --cmd utils/run.pl exp/mono0a/graph_tgpr data/test_yesno exp/mono0a/decode_test_yesno
decode.sh: feature type is delta
run.pl: job failed, log is in exp/mono0a/decode_test_yesno/log/decode.1.log
grep: exp/mono0a/decode_test_yesno/wer_*: No such file or directory
(py38) kuangfangjun:s5$ cat exp/mono0a/decode_test_yesno/log/decode.1.log
# gmm-latgen-simple --beam=13.0 --lattice-beam=6.0 --acoustic-scale=0.083333 --allow-partial=true --word-symbol-table=exp/mono0a/graph_tgpr/words.txt exp/mono0a/final.mdl exp/mono0a/graph_tgpr/HCLG.fst "ark,s,cs:apply-cmvn  --utt2spk=ark:data/test_yesno/split1/1/utt2spk scp:data/test_yesno/split1/1/cmvn.scp scp:data/test_yesno/split1/1/feats.scp ark:- | add-deltas  ark:- ark:- |" "ark:|gzip -c > exp/mono0a/decode_test_yesno/lat.1.gz"
# Started at Wed Aug 30 00:49:23 CST 2023
#
gmm-latgen-simple --beam=13.0 --lattice-beam=6.0 --acoustic-scale=0.083333 --allow-partial=true --word-symbol-table=exp/mono0a/graph_tgpr/words.txt exp/mono0a/final.mdl exp/mono0a/graph_tgpr/HCLG.fst 'ark,s,cs:apply-cmvn  --utt2spk=ark:data/test_yesno/split1/1/utt2spk scp:data/test_yesno/split1/1/cmvn.scp scp:data/test_yesno/split1/1/feats.scp ark:- | add-deltas  ark:- ark:- |' 'ark:|gzip -c > exp/mono0a/decode_test_yesno/lat.1.gz'
add-deltas ark:- ark:-
apply-cmvn --utt2spk=ark:data/test_yesno/split1/1/utt2spk scp:data/test_yesno/split1/1/cmvn.scp scp:data/test_yesno/split1/1/feats.scp ark:-
ERROR (gmm-latgen-simple[5.5.1057~2-be222]:ProcessNonemitting():lattice-simple-decoder.cc:574) Error in ProcessEmitting: no surviving tokens: frame is -1

[ Stack-Trace: ]
gmm-latgen-simple(kaldi::MessageLogger::LogMessage() const+0xb42) [0x56134a6471ee]
gmm-latgen-simple(kaldi::MessageLogger::LogAndThrow::operator=(kaldi::MessageLogger const&)+0x21) [0x56134a4a7903]
gmm-latgen-simple(kaldi::LatticeSimpleDecoder::ProcessNonemitting()+0x1cd) [0x56134a4b6fc3]
gmm-latgen-simple(kaldi::LatticeSimpleDecoder::InitDecoding()+0xe3) [0x56134a4b7419]
gmm-latgen-simple(kaldi::LatticeSimpleDecoder::Decode(kaldi::DecodableInterface*)+0x11) [0x56134a4b83ab]
gmm-latgen-simple(kaldi::DecodeUtteranceLatticeSimple(kaldi::LatticeSimpleDecoder&, kaldi::DecodableInterface&, kaldi::TransitionInformation const&,
fst::SymbolTable const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, double, bool, bool, kaldi::TableWriter<kaldi::BasicVectorHolder<int> >*, kaldi::TableWriter<kaldi::BasicVectorHolder<int> >*, kaldi::TableWriter<kaldi::CompactLatticeHolder>*, kaldi::TableWriter<kaldi::LatticeHolder>*, double*)+0x83) [0x56134a4e06cc]
gmm-latgen-simple(main+0xcf5) [0x56134a4a5c2f]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xe7) [0x7f67dd224bf7]
gmm-latgen-simple(_start+0x2a) [0x56134a4a4e5a]

WARNING (gmm-latgen-simple[5.5.1057~2-be222]:Close():kaldi-io.cc:515) Pipe apply-cmvn  --utt2spk=ark:data/test_yesno/split1/1/utt2spk scp:data/test_yesno/split1/1/cmvn.scp scp:data/test_yesno/split1/1/feats.scp ark:- | add-deltas  ark:- ark:- | had nonzero return status 36096
kaldi::KaldiFatalError# Accounting: time=0 threads=1
# Ended (code 255) at Wed Aug 30 00:49:23 CST 2023, elapsed time 0 seconds
@csukuangfj csukuangfj added the bug label Aug 29, 2023
csukuangfj added a commit to csukuangfj/kaldi-hmm-gmm that referenced this issue Aug 30, 2023
danpovey added a commit that referenced this issue Nov 10, 2023
Fix #4870, spurious error in ProcessNonemitting; queue can validly be empty.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant