我有以下代码:
b_counter = False
while (b_counter == False):
if (pyautogui.locateOnScreen('editcheck.png') is not None):
pyautogui.click(pyautogui.center(pyautogui.locateOnScreen('home.png')))
b_counter = True
循环在运行时会延迟,有时会在图像加载后长达10秒。我的机器本身是相当快的(i7,16 i7,内存等等)。有什么方法可以加速这个循环吗?
我正在加载网页,所以“主页”按钮不会立即出现。此循环发生在pyautogui输入要加载的网址之后。
转载请注明出处:http://www.66758680.com/article/20230526/2331639.html