Deep learning for NeuroImaging in Python.
Note
This page is a reference documentation. It only explains the function signature, and not how to use it. Please refer to the gallery for the big picture.
- surfify.utils.io.compute_and_store(func, cachedir=None)[source]¶
Decorator allowing to compute and store a function’s output to access them faster on the next calls of the wrapped function.
- Parameters:
func : callable
function to cache. It will receive arguments of the wrapped function that have the same name as its arguments when executed.
cachedir : str, default None
the path of the base directory to use as a data store or None. If None is given, no caching is done and the Memory object is completely transparent.
- Returns:
decorator : callable
the decorated function that can use the cached function outputs.
Notes
The decorator input function and the decorated function must have overlaping arguments. The decorator input function must also returns a dictionnary containing the items to be stored.
Follow us