smac.initial_design.initial_design module

class smac.initial_design.initial_design.InitialDesign(cs: ConfigSpace.configuration_space.ConfigurationSpace, rng: numpy.random.mtrand.RandomState, traj_logger: smac.utils.io.traj_logging.TrajLogger, ta_run_limit: int, configs: Optional[List[ConfigSpace.configuration_space.Configuration]] = None, n_configs_x_params: Optional[int] = 10, max_config_fracs: float = 0.25, init_budget: Optional[int] = None)[source]

Bases: object

Base class for initial design strategies that evaluates multiple configurations

cs
Type

ConfigurationSpace

configs

List of configurations to be evaluated

Type

typing.List[Configuration]

Constructor

Parameters
  • cs (ConfigurationSpace) – configuration space object

  • rng (np.random.RandomState) – Random state

  • traj_logger (TrajLogger) – Trajectory logging to add new incumbents found by the initial design.

  • ta_run_limit (int) – Number of iterations allowed for the target algorithm

  • configs (typing.Optional[typing.List[Configuration]]) – List of initial configurations. Disables the arguments n_configs_x_params if given. Either this, or n_configs_x_params or init_budget must be provided.

  • n_configs_x_params (int) – how many configurations will be used at most in the initial design (X*D). Either this, or init_budget or configs must be provided. Disables the argument n_configs_x_params if given.

  • max_config_fracs (float) – use at most X*budget in the initial design. Not active if a time limit is given.

  • init_budget (int, optional) – Maximal initial budget (disables the arguments n_configs_x_params and configs if both are given). Either this, or n_configs_x_params or configs must be provided.

_select_configurations() → List[ConfigSpace.configuration_space.Configuration][source]
_transform_continuous_designs(design: numpy.ndarray, origin: str, cs: ConfigSpace.configuration_space.ConfigurationSpace) → List[ConfigSpace.configuration_space.Configuration][source]
select_configurations() → List[ConfigSpace.configuration_space.Configuration][source]