lenskit.schemas.tuning.SearchConfig#
- class lenskit.schemas.tuning.SearchConfig#
Bases:
pydantic.BaseModelConfiguration options for the hyperparameter search.
- default_points: int = 60#
The default number of search points, if not limited by a maximum configuration.
- error_action: ErrorAction = 'continue'#
What to do when one of the search trials fails.
- num_cpus: int | Literal['threads', 'backend-threads', 'all-threads'] = 'threads'#
The number of CPUs to request from Ray Tune.
- median_min_trials: int = 5#
The minimum number of trials at an epoch for the median pruner to consider pruning.
- resolved_direction()#
Get the metric optimization direction.
- Return type:
Literal[‘min’, ‘max’]
- update_max_points(n)#
Limit the search points to a new maximum, if it exceeds the current maximum.
- Parameters:
n (int | None)
- merge(other)#
Produce a new configuration by merging another configuration into this one.
- Parameters:
other (SearchConfig) – The other configuration to merge.
- Returns:
The combination of
selfandother, where values fromotherare preferred in case of conflict.- Return type: