Giter VIP home page Giter VIP logo

pdftotxt's Introduction

PDF to TXT

Python code to do OCR recognition of a PDF file and export text to TXT file.

Setup for LocalOCR on Ubuntu

apt-get install python-pyocr python-wand imagemagick
apt-get install libleptonica-dev tesseract-ocr-dev
apt-get install tesseract-ocr-ita
pip install -r requirements.txt

Setup CloudOCR on Ubuntu

Install Google Cloud SDK

apt-get install pdfimages google-cloud-sdk-app-engine-python
pip install requirements.txt

pdftotxt's People

Contributors

lucab85 avatar takotab avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

pdftotxt's Issues

ImportError: MagickWand shared library not found.

Traceback (most recent call last):

  File "/Users/pidugu/Documents/OPENCV/PDFtoTXT-master/CloudOCR.py", line 4, in <module>
    from wand.image import Image
  File "/usr/local/lib/python2.7/site-packages/wand/image.py", line 20, in <module>
    from .api import MagickPixelPacket, libc, libmagick, library
  File "/usr/local/lib/python2.7/site-packages/wand/api.py", line 210, in <module>
    'Try to install:\n  ' + msg)

ImportError: MagickWand shared library not found.
You probably had not installed ImageMagick library.
Try to install:
brew install freetype imagemagick

Even tried installing imagemagick and it always promps me that its already installed and up to date

$ brew install freetype imagemagick
Updating Homebrew...
Warning: freetype 2.9.1 is already installed and up-to-date
To reinstall 2.9.1, run `brew reinstall freetype`
Warning: imagemagick 7.0.8-14 is already installed and up-to-date
To reinstall 7.0.8-14, run `brew reinstall imagemagick`

ignore white space

Can you please guide how to tackle this issue ==>white spaces are ignored

how does this work...

This is one of the more popular gits for turning .pdf to .txt. But, after installing everything how does it work? It would help to explain how you direct this .py program to the pdf and similalrly to the output txt file. Thanks

Reading scanned PDF

Hi ,

Does the code help us read scanned documents like invoices , or just editable texts ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.