Update HM.py

I have amended the class to remove the unnecessary (object) call and added a constructor so that the buttons are created automatically when the class is instaniated.