Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <hieuhoang@gmail.com>2015-11-09 15:23:43 +0300
committerHieu Hoang <hieuhoang@gmail.com>2015-11-09 15:23:43 +0300
commit176573c0724a65be8c36e5b5c3890d201f936d63 (patch)
tree200b8d0c0d1f2c0eafff620c7fb20232fb1c3bae /moses/Hypothesis.cpp
parent09bf755305c4895d20cc6cb3d1679483c168bbca (diff)
Consistent naming: m_futureScore --> m_estimatedScore
Diffstat (limited to 'moses/Hypothesis.cpp')
-rw-r--r--moses/Hypothesis.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/moses/Hypothesis.cpp b/moses/Hypothesis.cpp
index 44124bc81..de4f1849b 100644
--- a/moses/Hypothesis.cpp
+++ b/moses/Hypothesis.cpp
@@ -54,7 +54,7 @@ Hypothesis(Manager& manager, InputType const& source, const TranslationOption &i
, m_currTargetWordsRange(NOT_FOUND, NOT_FOUND)
, m_wordDeleted(false)
, m_totalScore(0.0f)
- , m_futureScore(0.0f)
+ , m_estimatedScore(0.0f)
, m_ffStates(StatefulFeatureFunction::GetStatefulFeatureFunctions().size())
, m_arcList(NULL)
, m_transOpt(initialTransOpt)
@@ -85,7 +85,7 @@ Hypothesis(const Hypothesis &prevHypo, const TranslationOption &transOpt, const
+ transOpt.GetTargetPhrase().GetSize())
, m_wordDeleted(false)
, m_totalScore(0.0f)
- , m_futureScore(0.0f)
+ , m_estimatedScore(0.0f)
, m_ffStates(prevHypo.m_ffStates.size())
, m_arcList(NULL)
, m_transOpt(transOpt)
@@ -206,10 +206,10 @@ EvaluateWhenApplied(float futureScore)
}
// FUTURE COST
- m_futureScore = futureScore;
+ m_estimatedScore = futureScore;
// TOTAL
- m_totalScore = m_currScoreBreakdown.GetWeightedScore() + m_futureScore;
+ m_totalScore = m_currScoreBreakdown.GetWeightedScore() + m_estimatedScore;
if (m_prevHypo) m_totalScore += m_prevHypo->GetScore();
IFVERBOSE(2) {
@@ -247,7 +247,7 @@ PrintHypothesis() const
TRACE_ERR( m_prevHypo->GetCurrTargetPhrase().GetSubString(range) << " ");
}
TRACE_ERR( ")"<<endl);
- TRACE_ERR( "\tbase score "<< (m_prevHypo->m_totalScore - m_prevHypo->m_futureScore) <<endl);
+ TRACE_ERR( "\tbase score "<< (m_prevHypo->m_totalScore - m_prevHypo->m_estimatedScore) <<endl);
TRACE_ERR( "\tcovering "<<m_currSourceWordsRange.GetStartPos()<<"-"<<m_currSourceWordsRange.GetEndPos()
<<": " << m_transOpt.GetInputPath().GetPhrase() << endl);
@@ -257,7 +257,7 @@ PrintHypothesis() const
// TRACE_ERR( "\tdistance: "<<GetCurrSourceWordsRange().CalcDistortion(m_prevHypo->GetCurrSourceWordsRange())); // << " => distortion cost "<<(m_score[ScoreType::Distortion]*weightDistortion)<<endl;
// TRACE_ERR( "\tlanguage model cost "); // <<m_score[ScoreType::LanguageModelScore]<<endl;
// TRACE_ERR( "\tword penalty "); // <<(m_score[ScoreType::WordPenalty]*weightWordPenalty)<<endl;
- TRACE_ERR( "\tscore "<<m_totalScore - m_futureScore<<" + future cost "<<m_futureScore<<" = "<<m_totalScore<<endl);
+ TRACE_ERR( "\tscore "<<m_totalScore - m_estimatedScore<<" + future cost "<<m_estimatedScore<<" = "<<m_totalScore<<endl);
TRACE_ERR( "\tunweighted feature scores: " << m_currScoreBreakdown << endl);
//PrintLMScores();
}
@@ -609,8 +609,8 @@ beats(Hypothesis const& b) const
{
if (m_totalScore != b.m_totalScore)
return m_totalScore > b.m_totalScore;
- else if (m_futureScore != b.m_futureScore)
- return m_futureScore > b.m_futureScore;
+ else if (m_estimatedScore != b.m_estimatedScore)
+ return m_estimatedScore > b.m_estimatedScore;
else if (m_prevHypo)
return b.m_prevHypo ? m_prevHypo->beats(*b.m_prevHypo) : true;
else return false;