summaryrefslogtreecommitdiff
path: root/decoder/viterbi.h
diff options
context:
space:
mode:
Diffstat (limited to 'decoder/viterbi.h')
-rw-r--r--decoder/viterbi.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/decoder/viterbi.h b/decoder/viterbi.h
index dd54752a..d4a97516 100644
--- a/decoder/viterbi.h
+++ b/decoder/viterbi.h
@@ -6,6 +6,8 @@
#include "hg.h"
#include "tdict.h"
+std::string viterbi_stats(Hypergraph const& hg, std::string const& name="forest", bool estring=true, bool etree=false);
+
// V must implement:
// void operator()(const vector<const T*>& ants, T* result);
template<typename T, typename Traversal, typename WeightType, typename WeightFunction>
@@ -21,7 +23,7 @@ WeightType Viterbi(const Hypergraph& hg,
const Hypergraph::Node& cur_node = hg.nodes_[i];
WeightType* const cur_node_best_weight = &vit_weight[i];
T* const cur_node_best_result = &vit_result[i];
-
+
const int num_in_edges = cur_node.in_edges_.size();
if (num_in_edges == 0) {
*cur_node_best_weight = WeightType(1);