Commit e1cb934
modify
Summary:
Pull Request resolved: #2073
To match penalty term with MC objective, we current unsqueeze the first dim which corresponds to the dimension of MC samples. However, when a `qxd`-dim X tensor is evaluated e.g. computing feasibility, it causes shape mismatch. As one would expect `q`-dim tensor returned, it will return `1xq`-dim tensor instead.
To fix, we check the dims of obj; if it is non-mc samples, we will sequeeze the first dim back.
Reviewed By: bletham
Differential Revision: D49305807
fbshipit-source-id: c8e2dedbdb38d79b5910aca393cf2d3d4e1e311fPenalizedMCObjective to support non-batch eval (#2073)1 parent d81a674 commit e1cb934
File tree
2 files changed
+7
-1
lines changed- botorch/acquisition
- test/acquisition
2 files changed
+7
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
366 | 366 | | |
367 | 367 | | |
368 | 368 | | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
369 | 375 | | |
370 | 376 | | |
371 | 377 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
291 | 291 | | |
292 | 292 | | |
293 | 293 | | |
294 | | - | |
| 294 | + | |
295 | 295 | | |
296 | 296 | | |
297 | 297 | | |
| |||
0 commit comments