close
import nltk
nltk.download('wordnet')

以上先下載wordnet

然後評估用的函式如下

import nltk.translate.meteor_score as mt

round(mt.meteor_score([refa,refb,refc],"你的翻譯"),4)

Meteor 跟Bleu相比多了使用語意庫wordnet來做同義詞的評分這樣


arrow
arrow

    低階ㄇㄋ 發表在 痞客邦 留言(0) 人氣()