conf net fix

git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1981 1f5c12ca-751b-0410-a591-d2e778427230
This commit is contained in:
hieuhoang1972 2009-01-15 18:12:53 +00:00
parent 5161b380d5
commit f076b03c10

View File

@ -621,16 +621,16 @@ void TranslationOptionCollection::CacheLexReordering()
for(iterTransOpt = transOptList.begin() ; iterTransOpt != transOptList.end() ; ++iterTransOpt)
{
TranslationOption &transOpt = **iterTransOpt;
Phrase sourcePhrase = m_source.GetSubString(WordsRange(startPos,endPos));
//const Phrase *sourcePhrase = transOpt.GetSourcePhrase();
//if (sourcePhrase)
//{
Score score = lexreordering.GetProb(sourcePhrase
, transOpt.GetTargetPhrase());
//Phrase sourcePhrase = m_source.GetSubString(WordsRange(startPos,endPos));
const Phrase *sourcePhrase = transOpt.GetSourcePhrase();
if (sourcePhrase)
{
Score score = lexreordering.GetProb(*sourcePhrase
, transOpt.GetTargetPhrase());
// TODO should have better handling of unknown reordering entries
if (!score.empty())
transOpt.CacheReorderingProb(lexreordering, score);
//}
}
}
}
}