[SciPy-user] fmin_cobyla hangs

dmitrey openopt@ukr....
Tue Sep 4 14:39:39 CDT 2007

Unfortunately, I can't run the script - I always got error why I try to 
import something from scipy.interpolate module.
However, one thing I would pay attention: your function is non-smooth 
(since you have abs() in  objective func, line 40 of your py-file). I 
had already encountered non-smooth funcs that made solvers intended for 
smooth funcs hang up. Of course, partially it shows absence of some loop 
stop criteria checks, but on the other hand, you take inappropriate solver.

Of course, you may have other causes as well - for example, your problem 
becomes unbounded for some cases.

Regards, D.

Christian K wrote:
> dmitrey wrote:
>> W/o code sample we can't say anything.
> Sure. Some explanations on the code:
> The goal is to find a smooth baseline for scattered data f(x). Therefore I let
> fmin_cobyla minimize the difference between the data and a n-point spline
> subject to the constraint data-spline > 0. Additionally constraints on the first
> and second derivative are applied. To reduce minimisation time the difference
> and the derivatives are only calculated at a subset of the data points.
> The strange thing is, that when running the minimisation separated from the
> application within which it is usually run, it still hangs, but under different
> conditions (different number of constraints). In the sample code the
> minimisation is repeated within a for loop while one parameter is changed (which
> is the number of points taken to calculate the difference). On my system, when
> run within the application, fmin_cobyla hangs for i=78, the stand alone script
> however hangs for i=15.
> Script and data are attached.
> Thanks, Christian
> ------------------------------------------------------------------------
> _______________________________________________
> SciPy-user mailing list
> SciPy-user@scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user

More information about the SciPy-user mailing list