Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <fishandfrolick@gmail.com>2012-12-19 18:37:00 +0400
committerHieu Hoang <fishandfrolick@gmail.com>2012-12-19 18:37:00 +0400
commitc2d9d84ba02f21fb191b966f2635d078fd130059 (patch)
treed5d9c6691e814d3a307fb2f3b21404ba9eb127ab /moses/ChartHypothesis.cpp
parentd0f59264a07d836d36eaa9a9db241d19c422538a (diff)
move feature function variables from TranslationSystem back to StaticData
Diffstat (limited to 'moses/ChartHypothesis.cpp')
-rw-r--r--moses/ChartHypothesis.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/moses/ChartHypothesis.cpp b/moses/ChartHypothesis.cpp
index a5de09013..562b7b995 100644
--- a/moses/ChartHypothesis.cpp
+++ b/moses/ChartHypothesis.cpp
@@ -51,7 +51,7 @@ ChartHypothesis::ChartHypothesis(const ChartTranslationOptions &transOpt,
ChartManager &manager)
:m_targetPhrase(*(item.GetTranslationDimension().GetTargetPhrase()))
,m_currSourceWordsRange(transOpt.GetSourceWordsRange())
- ,m_ffStates(manager.GetTranslationSystem()->GetStatefulFeatureFunctions().size())
+ ,m_ffStates(StaticData::Instance().GetStatefulFeatureFunctions().size())
,m_arcList(NULL)
,m_winningHypo(NULL)
,m_manager(manager)
@@ -166,13 +166,13 @@ void ChartHypothesis::CalcScore()
// compute values of stateless feature functions that were not
// cached in the translation option-- there is no principled distinction
const std::vector<const StatelessFeatureFunction*>& sfs =
- m_manager.GetTranslationSystem()->GetStatelessFeatureFunctions();
+ StaticData::Instance().GetStatelessFeatureFunctions();
for (unsigned i = 0; i < sfs.size(); ++i)
if (sfs[i]->ComputeValueInTranslationOption() == false)
sfs[i]->EvaluateChart(ChartBasedFeatureContext(this),&m_scoreBreakdown);
const std::vector<const StatefulFeatureFunction*>& ffs =
- m_manager.GetTranslationSystem()->GetStatefulFeatureFunctions();
+ StaticData::Instance().GetStatefulFeatureFunctions();
for (unsigned i = 0; i < ffs.size(); ++i)
m_ffStates[i] = ffs[i]->EvaluateChart(*this,i,&m_scoreBreakdown);