Skip to content

Commit

Permalink
fix the sign error in wide QR factorization
Browse files Browse the repository at this point in the history
  • Loading branch information
YigitElma committed Aug 13, 2024
1 parent 5c309d8 commit b9ba0be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion desc/optimize/tr_subproblems.py
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ def trust_region_step_exact_qr(
p_newton = solve_triangular_regularized(R, -Q.T @ f)
else:
Q, R = qr(J.T, mode="economic")
p_newton = Q @ solve_triangular_regularized(R.T, f, lower=True)
p_newton = Q @ solve_triangular_regularized(R.T, -f, lower=True)

Check warning on line 424 in desc/optimize/tr_subproblems.py

View check run for this annotation

Codecov / codecov/patch

desc/optimize/tr_subproblems.py#L424

Added line #L424 was not covered by tests

def truefun(*_):
return p_newton, False, 0.0
Expand Down

0 comments on commit b9ba0be

Please sign in to comment.