optimod package¶
Module contents¶
Optimization package.
The aim of the optimod package is to perform optimization.
-
optimod.get_operator(name, setup)¶ Text.
Parameters: - name (str) – Operator name to retrieve.
- setup (dict) – Optimization setup parameters.
Returns: Retrieved operator.
Return type: operator ()
-
optimod.set_algorithm(name, no_obj, setup)¶ Text.
Parameters: - name (str) – Name of the optimization algorithm.
- n_obj (int) – Number of objectives.
- setup (dict) – Optimization setup parameters.
Returns: Optization algorithm object.
Return type: algorithm ()
-
optimod.set_optimization(no_obj)¶ Set the selected optimization technique.
Parameters: n_obj (int) – Number of objectives. Returns: Optization algorithm object. termination (): Termination object. Return type: algorithm ()
-
optimod.solve_problem(problem, algorithm, termination, direct)¶ Solve the defined problem.
Parameters: - problem (datamod.problems.Custom) – Problem to solve.
- () (termination) – Optimization algorithm.
- () – Termination method.
- direct (bool) – Whether this is a direct optimization run.
Returns: Results object.
Return type: res (pymoo.model.result.Result)
Notes
Save_history will work with ANN surrogate from Tensorflow only if line 290 in site-packagespymoomodellgorithm is changed from deepcopy to copy. Optional seed not implemented.
-
optimod.unnormalize_res(res, norm_in, norm_out)¶ Unnormliazes results.
Parameters: - res (pymoo.model.result.Result) – Results object (unnormalized).
- norm_in (np.array) – Input normalization factors.
- norm_out (np.array) – Output normalization factors.
Returns: Results object (normalized).
Return type: res (pymoo.model.result.Result)
Notes
Implemented for: F,X.