mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-12-30 23:42:30 +03:00
debugging method for source phrase
This commit is contained in:
parent
f84e9c60e0
commit
aaa3f24109
@ -14,6 +14,7 @@
|
||||
#include "MemPool.h"
|
||||
#include "TypeDef.h"
|
||||
#include "legacy/FactorCollection.h"
|
||||
#include "SCFG/Word.h"
|
||||
|
||||
namespace Moses2
|
||||
{
|
||||
@ -120,20 +121,18 @@ inline std::ostream& operator<<(std::ostream &out, const Phrase<Moses2::Word> &o
|
||||
}
|
||||
return out;
|
||||
}
|
||||
/*
|
||||
template<typename WORD>
|
||||
inline std::ostream& operator<<(std::ostream &out, const Phrase<WORD> &obj)
|
||||
|
||||
inline std::ostream& operator<<(std::ostream &out, const Phrase<SCFG::Word> &obj)
|
||||
{
|
||||
if (obj.GetSize()) {
|
||||
out << obj[0];
|
||||
for (size_t i = 1; i < obj.GetSize(); ++i) {
|
||||
const WORD &word = obj[i];
|
||||
const SCFG::Word &word = obj[i];
|
||||
out << " " << word;
|
||||
}
|
||||
}
|
||||
return out;
|
||||
}
|
||||
*/
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
template<typename WORD>
|
||||
|
@ -95,7 +95,7 @@ void PhraseTableMemory::Load(System &system)
|
||||
SCFG::TargetPhraseImpl *target = SCFG::TargetPhraseImpl::CreateFromString(systemPool, *this,
|
||||
system, toks[1]);
|
||||
target->SetAlignmentInfo(toks[3]);
|
||||
cerr << "created target " << *target << endl;
|
||||
//cerr << "created target " << *target << " source=" << *source << endl;
|
||||
|
||||
target->GetScores().CreateFromString(toks[2], *this, system, true);
|
||||
//cerr << "created scores:" << *target << endl;
|
||||
|
Loading…
Reference in New Issue
Block a user