GSLS.ls_optimize¶
- GSLS.ls_optimize(n, obj_fun, initial_point, var_lb, var_ub)[source]¶
Run the line search optimization.
- Parameters
n (
int
) – Dimension of the problem.obj_fun (
callable
) – Objective function.initial_point (
ndarray
) – Initial point.var_lb (
ndarray
) – Vector of lower bounds on the decision variables. Vector elements can be -np.inf if the corresponding variable is unbounded from below.var_ub (
ndarray
) – Vector of upper bounds on the decision variables. Vector elements can be np.inf if the corresponding variable is unbounded from below.
- Return type
Tuple
[ndarray
,float
,int
,float
]- Returns
Final iterate as a vector, corresponding objective function value, number of evaluations, and norm of the gradient estimate.
- Raises
ValueError – If the number of dimensions mismatches the size of the initial point or the length of the lower or upper bound.