Support getting word IDs for CTC HLG decoding. (#978)
This commit is contained in:
@@ -108,6 +108,9 @@ static OfflineCtcDecoderResult DecodeOne(kaldi_decoder::FasterDecoder *decoder,
|
||||
// -1 here since the input labels are incremented during graph
|
||||
// construction
|
||||
r.tokens.push_back(arc.ilabel - 1);
|
||||
if (arc.olabel != 0) {
|
||||
r.words.push_back(arc.olabel);
|
||||
}
|
||||
|
||||
r.timestamps.push_back(t);
|
||||
prev = arc.ilabel;
|
||||
|
||||
Reference in New Issue
Block a user