-
Notifications
You must be signed in to change notification settings - Fork 610
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to evaluate the recommender(e.g. P@k) with Implict #30
Comments
Unfortunately, there isn't currently any support for evaluating models built into this library. It shouldn't be too hard to add - and is something I'm looking at doing. |
@benfred Hey I am planning to use this lib. in production. But before that I want to evaluate the performance of the algo. I am using the ALS for recommendation. |
How should the evaluation go? I'm also planning to use the lib in production, but it would be great to have a metric of its accuracy before that. Is help needed? |
Hey @benfred, support for evaluation would be great in order to use this library in production. Meanwhile, was thinking about the following for evaluation:
Do you think it is feasible approach, or some simpler evaluation may be implemented? |
@snexus I did the same to evaluate the system. |
FYI - https://jessesw.com/Rec-System/ contains a good approach for validation. It is easy to adapt to your needs. |
I've managed to do grid search and cross-evaluation using scikit-learn, even though it does not have built in support for recommenders: scikit-learn/scikit-learn#6142 I had to create a few custom classes:
The code is in this gist: https://gist.github.com/jbochi/2e8ddcc5939e70e5368326aa034a144e#file-evaluation-ipynb Do you guys have any suggestions to improve it? Would it make sense to add some of this to scikit-learn? |
@antonioalegria I've added some basic support for map@k and p@k that you can use in the latest version - there is an example of how to call here: #108 (comment) I'm leaving this issues open until I get around to writing some documentation on this =) |
Thanks @benfred does the train/test split deal well with them ending up with different users and items? |
@antonioalegria the train_test_split function should handle that (the returned matrices should have the same dimensions as the input - so there shouldn't be any out of bounds errors). |
Any plan for a Recall@k metric ? It shouldn't be a lot of work but I can't understand Cython myself :( |
I wasn't planning on adding a recall@k metric - but it shouldn't be difficult I guess (I think it's just replacing this line https://github.com/benfred/implicit/blob/master/implicit/evaluation.pyx#L114 with |
@benfred If I understand well, it should be that. A quick win ;) Thanks for all. This library rocks. |
according to benfred#30 (comment)
Hi, whenever I try the example in #108 I get this error: Is there possibly an error in the example code? |
No description provided.
The text was updated successfully, but these errors were encountered: