deepaugment/lib/decorators.py
def decorator_with_argumets(decorator):
    """Decorator of decorator allows the decorator it decorates to accept arbitrary
    number of arguments.
    
    It also allows the decorator to be used without arguments. Possible ways
    of calling the (decorated) decorator are:
        1. @decorator()
        2. @decorator(<args>)
        
    However, (decorated) decorator cannot be called without parantheses (e.g. @decorator)
    """

    def decorator_maker(*args, **kwargs):
        @wraps(decorator)
        def decorator_wrapper(func):
            return decorator(func, *args, **kwargs)

        return decorator_wrapper

    return decorator_maker
Decorator of decorator allows the decorator it decorates to accept arbitrary
    number of arguments.
    
    It also allows the decorator to be used without arguments. Possible ways
    of calling the (decorated) decorator are:
        1. @decorator()
        2. @decorator(<args>)
        
    However, (decorated) decorator cannot be called without parantheses (e.g. @decorator)
    
Decorator of decorator allows the decorator it decorates to accept arbitrary
number of arguments.

It also allows the decorator to be used without arguments. Possible ways
of calling the (decorated) decorator are:
1. @decorator()
2. @decorator()

However, (decorated) decorator cannot be called without parantheses
Decorator of decorator allows the decorator it decorates to accept arbitrary number of arguments . It also allows the decorator to be used without arguments . Possible ways of calling the ( decorated ) decorator are : 1 . @decorator () 2 . @decorator () However ( decorated ) decorator cannot be called without parantheses
def decorator_with_argumets(decorator):
    def decorator_maker(*args, **kwargs):
        @wraps(decorator)
        def decorator_wrapper(func):
            return decorator(func, *args, **kwargs)
        return decorator_wrapper
    return decorator_maker
def decorator_with_argumets ( decorator ) : def decorator_maker ( * args , ** kwargs ) : @ wraps ( decorator ) def decorator_wrapper ( func ) : return decorator ( func , * args , ** kwargs ) return decorator_wrapper return decorator_maker
Decorator of decorator allows the decorator it decorates to accept arbitrary
number of arguments.
Decorator of decorator allows the decorator it decorates to accept arbitrary number of arguments .
"""Decorator of decorator allows the decorator it decorates to accept arbitrary
    number of arguments.
    
    It also allows the decorator to be used without arguments. Possible ways
    of calling the (decorated) decorator are:
        1. @decorator()
        2. @decorator(<args>)
        
    However, (decorated) decorator cannot be called without parantheses (e.g. @decorator)
    """
decorator