-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Closed
Labels
defectA clear bug or issue that prevents SciPy from being installed or used as expectedA clear bug or issue that prevents SciPy from being installed or used as expectedscipy.linalg
Description
So I came up with an np.ndarray which fails when I try to factorize it to Singular Value Decomposition. It does not contain NaNs, just float64. It raises LinAlgError: SVD did not converge, but I don't know why.
Reproducing code example:
import numpy as np
from scipy import linalg
path = 'problematic_array.npy'
X = np.load(path)
np.isnan(X).any()
# False
U, s, Vh = linalg.svd(X)
Error message:
LinAlgError Traceback (most recent call last)
<ipython-input-16-119344cda5b9> in <module>
9 # False
10
---> 11 U, s, Vh = linalg.svd(X)
~/.local/lib/python3.6/site-packages/scipy/linalg/decomp_svd.py in svd(a, full_matrices, compute_uv, overwrite_a, check_finite, lapack_driver)
130
131 if info > 0:
--> 132 raise LinAlgError("SVD did not converge")
133 if info < 0:
134 raise ValueError('illegal value in %d-th argument of internal gesdd'
LinAlgError: SVD did not converge
...
Scipy/Numpy/Python version information:
Scipy version: 1.2.0
Numpy version: 1.15.4
Python version: sys.version_info(major=3, minor=6, micro=7, releaselevel='final', serial=0)
I am not sure how to share that ndarray with you. It is inside the following zip in an npy file. The reproducing code example should read it without problems.
problematic_array.zip
If it helps, it comes from a bootstrap of a resampling of MNIST
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
defectA clear bug or issue that prevents SciPy from being installed or used as expectedA clear bug or issue that prevents SciPy from being installed or used as expectedscipy.linalg