diff options
author | pjwilliams <pjwilliams@1f5c12ca-751b-0410-a591-d2e778427230> | 2011-06-27 19:13:15 +0400 |
---|---|---|
committer | pjwilliams <pjwilliams@1f5c12ca-751b-0410-a591-d2e778427230> | 2011-06-27 19:13:15 +0400 |
commit | 2451371ca2893b650a67918acebd9007fa830b9b (patch) | |
tree | 4f4d770a75eaf7c77750daae6d38eb2bdc2e43a0 /moses-chart-cmd | |
parent | c7cc79a20ec40a2a987560838e91c3c9eb55ad09 (diff) |
Changes to chart decoder cube pruning: create one cube per dotted rule
instead of one per translation and do 'non-lazy' scoring, i.e. fully
score the corner and neighbor hypotheses inside the rule cube instead
of waiting until an item is popped. The old behaviour -- faster but
with more search errors -- is available via the
cube-pruning-lazy-scoring option.
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@4039 1f5c12ca-751b-0410-a591-d2e778427230
Diffstat (limited to 'moses-chart-cmd')
-rw-r--r-- | moses-chart-cmd/src/IOWrapper.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/moses-chart-cmd/src/IOWrapper.cpp b/moses-chart-cmd/src/IOWrapper.cpp index 39498104b..31ec4c4ee 100644 --- a/moses-chart-cmd/src/IOWrapper.cpp +++ b/moses-chart-cmd/src/IOWrapper.cpp @@ -43,6 +43,10 @@ POSSIBILITY OF SUCH DAMAGE. #include "PhraseDictionary.h" #include "ChartTrellisPathList.h" #include "ChartTrellisPath.h" +#include "ChartTranslationOption.h" +#include "ChartHypothesis.h" +#include "CoveredChartSpan.h" + using namespace std; using namespace Moses; @@ -223,7 +227,11 @@ void OutputTranslationOptions(std::ostream &out, const ChartHypothesis *hypo, lo { // recursive if (hypo != NULL) { - out << "Trans Opt " << translationId << " " << hypo->GetCurrSourceRange() << ": " << hypo->GetTranslationOption() + out << "Trans Opt " << translationId + << " " << hypo->GetCurrSourceRange() + << ": " << hypo->GetTranslationOption().GetLastCoveredChartSpan() + << ": " << hypo->GetCurrTargetPhrase().GetTargetLHS() + << "->" << hypo->GetCurrTargetPhrase() << " " << hypo->GetTotalScore() << hypo->GetScoreBreakdown() << endl; } |