your_function = types.FunctionType(marshal.loads(marshaled_bytecode),
    globals(), pickle.loads(pickled_name), pickle.loads(pickled_arguments),
    pickle.loads(pickled_closure))
We need to pickle any sort of callable