RecommenderEvaluator接口用于实现对特定算法的评估. 目前实现对于ranking的评估器有AUC, AveragePrecision, AverageReciprocalHitRank, Diversity, HitRate, IdealDCG, Normalized, Precision, Recall, REciprocalRank十类评估器. 对于rating实现评估器MAE, MPE, MSE, RMSE四类.
若在配置文件中不进行评估器的指定, 最终评估时使用对应类型的全部评估器.
指定评估器的配置示例:
rating:
rec.recommender.isranking=false
rec.eval.enable=true
rec.eval.class=mse # if rating
ranking:
rec.recommender.isranking=true
rec.eval.enable=true
rec.eval.class=auc
rec.recommender.ranking.topn=10
不同评估器相应的简写见下表
Evaluator | configuration |
---|---|
AUCEvaluator | auc |
AveragePrecisionEvaluator | ap |
AverageReciprocalHitRankEvaluator | arhr |
DiversityEvaluator | diversity |
HitRateEvaluator | hitrate |
IdealDCGEvaluator | idcg |
NormalizedDCGEvaluator | ndcg |
PrecisionEvaluator | precision |
RecallEvaluator | recall |
ReciprocalRankEvaluator | rr |
MAEEvaluator | mae |
MPEEvaluator | mpe |
MSEEvaluator | mse |
RMSEEvaluator | rmse |