#include <DecodeStep.h>
Public Member Functions | |
DecodeStep () | |
DecodeStep (DecodeFeature *featurePtr, const DecodeStep *prevDecodeStep, const std::vector< FeatureFunction * > &features) | |
not implemented | |
virtual | ~DecodeStep () |
const FactorMask & | GetOutputFactorMask () const |
mask of factors that are present after this decode step | |
bool | IsFilteringStep () const |
returns true if this decode step must match some pre-existing factors | |
bool | IsFactorProducingStep () const |
returns true if this decode step produces one or more new factors | |
const std::vector < FeatureFunction * > & | GetFeaturesRemaining () const |
const std::vector< FactorType > & | GetNewOutputFactors () const |
const std::vector< FactorType > & | GetConflictFactors () const |
const PhraseDictionary * | GetPhraseDictionaryFeature () const |
const GenerationDictionary * | GetGenerationDictionaryFeature () const |
void | RemoveFeature (const FeatureFunction *ff) |
void | SetContainer (const DecodeGraph *container) |
const DecodeGraph * | GetContainer () const |
Protected Attributes | |
FactorMask | m_outputFactors |
std::vector< FactorType > | m_conflictFactors |
mask of what factors exist on the output side after this decode step | |
std::vector< FactorType > | m_newOutputFactors |
list of the factors that may conflict during this step | |
const DecodeFeature * | m_decodeFeature |
list of the factors that are new in this step, may be empty | |
const DecodeGraph * | m_container |
std::vector< FeatureFunction * > | m_featuresToApply |
std::vector< FeatureFunction * > | m_featuresRemaining |
Definition at line 49 of file DecodeStep.h.
Moses::DecodeStep::DecodeStep | ( | ) |
Moses::DecodeStep::DecodeStep | ( | DecodeFeature * | featurePtr, | |
const DecodeStep * | prevDecodeStep, | |||
const std::vector< FeatureFunction * > & | features | |||
) |
not implemented
Definition at line 29 of file DecodeStep.cpp.
References Moses::DecodeFeature::GetOutputFactorMask(), Moses::FeatureFunction::IsUseable(), k, m_conflictFactors, m_featuresRemaining, m_featuresToApply, m_newOutputFactors, m_outputFactors, Moses::DecodeFeature::SetContainer(), and VERBOSE.
Moses::DecodeStep::~DecodeStep | ( | ) | [virtual] |
Definition at line 64 of file DecodeStep.cpp.
const std::vector<FactorType>& Moses::DecodeStep::GetConflictFactors | ( | ) | const [inline] |
returns a list (possibly empty) of the (target side) factors that are produced BUT ALREADY EXIST and therefore must be checked for conflict or compatibility
Definition at line 96 of file DecodeStep.h.
References m_conflictFactors.
const DecodeGraph* Moses::DecodeStep::GetContainer | ( | ) | const [inline] |
Definition at line 111 of file DecodeStep.h.
References m_container.
Referenced by Moses::DecodeFeature::GetDecodeGraph().
const std::vector<FeatureFunction*>& Moses::DecodeStep::GetFeaturesRemaining | ( | ) | const [inline] |
Definition at line 81 of file DecodeStep.h.
References m_featuresRemaining.
Referenced by Moses::StaticData::LoadDecodeGraphsNew().
const GenerationDictionary * Moses::DecodeStep::GetGenerationDictionaryFeature | ( | ) | const |
returns generation table feature for generation step
returns generation feature (dictionary) for generation step
Definition at line 73 of file DecodeStep.cpp.
References m_decodeFeature.
Referenced by Moses::DecodeStepGeneration::Process().
const std::vector<FactorType>& Moses::DecodeStep::GetNewOutputFactors | ( | ) | const [inline] |
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 in the returned vector.
Definition at line 89 of file DecodeStep.h.
References m_newOutputFactors.
const FactorMask& Moses::DecodeStep::GetOutputFactorMask | ( | ) | const [inline] |
mask of factors that are present after this decode step
Definition at line 67 of file DecodeStep.h.
References m_outputFactors.
const PhraseDictionary * Moses::DecodeStep::GetPhraseDictionaryFeature | ( | ) | const |
returns phrase table feature for translation step
returns phrase feature (dictionary) for translation step
Definition at line 67 of file DecodeStep.cpp.
References m_decodeFeature.
Referenced by Moses::TranslationOptionCollection::CreateTranslationOptionsForRange(), Moses::DecodeStepTranslation::Process(), Moses::DecodeStepTranslation::ProcessInitialTranslation(), Moses::DecodeStepTranslation::ProcessInitialTransLEGACY(), and Moses::DecodeStepTranslation::ProcessLEGACY().
bool Moses::DecodeStep::IsFactorProducingStep | ( | ) | const [inline] |
returns true if this decode step produces one or more new factors
Definition at line 77 of file DecodeStep.h.
References m_newOutputFactors.
bool Moses::DecodeStep::IsFilteringStep | ( | ) | const [inline] |
returns true if this decode step must match some pre-existing factors
Definition at line 72 of file DecodeStep.h.
References m_conflictFactors.
Referenced by Moses::DecodeStepTranslation::Process(), Moses::DecodeStepGeneration::Process(), and Moses::DecodeStepTranslation::ProcessLEGACY().
void Moses::DecodeStep::RemoveFeature | ( | const FeatureFunction * | ff | ) |
Definition at line 78 of file DecodeStep.cpp.
References m_featuresToApply.
Referenced by Moses::DecodeStepTranslation::DecodeStepTranslation().
void Moses::DecodeStep::SetContainer | ( | const DecodeGraph * | container | ) | [inline] |
Definition at line 108 of file DecodeStep.h.
References m_container.
Referenced by Moses::DecodeGraph::Add().
std::vector<FactorType> Moses::DecodeStep::m_conflictFactors [protected] |
mask of what factors exist on the output side after this decode step
Definition at line 53 of file DecodeStep.h.
Referenced by DecodeStep(), GetConflictFactors(), IsFilteringStep(), Moses::DecodeStepTranslation::Process(), Moses::DecodeStepGeneration::Process(), and Moses::DecodeStepTranslation::ProcessLEGACY().
const DecodeGraph* Moses::DecodeStep::m_container [protected] |
const DecodeFeature* Moses::DecodeStep::m_decodeFeature [protected] |
list of the factors that are new in this step, may be empty
Definition at line 55 of file DecodeStep.h.
Referenced by GetGenerationDictionaryFeature(), and GetPhraseDictionaryFeature().
std::vector<FeatureFunction*> Moses::DecodeStep::m_featuresRemaining [protected] |
std::vector<FeatureFunction*> Moses::DecodeStep::m_featuresToApply [protected] |
Definition at line 58 of file DecodeStep.h.
Referenced by DecodeStep(), Moses::DecodeStepTranslation::Process(), Moses::DecodeStepGeneration::Process(), Moses::DecodeStepTranslation::ProcessLEGACY(), and RemoveFeature().
std::vector<FactorType> Moses::DecodeStep::m_newOutputFactors [protected] |
list of the factors that may conflict during this step
Definition at line 54 of file DecodeStep.h.
Referenced by DecodeStep(), GetNewOutputFactors(), IsFactorProducingStep(), Moses::DecodeStepTranslation::Process(), Moses::DecodeStepGeneration::Process(), and Moses::DecodeStepTranslation::ProcessLEGACY().
FactorMask Moses::DecodeStep::m_outputFactors [protected] |