Skip to content

Commit ecd0b19

Browse files
jduerholtfacebook-github-bot
authored andcommitted
Change defaults MC Samples to 512 (#1535)
Summary: <!-- Thank you for sending the PR! We appreciate you spending the time to make BoTorch better. Help us understand your motivation by explaining why you decided to make this change. You can learn more about contributing to BoTorch here: https://github.com/pytorch/botorch/blob/main/CONTRIBUTING.md --> ## Motivation I just recognized that in `get_acquisition_function` a default of 500 mc samples is used, but when one initializes an MC acquisition function directly a default of 512 samples is used: https://github.com/pytorch/botorch/blob/8ecc903392b21ad9468c9b45f26b867d51378461/botorch/acquisition/acquisition.py#L149 I think it makes sense to keep things consistent. In addition, I think it is recommended for sobol sampling to use a sampling size which corresponds to basis 2. ### Have you read the [Contributing Guidelines on pull requests](https://github.com/pytorch/botorch/blob/main/CONTRIBUTING.md#pull-requests)? Yes. Pull Request resolved: #1535 Test Plan: Only default value is changed. No tests necessary. Reviewed By: Balandat Differential Revision: D41651210 Pulled By: saitcakmak fbshipit-source-id: 12c0652eef45ee1493db2939ac3bcbacd191e213
1 parent 8ecc903 commit ecd0b19

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

botorch/acquisition/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def get_acquisition_function(
4343
posterior_transform: Optional[PosteriorTransform] = None,
4444
X_pending: Optional[Tensor] = None,
4545
constraints: Optional[List[Callable[[Tensor], Tensor]]] = None,
46-
mc_samples: int = 500,
46+
mc_samples: int = 512,
4747
seed: Optional[int] = None,
4848
**kwargs,
4949
) -> monte_carlo.MCAcquisitionFunction:

0 commit comments

Comments
 (0)