mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-08-17 07:20:48 +03:00
TrellisPath::InitTotalScore() and TrellisPath::GetScoreBreakDown() now use compute m_totalScore again in an identical fashion.
This commit is contained in:
parent
3a87b8f193
commit
ffdc9711e9
@ -42,7 +42,7 @@ TrellisPath::TrellisPath(const Hypothesis *hypo)
|
||||
|
||||
void TrellisPath::InitTotalScore()
|
||||
{
|
||||
m_totalScore = m_path[0]->GetWinningHypo()->GetFutureScore();
|
||||
m_totalScore = m_path[0]->GetWinningHypo()->GetFutureScore();
|
||||
|
||||
//calc score
|
||||
size_t sizePath = m_path.size();
|
||||
@ -50,7 +50,7 @@ void TrellisPath::InitTotalScore()
|
||||
const Hypothesis *hypo = m_path[pos];
|
||||
const Hypothesis *winningHypo = hypo->GetWinningHypo();
|
||||
if (hypo != winningHypo) {
|
||||
m_totalScore = m_totalScore - winningHypo->GetFutureScore() + hypo->GetFutureScore();
|
||||
m_totalScore += hypo->GetFutureScore() - winningHypo->GetFutureScore();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user