Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions smac/acquisition/maximizer/local_and_random_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@ class LocalAndSortedRandomSearch(AbstractAcquisitionMaximizer):
The ratio of random samples that are taken from the user-defined ConfigurationSpace, as opposed to the uniform
version (needs `uniform_configspace`to be defined).
seed : int, defaults to 0
n_jobs_ls: int, defaults to 1
Number of parallel jobs used when performing local search. If 1, the search is serial.
If >1, multiple starting points are evaluated in parallel.
exchange_size_ls: int, defaults to 1
Number of Hyperparameters changed by one step of the Local Search
"""

def __init__(
Expand All @@ -61,6 +66,8 @@ def __init__(
seed: int = 0,
uniform_configspace: ConfigurationSpace | None = None,
prior_sampling_fraction: float | None = None,
n_jobs_ls: int = 1,
exchange_size_ls: int = 1,
) -> None:
super().__init__(
configspace,
Expand Down Expand Up @@ -98,6 +105,8 @@ def __init__(
max_steps=max_steps,
n_steps_plateau_walk=n_steps_plateau_walk,
seed=seed,
n_jobs=n_jobs_ls,
exchange_size=exchange_size_ls,
)

self._local_search_iterations = local_search_iterations
Expand Down
Loading
Loading