>>> import pyautogui >>> button7location = pyautogui.locateOnScreen('calc7key.png') >>> print(button7location) #print location of button