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,
),
)

<gemseo.post.basic_history.BasicHistory object at 0x78590a53ca40>
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,
),
)

<gemseo.post.basic_history.BasicHistory object at 0x7859120e1820>
Total running time of the script: (0 minutes 0.330 seconds)