irlba
A C++ library for IRLBA
Loading...
Searching...
No Matches
Public Attributes | List of all members
irlba::Options Struct Reference

Options for the IRLBA algorithm. More...

#include <Options.hpp>

Public Attributes

double invariant_subspace_tolerance = -1
 
double convergence_tolerance = 1e-5
 
double singular_value_ratio_tolerance = -1
 
int extra_work = 7
 
int max_iterations = 1000
 
bool exact_for_small_matrix = true
 
bool exact_for_large_number = true
 
bool cap_number = false
 
uint64_t seed = std::mt19937_64::default_seed
 
voidinitial = NULL
 

Detailed Description

Options for the IRLBA algorithm.

Member Data Documentation

◆ cap_number

bool irlba::Options::cap_number = false

Whether to automatically cap the requested number of singular values to the smaller dimension of the input matrix. If false, an error is thrown instead.

◆ convergence_tolerance

double irlba::Options::convergence_tolerance = 1e-5

Tolerance on the residuals of the singular triplets. Lower values improve the accuracy of the decomposition. (See Equation 2.13 of Baglama and Reichel.)

◆ exact_for_large_number

bool irlba::Options::exact_for_large_number = true

Whether to perform an exact SVD if the requested number of singular values is too large (greater than or equal to half the smaller matrix dimension). This is more efficient and avoids inaccuracies from an insufficient workspace.

◆ exact_for_small_matrix

bool irlba::Options::exact_for_small_matrix = true

Whether to perform an exact SVD if the matrix is too small (fewer than 6 elements in any dimension). This is more efficient and avoids inaccuracies from an insufficient workspace.

◆ extra_work

int irlba::Options::extra_work = 7

Number of extra dimensions to define the working subspace. Larger values can speed up convergence at the cost of increased memory usage.

◆ initial

void* irlba::Options::initial = NULL

Pointer to an EigenVector_ (see compute()) containing the initial values of the first right singular vector. This should have length equal to the number of columns of the input matrix.

◆ invariant_subspace_tolerance

double irlba::Options::invariant_subspace_tolerance = -1

Set the tolerance to use to define invariant subspaces. This is used as the lower bound for the L2 norm for the subspace vectors; below this bound, vectors are treated as all-zero and are instead filled with random draws from a normal distribution. If negative, we instead use the machine epsilon to the power of 0.8.

◆ max_iterations

int irlba::Options::max_iterations = 1000

Maximum number of restart iterations. Larger values improve the chance of convergence.

◆ seed

uint64_t irlba::Options::seed = std::mt19937_64::default_seed

Seed for the creation of random vectors, primarily during initialization of the IRLBA algorithm.

◆ singular_value_ratio_tolerance

double irlba::Options::singular_value_ratio_tolerance = -1

Tolerance on the relative differences between singular values across iterations. Lower values improve the accuracy of the decomposition. If -1, the value in Options::convergence_tolerance is used.


The documentation for this struct was generated from the following file: