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 <hieuhoang@gmail.com>2014-12-02 22:09:10 +0300
committerHieu Hoang <hieuhoang@gmail.com>2014-12-02 22:09:10 +0300
commit3da84150959de4dc99edf3ee35665e81a23aae26 (patch)
treeee7c487a26f2d56f56763dd5fe8885f6d6130465 /moses/Manager.h
parentba7afba9f6f325441387557ab8af487d5901f023 (diff)
add OutputNBest() as abstract method to BaseManager. Tighten up framework
Diffstat (limited to 'moses/Manager.h')
-rw-r--r--moses/Manager.h17
1 files changed, 8 insertions, 9 deletions
diff --git a/moses/Manager.h b/moses/Manager.h
index e402c05a6..b078c5c8c 100644
--- a/moses/Manager.h
+++ b/moses/Manager.h
@@ -42,7 +42,6 @@ namespace Moses
class SentenceStats;
class TrellisPath;
class TranslationOptionCollection;
-class OutputCollector;
/** Used to output the search graph */
struct SearchGraphNode {
@@ -134,13 +133,13 @@ protected:
, const Moses::TrellisPathList &nBestList
, const std::vector<Moses::FactorType>& outputFactorOrder
, long translationId
- , char reportSegmentation);
+ , char reportSegmentation) const;
void OutputSurface(std::ostream &out, const Hypothesis &edge, const std::vector<FactorType> &outputFactorOrder,
- char reportSegmentation, bool reportAllFactors);
- void OutputAlignment(std::ostream &out, const AlignmentInfo &ai, size_t sourceOffset, size_t targetOffset);
- void OutputInput(std::ostream& os, const Hypothesis* hypo);
- void OutputInput(std::vector<const Phrase*>& map, const Hypothesis* hypo);
- std::map<size_t, const Factor*> GetPlaceholders(const Hypothesis &hypo, FactorType placeholderFactor);
+ char reportSegmentation, bool reportAllFactors) const;
+ void OutputAlignment(std::ostream &out, const AlignmentInfo &ai, size_t sourceOffset, size_t targetOffset) const;
+ void OutputInput(std::ostream& os, const Hypothesis* hypo) const;
+ void OutputInput(std::vector<const Phrase*>& map, const Hypothesis* hypo) const;
+ std::map<size_t, const Factor*> GetPlaceholders(const Hypothesis &hypo, FactorType placeholderFactor) const;
public:
InputType const& m_source; /**< source sentence to be translated */
@@ -186,8 +185,8 @@ public:
std::vector< const Hypothesis* >* pConnectedList, std::map < const Hypothesis*, std::set < const Hypothesis* > >* pOutgoingHyps, std::vector< float>* pFwdBwdScores) const;
// outputs
- void OutputNBest(OutputCollector *collector);
- void OutputLatticeSamples(OutputCollector *collector);
+ void OutputNBest(OutputCollector *collector) const;
+ void OutputLatticeSamples(OutputCollector *collector) const;
};
}