optimize(algorithm=’nelder-mead’)#
- Model.optimize(mapping='uniform', algorithm=None, control_vector=None, bounds=None, jobs_fun='nse', wjobs_fun=None, event_seg=None, gauge='downstream', wgauge='mean', ost=None, options=None, verbose=True, inplace=False)
Optimize the Model using the Nelder-Mead algorithm.
See also
For documentation for the rest of the parameters, see
Model.optimize- Options:
- maxiter, maxfevint or None, default None
Maximum allowed number of iterations and function evaluations.
Note
If not given, default to
N*200, whereNis the number of variables, if neither maxiter or maxfev is set. If both maxiter and maxfev are set, minimization will stop at the first reached.- dispbool, default False
If True, display convergence messages.
- return_allbool, default False
Set to True to return a list of the best solution at each of the iterations.
Warning
Not working at the moment.
- initial_simplexnp.ndarray of shape (N + 1, N) or None, default None
Initial simplex.
Note
If given, overrides prior control.
initial_simplex[j,:]should contain the coordinates of the jth vertex of theN+1vertices in the simplex, whereNis the dimension.- xatolfloat, default 0.0001
Absolute error in xopt between iterations that is acceptable for convergence.
- fatolfloat, default 0.0001
Absolute error in func(xopt) between iterations that is acceptable for convergence.
- adaptivebool, default True
Adapt algorithm parameters to dimensionality of problem. Useful for high-dimensional minimization.