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:
authorUlrich Germann <Ulrich.Germann@gmail.com>2015-03-26 21:25:54 +0300
committerUlrich Germann <Ulrich.Germann@gmail.com>2015-03-26 21:25:54 +0300
commit9dc75bfd8ad3092f08f7a6d2a6492323b7803e56 (patch)
treef13405e11bce5001e6718ae0089fdcf85d961c98 /moses/ChartManager.cpp
parent4410e9225a5bd495fc6d097b206290beb59f4839 (diff)
Managers and feature functions now have access to the entire TranslationTask, not just the InputType.
Diffstat (limited to 'moses/ChartManager.cpp')
-rw-r--r--moses/ChartManager.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/moses/ChartManager.cpp b/moses/ChartManager.cpp
index aa550e48b..d221bd0fc 100644
--- a/moses/ChartManager.cpp
+++ b/moses/ChartManager.cpp
@@ -39,21 +39,21 @@ using namespace std;
namespace Moses
{
+
extern bool g_mosesDebug;
/* constructor. Initialize everything prior to decoding a particular sentence.
* \param source the sentence to be decoded
* \param system which particular set of models to use.
*/
-ChartManager::ChartManager(InputType const& source)
- :BaseManager(source)
- ,m_hypoStackColl(source, *this)
- ,m_start(clock())
- ,m_hypothesisId(0)
- ,m_parser(source, m_hypoStackColl)
- ,m_translationOptionList(StaticData::Instance().GetRuleLimit(), source)
-{
-}
+ChartManager::ChartManager(ttasksptr const& ttask)
+ : BaseManager(ttask)
+ , m_hypoStackColl(m_source, *this)
+ , m_start(clock())
+ , m_hypothesisId(0)
+ , m_parser(ttask, m_hypoStackColl)
+ , m_translationOptionList(StaticData::Instance().GetRuleLimit(), m_source)
+{ }
ChartManager::~ChartManager()
{
@@ -67,6 +67,7 @@ ChartManager::~ChartManager()
//! decode the sentence. This contains the main laps. Basically, the CKY++ algorithm
void ChartManager::Decode()
{
+
VERBOSE(1,"Translating: " << m_source << endl);
ResetSentenceStats(m_source);