mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-12-26 05:14:36 +03:00
use new constructor
This commit is contained in:
parent
ed4921c0c9
commit
63cd5d4faf
@ -838,6 +838,9 @@ bool StaticData::LoadPhraseTables()
|
||||
if (implementation == SuffixArray) {
|
||||
targetPath = token[5];
|
||||
alignmentsFile= token[6];
|
||||
|
||||
ptLine << "target-path=" << targetPath << " ";
|
||||
ptLine << "alignment-path=" << alignmentsFile << " ";
|
||||
}
|
||||
|
||||
//This is needed for regression testing, but the phrase table
|
||||
@ -846,6 +849,8 @@ bool StaticData::LoadPhraseTables()
|
||||
PrintUserTime(string("Start loading PhraseTable ") + filePath);
|
||||
VERBOSE(1,"filePath: " << filePath <<endl);
|
||||
|
||||
PhraseDictionaryFeature* pdf = new PhraseDictionaryFeature(ptLine.str());
|
||||
/*
|
||||
PhraseDictionaryFeature* pdf = new PhraseDictionaryFeature(
|
||||
implementation
|
||||
, numScoreComponent
|
||||
@ -855,6 +860,7 @@ bool StaticData::LoadPhraseTables()
|
||||
, filePath
|
||||
, maxTargetPhrase[currDict]
|
||||
, targetPath, alignmentsFile);
|
||||
*/
|
||||
|
||||
//optional create sparse phrase feature
|
||||
if (m_sparsePhraseDictionary.size() > currDict) {
|
||||
|
@ -81,7 +81,17 @@ PhraseDictionaryFeature::PhraseDictionaryFeature(const std::string &line)
|
||||
else if (args[0] == "table-limit") {
|
||||
m_tableLimit = Scan<size_t>(args[1]);
|
||||
}
|
||||
else if (args[0] == "target-path") {
|
||||
m_targetFile = args[1];
|
||||
}
|
||||
else if (args[0] == "alignment-path") {
|
||||
m_alignmentsFile = args[1];
|
||||
}
|
||||
|
||||
else {
|
||||
UserMessage::Add("Unknown argument " + args[0]);
|
||||
abort();
|
||||
}
|
||||
} // for (size_t i = 0; i < toks.size(); ++i) {
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user