Moses::DecodeFeature Class Reference

#include <DecodeFeature.h>

Inheritance diagram for Moses::DecodeFeature:

Inheritance graph
[legend]
Collaboration diagram for Moses::DecodeFeature:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 DecodeFeature (const std::string &line, bool registerNow)
 DecodeFeature (size_t numScoreComponents, const std::string &line)
 DecodeFeature (size_t numScoreComponents, const std::vector< FactorType > &input, const std::vector< FactorType > &output, const std::string &line)
const FactorMaskGetOutputFactorMask () const
 returns output factor types as specified by the ini file
const FactorMaskGetInputFactorMask () const
 returns input factor types as specified by the ini file
const std::vector< FactorType > & GetInput () const
const std::vector< FactorType > & GetOutput () const
bool IsUseable (const FactorMask &mask) const
void SetParameter (const std::string &key, const std::string &value)
void EvaluateWhenApplied (const Hypothesis &hypo, ScoreComponentCollection *accumulator) const
void EvaluateWhenApplied (const ChartHypothesis &hypo, ScoreComponentCollection *accumulator) const
void EvaluateWhenApplied (const Syntax::SHyperedge &hyperedge, ScoreComponentCollection *accumulator) const
void EvaluateWithSourceContext (const InputType &input, const InputPath &inputPath, const TargetPhrase &targetPhrase, const StackVec *stackVec, ScoreComponentCollection &scoreBreakdown, ScoreComponentCollection *estimatedScores=NULL) const
void EvaluateTranslationOptionListWithSourceContext (const InputType &input, const TranslationOptionList &translationOptionList) const
void EvaluateInIsolation (const Phrase &source, const TargetPhrase &targetPhrase, ScoreComponentCollection &scoreBreakdown, ScoreComponentCollection &estimatedScores) const
void SetContainer (const DecodeStep *container)
const DecodeGraphGetDecodeGraph () const

Protected Attributes

std::vector< FactorTypem_input
std::vector< FactorTypem_output
FactorMask m_inputFactors
FactorMask m_outputFactors
const DecodeStepm_container


Detailed Description

Baseclass for phrase-table or generation table feature function

Definition at line 39 of file DecodeFeature.h.


Constructor & Destructor Documentation

Moses::DecodeFeature::DecodeFeature ( const std::string &  line,
bool  registerNow 
)

Definition at line 34 of file DecodeFeature.cpp.

References VERBOSE.

Moses::DecodeFeature::DecodeFeature ( size_t  numScoreComponents,
const std::string &  line 
)

Definition at line 41 of file DecodeFeature.cpp.

References VERBOSE.

Moses::DecodeFeature::DecodeFeature ( size_t  numScoreComponents,
const std::vector< FactorType > &  input,
const std::vector< FactorType > &  output,
const std::string &  line 
)

Definition at line 49 of file DecodeFeature.cpp.

References m_inputFactors, m_outputFactors, and VERBOSE.


Member Function Documentation

void Moses::DecodeFeature::EvaluateInIsolation ( const Phrase source,
const TargetPhrase targetPhrase,
ScoreComponentCollection scoreBreakdown,
ScoreComponentCollection estimatedScores 
) const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 85 of file DecodeFeature.h.

void Moses::DecodeFeature::EvaluateTranslationOptionListWithSourceContext ( const InputType input,
const TranslationOptionList translationOptionList 
) const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 81 of file DecodeFeature.h.

void Moses::DecodeFeature::EvaluateWhenApplied ( const Syntax::SHyperedge hyperedge,
ScoreComponentCollection accumulator 
) const [inline, virtual]

Reimplemented from Moses::StatelessFeatureFunction.

Definition at line 71 of file DecodeFeature.h.

void Moses::DecodeFeature::EvaluateWhenApplied ( const ChartHypothesis hypo,
ScoreComponentCollection accumulator 
) const [inline, virtual]

Same for chart-based features.

Implements Moses::StatelessFeatureFunction.

Definition at line 68 of file DecodeFeature.h.

void Moses::DecodeFeature::EvaluateWhenApplied ( const Hypothesis hypo,
ScoreComponentCollection accumulator 
) const [inline, virtual]

This should be implemented for features that apply to phrase-based models.

Implements Moses::StatelessFeatureFunction.

Definition at line 65 of file DecodeFeature.h.

void Moses::DecodeFeature::EvaluateWithSourceContext ( const InputType input,
const InputPath inputPath,
const TargetPhrase targetPhrase,
const StackVec stackVec,
ScoreComponentCollection scoreBreakdown,
ScoreComponentCollection estimatedScores = NULL 
) const [inline, virtual]

Implements Moses::FeatureFunction.

Definition at line 74 of file DecodeFeature.h.

const DecodeGraph & Moses::DecodeFeature::GetDecodeGraph (  )  const

Definition at line 108 of file DecodeFeature.cpp.

References Moses::DecodeStep::GetContainer(), and m_container.

Referenced by Moses::PhraseDictionary::SatisfyBackoff().

Here is the call graph for this function:

Here is the caller graph for this function:

const std::vector< FactorType > & Moses::DecodeFeature::GetInput (  )  const

Definition at line 87 of file DecodeFeature.cpp.

References m_input.

Referenced by Moses::GenerationDictionary::FindWord(), and Moses::GenerationDictionary::Load().

Here is the caller graph for this function:

const FactorMask & Moses::DecodeFeature::GetInputFactorMask (  )  const

returns input factor types as specified by the ini file

Definition at line 82 of file DecodeFeature.cpp.

References m_inputFactors.

const std::vector< FactorType > & Moses::DecodeFeature::GetOutput (  )  const

Definition at line 92 of file DecodeFeature.cpp.

References m_output.

Referenced by Moses::GenerationDictionary::Load().

Here is the caller graph for this function:

const FactorMask & Moses::DecodeFeature::GetOutputFactorMask (  )  const

returns output factor types as specified by the ini file

Definition at line 76 of file DecodeFeature.cpp.

References m_outputFactors.

Referenced by Moses::DecodeStep::DecodeStep().

Here is the caller graph for this function:

bool Moses::DecodeFeature::IsUseable ( const FactorMask mask  )  const [virtual]

Implements Moses::FeatureFunction.

Definition at line 97 of file DecodeFeature.cpp.

References m_output.

void Moses::DecodeFeature::SetContainer ( const DecodeStep container  )  [inline]

Definition at line 91 of file DecodeFeature.h.

References m_container.

Referenced by Moses::DecodeStep::DecodeStep().

Here is the caller graph for this function:

void Moses::DecodeFeature::SetParameter ( const std::string &  key,
const std::string &  value 
) [virtual]


Member Data Documentation

std::vector<FactorType> Moses::DecodeFeature::m_input [protected]

std::vector<FactorType> Moses::DecodeFeature::m_output [protected]


The documentation for this class was generated from the following files:

Generated on Thu Jul 6 00:33:02 2017 for Moses by  doxygen 1.5.9