On Feb 6, 2012, at 7:14 PM, Silvia wrote:

> Hi, I'm starting with nlopt and I've got this error calling opt.optimize
> (I've been following the NLopt Python Reference):
> 
> Traceback (most recent call last):
>  File "./toy_all_nlopt.py", line 42, in <module>
>    variables_values = opt.optimize(numpy.array([0]*36, dtype=numpy.double))
>  File "/Library/Python/2.7/site-packages/nlopt.py", line 254, in optimize
>    def optimize(self, *args): return _nlopt.opt_optimize(self, *args)
> TypeError: <lambda>() takes exactly 1 argument (2 given)

You don't provide your code, but I would guess that the error message means 
that you either passed 2 arguments when 1 was expected or you declared your 
objective function with 1 argument when it is supposed to take 2 arguments.


_______________________________________________
NLopt-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/nlopt-discuss

Reply via email to