Skip to content

Commit

Permalink
modified: optMethods.py
Browse files Browse the repository at this point in the history
  • Loading branch information
wyli committed Aug 25, 2013
1 parent d2fe999 commit e6032d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion optMethods.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def quasi_newton(start_point, obj_fun, iteration=10):
u = delta_k - np.dot(H, gamma_k)

scale_a = np.dot(u.T, gamma_k)
if scale_a == 0:
if scale_a == 0: # :(
scale_a = 0.000001
H = H + np.dot(u, u.T) / scale_a

Expand Down

0 comments on commit e6032d5

Please sign in to comment.