Smart-Cam

Smart-Cam

In this repository we extract text from image using tessaract-ocr and pytesseract and translate text into other language using textblob. and make a web app using flask.

How We extract text

  1. convert image to grayscale.
  2. Detect edges of images.
  3. Find contour of image(region were text are present)
  4. Extract text region from image
  5. From extracted region we get image data using pytesseract.

How we translate text

To transalate text we first we use text blob module it’s auto detect input language of text and translate it into desired language in this repo we translate text into three language. English,Hindi,Punjabi

Requirement

Here we use ubuntu 20.04 focal fossa To run this repo on your system you need to download some required module

1. tesseract-ocr

In Ubuntu

sudo apt install tesseract-ocr

In Windows

you need to download treeseract ocr from

https://github.com/UB-Mannheim/tesseract/wiki

And add this line in methods.py

pytesseract.pytesseract.tesseract_cmd = r”C:\Program Files\Tesseract-OCR\tesseract.exe”

  1. pytesseract
  2. opencv
  3. textblob
  4. numpy
  5. flask
  6. wekzeug
  7. urllib
  8. os
  9. time

FLASK WEBPAGE OUTPUT

Screenshot from 2020-12-02 22-22-41

Screenshot from 2020-12-02 22-40-26

Screenshot from 2020-12-02 22-40-49

Screenshot from 2020-12-02 22-46-11

Screenshot from 2020-12-02 22-46-22

Screenshot from 2020-12-02 22-46-55

Visit original content creator repository https://github.com/aqu9/Smart-Cam

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *