(func)
return _partial
A decorator that recieves a dict and passes the kwargs to wrapped func.
    It's very useful to use for spark functions:

        @receive_kwargs_as_dict
        def myfunc(a, b):
            return a > 1

        print myfunc({'a': 4, 'b': 6})
        sc.parallelize([{'a': 1, 'b': 2}, {'a': 3, 'b': 4}]).filter(myfunc)
A decorator that recieves a dict and passes the kwargs to wrapped func.
    It's very useful to use for spark functions:
A decorator that recieves a dict and passes the kwargs to wrapped func . It s very useful to use for spark functions :
def receive_kwargs_as_dict(func):
    """A decorator that recieves a dict and passes the kwargs to wrapped func.
    It's very useful to use for spark functions:

        @receive_kwargs_as_dict
        def myfunc(a, b):
            return a > 1

        print myfunc({'a': 4, 'b': 6})
        sc.parallelize([{'a': 1, 'b': 2}, {'a': 3, 'b': 4}]).filter(myfunc)
    """
    @functools.wraps(func)
    def _partial(kwargs_dct, **kwargs):
        kwargs.update(kwargs_dct)
        return func(**kwargs)
    return _partial
def receive_kwargs_as_dict ( func ) : @ functools . wraps ( func ) def _partial ( kwargs_dct , * * kwargs ) : kwargs . update ( kwargs_dct ) return func ( * * kwargs ) return _partial