Format trials

Utility functions for formatting data

Conversion functions between various data types used in framework’s ecosystem.

orion.core.utils.format_trials.dict_to_trial(data, space)[source]

Create a orion.core.worker.trial.Trial object from data, filling only parameter information from data.

  • data – A dict representing a sample point from space.

  • space ( – Definition of problem’s domain.


Format results from a orion.core.worker.trial.Trial using standard structures.


Convert parameter name to namespace format

orion.core.utils.format_trials.trial_to_tuple(trial, space)[source]

Extract a parameter tuple from a orion.core.worker.trial.Trial.

The order within the tuple is dictated by the defined object.

orion.core.utils.format_trials.tuple_to_trial(data, space, status='new')[source]

Create a orion.core.worker.trial.Trial object from data.

data: tuple

A tuple representing a sample point from space.

space: ``

Definition of problem’s domain.

status: str, optional

Status of the trial. One of orion.core.worker.trial.Trial.allowed_stati.

A trial object orion.core.worker.trial.Trial.