Skip to main content

Variables

  • INTEGRATION_VERSION_KEY: Key under which the version of the Neptune-Optuna integration is logged in Neptune. Set to the value of source_code/integrations/neptune-optuna.

log_study_metadata

Logs the metadata from the Optuna study to Neptune. With this function, you can log and display:
  • Values and params for each trial.
  • Current best values and params for the study.
  • Visualizations from the optuna.visualizations module.
  • Parameter distributions for each trial.
  • The study object itself, to load it later.
Parameters: Examples: Initialize a Neptune run and log Optuna study metadata:
Create and run the study:
Log single and multi-objective study metadata to Neptune:
Or optionally pass a list of one or more objective names:
For more, see the Neptune-Optuna Integration Guide.

load_study_from_run

Loads Optuna study from an existing Neptune run. Loading mechanics depend on the study storage type used during the run:
  • If the study used ‘InMemoryStorage’, it will be loaded from the logged pickled study object.
  • If the study used database storage, it will be loaded from the logged database URL.
To resume an existing run, you need the run ID. It is stored in the run’s “sys/id” field. Parameters: Examples: Initialize an existing run by passing the run ID:
Load study from the run and continue optimization:
For more, see the Neptune-Optuna Integration Guide.

NeptuneCallback

A callback that logs metadata from an Optuna Study to Neptune. With this callback, you can log and display:
  • Values and parameters for each trial.
  • Current best values and parameters for the study.
  • Visualizations from the optuna.visualizations module.
  • Parameter distributions for each trial.
  • The study object itself, to load it later.
Parameters: Examples: Initialize a Neptune run and log Optuna study metadata.
Initialize a NeptuneCallback:
Or optionally pass a list of one or more objective names:
Log single and multi-objective study metadata to Neptune by passing the callback to the Optuna Study:
For more, see the Neptune-Optuna Integration Guide.

Descendants

  • systematica.tuners.base.BaseCustomNeptuneCallback