#include <Base.h>


Public Member Functions | |
| virtual | ~LanguageModel () |
| virtual LanguageModel * | Duplicate (ScoreIndexManager &scoreIndexManager) const =0 |
| std::size_t | GetNumScoreComponents () const |
| see ScoreProducer.h | |
| bool | OOVFeatureEnabled () const |
| float | GetWeight () const |
| float | GetOOVWeight () const |
| std::string | GetScoreProducerWeightShortName (unsigned) const |
| returns the weight parameter name of this producer (used in n-best list) | |
| virtual void | InitializeBeforeSentenceProcessing () |
| virtual void | CleanUpAfterSentenceProcessing () |
| virtual const FFState * | EmptyHypothesisState (const InputType &input) const =0 |
| return the state associated with the empty hypothesis for a given sentence | |
| virtual bool | Useable (const Phrase &phrase) const =0 |
| virtual void | CalcScore (const Phrase &phrase, float &fullScore, float &ngramScore, std::size_t &oovCount) const =0 |
Protected Member Functions | |
| LanguageModel () | |
| void | Init (ScoreIndexManager &scoreIndexManager) |
Protected Attributes | |
| bool | m_enableOOVFeature |
Definition at line 38 of file Base.h.
| Moses::LanguageModel::LanguageModel | ( | ) | [protected] |
Definition at line 35 of file Base.cpp.
References Moses::StaticData::GetLMEnableOOVFeature(), Moses::StaticData::Instance(), and m_enableOOVFeature.

| virtual void Moses::LanguageModel::CalcScore | ( | const Phrase & | phrase, | |
| float & | fullScore, | |||
| float & | ngramScore, | |||
| std::size_t & | oovCount | |||
| ) | const [pure virtual] |
| virtual void Moses::LanguageModel::CleanUpAfterSentenceProcessing | ( | ) | [inline, virtual] |
Reimplemented in Moses::LMRefCount.
Definition at line 69 of file Base.h.
Referenced by Moses::TranslationSystem::CleanUpAfterSentenceProcessing().

| virtual LanguageModel* Moses::LanguageModel::Duplicate | ( | ScoreIndexManager & | scoreIndexManager | ) | const [pure virtual] |
Implemented in Moses::LMRefCount.
Referenced by Moses::StaticData::LoadLanguageModels().

| virtual const FFState* Moses::LanguageModel::EmptyHypothesisState | ( | const InputType & | input | ) | const [pure virtual] |
return the state associated with the empty hypothesis for a given sentence
Implements Moses::StatefulFeatureFunction.
Implemented in Moses::LMRefCount.
| size_t Moses::LanguageModel::GetNumScoreComponents | ( | ) | const [virtual] |
see ScoreProducer.h
Implements Moses::ScoreProducer.
Definition at line 46 of file Base.cpp.
References m_enableOOVFeature.
| float Moses::LanguageModel::GetOOVWeight | ( | ) | const |
Definition at line 60 of file Base.cpp.
References Moses::StaticData::GetAllWeights(), Moses::ScoreProducer::GetScoreBookkeepingID(), Moses::StaticData::GetScoreIndexManager(), Moses::StaticData::Instance(), and m_enableOOVFeature.
Referenced by Moses::LMList::CalcScore().


| std::string Moses::LanguageModel::GetScoreProducerWeightShortName | ( | unsigned | idx | ) | const [inline, virtual] |
returns the weight parameter name of this producer (used in n-best list)
Implements Moses::ScoreProducer.
| float Moses::LanguageModel::GetWeight | ( | ) | const |
Definition at line 54 of file Base.cpp.
References Moses::StaticData::GetAllWeights(), Moses::ScoreProducer::GetScoreBookkeepingID(), Moses::StaticData::GetScoreIndexManager(), and Moses::StaticData::Instance().
Referenced by Moses::LMList::CalcScore().


| void Moses::LanguageModel::Init | ( | ScoreIndexManager & | scoreIndexManager | ) | [protected] |
Definition at line 39 of file Base.cpp.
References Moses::ScoreIndexManager::AddScoreProducer().
Referenced by Moses::LMRefCount::LMRefCount().


| virtual void Moses::LanguageModel::InitializeBeforeSentenceProcessing | ( | ) | [inline, virtual] |
Reimplemented in Moses::LMRefCount.
Definition at line 67 of file Base.h.
Referenced by Moses::TranslationSystem::InitializeBeforeSentenceProcessing().

| bool Moses::LanguageModel::OOVFeatureEnabled | ( | ) | const [inline] |
Definition at line 56 of file Base.h.
References m_enableOOVFeature.
Referenced by Moses::LanguageModelImplementation::Evaluate().

| virtual bool Moses::LanguageModel::Useable | ( | const Phrase & | phrase | ) | const [pure virtual] |
Implemented in Moses::LMRefCount.
Referenced by Moses::LMList::CalcScore().

bool Moses::LanguageModel::m_enableOOVFeature [protected] |
Definition at line 45 of file Base.h.
Referenced by GetNumScoreComponents(), GetOOVWeight(), LanguageModel(), and OOVFeatureEnabled().
1.5.9