mlpack
|
Randomized block krylov SVD is a matrix factorization that is based on randomized matrix approximation techniques, developed in in "Randomized Block Krylov Methods for Stronger and Faster Approximate Singular Value Decomposition". More...
#include <randomized_block_krylov_svd.hpp>
Public Member Functions | |
RandomizedBlockKrylovSVD (const arma::mat &data, arma::mat &u, arma::vec &s, arma::mat &v, const size_t maxIterations=2, const size_t rank=0, const size_t blockSize=0) | |
Create object for the randomized block krylov SVD method. More... | |
RandomizedBlockKrylovSVD (const size_t maxIterations=2, const size_t blockSize=0) | |
Create object for the randomized block krylov SVD method. More... | |
void | Apply (const arma::mat &data, arma::mat &u, arma::vec &s, arma::mat &v, const size_t rank) |
Apply Principal Component Analysis to the provided data set using the randomized block krylov SVD. More... | |
size_t | MaxIterations () const |
Get the number of iterations for the power method. | |
size_t & | MaxIterations () |
Modify the number of iterations for the power method. | |
size_t | BlockSize () const |
Get the block size. | |
size_t & | BlockSize () |
Modify the block size. | |
Randomized block krylov SVD is a matrix factorization that is based on randomized matrix approximation techniques, developed in in "Randomized Block Krylov Methods for Stronger and Faster Approximate Singular Value Decomposition".
For more information, see the following.
An example of how to use the interface is shown below:
mlpack::svd::RandomizedBlockKrylovSVD::RandomizedBlockKrylovSVD | ( | const arma::mat & | data, |
arma::mat & | u, | ||
arma::vec & | s, | ||
arma::mat & | v, | ||
const size_t | maxIterations = 2 , |
||
const size_t | rank = 0 , |
||
const size_t | blockSize = 0 |
||
) |
Create object for the randomized block krylov SVD method.
data | Data matrix. |
u | First unitary matrix. |
v | Second unitary matrix. |
s | Diagonal matrix of singular values. |
maxIterations | Number of iterations for the power method (Default: 2). |
rank | Rank of the approximation (Default: number of rows.) |
blockSize | The block size, must be >= rank (Default: rank + 10). |
mlpack::svd::RandomizedBlockKrylovSVD::RandomizedBlockKrylovSVD | ( | const size_t | maxIterations = 2 , |
const size_t | blockSize = 0 |
||
) |
Create object for the randomized block krylov SVD method.
maxIterations | Number of iterations for the power method (Default: 2). |
blockSize | The block size, must be >= rank (Default: rank + 10). |
void mlpack::svd::RandomizedBlockKrylovSVD::Apply | ( | const arma::mat & | data, |
arma::mat & | u, | ||
arma::vec & | s, | ||
arma::mat & | v, | ||
const size_t | rank | ||
) |
Apply Principal Component Analysis to the provided data set using the randomized block krylov SVD.
data | Data matrix. |
u | First unitary matrix. |
v | Second unitary matrix. |
s | Diagonal matrix of singular values. |
rank | Rank of the approximation. |