Quick Start

In this section, we list the commonly used API objects and endpoints. For the complete core module documentation, please refer to the Endpoints and Objects pages.

Experiment

Object

Experiment - An experiment represents an objective that SigOpt is optimizing, the relevant parameters, and the underlying data.

Endpoints

Experiment Create - Creates a new Experiment.

Experiment Update - Updates an existing Experiment

Example: Experiment Create

conn = Connection(client_token="USER_TOKEN")

experiment = conn.experiments().create(
  name="first experiment",
  parameters=[
    dict(
      name="parameter_1",
      bounds=dict(
        min=10,
        max=100
        ),
      type="int"
      ),
    dict(
      name="parameter_2",
      bounds=dict(
        min=0.1,
        max=1.4,
        ),
      type="double"
      )
    ],
  metrics=[
    dict(
      name="metric_1",
      objective="maximize",
      strategy="optimize"
      )
    ],
  observation_budget=30,
)

Suggestion

Object

Suggestion - A representation of the parameters that SigOpt has suggested. Contains a list of parameters and their suggested values.

Endpoints

Suggestion Create - Creates a Suggestion that SigOpt recommends in order to optimize your metric.

Suggestion List - Retrieves a Pagination of all Suggestion objects for this experiment.

Suggestion Delete - Deletes a Suggestion

Example: Suggestion Create

suggestion = conn.experiments(EXPERIMENT_ID).suggestions().create()

Observation

Object

Observation - The observed data from a single trial in your experiment.

Endpoints

Observation Create - Create an Observation.

Observation List - Retrieves a Pagination of all Observation objects for this experiment.

Observation Delete - Deletes an Observation.

Example: Observation Create

observation = conn.experiments(EXPERIMENT_ID).observations().create(
  suggestion=SUGGESTION_ID,
  values=[{"name": "metric_1", "value": 3.14}],
)

Last updated