Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't use functools.lru_cache on methods #1650

Closed
wants to merge 1 commit into from

Conversation

esantorella
Copy link
Member

Summary:
It can cause memory leaks. For explanation
and fix, see https://rednafi.github.io/reflections/dont-wrap-instance-methods-with-functoolslru_cache-decorator-in-python.html

Differential Revision: D42980747

@facebook-github-bot facebook-github-bot added CLA Signed Do not delete this pull request or issue due to inactivity. fb-exported labels Feb 3, 2023
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D42980747

@codecov
Copy link

codecov bot commented Feb 3, 2023

Codecov Report

Merging #1650 (4b0e35c) into main (b3d3074) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##              main     #1650   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          165       165           
  Lines        14277     14284    +7     
=========================================
+ Hits         14277     14284    +7     
Impacted Files Coverage Δ
botorch/posteriors/fully_bayesian.py 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Summary:
Pull Request resolved: pytorch#1650

It can cause memory leaks. For explanation
 and fix, see https://rednafi.github.io/reflections/dont-wrap-instance-methods-with-functoolslru_cache-decorator-in-python.html

Differential Revision: D42980747

fbshipit-source-id: 8b780d2679bac46de9c0081d59123ee62f791436
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D42980747

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in 7e1350b.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Do not delete this pull request or issue due to inactivity. fb-exported Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants