
Caching ------- Smart caching of function results This module allows results of Python functions to be made persistent for subsequent rapid retrieval. Functions are intercepted, evaluated and their results are compressed and pickled using cPickle. Subsequent function calls with same arguments are replaced by the cached results. If the function or its arguments have been modified it will be recomputed. Recomputation can also be made dependent on the time stamp of arbitrary files or it can be triggered explicitly. This form of caching is very useful for time consuming functions that are called repetitively, such as database or WEB queries but it will work for any function which returns picklable objects. The following paper describes the caching module (along with some others) in more detail: A Toolbox Approach to Flexible and Efficient Data Mining Ole M. Nielsen, Peter Christen, Markus Hegland, Tatiana Semenova and Timothy Hancock. Accepted for the PAKDD-2001 Conference, Hong Kong, April 2001. Available at ftp://csl.anu.edu.au/pub/dm/papers/pakdd2001.pdf.gz or by emailing Ole.Nielsen@bigfoot.com URL: http://csl.anu.edu.au/ml/dm/dm_software.html Download: ftp://csl.anu.edu.au/pub/dm/dmtools/caching.py License: GPL Requires: zlib (recommended but not essential) Categories: Python Utilities Ole M. Nielsen (Ole.Nielsen@bigfoot.com) http://www.bigfoot.com/~Ole.Nielsen -- <a href="http://csl.anu.edu.au/ml/dm/dm_software.html">Caching</a> -- Smart caching of function results
participants (1)
-
Ole M.Nielsen