Files
damai/scripts/captcha_solver.py

9 lines
217 B
Python
Raw Normal View History

2026-03-13 12:05:03 +08:00
import pytesseract
from PIL import Image
def solve_captcha(image_path):
# 使用OCR识别验证码
image = Image.open(image_path)
captcha_text = pytesseract.image_to_string(image)
return captcha_text