Note
Go to the end to download the full example code.
Multi-start optimization#
The optimization algorithm multistart
generates starting points using a DOE algorithm
and run a sub-optimization algorithm from each starting point.
from __future__ import annotations
from gemseo import create_design_space
from gemseo import create_discipline
from gemseo import create_scenario
from gemseo import execute_post
from gemseo.algos.opt.multi_start.settings.multi_start_settings import (
MultiStart_Settings,
)
First, we create the disciplines
objective = create_discipline("AnalyticDiscipline", expressions={"obj": "x**3-x+1"})
constraint = create_discipline(
"AnalyticDiscipline", expressions={"cstr": "x**2+obj**2-1.5"}
)
and the design space
design_space = create_design_space()
design_space.add_variable("x", lower_bound=-1.5, upper_bound=1.5, value=1.5)
Then, we define the MDO scenario
scenario = create_scenario(
[objective, constraint],
"obj",
design_space,
formulation_name="DisciplinaryOpt",
)
Note that the formulation settings passed to create_scenario() can be provided
via a Pydantic model. For more information, see Formulation Settings.
scenario.add_constraint("cstr", constraint_type="ineq")
and execute it with the MultiStart optimization algorithm
combining the local optimization algorithm SLSQP
and the full-factorial DOE algorithm:
multistart_settings = MultiStart_Settings(
max_iter=100,
opt_algo_name="SLSQP",
doe_algo_name="PYDOE_FULLFACT",
n_start=10,
# Set multistart_file_path to save the history of the local optima.
multistart_file_path="multistart.hdf5",
)
scenario.execute(multistart_settings)
INFO - 16:24:30: *** Start MDOScenario execution ***
INFO - 16:24:30: MDOScenario
INFO - 16:24:30: Disciplines: AnalyticDiscipline AnalyticDiscipline
INFO - 16:24:30: MDO formulation: DisciplinaryOpt
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 1.5 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm MultiStart:
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.5 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 602.28 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 902.58 it/sec, feas=False, obj=-0.267]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1117.19 it/sec, feas=False, obj=-0.809]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1239.82 it/sec, feas=False, obj=-0.868]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1216.16 it/sec, feas=False, obj=-0.872]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1198.20 it/sec, feas=False, obj=-0.265]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1189.73 it/sec, feas=False, obj=0.136]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1247.61 it/sec, feas=False, obj=0.579]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1239.82 it/sec, feas=False, obj=0.289]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1283.92 it/sec, feas=False, obj=1.25]
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
WARNING - 16:24:30: The solution is not feasible.
INFO - 16:24:30: Objective: 0.2888129873625884
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = 0.1513713660745195
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.252181466244097 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.166666666666667 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 837.52 it/sec, feas=False, obj=0.579]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 967.10 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1178.62 it/sec, feas=False, obj=-0.267]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1300.66 it/sec, feas=False, obj=-0.809]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1394.29 it/sec, feas=False, obj=-0.868]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1353.95 it/sec, feas=False, obj=-0.874]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1318.55 it/sec, feas=False, obj=-0.266]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1295.24 it/sec, feas=False, obj=0.135]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1339.94 it/sec, feas=False, obj=0.577]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1326.35 it/sec, feas=False, obj=0.288]
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
WARNING - 16:24:30: The solution is not feasible.
INFO - 16:24:30: Objective: 0.28811314244670916
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = 0.15144075010172386
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.252370379421043 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -0.8333333333333334 | 1.5 | float |
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 835.52 it/sec, feas=False, obj=1.25]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 1175.37 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1185.39 it/sec, feas=False, obj=1.01]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1290.56 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1255.63 it/sec, feas=False, obj=0.819]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1329.91 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1302.29 it/sec, feas=False, obj=0.693]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1352.24 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1332.18 it/sec, feas=False, obj=0.584]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1370.20 it/sec, feas=False, obj=-0.875]
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
WARNING - 16:24:30: The solution is not feasible.
INFO - 16:24:30: Objective: 0.5837798748832244
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = 0.19806414473664136
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.165017254128868 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -0.5 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 844.26 it/sec, feas=False, obj=1.38]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 1167.84 it/sec, feas=False, obj=2.88]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1176.08 it/sec, feas=False, obj=1.23]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1299.55 it/sec, feas=False, obj=2.87]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1256.68 it/sec, feas=True, obj=0.848]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1185.05 it/sec, feas=True, obj=0.658]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1143.75 it/sec, feas=True, obj=0.643]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1119.23 it/sec, feas=True, obj=0.616]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1101.09 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1084.39 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.6150998219543254
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.788285881879476
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5773788419679762 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -0.1666666666666667 | 1.5 | float |
INFO - 16:24:30: +------+-------------+---------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 856.68 it/sec, feas=True, obj=1.16]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 1177.51 it/sec, feas=False, obj=2.87]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1119.68 it/sec, feas=True, obj=0.785]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1170.29 it/sec, feas=False, obj=2.88]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1117.35 it/sec, feas=True, obj=0.644]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1089.29 it/sec, feas=True, obj=0.624]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1065.08 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1051.99 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1043.79 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1035.78 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.6150998205402495
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.7883188793606977
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5773502675245377 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.1666666666666667 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 843.58 it/sec, feas=True, obj=0.838]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 1182.16 it/sec, feas=False, obj=2.88]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1200.54 it/sec, feas=True, obj=0.656]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1123.27 it/sec, feas=True, obj=0.639]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1085.15 it/sec, feas=True, obj=0.616]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1064.18 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1050.04 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1040.25 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1031.87 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Successive iterates of the objective function are closer than ftol_rel or ftol_abs. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.6150998205402495
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.7883188774386114
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5773502691891133 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 866.95 it/sec, feas=True, obj=0.625]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 1212.40 it/sec, feas=False, obj=2.87]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1223.90 it/sec, feas=True, obj=0.616]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1142.32 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1092.55 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1071.07 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1055.63 it/sec, feas=True, obj=0.615]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Successive iterates of the objective function are closer than ftol_rel or ftol_abs. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.6150998205402495
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.78831887743932
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5773502691884995 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.8333333333333335 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 856.16 it/sec, feas=True, obj=0.745]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 987.94 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1191.90 it/sec, feas=False, obj=-0.267]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1235.53 it/sec, feas=False, obj=-0.809]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1327.90 it/sec, feas=False, obj=-0.868]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1295.67 it/sec, feas=False, obj=-0.874]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1276.97 it/sec, feas=False, obj=-0.266]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1265.30 it/sec, feas=False, obj=0.135]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1314.87 it/sec, feas=False, obj=0.577]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1302.98 it/sec, feas=False, obj=0.288]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.7453703703703706
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.2499785665294918
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.8333333333333335 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 1.166666666666667 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 10%|█ | 1/10 [00:00<00:00, 844.94 it/sec, feas=False, obj=1.42]
INFO - 16:24:30: 20%|██ | 2/10 [00:00<00:00, 984.23 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 30%|███ | 3/10 [00:00<00:00, 1186.96 it/sec, feas=False, obj=-0.267]
INFO - 16:24:30: 40%|████ | 4/10 [00:00<00:00, 1313.59 it/sec, feas=False, obj=-0.809]
INFO - 16:24:30: 50%|█████ | 5/10 [00:00<00:00, 1395.96 it/sec, feas=False, obj=-0.868]
INFO - 16:24:30: 60%|██████ | 6/10 [00:00<00:00, 1352.27 it/sec, feas=False, obj=-0.874]
INFO - 16:24:30: 70%|███████ | 7/10 [00:00<00:00, 1323.96 it/sec, feas=False, obj=-0.266]
INFO - 16:24:30: 80%|████████ | 8/10 [00:00<00:00, 1301.52 it/sec, feas=False, obj=0.135]
INFO - 16:24:30: 90%|█████████ | 9/10 [00:00<00:00, 1345.48 it/sec, feas=False, obj=0.577]
INFO - 16:24:30: 100%|██████████| 10/10 [00:00<00:00, 1326.35 it/sec, feas=False, obj=0.288]
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
WARNING - 16:24:30: The solution is not feasible.
INFO - 16:24:30: Objective: 0.28811314244698893
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = 0.1514407501016959
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.252370379420967 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: Optimization problem:
INFO - 16:24:30: minimize obj(x)
INFO - 16:24:30: with respect to x
INFO - 16:24:30: under the inequality constraints
INFO - 16:24:30: cstr(x) <= 0
INFO - 16:24:30: over the design space:
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 1.5 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------+-------------+-------+
INFO - 16:24:30: Solving optimization problem with algorithm SLSQP:
INFO - 16:24:30: 11%|█ | 1/9 [00:00<00:00, 844.94 it/sec, feas=False, obj=2.88]
INFO - 16:24:30: 22%|██▏ | 2/9 [00:00<00:00, 981.24 it/sec, feas=False, obj=-0.875]
INFO - 16:24:30: 33%|███▎ | 3/9 [00:00<00:00, 1194.39 it/sec, feas=False, obj=-0.267]
INFO - 16:24:30: 44%|████▍ | 4/9 [00:00<00:00, 1311.95 it/sec, feas=False, obj=-0.809]
INFO - 16:24:30: 56%|█████▌ | 5/9 [00:00<00:00, 1403.25 it/sec, feas=False, obj=-0.868]
INFO - 16:24:30: 67%|██████▋ | 6/9 [00:00<00:00, 1359.87 it/sec, feas=False, obj=-0.874]
INFO - 16:24:30: 78%|███████▊ | 7/9 [00:00<00:00, 1330.50 it/sec, feas=False, obj=-0.266]
INFO - 16:24:30: 89%|████████▉ | 8/9 [00:00<00:00, 1307.25 it/sec, feas=False, obj=0.135]
INFO - 16:24:30: 100%|██████████| 9/9 [00:00<00:00, 1351.55 it/sec, feas=False, obj=0.577]
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: Maximum number of iterations reached. GEMSEO stopped the driver.
INFO - 16:24:30: Solution:
WARNING - 16:24:30: The solution is not feasible.
INFO - 16:24:30: Objective: 0.13490034433852438
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = 0.1877267982258064
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | -1.29210243221006 | 1.5 | float |
INFO - 16:24:30: +------+-------------+-------------------+-------------+-------+
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
WARNING - 16:24:30: Optimization found no feasible point; the least infeasible point is selected.
INFO - 16:24:30: Exporting the optimization problem to the file multistart.hdf5
INFO - 16:24:30: 1%| | 1/100 [00:00<00:11, 8.34 it/sec, feas=False, obj=0.577]
INFO - 16:24:30: Optimization result:
INFO - 16:24:30: Optimizer info:
INFO - 16:24:30: Status: None
INFO - 16:24:30: Message: None
INFO - 16:24:30: Solution:
INFO - 16:24:30: The solution is feasible.
INFO - 16:24:30: Objective: 0.6150998205402495
INFO - 16:24:30: Standardized constraints:
INFO - 16:24:30: cstr = -0.7883188793606977
INFO - 16:24:30: Design space:
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | Name | Lower bound | Value | Upper bound | Type |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: | x | -1.5 | 0.5773502675245377 | 1.5 | float |
INFO - 16:24:30: +------+-------------+--------------------+-------------+-------+
INFO - 16:24:30: *** End MDOScenario execution ***
Lastly, we can plot the history of the objective, either by concatenating the 10 sub-optimization histories:
execute_post(
scenario, post_name="BasicHistory", variable_names=["obj"], save=False, show=True
)

<gemseo.post.basic_history.BasicHistory object at 0x7c2f8fbd2660>
or by filtering the local optima (one per starting point):
execute_post(
"multistart.hdf5",
post_name="BasicHistory",
variable_names=["obj"],
save=False,
show=True,
)

INFO - 16:24:30: Importing the optimization problem from the file multistart.hdf5
<gemseo.post.basic_history.BasicHistory object at 0x7c2f7068cc50>
Total running time of the script: (0 minutes 0.356 seconds)