Commit b672f5d
Fit models in SumMarginalLogLikelihood sequentially by default (#183)
Summary:
Currently, `fit_gpytorch_model` solves a single joint optimization problem to fit ModelListGP (and, more generally, any ModuleList model that has a SumMarginalLogLikelihood).
If there are only a few models then this is just fine. If there are a lot of models, each with a lot of parameters, then the dimension of the optimization problem can become quite large, and the optimizer may have a hard time optimizing the joint problem (as it's not exploiting the independence structure).
This PR changes the default behavior to fit the models sequentially, solving multiple simpler optimization problems instead a single harder one. This can be overridden by passing in `sequential=False` to `fit_gpytorch_model`.
Pull Request resolved: #183
Test Plan: Unit tests
Reviewed By: sdaulton
Differential Revision: D15980508
Pulled By: Balandat
fbshipit-source-id: 5c8be7c8b8db4ceaed6a8d1738527f788097a6ba1 parent 5c33d69 commit b672f5d
2 files changed
+11
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
| |||
33 | 34 | | |
34 | 35 | | |
35 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
36 | 42 | | |
37 | 43 | | |
38 | 44 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| 71 | + | |
| 72 | + | |
71 | 73 | | |
| 74 | + | |
| 75 | + | |
72 | 76 | | |
73 | 77 | | |
74 | 78 | | |
| |||
0 commit comments