def func(*x):
    print(('func:', x))


class ABC:

    def __init__(self, f):
        self.f1 = MethodType(f, self, self.__class__)

def f2(*x):
    print(('f2:', x))
if __name__ == '__main__':
    pass
Python: calling a function as a method of a class