diff --git a/moses/DecodeStepTranslation.cpp b/moses/DecodeStepTranslation.cpp index f647bbefa..8a11c7f22 100644 --- a/moses/DecodeStepTranslation.cpp +++ b/moses/DecodeStepTranslation.cpp @@ -84,10 +84,9 @@ void DecodeStepTranslation::Process(const TranslationOption &inputPartialTranslO continue; } - outPhrase.GetScoreBreakdown().PlusEquals(transScores); - outPhrase.Evaluate(src); // need to do this as all non-transcores would be screwed up + outPhrase.Merge(targetPhrase, m_newOutputFactors); + outPhrase.Evaluate(src, m_featuresToApply); // need to do this as all non-transcores would be screwed up - outPhrase.MergeFactors(targetPhrase, m_newOutputFactors); TranslationOption *newTransOpt = new TranslationOption(sourceWordsRange, outPhrase); assert(newTransOpt != NULL); diff --git a/moses/TargetPhrase.cpp b/moses/TargetPhrase.cpp index 8c30829eb..d1ca142b0 100644 --- a/moses/TargetPhrase.cpp +++ b/moses/TargetPhrase.cpp @@ -123,10 +123,8 @@ void TargetPhrase::Evaluate(const Phrase &source, const std::vector { Phrase::MergeFactors(copy, factorVec); m_scoreBreakdown.Merge(copy.GetScoreBreakdown()); + m_futureScore += copy.m_futureScore; + m_fullScore += copy.m_fullScore; } TO_STRING_BODY(TargetPhrase);