#include <ScoreIndexManager.h>
Public Member Functions | |
| ScoreIndexManager () | |
| void | AddScoreProducer (const ScoreProducer *producer) |
| new score producer to manage. Producers must be inserted in the order they are created | |
| void | InitFeatureNames () |
| size_t | GetBeginIndex (size_t scoreBookkeepingID) const |
| starting score index for a particular score producer with scoreBookkeepingID | |
| size_t | GetEndIndex (size_t scoreBookkeepingID) const |
| end score index for a particular score producer with scoreBookkeepingID | |
| size_t | GetTotalNumberOfScores () const |
| sum of all score components from every score producer | |
| void | PrintLabeledScores (std::ostream &os, const ScoreComponentCollection &scc) const |
| print unweighted scores of each ScoreManager to stream os | |
| void | PrintLabeledWeightedScores (std::ostream &os, const ScoreComponentCollection &scc, const std::vector< float > &weights) const |
| print weighted scores of each ScoreManager to stream os | |
| void | InitWeightVectorFromFile (const std::string &fnam, std::vector< float > *m_allWeights) const |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const ScoreIndexManager &sim) |
Definition at line 24 of file ScoreIndexManager.h.
| Moses::ScoreIndexManager::ScoreIndexManager | ( | ) | [inline] |
Definition at line 28 of file ScoreIndexManager.h.
| void Moses::ScoreIndexManager::AddScoreProducer | ( | const ScoreProducer * | producer | ) |
new score producer to manage. Producers must be inserted in the order they are created
Definition at line 18 of file ScoreIndexManager.cpp.
References CHECK, Moses::ScoreProducer::GetNumScoreComponents(), Moses::ScoreProducer::GetScoreBookkeepingID(), Moses::ScoreProducer::GetScoreProducerDescription(), and VERBOSE.
Referenced by Moses::DistortionScoreProducer::DistortionScoreProducer(), Moses::GenerationDictionary::GenerationDictionary(), Moses::LanguageModel::Init(), Moses::UnknownWordPenaltyProducer::UnknownWordPenaltyProducer(), and Moses::WordPenaltyProducer::WordPenaltyProducer().


| size_t Moses::ScoreIndexManager::GetBeginIndex | ( | size_t | scoreBookkeepingID | ) | const [inline] |
starting score index for a particular score producer with scoreBookkeepingID
Definition at line 35 of file ScoreIndexManager.h.
Referenced by Moses::LMList::Add(), Moses::ScoreComponentCollection::Assign(), Moses::ScoreComponentCollection::GetScoreForProducer(), Moses::ScoreComponentCollection::GetScoresForProducer(), Moses::TranslationSystem::GetWeightWordPenalty(), Moses::ScoreComponentCollection::PlusEquals(), Moses::TargetPhrase::SetScore(), and Moses::StaticData::SetWeightsForScoreProducer().

| size_t Moses::ScoreIndexManager::GetEndIndex | ( | size_t | scoreBookkeepingID | ) | const [inline] |
end score index for a particular score producer with scoreBookkeepingID
Definition at line 39 of file ScoreIndexManager.h.
Referenced by Moses::LMList::Add(), Moses::ScoreComponentCollection::GetScoreForProducer(), Moses::ScoreComponentCollection::GetScoresForProducer(), Moses::ScoreComponentCollection::PlusEquals(), Moses::TargetPhrase::SetScore(), and Moses::StaticData::SetWeightsForScoreProducer().

| size_t Moses::ScoreIndexManager::GetTotalNumberOfScores | ( | ) | const [inline] |
sum of all score components from every score producer
Definition at line 43 of file ScoreIndexManager.h.
Referenced by Moses::StaticData::GetTotalScoreComponents(), and main().

| void Moses::ScoreIndexManager::InitFeatureNames | ( | ) |
Definition at line 59 of file ScoreIndexManager.cpp.
Referenced by Moses::StaticData::LoadData().

| void Moses::ScoreIndexManager::InitWeightVectorFromFile | ( | const std::string & | fnam, | |
| std::vector< float > * | m_allWeights | |||
| ) | const |
| void Moses::ScoreIndexManager::PrintLabeledScores | ( | std::ostream & | os, | |
| const ScoreComponentCollection & | scc | |||
| ) | const |
print unweighted scores of each ScoreManager to stream os
Definition at line 37 of file ScoreIndexManager.cpp.
References PrintLabeledWeightedScores().
Referenced by Moses::OutputSearchNode().


| void Moses::ScoreIndexManager::PrintLabeledWeightedScores | ( | std::ostream & | os, | |
| const ScoreComponentCollection & | scc, | |||
| const std::vector< float > & | weights | |||
| ) | const |
print weighted scores of each ScoreManager to stream os
Definition at line 43 of file ScoreIndexManager.cpp.
References CHECK.
Referenced by PrintLabeledScores().

| std::ostream& operator<< | ( | std::ostream & | os, | |
| const ScoreIndexManager & | sim | |||
| ) | [friend] |
Definition at line 133 of file ScoreIndexManager.cpp.
1.5.9