00001 #ifndef moses_SearchNormalBatch_h 00002 #define moses_SearchNormalBatch_h 00003 00004 #include "SearchNormal.h" 00005 #include "SentenceStats.h" 00006 00007 namespace Moses 00008 { 00009 00010 class Manager; 00011 class InputType; 00012 class TranslationOptionCollection; 00013 00018 class SearchNormalBatch: public SearchNormal 00019 { 00020 protected: 00021 00022 // Added for asynclm decoding. 00023 std::vector<const StatelessFeatureFunction*> m_stateless_ffs; 00024 std::map<int, LanguageModel*> m_dlm_ffs; 00025 std::map<int, StatefulFeatureFunction*> m_stateful_ffs; 00026 std::vector<Hypothesis*> m_partial_hypos; 00027 uint32_t m_batch_size; 00028 int m_max_stack_size; 00029 00030 // functions for creating hypotheses 00031 void ExpandHypothesis(const Hypothesis &hypothesis,const TranslationOption &transOpt, float expectedScore); 00032 void EvalAndMergePartialHypos(); 00033 00034 public: 00035 SearchNormalBatch(Manager& manager, const InputType &source, const TranslationOptionCollection &transOptColl); 00036 ~SearchNormalBatch(); 00037 00038 void Decode(); 00039 00040 }; 00041 00042 } 00043 00044 #endif