[SciPy-user] Bug in openopt: objFunrelated

dmitrey dmitrey.kroshko at scipy.org
Thu Jan 31 03:48:15 EST 2008


Could you provide a code that yields the error?
Regards, D.

Mclean Edwards wrote:
> For a user supplied gradient that is not iterable, user_df in 
> objFunRelated.py returns an UnboundLocalError since user_df_func in 
> reference before it is assigned.
>
> Looking at the code, this is obvious.
>
> Suggest a line after 116 as an else to the if on 112:
>
> else: user_df_func = p.user.df
>
> When openopt is compiled with this change, the solver runs without 
> crashing, and my NLP runs to an approximate solution on all the major 
> solvers. I see no reason not to adopt this change.
>
>
> Cheers,
>
> Mclean
> _______________________________________________
> SciPy-user mailing list
> SciPy-user at scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user
>
>
>
>   




More information about the SciPy-User mailing list