1、pip install pillow
2、安装tesseract-ocr
-
配置环境变量
3、书写代码
pip install pytesseract==0.1.8
from pytesseract import image_to_string
from PIL import Image
img = Image.open(r"GetValidateCode.jpg")
# print(img)
print(image_to_string(img))
报错:
image.png image.png image.png
网友评论