0

I'm trying to read a .pdf file for the first time in python, This file has OCR in it.

from wand.image import Image
from PIL import Image as PI
#import pyocrfrom PythonMagick import Image
from PythonMagick import Image
import pyocr.builders
import io

im = Image()
im.read(r"D:/test.pdf")

I have downloaded PythonMagick file which has .whl extension, as directed in this post But still I get error ModuleNotFoundError: No module named 'PythonMagick'

How and what step should be followed so that I could be able to read the OCR PDF in python. Any suggestions are appreciated. Thanks

4

1 回答 1

0

.whl不是您要下载的文件。安装pip工具并使用pip install PythonMagick命令。如果您使用的是 Windows,安装 pip 有点复杂。

于 2017-09-19T11:35:57.997 回答