def __init__(self): wx.Frame.__init__(self, None, title='Image Extractor') self.panel = wx.Panel(self) loc = wx.IconLocation(r'C:\Python35\python.exe', 0) self.SetIcon(wx.Icon(loc))