diff options
author | Hieu Hoang <hieu@hoang.co.uk> | 2013-05-30 14:25:57 +0400 |
---|---|---|
committer | Hieu Hoang <hieu@hoang.co.uk> | 2013-05-30 14:25:57 +0400 |
commit | b61a57d654e1cfc7c0e5a2eef59e3eab45b31524 (patch) | |
tree | 7a226c73faa5290a016cc2b57f07b84f873e7201 /moses/DecodeStep.h | |
parent | 84ec2043b7d100ac9ac07aa7ad8c5bf577dcad8b (diff) |
figure out which feature function to apply at which decode step. Book-keeping
Diffstat (limited to 'moses/DecodeStep.h')
-rw-r--r-- | moses/DecodeStep.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/moses/DecodeStep.h b/moses/DecodeStep.h index 1629224bc..6e253c77e 100644 --- a/moses/DecodeStep.h +++ b/moses/DecodeStep.h @@ -38,6 +38,7 @@ class TranslationOptionCollection; class PartialTranslOptColl; class FactorCollection; class InputType; +class FeatureFunction; /** Specification for a decoding step. * The factored translation model consists of Translation and Generation @@ -53,9 +54,12 @@ protected: std::vector<FactorType> m_newOutputFactors; //! list of the factors that are new in this step, may be empty const DecodeFeature* m_decodeFeature; + std::vector<FeatureFunction*> m_featuresToApply, m_featuresRemaining; public: DecodeStep(); //! not implemented - DecodeStep(const DecodeFeature *featurePtr, const DecodeStep* prevDecodeStep); + DecodeStep(const DecodeFeature *featurePtr, + const DecodeStep* prevDecodeStep, + const std::vector<FeatureFunction*> &features); virtual ~DecodeStep(); //! mask of factors that are present after this decode step @@ -73,6 +77,9 @@ public: return !m_newOutputFactors.empty(); } + const std::vector<FeatureFunction*> &GetFeaturesRemaining() const + { return m_featuresRemaining; } + /*! returns a list (possibly empty) of the (target side) factors that * are produced in this decoding step. For example, if a previous step * generated factor 1, and this step generates 1,2, then only 2 will be |