Questions tagged [svd]

Singular Value Decomposition (SVD) is a factorization of a real or complex matrix, with many useful applications in signal processing and statistics.

The Singular Value Decomposition (SVD) of a rectangular matrix A is a decomposition of the form:

A = U S V*

where U and V are orthogonal matrices, and S is a diagonal matrix containing the singular values.

In scientific software for statistical computing, function svd computes this decomposition.

746 questions
6
votes
2 answers

Randomized SVD for LSA\LSI on Windows environment

I am working on a project which includes the use of latent semantic analysis (LSA). This requires the usage of singular value decomposition (SVD), sometimes on large data sets. Is there an implementation of randomized-SVD (rSVD) available for…
Leeor
  • 627
  • 7
  • 24
6
votes
1 answer

What is the difference between SVD and SVM

I know the abbreviations SVM(Support Vector Machines) and SVD(Singular Value Decomposition) and that both SVM, SVD are used in recommendation engines. In lay man's terms what is the difference between these two algorithms and how would they impact…
Gokul N K
  • 2,428
  • 2
  • 32
  • 40
6
votes
1 answer

Mahout: how to make recommendations for new users

We plan to use Mahout for a movie recommendation system. And we also plan to use SVD for model building. When a new user comes we will require him/her to rate a certain number of movies (say 10). The problem is that, in order to make a…
Ahmet Yılmaz
  • 125
  • 1
  • 2
  • 8
5
votes
3 answers

Doing PCA in java on large matrix

I have a very large matrix (about 500000 * 20000) containing the data that I would analyze with pca. To do this I'm using ParallelColt library, but both using singular value decomposition and eigenvalues decomposition in order to get the…
dacanalr
  • 183
  • 2
  • 14
5
votes
1 answer

Python: Implement a PCA using SVD

I am trying to figure out the differences between PCA using Singular Value Decomposition as oppossed to PCA using Eigenvector-Decomposition. Picture the following matrix: B = np.array([ [1, 2], [3, 4], …
Luk
  • 1,009
  • 2
  • 15
  • 33
5
votes
1 answer

Truncated SVD is taking lot of time

I'm trying to reduce dimension of data set by computing what can be the best n_components using truncated SVD but its taking lot of time. from sklearn.decomposition import TruncatedSVD pca = TruncatedSVD() pca.n_components = 10048 pca_data =…
5
votes
2 answers

Numpy svd vs Scipy.sparse svds

I was working on implementing a solver for sparse undetermined systems in Python (discussed here) and I was trying to rebuild the nullspace function that uses the standard numpy svd function (numpy.linalg.svd) in the SciPy cookbook using the…
Rushabh Mehta
  • 1,529
  • 1
  • 13
  • 29
5
votes
1 answer

Using the SVD rather than covariance matrix to calculate eigenfaces

I'm using the set of n = 40 faces from AT&T (http://www.cl.cam.ac.uk/research/dtg/attarchive/facedatabase.html) to try and generate eigenfaces via the SVD. First I calculate the average vector: Then I subtract it from every vector in the training…
mic
  • 4,300
  • 1
  • 19
  • 25
5
votes
2 answers

Why use LSA before K-Means when doing text clustering

I'm following this tutorial from Scikit learn on text clustering using K-Means: http://scikit-learn.org/stable/auto_examples/text/document_clustering.html In the example, optionally LSA (using SVD) is used to perform dimensionality reduction. Why is…
Niko Nelissen
  • 120
  • 2
  • 10
5
votes
2 answers

numpy svd: is there a way to find only the first singular vectors instead of doing full svd?

numpy.linalg.svd function gives the full svd of the input matrix. However I want only the first singular vectors. I was wondering if there is any function in numpy for that or any other library in python?
Harit Vishwakarma
  • 2,338
  • 4
  • 21
  • 36
5
votes
1 answer

SVD Matlab Implementation

I tried to write matlab code that would decompose a matrix to its SVD form. "Theory": To get U, I found the eigenvectors of AA', and to get V, I found the eigenvectors of A'A. Finally, Sigma is a matrix of the same dimension as A, with the root of…
Ana M
  • 657
  • 6
  • 9
5
votes
1 answer

How to use SVD correctly in Accord.net

SVD stands for Singular Value Decomposition and is said to be the popular technique to conduct feature reduction in text classification. I know the principle as this link. I have been using C#, using Accord.Net library and had a jagged array…
user3819222
  • 127
  • 8
5
votes
2 answers

Using SVD to plot word vector to measure similarity

This is the code I am using to calculate a word co-occurrence matrix for immediate neighbor counts. I found the following code on the net, which uses SVD. import numpy as np la = np.linalg words =…
Seja Nair
  • 787
  • 2
  • 9
  • 23
5
votes
1 answer

R Mclust - getting svd error 'infinite or missing value'

I'm using Mclust function (from mclust package) to perform a mixed gaussian glustering. The data set is composed of 21000+ rows and 10 columns. I got the following error: Error in svd(shape.o, nu = 0) : infinite or missing values in 'x' What is…
lilloraffa
  • 1,367
  • 3
  • 17
  • 22
5
votes
1 answer

large sparse matrix, svd with spark,python

I want to analyze data on spark. I need svd matrix to achieve recommendation algorithm using python or scala if python doesn't work. But the data is large and sparse. there are two columns in the data. one is user name, the other one is item…
DarryO
  • 71
  • 3