From 28f2a235be95f1638e3b2e101fccdeb07ede6078 Mon Sep 17 00:00:00 2001 From: graehl Date: Wed, 1 Sep 2010 20:01:24 +0000 Subject: compile git-svn-id: https://ws10smt.googlecode.com/svn/trunk@640 ec762483-ff6d-05da-a07a-a48fb63a330f --- decoder/apply_fsa_models.cc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'decoder') diff --git a/decoder/apply_fsa_models.cc b/decoder/apply_fsa_models.cc index bffd7033..6031dbab 100755 --- a/decoder/apply_fsa_models.cc +++ b/decoder/apply_fsa_models.cc @@ -164,7 +164,7 @@ struct PrefixTrieEdge { //note: ending a rule is handled with a special final edge, so that possibility can be explored in best-first order along with the rest (alternative: always finish a final rule by putting it on queue). this edge has no symbol on it. struct PrefixTrieNode { best_t p; // viterbi (max prob) of rule this node leads to - when building. telescope later onto edges for best-first. - bool final; // may also have successors, of course. we don't really need to track this; a null dest edge in the adj list lets us encounter the fact in best first order. +// bool final; // may also have successors, of course. we don't really need to track this; a null dest edge in the adj list lets us encounter the fact in best first order. typedef TrieBackP BP; typedef std::vector BPs; void back_vec(BPs &ns) const { @@ -338,7 +338,7 @@ public: void set_final(NTHandle lhs_,best_t pf) { assert(no_adj()); - final=true; +// final=true; PrefixTrieEdge &e=edge_for[null_wordid]; e.p=pf; e.dest=0; @@ -500,15 +500,15 @@ typedef Item *ItemP; #endif struct Item : ItemPrio,ItemKey { - explicit Item(NodeP dot,int next=0) : ItemKey(dot),next(next),from(0) + explicit Item(NodeP dot,int next=0) : ItemKey(dot),trienext(next),from(0) INIT_LOCATION { } - explicit Item(NodeP dot,FFState const& state,int next=0) : ItemKey(dot,state),next(next),from(0) + explicit Item(NodeP dot,FFState const& state,int next=0) : ItemKey(dot,state),trienext(next),from(0) INIT_LOCATION { } typedef std::queue Predicted; Predicted predicted; // this is empty, unless this is a predicted L -> .asdf item, or a to-complete L -> asdf . - int next; // index of dot->adj to complete (if dest==0), or predict (if NT), or scan (if word). note: we could store pointer inside adj since it and trie are @ fixed addrs. less pointer arith, more space. + int trienext; // index of dot->adj to complete (if dest==0), or predict (if NT), or scan (if word). note: we could store pointer inside adj since it and trie are @ fixed addrs. less pointer arith, more space. ItemP from; //backpointer - 0 for L -> . asdf for the rest; L -> a .sdf, it's the L -> .asdf item. ItemP predicted_from() const { ItemP p=(ItemP)this; @@ -521,7 +521,7 @@ struct Item : ItemPrio,ItemKey { ItemKey::print(o); o<<' '; ItemPrio::print(o); - o<<" next="<