Here\'s the code that I\'m trying to run:
import pyautogui r=pyautogui.locateOnScreen(\'C:\\Users\\David\\Desktop\\index.png\',grayscale=False) print r
The first answer was the answer for me.
After doing pip install opencv_python and then modifying my search like below things worked:
button7location = pyautogui.locateOnScreen('1606271188298.png',grayscale=True, confidence=.5)
Thanks!