Skip to content

Commit

Permalink
Update optuna/_gp/acqf.py
Browse files Browse the repository at this point in the history
Co-authored-by: Shuhei Watanabe <47781922+nabenabe0928@users.noreply.github.com>
  • Loading branch information
contramundum53 and nabenabe0928 committed Feb 8, 2024
1 parent 841e7cb commit dd030cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion optuna/_gp/acqf.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def eval_acqf(acqf_params: AcquisitionFunctionParams, x: torch.Tensor) -> torch.
if acqf_params.acqf_type == AcquisitionFunctionType.LOG_EI:
return logei(mean=mean, var=var + acqf_params.acqf_stabilizing_noise, f0=acqf_params.max_Y)
elif acqf_params.acqf_type == AcquisitionFunctionType.UCB:
assert acqf_params.beta is not None
assert acqf_params.beta is not None, "beta must be given to UCB."
return ucb(mean=mean, var=var, beta=acqf_params.beta)
else:
assert False, "Unknown acquisition function type."
Expand Down

0 comments on commit dd030cd

Please sign in to comment.