diff options
Diffstat (limited to 'lm/builder/initial_probabilities.cc')
-rw-r--r-- | lm/builder/initial_probabilities.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lm/builder/initial_probabilities.cc b/lm/builder/initial_probabilities.cc index f6ee334c7..5d19a8973 100644 --- a/lm/builder/initial_probabilities.cc +++ b/lm/builder/initial_probabilities.cc @@ -69,9 +69,12 @@ class PruneNGramStream { block_->SetValidSize(dest_.Base() - block_base); ++block_; StartBlock(); + if (block_) { + currentCount_ = current_.CutoffCount(); + } + } else { + currentCount_ = current_.CutoffCount(); } - - currentCount_ = current_.CutoffCount(); return *this; } |