You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using NChooseK constraints in high-dim optimizations results in very slow candidate generation. We are treating NChooseK constraints as nonlinear constraints using the same continuous relaxations as in this paper: https://arxiv.org/abs/2203.01900.
When using nonlinear constraints in botorch, one has to provide starting points that fulfil the constraints. This is done by using BoFire's RandomStrategy:
The RandomStrategy is very inefficient when using NChooseK's in high dimensions, which can be easily shown by this script, which runs essentially forever:
When reducint N_INPUTS to smaller numbers like 20, it start to work again. The reason for the slow performance is that the random strategy generates all possible combinations for the NChooseK constraints:
For this purpose, it uses domain.get_nchoosek_combinations which is super slow legacy code which was not written for high-dim problem settings. So to speed up the optimization, the generation of the valid starting points for the ACQF implementation has to be improved, or one has to swich to alternative solutions like SEBO, nevertheless a tidy-up of this part of the code is definitely necessary.
Using NChooseK constraints in high-dim optimizations results in very slow candidate generation. We are treating NChooseK constraints as nonlinear constraints using the same continuous relaxations as in this paper: https://arxiv.org/abs/2203.01900.
bofire/bofire/utils/torch_tools.py
Line 136 in 27e4693
When using nonlinear constraints in botorch, one has to provide starting points that fulfil the constraints. This is done by using BoFire's
RandomStrategy
:bofire/bofire/strategies/predictives/botorch.py
Line 248 in 27e4693
The
RandomStrategy
is very inefficient when using NChooseK's in high dimensions, which can be easily shown by this script, which runs essentially forever:When reducint
N_INPUTS
to smaller numbers like 20, it start to work again. The reason for the slow performance is that the random strategy generates all possible combinations for the NChooseK constraints:bofire/bofire/strategies/random.py
Line 124 in 27e4693
For this purpose, it uses
domain.get_nchoosek_combinations
which is super slow legacy code which was not written for high-dim problem settings. So to speed up the optimization, the generation of the valid starting points for the ACQF implementation has to be improved, or one has to swich to alternative solutions like SEBO, nevertheless a tidy-up of this part of the code is definitely necessary.cc: @CompRhys
The text was updated successfully, but these errors were encountered: