Skip to content

Commit

Permalink
fix reshape issue for bayesian strategy (#1042)
Browse files Browse the repository at this point in the history
Signed-off-by: Kaihui-intel <[email protected]>
  • Loading branch information
Kaihui-intel authored Jun 29, 2023
1 parent 501440a commit 77cb836
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion neural_compressor/strategy/bayesian.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def acq_max(ac, gp, y_max, bounds, random_seed, n_warmup=10000, n_iter=10):
for x_try in x_seeds:
# Find the minimum of minus the acquisition function
res = minimize(lambda x: -ac(x.reshape(1, -1), gp=gp, y_max=y_max),
x_try.reshape(1, -1),
x_try.flatten(),
bounds=bounds,
method="L-BFGS-B")

Expand Down

0 comments on commit 77cb836

Please sign in to comment.