'Call wrapped function and cache result, or read cache if available.
This function returns the wrapped function output and some metadata.
Returns
output: value or tuple
what is returned by wrapped function
argument_hash: string
hash of function arguments
metadata: dict
some metadata about wrapped function call (see _persist_input())'

def _cached_call(self, args, kwargs):

    (output_dir, argument_hash) = self._get_output_dir(*args, **kwargs)
    metadata = None
    output_pickle_path = os.path.join(output_dir, 'output.pkl')
    if (not (self._check_previous_func_code(stacklevel=4) and os.path.isfile(output_pickle_path))):
        if (self._verbose > 10):
            (_, name) = get_func_name(self.func)
            self.warn(('Computing    func    %s,    argument    hash    %s    in    directory    %s' % (name, argument_hash, output_dir)))
        (out, metadata) = self.call(*args, **kwargs)
        if (self.mmap_mode is not None):
            out = _load_output(output_dir, _get_func_fullname(self.func), timestamp=self.timestamp, mmap_mode=self.mmap_mode, verbose=self._verbose)
    else:
        try:
            t0 = time.time()
            out = _load_output(output_dir, _get_func_fullname(self.func), timestamp=self.timestamp, metadata=metadata, mmap_mode=self.mmap_mode, verbose=self._verbose)
            if (self._verbose > 4):
                t = (time.time() - t0)
                (_, name) = get_func_name(self.func)
                msg = ('%s    cache    loaded    -    %s' % (name, format_time(t)))
                print ((max(0, (80 - len(msg))) * '_') + msg)
        except Exception:
            (_, signature) = format_signature(self.func, *args, **kwargs)
            self.warn('Exception    while    loading    results    for    {}\n    {}'.format(signature, traceback.format_exc()))
            (out, metadata) = self.call(*args, **kwargs)
            argument_hash = None
    return (out, argument_hash, metadata)
