removing outdated method

This commit is contained in:
Ales Tamchyna 2016-03-07 15:49:53 +01:00
parent 7fbbc65902
commit f169c59204

View File

@ -50,20 +50,6 @@ protected:
// 0 = last word of the hypothesis
// 1 = next to last word
// ...etc.
//
// We may have to go through more than one hypothesis when the context is long.
inline std::string GetWord(const Hypothesis *hypo, size_t posFromEnd) const {
while (hypo->GetCurrTargetPhrase().GetSize() <= posFromEnd) {
posFromEnd -= hypo->GetCurrTargetPhrase().GetSize();
hypo = hypo->GetPrevHypo();
if (! hypo)
return BOS_; // translation is not long enough
}
const Phrase &phrase = hypo->GetCurrTargetPhrase();
return phrase.GetWord(phrase.GetSize() - posFromEnd - 1).GetString(m_targetFactors, false);
}
inline std::string GetWord(const Phrase &phrase, size_t posFromEnd) const {
return phrase.GetWord(phrase.GetSize() - posFromEnd - 1).GetString(m_targetFactors, false);
}