#๐Ÿ”’ I am trying to make an image recognition code, but can't get it done, can someone help?

27 messages ยท Page 1 of 1 (latest)

wooden cosmos
#

The code is in pinned

stray daggerBOT
#

@wooden cosmos

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

wooden cosmos
#

code is in pinned messages

crimson mica
wooden cosmos
#

idk if you can see it, but if you click expand, you might be able to see it

crimson mica
#

I'm already in full view

topaz ridge
#

#1293478722711846942

wooden cosmos
#

it just outputs an error

crimson mica
#

not exactly the image recognition algorithm I was expecting, sorry couldn't help you with it.

leaden glade
wooden cosmos
leaden glade
# wooden cosmos what

!e

print((123, 456)[0])
print((789, 258)[1])
print((852, 963)[123])

The first 2 will print fine.
The last one will error out

stray daggerBOT
leaden glade
#

same error as you

leaden glade
wooden cosmos
leaden glade
#
>>> import pyautogui
>>> pyautogui.pixelMatchesColor(100, 200, (130, 135, 144))
True
>>> pyautogui.pixelMatchesColor(100, 200, (0, 0, 0))
False
wooden cosmos
#

oh

#

idk

leaden glade
#

well its either that or just the .red part

#

e.g.

>>> import pyautogui
>>> pix = pyautogui.pixel(100, 200)
>>> pix
RGB(red=130, green=135, blue=144)
>>> pix[0]
130
>>> pix.red
130
stray daggerBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.