diff options
author | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-31 05:10:54 +0000 |
---|---|---|
committer | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-31 05:10:54 +0000 |
commit | 526efd6515eb9efdcc1fe756c3cec4981ca10186 (patch) | |
tree | 788fbbc985492f76afac5bdbef769e8fb6410ea2 /decoder/ff_lm_fsa.h | |
parent | 56400a763cb2e56738fe82034dec5769b6d171a8 (diff) |
shorten_left comment
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@464 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/ff_lm_fsa.h')
-rwxr-xr-x | decoder/ff_lm_fsa.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/decoder/ff_lm_fsa.h b/decoder/ff_lm_fsa.h index 9ba7b2c5..df11ab18 100755 --- a/decoder/ff_lm_fsa.h +++ b/decoder/ff_lm_fsa.h @@ -44,7 +44,9 @@ struct LanguageModelFsa : public FsaFeatureFunctionBase<LanguageModelFsa> { template <class Accum> void ScanAccum(SentenceMetadata const& /* smeta */,Hypergraph::Edge const& edge,WordID w,void const* old_st,void *new_st,Accum *a) const { +#if USE_INFO_EDGE Hypergraph::Edge &de=(Hypergraph::Edge &)edge; +#endif if (!ctxlen_) { Add(floored(pimpl_->WordProb(w,&empty_context)),a); return; @@ -72,7 +74,9 @@ struct LanguageModelFsa : public FsaFeatureFunctionBase<LanguageModelFsa> { //FIXME: there is a bug in here somewhere, or else the 3gram LM we use gives different scores for phrases (impossible? BOW nonzero when shortening context past what LM has?) template <class Accum> void ScanPhraseAccum(SentenceMetadata const& /* smeta */,const Hypergraph::Edge&edge,WordID const* begin,WordID const* end,void const* old_st,void *new_st,Accum *a) const { +# if USE_INFO_EDGE Hypergraph::Edge &de=(Hypergraph::Edge &)edge; +# endif if (begin==end) return; // otherwise w/ shortening it's possible to end up with no words at all. /* // this is forcing unigram prob always. we will instead build the phrase if (!ctxlen_) { |