推荐学习书目
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 · Nov 20, 2017 · 3695 views
    This topic created in 3124 days ago, the information mentioned may be changed or developed.

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

    在这里先感谢各位了,

    6 replies    2017-11-21 17:36:02 +08:00
    ynyounuo
        1
    ynyounuo  
       Nov 20, 2017
    tesseract
    bingod
        2
    bingod  
       Nov 20, 2017
    GitHub 搜索 PyPDFOCR
    zhidian
        3
    zhidian  
       Nov 20, 2017   ❤️ 1
    xpdf. 或者... 不需要批量处理? 用 pdf.io 在线处理.
    Forbidden
        5
    Forbidden  
       Nov 21, 2017   ❤️ 1
    gs -sDEVICE=jpeg -sOutputFile=%09d.jpg -r300 -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -dBATCH -dNOPAUSE
    woshichuanqilz
        6
    woshichuanqilz  
    OP
       Nov 21, 2017
    @zhidian 这个工具 ok 的 无损转换 谢谢
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1374 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 35ms · UTC 17:00 · PVG 01:00 · LAX 10:00 · JFK 13:00
    ♥ Do have faith in what you're doing.