recommenders-team / recommenders

Best Practices on Recommendation Systems
https://recommenders-team.github.io/recommenders/intro.html
MIT License
19.28k stars 3.11k forks source link

Add Mean Reciprocal Rank #281

Open yueguoguo opened 5 years ago

yueguoguo commented 5 years ago

It is used in many known cases when only one relevant item from a recommended list is considered.

dciborow commented 5 years ago

I have added this in scala to MMLSpark.

https://github.com/Azure/mmlspark/blob/master/src/recommendation/src/main/scala/RankingEvaluator.scala You can either use my code as a base, or you can do something like the SAR+ notebook to import MMLSpark and use it like this python test. https://github.com/Azure/mmlspark/blob/master/src/recommendation/src/test/python/RankingSpec.py

yueguoguo commented 5 years ago

Thanks @dciborow is there a derived PySpark / Python version of the Scala codes in mmlspark?