Hi Bertrand,
I am not familiar with RandomizedPCA so I do not known if nipals is faster
than RandomizedPCA. It is for sure faster than SVD when we are interested
only in few components.  My impression is that RandomizedPCA is an
approximation of PCA while nipals should be an algorithm that theoretically
converges to the same result of SVD.

Regarding SparsePCA  I don't think that there is an equivalent of
RandomizedPCA in sklearn.  Here http://justpaste.it/fobq  I have
implemented the algorithm described in "Sparse PCA through Low-rank
Approximations".  In the linked file is included a speed comparison with
SparsePCA. The value of the penalty alpha seems to have a slightly
different effect but the overall result is almost the same.

Let me know about that.
Best,
Luca




     Dear Luca,

>
>       In terms of efficiency, do you think that nipals outperforms the
> RandomizedPCA ? I'm not an expert in these methods, but it sounds like
> they rely on similar tricks.
>       My suggestion would be to run a benchmark on some dataset of the
> scikit to compare the accurcay/computation time tradeoffs.
>       Best,
>
> Bertrand
>
> On 28/05/2014 18:45, Luca Puggini wrote:
> > Hi,
> > I was looking to the PCA and SparsePCA implementation of sklearn.
> > They are both based on SVD but I think that the nipals implementation
> > of the same algorithm can really increase the speed in some situations.
> >
> > In particular with sparse PCA we usually use a small number of
> > components and so its speed can be increased using nipals to compute
> > the initial value of  u,v (in the class dictionary learning).
> >
> > Always on this road there is a nipals like algorithm for Sparse PCA. I
> > have already written a python implementation for this and should not
> > be  a problem for me to integrate it with sklearn.
> >
> > Is this considered useful for the community or is this off topic?
> > Are there others people already working on it?
> >
> > Thanks,
> > Luca
> >
>
------------------------------------------------------------------------------
Time is money. Stop wasting it! Get your web API in 5 minutes.
www.restlet.com/download
http://p.sf.net/sfu/restlet
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to