Skip to content

Commit

Permalink
fix typo f->f_a and f->L_a
Browse files Browse the repository at this point in the history
  • Loading branch information
YigitElma committed Aug 15, 2024
1 parent 7975cc3 commit b379412
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions desc/optimize/aug_lagrangian_ls.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,10 +374,10 @@ def lagjac(z, y, mu, *args):
tall = J_a.shape[0] >= J_a.shape[1]
if tall:
Q, R = qr(J_a, mode="economic")
p_newton = solve_triangular_regularized(R, -Q.T @ f)
p_newton = solve_triangular_regularized(R, -Q.T @ L_a)
else:
Q, R = qr(J_a.T, mode="economic")
p_newton = Q @ solve_triangular_regularized(R.T, -f, lower=True)
p_newton = Q @ solve_triangular_regularized(R.T, -L_a, lower=True)

Check warning on line 380 in desc/optimize/aug_lagrangian_ls.py

View check run for this annotation

Codecov / codecov/patch

desc/optimize/aug_lagrangian_ls.py#L379-L380

Added lines #L379 - L380 were not covered by tests

actual_reduction = -1
Lactual_reduction = -1
Expand Down
4 changes: 2 additions & 2 deletions desc/optimize/least_squares.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,10 +274,10 @@ def lsqtr( # noqa: C901 - FIXME: simplify this
tall = J_a.shape[0] >= J_a.shape[1]
if tall:
Q, R = qr(J_a, mode="economic")
p_newton = solve_triangular_regularized(R, -Q.T @ f)
p_newton = solve_triangular_regularized(R, -Q.T @ f_a)
else:
Q, R = qr(J_a.T, mode="economic")
p_newton = Q @ solve_triangular_regularized(R.T, -f, lower=True)
p_newton = Q @ solve_triangular_regularized(R.T, -f_a, lower=True)

actual_reduction = -1

Expand Down

0 comments on commit b379412

Please sign in to comment.