mahout-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ted Dunning <ted.dunn...@gmail.com>
Subject Re: Question Regarding Distributed Row Matrix
Date Fri, 06 May 2011 01:02:41 GMT
Here is the R code I used in my test.  I have used this on medium ginormous
sparse matrices as well.

# decompose A to get k singular values
incore_stoch_svd = function(A, k) {
  # this should selected by a more sophisticated method
  p = 10
  n = dim(A)[1]
  m = dim(A)[2]

  # begin out of core
  Y = (A %*% matrix(rnorm((k+p) * m), ncol=k+p))
  Q = qr.Q(qr(Y))
  B = t(Q) %*% A

  s = svd(B)
  U = Q %*% s$u
  return (list(u=U, v=s$v, d=s$d))
}


On Thu, May 5, 2011 at 12:11 PM, Vckay <darkvckay@gmail.com> wrote:

> Hmm..You make a good point. Thanks for the suggestion. I will try to code
> up
> a sequential algorithm and check how it scales up.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message