V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
woshichuanqilz
V2EX  ›  Python

求一个可以无损转换 pdf 为图片文件的方法, 或者 ocr pdf 文件的方法, 命令行的形式?

  •  
  •   woshichuanqilz · 2017-11-20 22:55:48 +08:00 · 3041 次点击
    这是一个创建于 2347 天前的主题,其中的信息可能已经有所发展或是发生改变。

    我的目的是想 ocr 的一个 pdf 文件, 用 python 调用的方式, 我是用了百度 ocr 的接口, 但是这个接口没有办法转换,pdf 文件,可以转换图片文件,嗯,所以我用了 mutool 这个东西去转换 pdf 文件为图片文件,但是问题是,转换过来的图片是比较模糊的,这个应该不利于 ocr 识别,所以我现在想了两个办法,有没有什么高清可以无损转换 pdf 文件的方法?或者有没有什么直接可以 ocr 这个 pdf 文件的方法?

    在这里先感谢各位了,

    6 条回复    2017-11-21 17:36:02 +08:00
    ynyounuo
        1
    ynyounuo  
       2017-11-20 22:59:25 +08:00
    tesseract
    bingod
        2
    bingod  
       2017-11-20 23:05:52 +08:00
    GitHub 搜索 PyPDFOCR
    zhidian
        3
    zhidian  
       2017-11-20 23:32:41 +08:00   ❤️ 1
    xpdf. 或者... 不需要批量处理? 用 pdf.io 在线处理.
    omph
        4
    omph  
       2017-11-21 00:09:37 +08:00
    Forbidden
        5
    Forbidden  
       2017-11-21 10:31:34 +08:00   ❤️ 1
    gs -sDEVICE=jpeg -sOutputFile=%09d.jpg -r300 -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -dBATCH -dNOPAUSE
    woshichuanqilz
        6
    woshichuanqilz  
    OP
       2017-11-21 17:36:02 +08:00
    @zhidian 这个工具 ok 的 无损转换 谢谢
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   1185 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 28ms · UTC 18:21 · PVG 02:21 · LAX 11:21 · JFK 14:21
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.