bwasti / cache.py Goto Github PK
View Code? Open in Web Editor NEWPython memoization across program runs.
Python memoization across program runs.
Hi,
This is a nice tool and I'd like to use it but unfortunately it does not have a license.
Can you please add license information to your code
More a suggestion really: you can include the has of the function in the list of cache keys to get automatic cache invalidation if the function changes...
This would be a bot flaky, as it would not handle changes in dependent functions, and I don't know how stable python function hashes are in practice. Still, having done a lot of memoization in non-introspecting languages where this is not an option, I think this is a neat possibility.
Alternatively, you might want to add a way of clearing the cache?
But thanks for putting this up!
Hi, I wanted to use caching option in a file,
but I think that the file that store the data is going to grow fast.
Do you think it could be interesting to store data in hdf5 files,
like that we could only retrieve the appropriate data at each call ?
(I am no expert in hdf5 format, but I think that it works like that)
Best
Would this be suitable to optimize web application calls? (e. g. Flask)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.