@@ -126,10 +126,10 @@ bool LatticeFasterDecoderCombineTpl<FST, Token>::GetRawLattice(
126126 KALDI_ERR << " You cannot call FinalizeDecoding() and then call "
127127 << " GetRawLattice() with use_final_probs == false" ;
128128
129- std::unordered_map<Token*, BaseFloat> recover_map ;
129+ std::unordered_map<Token*, BaseFloat> token_orig_cost ;
130130 if (!decoding_finalized_) {
131131 // Process the non-emitting arcs for the unfinished last frame.
132- ProcessNonemitting (&recover_map );
132+ ProcessNonemitting (&token_orig_cost );
133133 }
134134
135135
@@ -202,7 +202,7 @@ bool LatticeFasterDecoderCombineTpl<FST, Token>::GetRawLattice(
202202 }
203203
204204 if (!decoding_finalized_) { // recover last token list
205- RecoverLastTokenList (recover_map );
205+ RecoverLastTokenList (token_orig_cost );
206206 }
207207 return (ofst->NumStates () > 0 );
208208}
@@ -215,13 +215,13 @@ bool LatticeFasterDecoderCombineTpl<FST, Token>::GetRawLattice(
215215// will not be affacted.
216216template <typename FST, typename Token>
217217void LatticeFasterDecoderCombineTpl<FST, Token>::RecoverLastTokenList(
218- const std::unordered_map<Token*, BaseFloat> &recover_map ) {
219- if (!recover_map .empty ()) {
218+ const std::unordered_map<Token*, BaseFloat> &token_orig_cost ) {
219+ if (!token_orig_cost .empty ()) {
220220 for (Token* tok = active_toks_[active_toks_.size () - 1 ].toks ;
221221 tok != NULL ;) {
222- if (recover_map .find (tok) != recover_map .end ()) {
222+ if (token_orig_cost .find (tok) != token_orig_cost .end ()) {
223223 DeleteForwardLinks (tok);
224- tok->tot_cost = recover_map .find (tok)->second ;
224+ tok->tot_cost = token_orig_cost .find (tok)->second ;
225225 tok->in_current_queue = false ;
226226 tok = tok->next ;
227227 } else {
@@ -897,10 +897,10 @@ void LatticeFasterDecoderCombineTpl<FST, Token>::ProcessForFrame(
897897
898898template <typename FST, typename Token>
899899void LatticeFasterDecoderCombineTpl<FST, Token>::ProcessNonemitting(
900- std::unordered_map<Token*, BaseFloat> *recover_map ) {
901- if (recover_map ) { // Build the elements which are used to recover
900+ std::unordered_map<Token*, BaseFloat> *token_orig_cost ) {
901+ if (token_orig_cost ) { // Build the elements which are used to recover
902902 for (IterType iter = cur_toks_.begin (); iter != cur_toks_.end (); iter++) {
903- (*recover_map )[iter->second ] = iter->second ->tot_cost ;
903+ (*token_orig_cost )[iter->second ] = iter->second ->tot_cost ;
904904 }
905905 }
906906
0 commit comments