From b96f8ca79c3293062a4b24266e07859cedc936c2 Mon Sep 17 00:00:00 2001 From: "graehl@gmail.com" Date: Mon, 9 Aug 2010 06:14:04 +0000 Subject: hg sort in_edges by viterbi, debug print temporarily enabled which always --show_derivation git-svn-id: https://ws10smt.googlecode.com/svn/trunk@494 ec762483-ff6d-05da-a07a-a48fb63a330f --- decoder/viterbi.cc | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'decoder/viterbi.cc') diff --git a/decoder/viterbi.cc b/decoder/viterbi.cc index b21139df..6bcc97db 100644 --- a/decoder/viterbi.cc +++ b/decoder/viterbi.cc @@ -5,6 +5,8 @@ #include #include "hg.h" +#define DEBUG_VITERBI_SORT + using namespace std; std::string viterbi_stats(Hypergraph const& hg, std::string const& name, bool estring, bool etree,bool show_derivation) @@ -25,7 +27,12 @@ std::string viterbi_stats(Hypergraph const& hg, std::string const& name, bool es o << hg.show_viterbi_tree(false); // last item should be goal (or at least depend on prev items). TODO: this doesn't actually reorder the nodes in hg. o<(hg).ViterbiSortInEdges(); + o<