Repository navigation
Update skip_fit_gpytorch_mll mock to patch at call site - #5037
Closed
esantorella wants to merge 1 commit into
Closed
esantorella wants to merge 1 commit into
esantorella wants to merge 1 commit into
Conversation
Summary: `FitGPyTorchMLL` is going away, so a mock needs to be updated. Note that `skip_fit_gpytorch_mll_context_manager` will now only work with MBM. It used to mock a function used by `fit_gpytorch_mll`, so it would work whereever `fit_gpytorch_mll` was called; now does so by mocking `fit_gpytorch_mll` itself, through its import at `ax.generators.torch.botorch_modular.utils`. Is this OK for current use cases? There are only two places in Ax that `fit_gpytorch_mll` is used: One in `botorch_modular/utils`, where this will work, and one in `tutorials/modular_botorch/modular_botorch.ipynb`, where this won't work since `fit_gpytorch_mll` is imported from `botorch.fit`. So I updated the tutorial to import from `ax.generators.torch.botorch_modular.utils` Reviewed By: saitcakmak, mpolson64 Differential Revision: D96645791
|
@esantorella has exported this pull request. If you are a Meta employee, you can view the originating Diff in D96645791. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5037 +/- ##
=======================================
Coverage 96.83% 96.84%
=======================================
Files 606 606
Lines 65322 65322
=======================================
+ Hits 63256 63261 +5
+ Misses 2066 2061 -5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
This pull request has been merged in 3659190. |
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:
FitGPyTorchMLLis going away, so a mock needs to be updated.Note that
skip_fit_gpytorch_mll_context_managerwill now only work with MBM. It used to mock a function used byfit_gpytorch_mll, so it would work whereeverfit_gpytorch_mllwas called; now does so by mockingfit_gpytorch_mllitself, through its import atax.generators.torch.botorch_modular.utils.Is this OK for current use cases? There are only two places in Ax that
fit_gpytorch_mllis used: One inbotorch_modular/utils, where this will work, and one intutorials/modular_botorch/modular_botorch.ipynb, where this won't work sincefit_gpytorch_mllis imported frombotorch.fit. So I updated the tutorial to import fromax.generators.torch.botorch_modular.utilsReviewed By: saitcakmak, mpolson64
Differential Revision: D96645791