possible bug in scipy.optimize.newton_krylov

16 views
Skip to first unread message

Matt Chan

unread,
Aug 29, 2012, 5:20:04 PM8/29/12
to scipy...@googlegroups.com
Hi,

I'm having trouble setting the tolerance for the inner method of the newton-krylov method. Although the documentation says it is possible, setting inner_tol returns an error complaining about duplicate arguments. http://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.newton_krylov.html

I've pasted the stack trace below. Is there something I am doing incorrectly?

Traceback (most recent call last):
  File "<zip>", line 758, in <module>
    x_star= op.newton_krylov(my_fn, x0, method='lgmres', inner_tol=1e-8)
  File "<string>", line 8, in newton_krylov
  File "/usr/lib64/python2.7/site-packages/scipy/optimize/nonlin.py", line 294, in nonlin_solve
    dx = -jacobian.solve(Fx, tol=tol)
  File "/usr/lib64/python2.7/site-packages/scipy/optimize/nonlin.py", line 1394, in solve
    sol, info = self.method(self.op, rhs, tol=tol, **self.method_kw)
TypeError: lgmres() got multiple values for keyword argument 'tol'

Thanks,
Matt
Reply all
Reply to author
Forward
0 new messages