diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2012-06-05 15:47:09 -0400 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2012-06-05 15:47:09 -0400 |
commit | 23c7a1ed9f4d2360f8e1183539e3569fdbf60b48 (patch) | |
tree | 5cffb41d2cccb7ec3cc4583be12d78d1cedd9544 /decoder/ff_klm.cc | |
parent | 84bc2dd5a966eea898d4c0213205fd3917b285f4 (diff) | |
parent | 98e13188c40adf13b73ca994d3410f3e87d20355 (diff) |
Merge branch 'master' of github.com:redpony/cdec
Diffstat (limited to 'decoder/ff_klm.cc')
-rw-r--r-- | decoder/ff_klm.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/decoder/ff_klm.cc b/decoder/ff_klm.cc index 7a84add7..09ef282c 100644 --- a/decoder/ff_klm.cc +++ b/decoder/ff_klm.cc @@ -11,6 +11,7 @@ #include "tdict.h" #include "lm/model.hh" #include "lm/enumerate_vocab.hh" +#include "utils/verbose.h" #include "lm/left.hh" @@ -232,7 +233,8 @@ class KLanguageModelImpl { ngram_ = new Model(filename.c_str(), conf); } order_ = ngram_->Order(); - cerr << "Loaded " << order_ << "-gram KLM from " << filename << " (MapSize=" << cdec2klm_map_.size() << ")\n"; + if (!SILENT) + cerr << "Loaded " << order_ << "-gram KLM from " << filename << " (MapSize=" << cdec2klm_map_.size() << ")\n"; // special handling of beginning / ending sentence markers kSOS_ = MapWord(kCDEC_SOS); @@ -252,7 +254,8 @@ class KLanguageModelImpl { string line; vector<WordID> dummy; int lc = 0; - cerr << " Loading word classes from " << file << " ...\n"; + if (!SILENT) + cerr << " Loading word classes from " << file << " ...\n"; AddWordToClassMapping_(TD::Convert("<s>"), TD::Convert("<s>")); AddWordToClassMapping_(TD::Convert("</s>"), TD::Convert("</s>")); while(in) { |