win10下安装tesserocr失败(Failed building wheel for tesserocr)问题的解决方法

在win10下使用pip install tesserocr安装时,始终报错:
其中有几个关键点:

  1. Subprocess output does not appear to be encoded as cp936

  2. error: Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual C++ Build Tools”: https://visualstudio.microsoft.com/downloads/

  3. Failed building wheel for tesserocr

  4. Command “e:\anaconda353\python.exe -u -c “import setuptools, tokenize;file=‘C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-6mm2ji_b\tesserocr\setup.py’;f=getattr(tokenize, ‘open’, open)(file);code=f.read().replace(’\r\n’, ‘\n’);f.close();exec(compile(code, file, ‘exec’))” install --record C:\Users\ADMINI~1\AppData\Local\Temp\pip-record-23p4bk4v\install-record.txt --single-version-externally-managed --compile” failed with error code 1 in C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-6mm2ji_b\tesserocr\

在这里插入图片描述
看错误中的关键点,好像和“Microsoft Visual C++ 14.0”还有关系,当然你可以去更新这个Microsoft Visual C++ 14.0来解决这个问题,但是微软的问题,一装都是好几G,实在不想折腾,安装这类文件还有一个方法,那就是通过下载whl文件,然后再通过pip安装即可

  1. 先下载tesserocr的whl安装包:点击下载

  2. 选择适合的版本下载,把下载好的.whl文件放到python安装路径里(一般都是C:\Users\Administrator下面)

  3. 在命令行输入pip install 你下载的文件全名(pip install tesserocr-2.3.1-cp37-cp37m-win_amd64.whl),回车安装成功。
    在这里插入图片描述
    在这里插入图片描述

oK了。


关键词:tesserocr
下一篇


读后有收获可以支付宝请作者喝枸杞,有疑问也可以加作者讨论:





友情链接
@寅春树 豫ICP备20020705号 Powered by Thinkcmfx