Skip to content

Commit

Permalink
Merge pull request scipy#4803 from ewmoore/qrup_fixes
Browse files Browse the repository at this point in the history
Issues with relaxed strides in QR updating routines
  • Loading branch information
argriffing committed May 4, 2015
2 parents 3249faf + f32f960 commit d4fbcce
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions scipy/linalg/_decomp_update.pyx.in
Original file line number Diff line number Diff line change
Expand Up @@ -2239,8 +2239,12 @@ def qr_update(Q, R, u, v, overwrite_qruv=False, check_finite=True):
if u1.ndim != v1.ndim:
raise ValueError('u and v must have the same number of dimensions')

if u1.ndim == 2 and u1.shape[1] != v1.shape[1]:
raise ValueError('Second dimension of u and v must be the same')
if u1.ndim == 2:
if u1.shape[1] != v1.shape[1]:
raise ValueError('Second dimension of u and v must be the same')
elif u1.shape[1] == 1:
u1 = np.squeeze(u1)
v1 = np.squeeze(v1)

if u1.ndim == 1:
p = 1
Expand Down

0 comments on commit d4fbcce

Please sign in to comment.