"Crossproducts" SVD.

linalg_cpsvd(x, s, u = NULL, vt = NULL)

Arguments

x

Input data. The input values are overwritten.

s

Singular values.

u, vt

The left/right singular vectors. Should both be NULL or matrices of the same backend and fundamental type as x.

Details

Computes the approximate SVD via the eigenvalue decomposition of crossprod(x) if the input is tall/skinny and tcrossprod(x) otherwise.