On Sun, May 8, 2011 at 11:42 AM, Skipper Seabold <jsseab...@gmail.com> wrote: > On Fri, May 6, 2011 at 11:30 AM, Till Stensitzki <mail.t...@gmx.de> wrote: >> Hi, >> discovered another small bug. Windows 7 32 bit, Python 2.6. >> >> In [1]: np.__version__ >> Out[1]: '1.5.1' >> >> In [2]: a=np.zeros((0,2)) >> >> In [3]: np.linalg.qr(a) >> ** On entry to DGEQRF parameter number 4 had an illegal value >> > > In [3]: a > Out[3]: array([], shape=(0, 2), dtype=float64) > > It doesn't crash for me on 1.5.1, but returns error code -4 from > dgeqrf. Maybe np.linalg.linalg._assertRank2 should also check that > a.size > 0, or there should an _assertNotEmpty? > > Maybe you should file a ticket so it doesn't get lost. >
Added an _assertNonEmpty to qr and filed a pull request. https://github.com/jseabold/numpy/compare/master...qr-nonempty-check Skipper _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion