You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In numpy 1.19.3 or later, when using np.linalg.svd on a certain architecture, the 2nd and 3rd columns of the u result array and the 2nd and 3rd rows of the vh result arrays are switched.
Mismatched elements: 6 / 9 (66.7%)
Max absolute difference: 1.11535507
Max relative difference: 1.60871119e+16
x: array([[-5.7735027e-01, 8.1649658e-01, -5.0417908e-17],
[-5.7735027e-01, -4.0824829e-01, -7.0710678e-01],
[-5.7735027e-01, -4.0824829e-01, 7.0710678e-01]])
y: array([[-5.7735027e-01, -5.0754703e-17, 8.1649658e-01],
[-5.7735027e-01, -7.0710678e-01, -4.0824829e-01],
[-5.7735027e-01, 7.0710678e-01, -4.0824829e-01]])
Exited with code exit status 1
Runtime information:
1.19.3
3.9.13 (main, May 27 2022, 22:45:39)
[GCC 9.4.0]
Note: This behavior is also occurring with numpy 1.24.1
Context for the issue:
The behavior is observed in CircleCI with the following info:
Docker with Python using cimg/python:3.9.13
Model name: Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz
When you have duplicate singular values, as you do here, the SVD is not unique. The vectors associated with the duplicate singular values can be rotated freely. Different versions of the underlying linear algebra library may take different paths and return different choices in such cases. Both versions of the returned matrices are correct.
Describe the issue:
In numpy 1.19.3 or later, when using np.linalg.svd on a certain architecture, the 2nd and 3rd columns of the
u
result array and the 2nd and 3rd rows of thevh
result arrays are switched.Reproduce the code example:
Error message:
Mismatched elements: 6 / 9 (66.7%) Max absolute difference: 1.11535507 Max relative difference: 1.60871119e+16 x: array([[-5.7735027e-01, 8.1649658e-01, -5.0417908e-17], [-5.7735027e-01, -4.0824829e-01, -7.0710678e-01], [-5.7735027e-01, -4.0824829e-01, 7.0710678e-01]]) y: array([[-5.7735027e-01, -5.0754703e-17, 8.1649658e-01], [-5.7735027e-01, -7.0710678e-01, -4.0824829e-01], [-5.7735027e-01, 7.0710678e-01, -4.0824829e-01]]) Exited with code exit status 1
Runtime information:
1.19.3
3.9.13 (main, May 27 2022, 22:45:39)
[GCC 9.4.0]
Note: This behavior is also occurring with numpy 1.24.1
Context for the issue:
The behavior is observed in CircleCI with the following info:
Docker with Python using cimg/python:3.9.13
Model name: Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz
Branch featuring bug: https://github.com/lace/entente/tree/numpy-bug
Failure in CI: https://app.circleci.com/pipelines/github/lace/entente/1829/workflows/8973da1a-38f4-46a3-8dc5-63a8a1e4ee17/jobs/5937
CI config: https://github.com/lace/entente/blob/numpy-bug/.circleci/config.yml
Not reproducible on MacOS or Linux native.
Not reproducible on MacOS or Linux with same Docker image.
Not reproducible in Numpy 1.19.2.
The text was updated successfully, but these errors were encountered: