diff options
author | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-24 21:24:59 +0000 |
---|---|---|
committer | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-24 21:24:59 +0000 |
commit | 8c4670939f2faa4c5145823302ded212b30f631e (patch) | |
tree | 36edd096de4a51b8073c539d0531e628aab3dc94 /decoder/ff_fsa.h | |
parent | 5bc0b9b1fc76064d13d2c553c019a381ee52dfa1 (diff) |
compile
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@400 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/ff_fsa.h')
-rwxr-xr-x | decoder/ff_fsa.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/decoder/ff_fsa.h b/decoder/ff_fsa.h index 0a7aebde..e199ec04 100755 --- a/decoder/ff_fsa.h +++ b/decoder/ff_fsa.h @@ -136,7 +136,7 @@ public: // NOTE: if you want to e.g. track statistics, cache, whatever, cast const away or use mutable members inline void Scan(SentenceMetadata const& smeta,const Hypergraph::Edge& edge,WordID w,void const* state,void *next_state,FeatureVector *features) const { - features->add_value(fid_,Scan1(w,state,next_state)); + features->maybe_add(fid_,Scan1(w,state,next_state)); } // don't set state-bytes etc. in ctor because it may depend on parsing param string @@ -244,7 +244,7 @@ public: int markov_order() const { return 1; } Featval ScanT1(WordID w,int prevlen,int &len) const { return 0; } inline void ScanT(SentenceMetadata const& smeta,const Hypergraph::Edge& edge,WordID w,int prevlen,int &len,FeatureVector *features) const { - features->add_value(d().fid_,d().ScanT1(w,prevlen,len)); + features->maybe_add(d().fid_,d().ScanT1(w,prevlen,len)); } inline void Scan(SentenceMetadata const& smeta,const Hypergraph::Edge& edge,WordID w,void const* st,void *next_state,FeatureVector *features) const { |