Giter Club home page Giter Club logo

recommender_system's Introduction

recommender_system

To compare the performance of different implementations(SVD, CUR and collaborative filtering) of recommendation system based on metrics like precision, spearman rank correlation. Result

Data : A corpus of user-movie ratings has been taken from MovieLens, which consists of ratings of 671 users on 1000 movies. Rating files are "training.csv" and "test1.csv" which consists of data split in 70:30 ratio.

SVD In SVD.java, Ratings from training data is extracted and put in adj[][] array.Ratings from testing data is extracted and put in test[][] array. Then, the transpose of "adj" is calculated and both are multiplied. Here, " JAMA" package is used, for matrix multiplications and eigenvalue decomposition of rating matrix "adj"(Used .getV() to form eigenvector matrix and .getD() for eigenvalue matrix)

Some of the complications faced while using the package:

  1. The eigen value matrix that we extracted from package were is ascending order. So, we had to change them descending order, and then according change the order of columns in "U" matrix, and order of rows in "Vt" matrix.
  2. Few of the eigenvalues calculated, came out to be negative. So we had to make them zero in order to avoid complex singular values. Then by application of 90% energy rule, and in the process, few eigen values are removed and resized the "U" and "Vt" matrix accordingly.

CUR In CUR.java: The same data set has been used for CUR for both training and testing. An object of “Random” class has been created to produce random numbers within a range, which are further used to sample rows and columns. SVD is performed in a similar process as mentioned above, on the intersection of sampled rows and columns.

Collaborative Filtering

Collaborative filtering.gif

This image shows an example of predicting of the user's rating using collaborative filtering. At first, people rate different items (like videos, images, games). After that, the system is making predictions about user's rating for an item, which the user hasn't rated yet. These predictions are built upon the existing ratings of other users, who have similar ratings with the active user. For instance, in our case the system has made a prediction, that the active user won't like the video

[source: wikipedia]

Results

With different evaluation metrics, each implementation has the following characterstics:

Hybrid model

recommender_system's People

Contributors

barkha1729 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.