用google搜: module 'pytesseract' has no attribute 'image_to_string' 找到了 python - AttributeError: module 'pytesseract' has no attribute 'image_to_string' - Stack Overflow 想到了:可能是你 测试文件名 和 库文件 同名导致的。 仔细一看你截图,果然是 当前目录下 有个 pytesseract.py,和库文件 同名了 解决办法: 确保你测试的文件 不要和 被测的库 同名 此处即: 把(被测文件pytesseract2.py所在同目录中的)pytesseract.py 改为 比如 pytesseractTest.py 详见: 测试文件名和库同名 · Python新手小白常见错误和问题
37,744
社区成员
34,212
社区内容
加载中
试试用AI创作助手写篇文章吧