diff options
author | Hieu Hoang <hieu@hoang.co.uk> | 2013-05-23 21:49:31 +0400 |
---|---|---|
committer | Hieu Hoang <hieu@hoang.co.uk> | 2013-05-23 21:49:31 +0400 |
commit | def03041b7f6ad54f39d9695cedaffceb24ced96 (patch) | |
tree | 36bcc526100fc314cfc8ace7a839cc3fec914261 /moses/ScoreComponentCollection.h | |
parent | 02b6977395405622ac53b3e4f57ab56262d29074 (diff) |
make evaluation of TargetWordInsertionFeature more efficient. It's a normal stateless feature, was evaluating at every hypothesis expansion
Diffstat (limited to 'moses/ScoreComponentCollection.h')
-rw-r--r-- | moses/ScoreComponentCollection.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/moses/ScoreComponentCollection.h b/moses/ScoreComponentCollection.h index afec0ab9d..0884e82bc 100644 --- a/moses/ScoreComponentCollection.h +++ b/moses/ScoreComponentCollection.h @@ -281,8 +281,7 @@ public: m_scores[index] = score; } - //For features which have an unbounded number of components - void Assign(const FeatureFunction*sp, const std::string name, float score) + void Assign(const FeatureFunction*sp, const StringPiece &name, float score) { FName fname(sp->GetScoreProducerDescription(),name); m_scores[fname] = score; |