Skip to content

Instantly share code, notes, and snippets.

@ZakyHermawan
Created June 10, 2021 21:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ZakyHermawan/bec65929114802e40f73844fb920facd to your computer and use it in GitHub Desktop.
Save ZakyHermawan/bec65929114802e40f73844fb920facd to your computer and use it in GitHub Desktop.
take screenshot of chess board using pyautogui
def take_screenshot():
img = pyautogui.screenshot()
board_image = np.array(img)
board_image = board_image[:, :, ::-1].copy()
return board_image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment