public abstract class AbstractRecommenderEvaluator extends java.lang.Object implements RecommenderEvaluator
Modifier and Type | Field and Description |
---|---|
protected Configuration |
conf
configuration of the evaluator
|
protected java.util.Map<java.lang.String,RecommenderSimilarity> |
similarities
all similarity maps
|
protected SymmMatrix |
similarityMatrix
default similarityMatrix
|
protected int |
topN
the number of recommended items
|
Constructor and Description |
---|
AbstractRecommenderEvaluator() |
Modifier and Type | Method and Description |
---|---|
double |
evaluate(RecommenderContext context,
RecommendedList recommendedList)
Evaluate on the recommender context with the recommended list.
|
abstract double |
evaluate(SparseMatrix testMatrix,
RecommendedList recommendedList)
Evaluate on the test set with the the list of recommended items.
|
Configuration |
getConf()
Return the configuration fo the evaluator.
|
void |
setTopN(int topN)
Set the number of recommended items.
|
protected int topN
protected Configuration conf
protected SymmMatrix similarityMatrix
protected java.util.Map<java.lang.String,RecommenderSimilarity> similarities
public double evaluate(RecommenderContext context, RecommendedList recommendedList)
evaluate
in interface RecommenderEvaluator
context
- the recommender contextrecommendedList
- the list of recommended itemspublic abstract double evaluate(SparseMatrix testMatrix, RecommendedList recommendedList)
testMatrix
- the given test setrecommendedList
- the list of recommended itemspublic void setTopN(int topN)
setTopN
in interface RecommenderEvaluator
topN
- the number of recommended itemspublic Configuration getConf()
Copyright © 2017. All Rights Reserved.