mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-12-25 04:43:03 +03:00
Actually support multiple output factors for XML-specified translations
This commit is contained in:
parent
b1fb21ecf0
commit
25f0165db7
@ -486,7 +486,8 @@ ProcessAndStripXMLTags(AllOptions const& opts, string &line,
|
||||
// system would have "word", a two-factor system would have
|
||||
// "word|class", and so on.
|
||||
vector<FactorType> fakeOutputFactorOrder;
|
||||
size_t factorsInAltText = Tokenize(altTexts[i], StaticData::Instance().GetFactorDelimiter()).size();
|
||||
// Factors in first word of alt text
|
||||
size_t factorsInAltText = TokenizeMultiCharSeparator(Tokenize(altTexts[i])[0], StaticData::Instance().GetFactorDelimiter()).size();
|
||||
for (size_t f = 0; f < factorsInAltText; ++f) {
|
||||
fakeOutputFactorOrder.push_back(f);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user