diff options
author | Sebastian Berg <sebastian@sipsolutions.net> | 2014-03-07 23:05:47 +0100 |
---|---|---|
committer | Sebastian Berg <sebastian@sipsolutions.net> | 2014-03-12 10:34:02 +0100 |
commit | 5a3b0abf6da4a7357e24a8243bee14b3cc7a242f (patch) | |
tree | 0ce937843dc23515a84476a9842548e91ce71bf5 /numpy/linalg/tests/test_regression.py | |
parent | 4da29a8e7393356094b0eb3289b14360beac9d89 (diff) | |
download | numpy-5a3b0abf6da4a7357e24a8243bee14b3cc7a242f.tar.gz |
BUG: Delay npyiter size check when size may change
When a multi index is tracked and RemoveAxis can be called, the
size of the iterator may still change. This was causing failures
for example for the SVD, because the gufunc machinery requires
a temporarily larger iterator for output allocation.
Thanks to Jaime (jaime.frio@gmail.com) for noting that this is
plausible since the size check can be delayed pretty ok up
until GetIterNext (or similar functions).
Closes gh-4442
Diffstat (limited to 'numpy/linalg/tests/test_regression.py')
-rw-r--r-- | numpy/linalg/tests/test_regression.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/numpy/linalg/tests/test_regression.py b/numpy/linalg/tests/test_regression.py index 4ff14a6a5..b0b2b2e30 100644 --- a/numpy/linalg/tests/test_regression.py +++ b/numpy/linalg/tests/test_regression.py @@ -69,5 +69,11 @@ class TestRegression(TestCase): bp = linalg.cholesky(b) assert_array_equal(ap, bp) + def test_large_svd_32bit(self): + # See gh-4442, 64bit would require very large/slow matrices. + x = np.eye(1000, 66) + np.linalg.svd(x) + + if __name__ == '__main__': run_module_suite() |