diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2011-12-20 15:51:11 -0500 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2011-12-20 15:51:11 -0500 |
commit | 2eb3bb96c6f780c477585b33273fc0c0d56c80e4 (patch) | |
tree | be8fd2a5df3251ce8fa0a908edc0b40cc2c22e9c /mteval/scorer_test.cc | |
parent | 0da1f6de1b33bbff5cb99b1938bb07d050479f10 (diff) |
new scorer interface is implemented, but not used
Diffstat (limited to 'mteval/scorer_test.cc')
-rw-r--r-- | mteval/scorer_test.cc | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/mteval/scorer_test.cc b/mteval/scorer_test.cc index 09da250c..73159557 100644 --- a/mteval/scorer_test.cc +++ b/mteval/scorer_test.cc @@ -205,20 +205,22 @@ TEST_F(ScorerTest, Kernel) { } TEST_F(ScorerTest, NewScoreAPI) { - EvaluationMetric* metric = EvaluationMetric::Instance("IBM_BLEU"); + //EvaluationMetric* metric = EvaluationMetric::Instance("IBM_BLEU"); + //EvaluationMetric* metric = EvaluationMetric::Instance("METEOR"); + EvaluationMetric* metric = EvaluationMetric::Instance("COMB:IBM_BLEU=0.5;TER=-0.5"); boost::shared_ptr<SegmentEvaluator> e1 = metric->CreateSegmentEvaluator(refs0); boost::shared_ptr<SegmentEvaluator> e2 = metric->CreateSegmentEvaluator(refs1); SufficientStats stats1; - e1->Evaluate(hyp2, &stats1); + e1->Evaluate(hyp1, &stats1); SufficientStats stats2; - e2->Evaluate(hyp1, &stats2); + e2->Evaluate(hyp2, &stats2); stats1 += stats2; string ss; stats1.Encode(&ss); cerr << "SS: " << ss << endl; cerr << metric->ComputeScore(stats1) << endl; - SufficientStats statse("IBM_BLEU 53 32 18 11 65 63 61 59 65 72"); - cerr << metric->ComputeScore(statse) << endl; + //SufficientStats statse("IBM_BLEU 53 32 18 11 65 63 61 59 65 72"); + //cerr << metric->ComputeScore(statse) << endl; } int main(int argc, char **argv) { |