a, q0, r0 = self.generate('tall')
for dtype in dts:
q = q0.real.astype(dtype)
- r = r0.real.astype(dtype)
+ with np.errstate(invalid="ignore"):
+ r = r0.real.astype(dtype)
assert_raises(ValueError, qr_delete, q, r0, 0, 1, 'row')
assert_raises(ValueError, qr_delete, q, r0, 0, 2, 'row')
assert_raises(ValueError, qr_delete, q, r0, 0, 1, 'col')
a, q0, r0, u0 = self.generate('sqr', which='row')
for dtype in dts:
q = q0.real.astype(dtype)
- r = r0.real.astype(dtype)
+ with np.errstate(invalid="ignore"):
+ r = r0.real.astype(dtype)
u = u0.real.astype(dtype)
assert_raises(ValueError, qr_insert, q, r0, u0, 0, 'row')
assert_raises(ValueError, qr_insert, q, r0, u0, 0, 'col')
a, q0, r0, u0, v0 = self.generate('tall')
for dtype in dts:
q = q0.real.astype(dtype)
- r = r0.real.astype(dtype)
+ with np.errstate(invalid="ignore"):
+ r = r0.real.astype(dtype)
u = u0.real.astype(dtype)
v = v0.real.astype(dtype)
assert_raises(ValueError, qr_update, q, r0, u0, v0)
# check conversions
for x in supported_dtypes:
- A = self.__A.astype(x)
+ with np.errstate(invalid="ignore"):
+ A = self.__A.astype(x)
Asp = self.spmatrix(A)
for y in supported_dtypes:
if not np.issubdtype(y, np.complexfloating):
- B = self.__B.real.astype(y)
+ with np.errstate(invalid="ignore"):
+ B = self.__B.real.astype(y)
else:
B = self.__B.astype(y)
Bsp = self.spmatrix(B)
self.__A @ self.__B.T)
for x in supported_dtypes:
- A = self.__A.astype(x)
+ with np.errstate(invalid="ignore"):
+ A = self.__A.astype(x)
Asp = self.spmatrix(A)
for y in supported_dtypes:
if np.issubdtype(y, np.complexfloating):
B = self.__B.astype(y)
else:
- B = self.__B.real.astype(y)
+ with np.errstate(invalid="ignore"):
+ B = self.__B.real.astype(y)
Bsp = self.spmatrix(B)
D1 = A @ B.T