blob: 1e2f0c25262a4653624669a41cbaf2c698b81fd2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#ifndef COMB_SCORER_H_
#define COMB_SCORER_H_
#include "scorer.h"
class BLEUTERCombinationScorer : public SentenceScorer {
public:
BLEUTERCombinationScorer(const std::vector<std::vector<WordID> >& refs);
~BLEUTERCombinationScorer();
ScoreP ScoreCandidate(const std::vector<WordID>& hyp) const;
ScoreP ScoreCCandidate(const std::vector<WordID>& hyp) const;
static ScoreP ScoreFromString(const std::string& in);
private:
ScorerP bleu_,ter_;
};
class BLEUCBLEUCombinationScorer : public SentenceScorer {
public:
BLEUCBLEUCombinationScorer(const std::vector<std::vector<WordID> >& refs);
~BLEUCBLEUCombinationScorer();
ScoreP ScoreCandidate(const std::vector<WordID>& hyp) const;
ScoreP ScoreCCandidate(const std::vector<WordID>& hyp) const;
static ScoreP ScoreFromString(const std::string& in);
private:
ScorerP bleu_, cbleu_;
};
#endif
|