Alternative Experiment Types

A random search experiment enables you to randomly search over your parameter space with the SigOpt Platform. To create a random search Experiment, simply set the Experiment type to "random".

By default, SigOpt random suggests uniformly from the parameter space. Random search can be combined with Prior Beliefs to modify the search distribution.

Core Module

experiment = conn.experiments().create(
  name="Random search",
  type="random",
  parameters=[
    dict(
      name="omp_thread",
      type="int",
      bounds=dict(
        min=1,
        max=16,
      )
    ),
    dict(
      name="omp_places",
      type="categorical",
      categorical_values=[
        "threads",
        "core",
        "sockets",
      ]
    )
  ],
  metrics=[
    dict(
      name="throughput",
      objective="maximize"
    )
  ],
  observation_budget=30
)

AI Module

sigopt.create_experiment(
  name="Random search",
  type="random",
  parameters=[
    dict(
      name="learning_rate",
      type="double",
      bounds=dict(
        min=1e-5,
        max=1e-2
      ),
      transformation="log"
    ),
    dict(
      name="activation_function",
      type="categorical",
      categorical_values=[
        "relu",
        "tanh"
      ]
    )
  ],
  metrics=[
    dict(
      name="holdout_accuracy",
      objective="maximize"
    )
  ],
  budget=30
)

A grid search experiment enables users to execute an exhaustive search on a user-defined grid with the SigOpt Platform. This means that every parameter needs to have discrete values; meaning either categorical type or parameters with assigned grid values. To create a grid search Experiment, simply set the Experiment type to "grid".

Grid Search Experiments must have budget that match up with the total number of possible combination of parameter values.

Core Module

experiment = conn.experiments().create(
  name="Grid search",
  type="grid",
  parameters=[
    dict(
      name="omp_thread",
      type="int",
      grid=[1, 2, 3, 4, 5, 6, 7, 8]
    ),
    dict(
      name="omp_places",
      type="categorical",
      categorical_values=[
        "threads",
        "core",
        "sockets",
      ]
    )
  ],
  metrics=[
    dict(
      name="throughput",
      objective="maximize"
    )
  ],
  observation_budget=24
)

AI Module

sigopt.create_experiment(
  name="Grid search",
  type="grid",
  parameters=[
    dict(
      name="learning_rate",
      type="double",
      grid=[1e-5, 1e-4, 1e-3, 1e-2],
      transformation="log"
    ),
    dict(
      name="kernel_size",
      type="int",
      grid=[2, 4, 6, 12]
    ),
    dict(
      name="activation_function",
      type="categorical",
      categorical_values=[
        "relu",
        "tanh"
      ]
    )
  ],
  metrics=[
    dict(
      name="holdout_accuracy",
      objective="maximize"
    )
  ],
  budget=32
)

Last updated