(fn)
return wrapper
Decorator to time the execution of the function.

    :param fn: the function to be decorated
    :type fn: C{func}

    :return: the decorated function
    :rtype: C{func}
Decorator to time the execution of the function.
Decorator to time the execution of the function .
def time_calls(fn):
    """
    Decorator to time the execution of the function.

    :param fn: the function to be decorated
    :type fn: C{func}

    :return: the decorated function
    :rtype: C{func}
    """

    @functools.wraps(fn)
    def wrapper(*args, **kwargs):
        _timer = timer("%s_calls" % get_qualname(fn))
        with _timer.time(fn=get_qualname(fn)):
            return fn(*args, **kwargs)

    return wrapper
def time_calls ( fn ) : @ functools . wraps ( fn ) def wrapper ( * args , * * kwargs ) : _timer = timer ( "%s_calls" % get_qualname ( fn ) ) with _timer . time ( fn = get_qualname ( fn ) ) : return fn ( * args , * * kwargs ) return wrapper