diff options
author | Hieu Hoang <hieuhoang@gmail.com> | 2014-12-10 23:04:16 +0300 |
---|---|---|
committer | Hieu Hoang <hieuhoang@gmail.com> | 2014-12-10 23:04:16 +0300 |
commit | 1a0e329791bf8f9d8815a1353027be16fb2b15c3 (patch) | |
tree | d0885e50d37d3b871ffd88c35d714caa79ecb7ae /moses/LatticeMBR.cpp | |
parent | 81640945d09b22ff297673c9c685cab9f344b266 (diff) |
const some args. Ready to internalize n-best creation into Managers
Diffstat (limited to 'moses/LatticeMBR.cpp')
-rw-r--r-- | moses/LatticeMBR.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/moses/LatticeMBR.cpp b/moses/LatticeMBR.cpp index 9ea21d5db..b6fa14757 100644 --- a/moses/LatticeMBR.cpp +++ b/moses/LatticeMBR.cpp @@ -499,7 +499,7 @@ bool ascendingCoverageCmp(const Hypothesis* a, const Hypothesis* b) return a->GetWordsBitmap().GetNumWordsCovered() < b->GetWordsBitmap().GetNumWordsCovered(); } -void getLatticeMBRNBest(Manager& manager, TrellisPathList& nBestList, +void getLatticeMBRNBest(const Manager& manager, const TrellisPathList& nBestList, vector<LatticeMBRSolution>& solutions, size_t n) { const StaticData& staticData = StaticData::Instance(); @@ -546,7 +546,7 @@ void getLatticeMBRNBest(Manager& manager, TrellisPathList& nBestList, VERBOSE(2,"LMBR Score: " << solutions[0].GetScore() << endl); } -vector<Word> doLatticeMBR(Manager& manager, TrellisPathList& nBestList) +vector<Word> doLatticeMBR(const Manager& manager, const TrellisPathList& nBestList) { vector<LatticeMBRSolution> solutions; @@ -554,7 +554,7 @@ vector<Word> doLatticeMBR(Manager& manager, TrellisPathList& nBestList) return solutions.at(0).GetWords(); } -const TrellisPath doConsensusDecoding(Manager& manager, TrellisPathList& nBestList) +const TrellisPath doConsensusDecoding(const Manager& manager, const TrellisPathList& nBestList) { static const int BLEU_ORDER = 4; static const float SMOOTH = 1; |