Wrapped Runner#
Runner that calls your wrappers to run your model and poll the trial status.
- class boa.runner.WrappedJobRunner(wrapper: Optional[BaseWrapper] = None, *args, **kwargs)[source]#
Bases:
Runner- Parameters:
wrapper (BaseWrapper) –
- run(trial: BaseTrial) Dict[str, Any][source]#
Deploys a trial based on custom runner subclass implementation.
- poll_trial_status(trials: Iterable[BaseTrial]) Dict[TrialStatus, Set[int]][source]#
Checks the status of any non-terminal trials and returns their indices as a mapping from TrialStatus to a list of indices. Required for runners used with Ax
Scheduler.NOTE: Does not need to handle waiting between polling calls while trials are running; this function should just perform a single poll.
- Parameters:
trials (Iterable[BaseTrial]) – Trials to poll.
- Returns:
A dictionary mapping TrialStatus to a list of trial indices that have the respective status at the time of the polling. This does not need to include trials that at the time of polling already have a terminal (ABANDONED, FAILED, COMPLETED) status (but it may).
- Return type: