gemseo / core

doe_scenario module

Scenario which drivers are Design of Experiments

class gemseo.core.doe_scenario.DOEScenario(disciplines, formulation, objective_name, design_space, name=None, **formulation_options)[source]

Bases: gemseo.core.scenario.Scenario

Design of Experiments scenario, based on MDO scenario but with a DOE driver.

The main differences between Scenario and MDOScenario are the allowed inputs in the MDOScenario.json, which differs from DOEScenario.json, at least on the driver names

MDO Problem description: links the disciplines and the formulation to create an optimization problem. Use the class by instantiation. Create your disciplines beforehand.

Specify the formulation by giving the class name such as the string “MDF”

The reference_input_data is the typical input data dict that is provided to the run method of the disciplines

Specify the objective function name, which must be an output of a discipline of the scenario, with the “objective_name” attribute

If you want to add additional design constraints, use the add_user_defined_constraint method

To view the results, use the “post_process” method after execution. You can view:

  • the design variables history, the objective value, the constraints, by using: scenario.post_process(“OptHistoryView”, show=False, save=True)

  • Quadratic approximations of the functions close to the optimum, when using gradient based algorithms, by using: scenario.post_process(“QuadApprox”, method=”SR1”, show=False, save=True, function=”my_objective_name”, file_path=”appl_dir”)

  • Self Organizing Maps of the design space, by using: scenario.post_process(“SOM”, save=True, file_path=”appl_dir”)

To list post processings on your setup, use the method Scenario.posts. For more details on their options, go to the gemseo.post package.

Constructor, initializes the DOE scenario Objects instantiation and checks are made before run intentionally

Parameters
  • disciplines – the disciplines of the scenario

  • formulation – the formulation name, the class name of the formulation in gemseo.formulations

  • objective_name – the objective function name

  • design_space – the design space

  • name – scenario name

  • formulation_options – options for creation of the formulation

EVAL_JAC = 'eval_jac'
N_SAMPLES = 'n_samples'