Make fully Bayesian imports lazy (#5148)#5148
Closed
sdaulton wants to merge 1 commit into
Closed
Conversation
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 6, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 7, 2026
Summary: X-link: facebook/Ax#5148 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
164bc8b to
b9aac36
Compare
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 7, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 7, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 7, 2026
Summary: Pull Request resolved: facebook#5148 X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
b9aac36 to
90db75f
Compare
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 7, 2026
Summary: X-link: facebook/Ax#5148 Pull Request resolved: meta-pytorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 8, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 8, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
90db75f to
1436ffa
Compare
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 8, 2026
Summary: X-link: facebook/Ax#5148 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 8, 2026
Summary: X-link: facebook/Ax#5148 Pull Request resolved: meta-pytorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 8, 2026
Summary: Pull Request resolved: facebook#5148 X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
1436ffa to
227aacf
Compare
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 9, 2026
Summary: X-link: facebook/Ax#5148 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
227aacf to
970cdd0
Compare
sdaulton
added a commit
to sdaulton/Ax-1
that referenced
this pull request
Apr 9, 2026
Summary: X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
Summary: Pull Request resolved: facebook#5148 X-link: meta-pytorch/botorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
sdaulton
added a commit
to sdaulton/botorch
that referenced
this pull request
Apr 9, 2026
Summary: X-link: facebook/Ax#5148 Pull Request resolved: meta-pytorch#3265 `import botorch` eagerly loaded Pyro via two import paths: 1. `botorch.fit` → `from pyro.infer.mcmc import MCMC, NUTS` 2. `botorch.models.__init__` → `fully_bayesian.py` → Pyro imports This diff makes fully Bayesian imports lazy so that `import botorch` no longer eagerly loads Pyro. The imports are deferred until `fit_fully_bayesian_model_nuts` is called or `SaasFullyBayesianSingleTaskGP`/`SaasFullyBayesianMultiTaskGP` are accessed from `botorch.models`. Reviewed By: saitcakmak Differential Revision: D99687047
970cdd0 to
d62d265
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
X-link: meta-pytorch/botorch#3265
import botorcheagerly loaded Pyro via two import paths:botorch.fit→from pyro.infer.mcmc import MCMC, NUTSbotorch.models.__init__→fully_bayesian.py→ Pyro importsThis diff makes fully Bayesian imports lazy so that
import botorchno longereagerly loads Pyro. The imports are deferred until
fit_fully_bayesian_model_nutsis called or
SaasFullyBayesianSingleTaskGP/SaasFullyBayesianMultiTaskGPareaccessed from
botorch.models.Reviewed By: saitcakmak
Differential Revision: D99687047