SciPy

scipy.linalg.svdvals

scipy.linalg.svdvals(a, overwrite_a=False, check_finite=True)[source]

Compute singular values of a matrix.

Parameters:

a : (M, N) array_like

Matrix to decompose.

overwrite_a : bool, optional

Whether to overwrite a; may improve performance. Default is False.

check_finite : boolean, optional

Whether to check that the input matrix contains only finite numbers. Disabling may give a performance gain, but may result in problems (crashes, non-termination) if the inputs do contain infinities or NaNs.

Returns:

s : (min(M, N),) ndarray

The singular values, sorted in decreasing order.

Raises:

LinAlgError

If SVD computation does not converge.

See also

svd
Compute the full singular value decomposition of a matrix.
diagsvd
Construct the Sigma matrix, given the vector s.

Previous topic

scipy.linalg.svd

Next topic

scipy.linalg.diagsvd