Giter Site home page Giter Site logo

smadwer / extract_text_from_img Goto Github PK

View Code? Open in Web Editor NEW

This project forked from adinyk03/extract_text_from_img

0.0 0.0 0.0 3 KB

This Python script reads a PDF, extracts images, and performs OCR to extract text. It analyzes image-containing PDFs using PyPDF2, PIL, and Tesseract for text extraction.

Python 100.00%

extract_text_from_img's Introduction


Extract Text from Image in PDF

This repository contains a Python script that facilitates text extraction from images embedded in a PDF file. The script utilizes libraries such as PyPDF2, PIL (Python Imaging Library), and Tesseract OCR for efficient image processing and text extraction.

Features

  • Extracts text from image-based PDF documents.
  • Utilizes PyPDF2 to read PDF files and identify images within them.
  • Uses PIL to handle image data, converting it to a readable format for Tesseract OCR.
  • Leverages Tesseract OCR to perform Optical Character Recognition on images.

Installation

  1. Clone the repository:

    git clone https://github.com/Adinyk03/extract_text_from_img.git
  2. Install the required Python libraries:

    pip install PyPDF2 pillow pytesseract
  3. Ensure Tesseract OCR is installed on your system. You can download it from: Tesseract OCR

Usage

  1. Place your PDF file containing images in the repository directory.

  2. Modify the pdf_file_path variable in the Python script to match your PDF file's path.

  3. Run the Python script:

    python extract_text_from_pdf.py
  4. The script will process the PDF, extract images, perform OCR, and display the extracted text from each image.

License

This project is licensed under the MIT License. See the LICENSE file for details.


extract_text_from_img's People

Contributors

adinyk03 avatar

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.