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

Replace custom memoize module with cachetools #4509

Merged
merged 2 commits into from
Mar 8, 2021

Conversation

brandonwillard
Copy link
Contributor

This PR replaces our custom pymc3.memoize module with cachetools.

Closes #4506.

@brandonwillard brandonwillard self-assigned this Mar 7, 2021
@twiecki
Copy link
Member

twiecki commented Mar 7, 2021

Needs a line in release-notes.

@brandonwillard brandonwillard force-pushed the fix-memoization branch 2 times, most recently from dd1dd51 to ca59303 Compare March 7, 2021 21:10
@brandonwillard
Copy link
Contributor Author

I changed all the caches to LRUs with a maximum of 128 items. This should help prevent memory leaks—at the cost of speed in certain cases, of course.

RELEASE-NOTES.md Outdated Show resolved Hide resolved
@brandonwillard brandonwillard merged commit 34b35c1 into pymc-devs:master Mar 8, 2021
@brandonwillard brandonwillard deleted the fix-memoization branch March 8, 2021 00:43
@ferrine
Copy link
Member

ferrine commented Mar 8, 2021

Thanks, @brandonwillard!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hash collisions in memoization result in invalid values
3 participants