gemseo.algos.opt.scipy_local.settings.nelder_mead module#

Settings for the SciPy Nelder-Mead algorithm.

Settings NELDER_MEAD_Settings(*, enable_progress_bar=None, eq_tolerance=1e-06, ineq_tolerance=0.0001, log_problem=True, max_time=0.0, normalize_design_space=True, reset_iteration_counters=True, round_ints=True, use_database=True, use_one_line_progress_bar=False, store_jacobian=True, ftol_rel=1e-09, ftol_abs=1e-09, max_iter=1000, scaling_threshold=None, stop_crit_n_x=3, xtol_rel=1e-09, xtol_abs=1e-09, disp=False, return_all=False, initial_simplex=None, adaptive=False)#

Bases: BaseScipyLocalSettings

Settings for the SciPy Nelder-Mead algorithm.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:
  • enable_progress_bar (bool | None)

  • eq_tolerance (Annotated[float, Ge(ge=0), Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 1e-06.

  • ineq_tolerance (Annotated[float, Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 0.0001.

  • log_problem (bool) --

    By default it is set to True.

  • max_time (Annotated[float, Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 0.0.

  • normalize_design_space (bool) --

    By default it is set to True.

  • reset_iteration_counters (bool) --

    By default it is set to True.

  • round_ints (bool) --

    By default it is set to True.

  • use_database (bool) --

    By default it is set to True.

  • use_one_line_progress_bar (bool) --

    By default it is set to False.

  • store_jacobian (bool) --

    By default it is set to True.

  • ftol_rel (Annotated[float, Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 1e-09.

  • ftol_abs (Annotated[float, Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 1e-09.

  • max_iter (Annotated[int, Gt(gt=0), Gt(gt=0), Gt(gt=0)]) --

    By default it is set to 1000.

  • scaling_threshold (Annotated[float, Ge(ge=0)] | None)

  • stop_crit_n_x (Annotated[int, Ge(ge=2)]) --

    By default it is set to 3.

  • xtol_rel (Annotated[float, Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 1e-09.

  • xtol_abs (Annotated[float, Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0), Ge(ge=0)]) --

    By default it is set to 1e-09.

  • disp (bool) --

    By default it is set to False.

  • return_all (bool) --

    By default it is set to False.

  • initial_simplex (Sequence[float] | _NDArrayPydantic[Any, dtype[float]] | None)

  • adaptive (bool) --

    By default it is set to False.

Return type:

None

adaptive: bool = False#

Whether to adapt the algorithm parameters to dimensionality of problem.

initial_simplex: Sequence[float] | NDArrayPydantic[float] | None = None#

The initial simplex.

If provided, the expected shape is (N+1, N) where N is the problem dimension.

return_all: bool = False#

Whether to return a list of the best solution at each of the iterations.

model_post_init(context, /)#

We need to both initialize private attributes and call the user-defined model_post_init method.

Parameters:
  • self (BaseModel)

  • context (Any)

Return type:

None