mahout-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From michal shmueli <michal.shmu...@gmail.com>
Subject problems with GenericRecommenderIRStatsEvaluator:
Date Wed, 04 Nov 2009 12:22:04 GMT
Hi,

I'm trying to evaluate the quality of the Boolean recommender. (I have no
ratings in my data but only: (userId,itemId,1) 1 for all entries.
I'm using this setting for the recommender:

UserSimilarity userSimilarity = new
TanimotoCoefficientSimilarity(dataModel);
UserNeighborhood neighborhood =  new NearestNUserNeighborhood(10, 0.0,
userSimilarity, dataModel, 1.0);
 recommender = new CachingRecommender(new
GenericBooleanPrefUserBasedRecommender(dataModel, neighborhood,
userSimilarity));

As for the evaluator :

 RecommenderIRStatsEvaluator evaluator = new
GenericRecommenderIRStatsEvaluator();
  IRStatistics stats =      evaluator.evaluate(new
GroupLensRecommenderBuilder(), null,model, null, 50, 1.0,0.7);



When running the eval, I keep getting:
09/11/04 13:56:01 INFO eval.
GenericRecommenderIRStatsEvaluator:
processOtherUSer: debug debug --- original id: 9606925 evaluate id: 9606925
09/11/04 13:56:01 INFO model.GenericUserPreferenceArray: debug debug ---
user id is: 0 size is: 0
Exception in thread "main" java.lang.IllegalArgumentException: size is
less than 1
       at
org.apache.mahout.cf.taste.impl.model.GenericUserPreferenceArray.<init>(GenericUserPreferenceArray.java:54)
       at
org.apache.mahout.cf.taste.impl.model.GenericUserPreferenceArray.<init>(GenericUserPreferenceArray.java:66)
       at
org.apache.mahout.cf.taste.impl.eval.GenericRecommenderIRStatsEvaluator.processOtherUser(GenericRecommenderIRStatsEvaluator.java:200)
       at
org.apache.mahout.cf.taste.impl.eval.GenericRecommenderIRStatsEvaluator.evaluate(GenericRecommenderIRStatsEvaluator.java:132)
       at
org.apache.mahout.cf.taste.example.grouplens.GroupLensRecommenderEvaluatorRunner.main(GroupLensRecommenderEvaluatorRunner.java:68)


However, when I'm trying to access the recommendation of this user :9606925
from the server I'm getting:

User:9606925
Recommender: GroupLensRecommender[recommender:CachingRecommender[recommender:GenericBooleanPrefUserBasedRecommender]]

Top 20 Preferences:
1.0	552559


1.0	450097
1.0	450098
1.0	450133
1.0	450133
1.0	450133
1.0	450133
1.0	450990
1.0	450990
1.0	457282
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458155
1.0	458157



Recommendations:
4.9622216	457294
3.5182436	550267
3.1865802	459571
3.1865802	459823
3.1865802	550995
2.404762	458841
2.404762	450047
2.3295739	550150
2.3295739	459390
2.3295739	550545
2.3295739	551189
2.3295739	551428
2.3295739	551552
1.5438596	551940

Is something wrong with the way I'm using the evaluator? It does evaluate
the precision/recall for some of the users.
Any suggstions?

thanks.
Michal

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message