Moses::GlobalLexicalModel Class Reference

#include <GlobalLexicalModel.h>

Inheritance diagram for Moses::GlobalLexicalModel:

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

Collaboration graph
[legend]

List of all members.

Classes

struct  ThreadLocalStorage

Public Member Functions

 GlobalLexicalModel (const std::string &filePath, const float weight, const std::vector< FactorType > &inFactors, const std::vector< FactorType > &outFactors)
virtual ~GlobalLexicalModel ()
virtual size_t GetNumScoreComponents () const
virtual std::string GetScoreProducerDescription (unsigned) const
 returns a string description of this producer
virtual std::string GetScoreProducerWeightShortName (unsigned) const
 returns the weight parameter name of this producer (used in n-best list)
void InitializeForInput (Sentence const &in)
void Evaluate (const TargetPhrase &, ScoreComponentCollection *) const
 Evaluate for stateless feature functions. Implement this.


Detailed Description

Discriminatively trained global lexicon model This is a implementation of Mauser et al., 2009's model that predicts each output word from _all_ the input words. The intuition behind this feature is that it uses context words for disambiguation

Definition at line 35 of file GlobalLexicalModel.h.


Constructor & Destructor Documentation

Moses::GlobalLexicalModel::GlobalLexicalModel ( const std::string &  filePath,
const float  weight,
const std::vector< FactorType > &  inFactors,
const std::vector< FactorType > &  outFactors 
)

Moses::GlobalLexicalModel::~GlobalLexicalModel (  )  [virtual]

Definition at line 34 of file GlobalLexicalModel.cpp.


Member Function Documentation

void Moses::GlobalLexicalModel::Evaluate ( const TargetPhrase cur_hypo,
ScoreComponentCollection accumulator 
) const [virtual]

Evaluate for stateless feature functions. Implement this.

Reimplemented from Moses::StatelessFeatureFunction.

Definition at line 167 of file GlobalLexicalModel.cpp.

References Moses::ScoreComponentCollection::PlusEquals().

Here is the call graph for this function:

virtual size_t Moses::GlobalLexicalModel::GetNumScoreComponents (  )  const [inline, virtual]

returns the number of scores that a subclass produces. For example, a language model conventionally produces 1, a translation table some arbitrary number, etc

Implements Moses::ScoreProducer.

Definition at line 74 of file GlobalLexicalModel.h.

virtual std::string Moses::GlobalLexicalModel::GetScoreProducerDescription ( unsigned  idx  )  const [inline, virtual]

returns a string description of this producer

Implements Moses::ScoreProducer.

Definition at line 78 of file GlobalLexicalModel.h.

virtual std::string Moses::GlobalLexicalModel::GetScoreProducerWeightShortName ( unsigned  idx  )  const [inline, virtual]

returns the weight parameter name of this producer (used in n-best list)

Implements Moses::ScoreProducer.

Definition at line 82 of file GlobalLexicalModel.h.

void Moses::GlobalLexicalModel::InitializeForInput ( Sentence const &  in  ) 

Definition at line 111 of file GlobalLexicalModel.cpp.


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

Generated on Wed Feb 8 23:04:10 2012 for Moses by  doxygen 1.5.9