NLOpt_Algorithm
¶
Module Contents¶
Classes¶
-
class
NLOpt_Algorithm
¶ Bases:
optimeed.optimize.optiAlgorithms.algorithmInterface.AlgorithmInterface
,optimeed.core.Option_class
Interface for the optimization algorithm
-
initialize
(initialVectorGuess, listOfOptimizationVariables)¶ This function is called once parameters can’t be changed anymore, before “get_convergence”.
Parameters: - initialVectorGuess – list of variables that describe the initial individual
- listOfOptimizationVariables – list of
optimeed.optimize.optiVariable.OptimizationVariable
Returns:
-
compute
()¶ Launch the optimization
Returns: vector of optimal variables
-
set_evaluationFunction
(evaluationFunction, callback_on_evaluation, numberOfObjectives, numberOfConstraints, array_evaluator)¶ Set the evaluation function and all the necessary callbacks
Parameters: - evaluationFunction – check
evaluateObjectiveAndConstraints()
- callback_on_evaluation – check
callback_on_evaluation()
. Call this function after performing the evaluation of the individuals - numberOfObjectives – int, number of objectives
- numberOfConstraints – int, number of constraints
- array_evaluator – If True, evaluate each generation at once using numpy array. Use it only with care, as it dismisses some features (expert mode)
- evaluationFunction – check
-
set_maxtime
(maxTime)¶ Set maximum optimization time (in seconds)
-
__str__
()¶ Return str(self).
-
get_convergence
()¶ Get the convergence of the optimization
Returns: InterfaceConvergence
-