Python Add Function To Class Instance