Course Number : CS F469
Contributors :
- G V Sandeep
- Kushagra Agrawal
- Snehal Wadhwani
Language : Python v2.7.12
- A function defined in
common.py
handles the input from the corpus and a matrix of user-movie ratings is made. This function is used by all other files that use the user-movie ratings matrix. - The file
single_iter_svd_.py
(which uses functions defined insvd.py
) decomposes the ratings matrix into the appropriate U, sigma and V matrices based on the eigenvalues and eigenvectors calculated using python's numpy package. The eigenvectors are further pruned on the basis of whether they result in eigenvaleus being positive. If not, the sign of the corresponding eigenvector in U is reversed. - The file
cur_replace.py
performs the CUR decomposition on the ratings matrix in a manner similar to the previous two files that give the SVD decomposition. This file uses the svd function defined in
svd.py
for one of its intermediate steps.
- Install python's
numpy
package. - Run
single_iter_svd.py, multi_iter_svd.py
andcur.py
for the comparison between the two decompositions.