Note
Go to the end to download the full example code.
Basic history#
In this example, we illustrate the use of the BasicHistory post-processing
on the Sobieski's SSBJ problem.
The BasicHistory can plot any of the constraint or objective functions
w.r.t. the optimization iterations or sampling snapshots.
from __future__ import annotations
from gemseo import execute_post
from gemseo.settings.post import BasicHistory_Settings
We can post-process the objective:
execute_post(
"sobieski_mdf_scenario.h5",
settings_model=BasicHistory_Settings(
variable_names=["y_4"],
save=False,
show=True,
),
)

INFO - 16:25:41: Importing the optimization problem from the file sobieski_mdf_scenario.h5
<gemseo.post.basic_history.BasicHistory object at 0x72a4e0e0f170>
We can also post-process the constraints:
execute_post(
"sobieski_mdf_scenario.h5",
settings_model=BasicHistory_Settings(
variable_names=["g_1", "g_2", "g_3"],
save=False,
show=True,
),
)

INFO - 16:25:42: Importing the optimization problem from the file sobieski_mdf_scenario.h5
<gemseo.post.basic_history.BasicHistory object at 0x72a4e1b8eae0>
Total running time of the script: (0 minutes 0.321 seconds)