lenskit.tuning.RayTuneResults#

class lenskit.tuning.RayTuneResults#

Bases: lenskit.tuning._base.TuneResults

Helper class that provides a standard way to create an ABC using inheritance.

iterative: bool#
results: ray.tune.ResultGrid#
num_trials()#

Get the number of completed trials in this search.

trials()#

Iterate over individual trials in this search. Each dictionary contains metric(s), the configuration (as "config"), and other tuner-specific fields.

Return type:

collections.abc.Iterable[dict[str, pydantic.JsonValue]]

epochs()#

Iterate over individual iterations within trials. The dictionary contains columns identifying both the iteration and the trial.

Return type:

collections.abc.Iterable[dict[str, pydantic.JsonValue]]

best_config(*, scope='all')#

Get the best configuration.

Parameters:

scope (str) – The metric search scope for iterative training. Set to "last" to use the last iteration instead of the best iteration. See ray.tune.ResultGrid.get_best_result() for details.

Return type:

dict[str, pydantic.JsonValue]

best_result(*, scope='all')#

Get the best configuration and its validation metrics.

Parameters:

scope (str) – The metric search scope for iterative training. Set to "last" to use the last iteration instead of the best iteration. See ray.tune.ResultGrid.get_best_result() for details.

Return type:

dict[str, pydantic.JsonValue]