diff options
author | graehl@gmail.com <graehl@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-08-02 07:57:23 +0000 |
---|---|---|
committer | graehl@gmail.com <graehl@gmail.com@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-08-02 07:57:23 +0000 |
commit | f9859ad4116733e145d7b8eb31c3cc9318ff7564 (patch) | |
tree | 92f6942fc7fd7066eb400bce6d2cbd2fee46c801 /decoder/earley_composer.cc | |
parent | 6da285dfa7b0a1929dcec882d7e48a585e878d18 (diff) |
fake tdict names for non-ids, push viterbi cost to root in hg, store as feature. type erased fsa feature via virtual interface. made lexical_cast assume C locale for speed.
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@465 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/earley_composer.cc')
-rw-r--r-- | decoder/earley_composer.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/decoder/earley_composer.cc b/decoder/earley_composer.cc index f6a01e52..48e94a31 100644 --- a/decoder/earley_composer.cc +++ b/decoder/earley_composer.cc @@ -9,7 +9,7 @@ #include <boost/shared_ptr.hpp> #include <boost/program_options.hpp> #include <boost/program_options/variables_map.hpp> -#include <boost/lexical_cast.hpp> +#include "fast_lexical_cast.hpp" #include "phrasetable_fst.h" #include "sparse_vector.h" @@ -206,15 +206,15 @@ ostream& operator<<(ostream& os, const Edge& e) { if (e.IsCreatedByScan()) type = "SCAN"; else if (e.IsCreatedByComplete()) - type = "COMPLETE"; + type = "COMPLETE"; os << "[" #ifdef DEBUG_CHART_PARSER << '(' << e.id << ") " #else << '(' << &e << ") " #endif - << "q=" << e.q << ", r=" << e.r - << ", cat="<< TD::Convert(e.cat*-1) << ", dot=" + << "q=" << e.q << ", r=" << e.r + << ", cat="<< TD::Convert(e.cat*-1) << ", dot=" << e.dot #ifdef DEBUG_CHART_PARSER << e.dot->hint @@ -588,7 +588,7 @@ class EarleyComposerImpl { assert(!"self-loop found!"); } #endif - Hypergraph::Edge* hg_edge = NULL; + Hypergraph::Edge* hg_edge = NULL; if (tail.size() == 0) { hg_edge = hg->AddEdge(kEPSRule, tail); } else if (tail.size() == 1) { |