NIUCLOUD是一款SaaS管理后台框架多应用插件+云编译。上千名开发者、服务商正在积极拥抱开发者生态。欢迎开发者们免费入驻。一起助力发展! 广告
简介 ``` 一个将图象翻译成文字的OCR库 ``` 安装 ``` windows https://code.google.com/p/tesseract-ocr/downloads/list ``` ``` Linux apt-get install tesseract-ocr ``` ``` Mac brew install tesseract ``` 在终端中使用 ``` tesseract test.png text ``` python中使用 ``` pip3 install pytesseract ``` ``` import pytesseract from PIL import Image # 打开图片 img = Image.open("test.png") # 调用tesseract识别图片 data = pytesseract.image_to_string(img) # 输出结果 print(data) ```