mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-09-20 23:58:15 +03:00
Integrated handling of oov penalty into irstlm library.
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@1874 1f5c12ca-751b-0410-a591-d2e778427230
This commit is contained in:
parent
7a0e5811ba
commit
842f5842a2
@ -203,12 +203,6 @@ float LanguageModelIRST::GetValue(const vector<const Word*> &contextFactor, Stat
|
||||
|
||||
float prob = m_lmtb->clprob(*m_lmtb_ng);
|
||||
|
||||
//apply OOV penalty if the n-gram starts with an OOV word
|
||||
//in a following version this will be integrated into the
|
||||
//irstlm library
|
||||
|
||||
if (*m_lmtb_ng->wordp(1) == m_lmtb->dict->oovcode())
|
||||
prob-=m_lmtb->getlogOOVpenalty();
|
||||
|
||||
return TransformIRSTScore(prob);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user