Skip to content

Commit

Permalink
Merge pull request #5428 from eukaryo/gp-indep-multi-error
Browse files Browse the repository at this point in the history
Check whether the study is multi-objective in `sample_independent` of `GPSampler`
  • Loading branch information
HideakiImamura committed May 7, 2024
2 parents 89b0fd1 + 6a23882 commit 3d8e199
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions optuna/samplers/_gp/sampler.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ def sample_independent(
param_name: str,
param_distribution: BaseDistribution,
) -> Any:
self._raise_error_if_multi_objective(study)
return self._independent_sampler.sample_independent(
study, trial, param_name, param_distribution
)
Expand Down

0 comments on commit 3d8e199

Please sign in to comment.