From 39cbe718540d408fc7432c04f1602b2e34f959d3 Mon Sep 17 00:00:00 2001 From: Hieu Hoang Date: Fri, 29 Jul 2016 21:51:35 +0100 Subject: [PATCH] delete unused fn --- contrib/other-builds/moses2/Scores.cpp | 19 ------------------- contrib/other-builds/moses2/Scores.h | 4 ---- 2 files changed, 23 deletions(-) diff --git a/contrib/other-builds/moses2/Scores.cpp b/contrib/other-builds/moses2/Scores.cpp index 4994bc125..4a2da5e5e 100644 --- a/contrib/other-builds/moses2/Scores.cpp +++ b/contrib/other-builds/moses2/Scores.cpp @@ -117,25 +117,6 @@ void Scores::PlusEquals(const System &system, } } -void Scores::PlusEquals(const System &system, - const FeatureFunction &featureFunction, const Vector &scores) -{ - assert(scores.size() == featureFunction.GetNumScores()); - - const Weights &weights = system.weights; - - size_t ffStartInd = featureFunction.GetStartInd(); - for (size_t i = 0; i < scores.size(); ++i) { - SCORE incrScore = scores[i]; - if (system.options.nbest.nbest_size) { - m_scores[ffStartInd + i] += incrScore; - } - //cerr << "ffStartInd=" << ffStartInd << " " << i << endl; - SCORE weight = weights[ffStartInd + i]; - m_total += incrScore * weight; - } -} - void Scores::PlusEquals(const System &system, const FeatureFunction &featureFunction, SCORE scores[]) { diff --git a/contrib/other-builds/moses2/Scores.h b/contrib/other-builds/moses2/Scores.h index 95e3db2d1..ef4896ad1 100644 --- a/contrib/other-builds/moses2/Scores.h +++ b/contrib/other-builds/moses2/Scores.h @@ -10,7 +10,6 @@ #include #include "TypeDef.h" #include "MemPool.h" -#include "Vector.h" namespace Moses2 { @@ -48,9 +47,6 @@ public: void PlusEquals(const System &system, const FeatureFunction &featureFunction, const std::vector &scores); - void PlusEquals(const System &system, const FeatureFunction &featureFunction, - const Vector &scores); - void PlusEquals(const System &system, const FeatureFunction &featureFunction, SCORE scores[]);