summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2017-08-04 12:49:45 +0200
committerPatrick Simianer <p@simianer.de>2017-08-04 12:49:45 +0200
commitc98c811f01718f903e013ee483828a0f3f155b07 (patch)
tree71f329d50033bcdfc331d82f2f23ee02b99c274c
parent2f04e5647ca1889cdd5da731dfc9f15138212def (diff)
python/psb.py: fix
-rw-r--r--python/psb.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/python/psb.py b/python/psb.py
index 2d575fa..9d963f1 100644
--- a/python/psb.py
+++ b/python/psb.py
@@ -4,6 +4,6 @@ smoothing = SmoothingFunction()
hypothesis = open('in').read().strip()
reference = open('ref').read().strip()
-score = nltk.translate.bleu_score.sentence_bleu([reference], hypothesis, smoothing_function=smoothing.method0)
+score = nltk.translate.bleu_score.sentence_bleu([reference.split()], hypothesis.split(), smoothing_function=smoothing.method2)
print("%f"%(score*100))