I will give some ideas how to process your image, but I will limit that to page 3 of the given document, i.e. the page shown in the question.

For converting the PDF page to some image, I used pdf2image.

For the OCR, I use pytesseract, but instead of lang='hin', I use lang='Devanagari', cf. the Tesseract GitHub. In general, make sure to work through Improving the quality of the output from the Tesseract documentation, especially the page segmentation method.

Here's a (lengthy) description of the whole procedure:

  1. Inverse binarize the image for contour finding: white texts, shapes, etc. on black background.
  2. Find all contours, and filter out the two very large contours, i.e. these are the two tables.
  3. Extract texts outside of the two tables:
    1. Mask out tables in the binarized image.
    2. Do morphological closing to connect remaining lines of text.
    3. Find contours, and bounding rectangles of these lines of text.
    4. Run pytesseract to extract the texts.
  4. Extract texts inside of the two tables:
    1. Extract the cells, better: their bounding rectangles, from the current table.
    2. For the first table:
      1. Run pytesseract to extract the texts as-is.
    3. For the second table:
      1. Floodfill the rectangle around the number to prevent faulty OCR output.
      2. Mask the left (Hindi) and right (English) part.
      3. Run pytesseract using lang='Devaganari' on the left, and using lang='eng' on the right part to improve OCR quality for both.

That'd be the whole code:

import cv2
import numpy as np
import pdf2image
import pytesseract

# Extract page 3 from PDF in proper quality
page_3 = np.array(pdf2image.convert_from_path('BADI KA BANS-Ward No-002.pdf',
                                              first_page=3, last_page=3,
                                              dpi=300, grayscale=True)[0])

# Inverse binarize for contour finding
thr = cv2.threshold(page_3, 128, 255, cv2.THRESH_BINARY_INV)[1]

# Find contours w.r.t. the OpenCV version
cnts = cv2.findContours(thr, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
cnts = cnts[0] if len(cnts) == 2 else cnts[1]

# STEP 1: Extract texts outside of the two tables

# Mask out the two tables
cnts_tables = [cnt for cnt in cnts if cv2.contourArea(cnt) > 10000]
no_tables = cv2.drawContours(thr.copy(), cnts_tables, -1, 0, cv2.FILLED)

# Find bounding rectangles of texts outside of the two tables
no_tables = cv2.morphologyEx(no_tables, cv2.MORPH_CLOSE, np.full((21, 51), 255))
cnts = cv2.findContours(no_tables, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
cnts = cnts[0] if len(cnts) == 2 else cnts[1]
rects = sorted([cv2.boundingRect(cnt) for cnt in cnts], key=lambda r: r[1])

# Extract texts from each bounding rectangle
print('\nExtract texts outside of the two tables\n')
for (x, y, w, h) in rects:
    text = pytesseract.image_to_string(page_3[y:y+h, x:x+w],
                                       config='--psm 6', lang='Devanagari')
    text = text.replace('\n', '').replace('\f', '')
    print('x: {}, y: {}, text: {}'.format(x, y, text))

# STEP 2: Extract texts from inside of the two tables

rects = sorted([cv2.boundingRect(cnt) for cnt in cnts_tables],
               key=lambda r: r[1])

# Iterate each table
for i_r, (x, y, w, h) in enumerate(rects, start=1):

    # Find bounding rectangles of cells inside of the current table
    cnts = cv2.findContours(page_3[y+2:y+h-2, x+2:x+w-2],
                            cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
    cnts = cnts[0] if len(cnts) == 2 else cnts[1]
    inner_rects = sorted([cv2.boundingRect(cnt) for cnt in cnts],
                         key=lambda r: (r[1], r[0]))

    # Extract texts from each cell of the current table
    print('\nExtract texts inside table {}\n'.format(i_r))
    for (xx, yy, ww, hh) in inner_rects:

        # Set current coordinates w.r.t. full image
        xx += x
        yy += y

        # Get current cell
        cell = page_3[yy+2:yy+hh-2, xx+2:xx+ww-2]

        # For table 1, simply extract texts as-is
        if i_r == 1:
            text = pytesseract.image_to_string(cell, config='--psm 6',
                                               lang='Devanagari')
            text = text.replace('\n', '').replace('\f', '')
            print('x: {}, y: {}, text: {}'.format(xx, yy, text))

        # For table 2, extract single elements
        if i_r == 2:

            # Floodfill rectangles around numbers
            ys, xs = np.min(np.argwhere(cell == 0), axis=0)
            temp = cv2.floodFill(cell.copy(), None, (xs, ys), 255)[1]
            mask = cv2.floodFill(thr[yy+2:yy+hh-2, xx+2:xx+ww-2].copy(),
                                 None, (xs, ys), 0)[1]

            # Extract left (Hindi) and right (English) parts
            mask = cv2.morphologyEx(mask, cv2.MORPH_CLOSE,
                                    np.full((2 * hh, 5), 255))
            cnts = cv2.findContours(mask,
                                    cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
            cnts = cnts[0] if len(cnts) == 2 else cnts[1]
            boxes = sorted([cv2.boundingRect(cnt) for cnt in cnts],
                           key=lambda b: b[0])

            # Extract texts from each part of the current cell
            for i_b, (x_b, y_b, w_b, h_b) in enumerate(boxes, start=1):

                # For the left (Hindi) part, extract Hindi texts
                if i_b == 1:

                    text = pytesseract.image_to_string(
                        temp[y_b:y_b+h_b, x_b:x_b+w_b],
                        config='--psm 6',
                        lang='Devanagari')
                    text = text.replace('\f', '')

                # For the left (English) part, extract English texts
                if i_b == 2:

                    text = pytesseract.image_to_string(
                        temp[y_b:y_b+h_b, x_b:x_b+w_b],
                        config='--psm 6',
                        lang='eng')
                    text = text.replace('\f', '')

                print('x: {}, y: {}, text:\n{}'.format(xx, yy, text))

And, here are the first few lines of the output:

Extract texts outside of the two tables

x: 972, y: 93, text: राज्य निर्वाचन आयोग, राजस्थान
x: 971, y: 181, text: पंचायत चुनाव निर्वाचक नामावली, 2021
x: 166, y: 610, text: मिश्र का बाढ़ ,श्रीराम की नॉगल
x: 151, y: 3417, text: आयु 1 जनवरी 2021 के अनुसार
x: 778, y: 3419, text: पृष्ठ संख्या : 3 / 10

Extract texts inside table 1

x: 146, y: 240, text: जिलापरिषद का नाम : जयपुर
x: 1223, y: 240, text: जि° प° सदस्य निर्वाचन क्षेत्र : 21
x: 146, y: 327, text: पंचायत समिति का नाम : सांगानेर
x: 1223, y: 327, text: पं° स° सदस्य निर्वाचन क्षेत्र : 6
x: 146, y: 415, text: ग्रामपंचायत : बडी का बांस
x: 1223, y: 415, text: वार्ड क्रमांक : 2
x: 146, y: 502, text: विधानसभा क्षेत्र की संख्या एवं नाम:- 56-बगरु

Extract texts inside table 2

x: 142, y: 665, text:
1 RBP2469583
नाम: आरती चावला
पिता का नामःलाला राम चावला
मकान संख्याः १९
आयुः 21 लिंगः स्त्री

x: 142, y: 665, text:
Photo is
Available

x: 867, y: 665, text:
2 MRQ3101367
नामः सूरज देवी
पिता का नामःरामावतार
मकान संख्याः डी /18
आयुः 44 लिंगः स्त्री

x: 867, y: 665, text:
Photo is
Available

I checked a few texts using manual character-by-character comparison, and thought it looked quite good, but unable to understand Hindi or reading Devanagari script, I can't comment on the overall quality of the OCR. Please let me know!

Annoyingly, the number 9 from the corresponding "card" is falsely extracted as 2. I assume, that happens due to the different font compared to the rest of the text, and in combination with lang='Devanagari'. Couldn't find a solution for that – without extracting the rectangle separately from the "card".

----------------------------------------
System information
----------------------------------------
Platform:      Windows-10-10.0.19041-SP0
Python:        3.9.1
PyCharm:       2021.1.1
NumPy:         1.19.5
OpenCV:        4.5.2
pdf2image      1.14.0
pytesseract:   5.0.0-alpha.20201127
----------------------------------------
Answer from HansHirse on Stack Overflow
Top answer
1 of 3
19

I will give some ideas how to process your image, but I will limit that to page 3 of the given document, i.e. the page shown in the question.

For converting the PDF page to some image, I used pdf2image.

For the OCR, I use pytesseract, but instead of lang='hin', I use lang='Devanagari', cf. the Tesseract GitHub. In general, make sure to work through Improving the quality of the output from the Tesseract documentation, especially the page segmentation method.

Here's a (lengthy) description of the whole procedure:

  1. Inverse binarize the image for contour finding: white texts, shapes, etc. on black background.
  2. Find all contours, and filter out the two very large contours, i.e. these are the two tables.
  3. Extract texts outside of the two tables:
    1. Mask out tables in the binarized image.
    2. Do morphological closing to connect remaining lines of text.
    3. Find contours, and bounding rectangles of these lines of text.
    4. Run pytesseract to extract the texts.
  4. Extract texts inside of the two tables:
    1. Extract the cells, better: their bounding rectangles, from the current table.
    2. For the first table:
      1. Run pytesseract to extract the texts as-is.
    3. For the second table:
      1. Floodfill the rectangle around the number to prevent faulty OCR output.
      2. Mask the left (Hindi) and right (English) part.
      3. Run pytesseract using lang='Devaganari' on the left, and using lang='eng' on the right part to improve OCR quality for both.

That'd be the whole code:

import cv2
import numpy as np
import pdf2image
import pytesseract

# Extract page 3 from PDF in proper quality
page_3 = np.array(pdf2image.convert_from_path('BADI KA BANS-Ward No-002.pdf',
                                              first_page=3, last_page=3,
                                              dpi=300, grayscale=True)[0])

# Inverse binarize for contour finding
thr = cv2.threshold(page_3, 128, 255, cv2.THRESH_BINARY_INV)[1]

# Find contours w.r.t. the OpenCV version
cnts = cv2.findContours(thr, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
cnts = cnts[0] if len(cnts) == 2 else cnts[1]

# STEP 1: Extract texts outside of the two tables

# Mask out the two tables
cnts_tables = [cnt for cnt in cnts if cv2.contourArea(cnt) > 10000]
no_tables = cv2.drawContours(thr.copy(), cnts_tables, -1, 0, cv2.FILLED)

# Find bounding rectangles of texts outside of the two tables
no_tables = cv2.morphologyEx(no_tables, cv2.MORPH_CLOSE, np.full((21, 51), 255))
cnts = cv2.findContours(no_tables, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
cnts = cnts[0] if len(cnts) == 2 else cnts[1]
rects = sorted([cv2.boundingRect(cnt) for cnt in cnts], key=lambda r: r[1])

# Extract texts from each bounding rectangle
print('\nExtract texts outside of the two tables\n')
for (x, y, w, h) in rects:
    text = pytesseract.image_to_string(page_3[y:y+h, x:x+w],
                                       config='--psm 6', lang='Devanagari')
    text = text.replace('\n', '').replace('\f', '')
    print('x: {}, y: {}, text: {}'.format(x, y, text))

# STEP 2: Extract texts from inside of the two tables

rects = sorted([cv2.boundingRect(cnt) for cnt in cnts_tables],
               key=lambda r: r[1])

# Iterate each table
for i_r, (x, y, w, h) in enumerate(rects, start=1):

    # Find bounding rectangles of cells inside of the current table
    cnts = cv2.findContours(page_3[y+2:y+h-2, x+2:x+w-2],
                            cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
    cnts = cnts[0] if len(cnts) == 2 else cnts[1]
    inner_rects = sorted([cv2.boundingRect(cnt) for cnt in cnts],
                         key=lambda r: (r[1], r[0]))

    # Extract texts from each cell of the current table
    print('\nExtract texts inside table {}\n'.format(i_r))
    for (xx, yy, ww, hh) in inner_rects:

        # Set current coordinates w.r.t. full image
        xx += x
        yy += y

        # Get current cell
        cell = page_3[yy+2:yy+hh-2, xx+2:xx+ww-2]

        # For table 1, simply extract texts as-is
        if i_r == 1:
            text = pytesseract.image_to_string(cell, config='--psm 6',
                                               lang='Devanagari')
            text = text.replace('\n', '').replace('\f', '')
            print('x: {}, y: {}, text: {}'.format(xx, yy, text))

        # For table 2, extract single elements
        if i_r == 2:

            # Floodfill rectangles around numbers
            ys, xs = np.min(np.argwhere(cell == 0), axis=0)
            temp = cv2.floodFill(cell.copy(), None, (xs, ys), 255)[1]
            mask = cv2.floodFill(thr[yy+2:yy+hh-2, xx+2:xx+ww-2].copy(),
                                 None, (xs, ys), 0)[1]

            # Extract left (Hindi) and right (English) parts
            mask = cv2.morphologyEx(mask, cv2.MORPH_CLOSE,
                                    np.full((2 * hh, 5), 255))
            cnts = cv2.findContours(mask,
                                    cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
            cnts = cnts[0] if len(cnts) == 2 else cnts[1]
            boxes = sorted([cv2.boundingRect(cnt) for cnt in cnts],
                           key=lambda b: b[0])

            # Extract texts from each part of the current cell
            for i_b, (x_b, y_b, w_b, h_b) in enumerate(boxes, start=1):

                # For the left (Hindi) part, extract Hindi texts
                if i_b == 1:

                    text = pytesseract.image_to_string(
                        temp[y_b:y_b+h_b, x_b:x_b+w_b],
                        config='--psm 6',
                        lang='Devanagari')
                    text = text.replace('\f', '')

                # For the left (English) part, extract English texts
                if i_b == 2:

                    text = pytesseract.image_to_string(
                        temp[y_b:y_b+h_b, x_b:x_b+w_b],
                        config='--psm 6',
                        lang='eng')
                    text = text.replace('\f', '')

                print('x: {}, y: {}, text:\n{}'.format(xx, yy, text))

And, here are the first few lines of the output:

Extract texts outside of the two tables

x: 972, y: 93, text: राज्य निर्वाचन आयोग, राजस्थान
x: 971, y: 181, text: पंचायत चुनाव निर्वाचक नामावली, 2021
x: 166, y: 610, text: मिश्र का बाढ़ ,श्रीराम की नॉगल
x: 151, y: 3417, text: आयु 1 जनवरी 2021 के अनुसार
x: 778, y: 3419, text: पृष्ठ संख्या : 3 / 10

Extract texts inside table 1

x: 146, y: 240, text: जिलापरिषद का नाम : जयपुर
x: 1223, y: 240, text: जि° प° सदस्य निर्वाचन क्षेत्र : 21
x: 146, y: 327, text: पंचायत समिति का नाम : सांगानेर
x: 1223, y: 327, text: पं° स° सदस्य निर्वाचन क्षेत्र : 6
x: 146, y: 415, text: ग्रामपंचायत : बडी का बांस
x: 1223, y: 415, text: वार्ड क्रमांक : 2
x: 146, y: 502, text: विधानसभा क्षेत्र की संख्या एवं नाम:- 56-बगरु

Extract texts inside table 2

x: 142, y: 665, text:
1 RBP2469583
नाम: आरती चावला
पिता का नामःलाला राम चावला
मकान संख्याः १९
आयुः 21 लिंगः स्त्री

x: 142, y: 665, text:
Photo is
Available

x: 867, y: 665, text:
2 MRQ3101367
नामः सूरज देवी
पिता का नामःरामावतार
मकान संख्याः डी /18
आयुः 44 लिंगः स्त्री

x: 867, y: 665, text:
Photo is
Available

I checked a few texts using manual character-by-character comparison, and thought it looked quite good, but unable to understand Hindi or reading Devanagari script, I can't comment on the overall quality of the OCR. Please let me know!

Annoyingly, the number 9 from the corresponding "card" is falsely extracted as 2. I assume, that happens due to the different font compared to the rest of the text, and in combination with lang='Devanagari'. Couldn't find a solution for that – without extracting the rectangle separately from the "card".

----------------------------------------
System information
----------------------------------------
Platform:      Windows-10-10.0.19041-SP0
Python:        3.9.1
PyCharm:       2021.1.1
NumPy:         1.19.5
OpenCV:        4.5.2
pdf2image      1.14.0
pytesseract:   5.0.0-alpha.20201127
----------------------------------------
2 of 3
6

If you want to get texts from these 'cards' I've managed to do it for page 3 via module tabula-py this way:

import tabula

pdf_file = "BADI KA BANS-Ward No-002.pdf"
page = 3

x = 30      # left edge of the table
y = 160     # top edge of the table
w = 173     # width of a card
h = 73      # height of a card
photo = 61  # width of a photo

rows = 8    # number of rows of the table
cols = 3    # number of columns of the table

counter = 1

def get_area(row, col):
    ''' return area of the card in given position in the table '''
    top    = y + h * row
    left   = x + w * col
    bottom = top + h
    right  = left + w - photo
    return (top, left, bottom, right)

for row in range(rows):
    for col in range(cols):
        file_name = "card_" + str(counter).zfill(3) + ".txt"
        tabula.convert_into(pdf_file, file_name,
        pages=page,
        output_format = "csv",
        java_options = "-Dfile.encoding=UTF8",
        lattice = False,
        area = get_area(row, col))
        counter += 1

Input:

Output

24 txt files:

card_001.txt
card_002.txt
card_003.txt
card_004.txt
.
.
.
card_023.txt
card_024.txt

card_001.txt:

1 RBP2469583
नरम: आरतल चररलर
नपतर कर नरम:लरलर ररम चररल
मकरन सखजर: १९
आज:  21 ललग: सल

card_002.txt

2 MRQ3101367
नरम: सरज दरल
नपतर कर नरम:ररमररतरर
मकरन सखजर: रल /18
आज:  44 ललग: सल

card_024.txt

24 RBP0230979
नरम: सनमतकरर
पनत कर नरम: हररलसह
मकरन सखजर: 13
आज:  41 ललग: सल

As far as I can see all the 'cards' have the same dimensions. The solution could be applied for all pages if they look alike. Unfortunately the pages have differences. So initial variables must be changed for every page. I see no way to make the changes automatically. Except the numbers of the cards can be taken from the card instead of the simply counter.

https://pypi.org/project/tabula-py/

https://aegis4048.github.io/parse-pdf-files-while-retaining-structure-with-tabula-py

🌐
YouTube
youtube.com › bhavesh bhatt
OCR Hindi Text recognition with EasyOCR & Python - YouTube
In this video, I'll show you how you can extract Hindi text from images using EasyOCR which is a Ready-to-use OCR library with 40+ languages supported includ...
Published   August 1, 2020
Views   800
Discussions

Extract hindi text and save it into database
Step-1 would be the pictures of pages. Step-2 computer vision libraries (python). Use a Jupyter notebook to read the pages. upload pages pics to aws or google collab. Lot of 3rd party Computer vision libraries which would extract the text and convert it into Hindi text. Step-3 now you have the text. Python has libraries to handle most languages. I would be surprised if Hindi isn’t there. Step-4 in the same Jupiter notebook use cloud databases to store the text. Use json datatype. It will convert the text with some encoding and then it will be stored in database. Similar process while retrieving PS- I have never done it but a man can try based on his experience More on reddit.com
🌐 r/developersIndia
11
5
May 11, 2023
The fact that Chat GPT 4 can just straioght up read text off of images is blowing my mind.
Text recognition is probably the least impressive thing about GPT-4V More on reddit.com
🌐 r/OpenAI
111
228
October 15, 2023
Extracting text from PDF files without the OCR errors
If your pdf is not a scanned one, why are you trying with tesseract or anyother ocr tools. Just use the pdftotext package from xpdftools. Or you can try with apache tika too. More on reddit.com
🌐 r/LanguageTechnology
8
4
September 19, 2018
[D] Using a CNN to extract text from a pdf file.
If PDF -> latex source is possible with a CNN, PDF -> raw text seems like it should be doable. More on reddit.com
🌐 r/MachineLearning
15
19
November 28, 2016
People also ask

How do I extract Hindi text from an image?
Upload the image, choose Hindi as the language, then click 'Start OCR'. The tool recognizes the Devanagari text and returns it in editable form.
🌐
i2ocr.com
i2ocr.com › home › free online hindi ocr
Free Hindi Image OCR Tool – Extract Hindi Text from Images
How accurate is Hindi Image OCR for Devanagari?
It performs best on clear printed Hindi with good contrast. Blurry photos, low resolution, or stylized fonts can lower recognition quality.
🌐
i2ocr.com
i2ocr.com › home › free online hindi ocr
Free Hindi Image OCR Tool – Extract Hindi Text from Images
Is Hindi Image OCR free?
Yes. You can run OCR for one image at a time without registration.
🌐
i2ocr.com
i2ocr.com › home › free online hindi ocr
Free Hindi Image OCR Tool – Extract Hindi Text from Images
🌐
Dwayo
blog.dwayo.com › setting-up-hindi-ocr-using-pytesseract-a-step-by-step-guide
Setting Up Hindi OCR Using Pytesseract – Dwayo DevBlog
July 12, 2022 - import pytesseract from PIL import ... is installed on your system. Run Your Script: Execute your Python script, and Pytesseract will use Tesseract with Hindi language support to perform OCR on the specified image....
🌐
Medium
medium.com › @akshit_29 › optical-character-recognition-ocr-for-the-hindi-language-single-multiple-files-8f60ca2bfc06
Optical Character Recognition (OCR) for the Hindi Language (Single/Multiple files) | by Akshit Gupta | Medium
October 13, 2020 - Now, one of the major features missing from the online(free) OCR tools is that they do not support multiple files upload. Imagine doing manual uploading of 100s of images, extracting the text, and then copy it to a text file. 😣🤯 · Today we will be looking into Python implementation for two applications of OCR: OCR for the Hindi language implemented in Python using tesseract.
🌐
India Typing
indiatyping.com › index.php › optical-character-recognition
Hindi OCR | Image to Text Extractor | Copy Hindi Text from Image
The HIndi OCR tool can extract Hindi text from images as well as PDF files, so you can copy the text of the file and re-use it anywhere. This free online tool uses Devanagari OCR to extract text from an image or PDF file.
🌐
i2OCR
i2ocr.com › home › free online hindi ocr
Free Hindi Image OCR Tool – Extract Hindi Text from Images
Hindi Image OCR is a free online OCR service that reads Hindi (Devanagari) text from images such as JPG, PNG, TIFF, BMP, GIF, and WEBP. It supports Hindi extraction with single-image processing per run and offers optional bulk OCR for larger workloads.
Find elsewhere
🌐
Reddit
reddit.com › r/developersindia › extract hindi text and save it into database
r/developersIndia on Reddit: Extract hindi text and save it into database
May 11, 2023 -

Hey fellow Redditors, I hope you're all doing well. I have a project at hand and could really use some advice and insights from the community. I have a collection of Hindi documents that I need to digitize. My goal is to extract the Hindi text from these documents, which also include tables, and store them in a database for easier access, searchability, and analysis. I'm specifically looking for recommendations on the most suitable database and technology stack to handle the extraction and storage of Hindi text and tables effectively. It's important for the chosen technology to support Unicode encoding and be capable of handling the complexities of the Hindi language. Additionally, I'm curious to know if anyone here has tackled a similar project involving Hindi document digitization, text extraction, and database storage. If you have experience or insights to share, I would greatly appreciate hearing about your approach and any lessons learned. I'm open to any suggestions, whether it's specific technologies, best practices, or even potential collaboration opportunities with individuals or teams who have expertise in this area. Thank you in advance for your valuable input and assistance. I'm eager to hear your thoughts and learn from your experiences.

🌐
YouTube
youtube.com › watch
Best way to extract or convert Hindi text from Image (OCR HINDI) IMAGE TO TEXT - YouTube
Try Tenorshare PDNob Image to Text Converter: https://bit.ly/3FvVzu7, the best way to extract or convert Hindi text from Image.► Corel Draw & Adobe Photoshop...
Published   November 8, 2020
🌐
Project Gurukul
projectgurukul.org › home › python project – text detection and extraction with opencv and ocr
Python Project - Text Detection and Extraction with OpenCV and OCR - Project Gurukul
June 15, 2021 - In this python project, we’re going to make a text detector and extractor from an image using opencv and ocr. We’ll use the Tesseract engine to perform the character recognition system and the pytesseract python package to interact with Tesseract in python. OCR or Optical Character Recognition is a system that can detect characters or text from a 2d image. The image could contain machine-printed or handwritten text. OCR can detect several languages, for example, English, Hindi, German, etc.
🌐
Medium
medium.com › @tejpal.abhyuday › information-extraction-part-5-optical-character-recognition-with-easyocr-and-pytesseract-9dbbcaf7824b
Information Extraction — Part 5 ( Optical Character Recognition with EasyOCR and Pytesseract | by Tejpal Kumawat | Medium
March 4, 2023 - For using Jupyter Notebook a virtual environment must be created with the dependencies installed using requirements.txt from this GitHub repository. ... # import library import easyocr #specify shortform of language you want to extract, # I am using Hindi(hi) and English(en) here by list of language ids reader = easyocr.Reader(['en']) # If any image contain text in different languages we can add it in the form of # ['en','fr','hn, etc ....]
🌐
GitHub
github.com › shubhamranswal › EngHiOCR
GitHub - shubhamranswal/EngHiOCR: This tool allows you to perform Optical Character Recognition (OCR) on images containing English and Hindi text, and search for specific keywords. · GitHub
Upload an Image: Allows you to upload image files (JPG, JPEG, PNG). Extract Text: Uses OCR to extract text in Hindi and English from the uploaded image.
Author   shubhamranswal
🌐
GitHub
github.com › Priyansu-Bhandari › EasyOCR_Project
GitHub - Priyansu-Bhandari/EasyOCR_Project: Text extraction from images uses the EasyOCR library to extract text from images containing English and Hindi characters. · GitHub
Clone the repository: git clone ... -r requirements.txt · Usage: Upload Image: Select an image file (in JPG, PNG, or TIFF format) containing English or Hindi text that you want to extract....
Starred by 17 users
Forked by 3 users
Languages   Jupyter Notebook
🌐
Kaggle
kaggle.com › code › rhythmcam › pytesseract-ocr-extract-text-from-image
[pytesseract OCR]extract text from image
Checking your browser before accessing www.kaggle.com · Click here if you are not automatically redirected after 5 seconds
🌐
Typeinhindi
typeinhindi.com › online-hindi-ocr
Hindi OCR - Extract Hindi Text from Images | Free Online
Extract Hindi text from images instantly. Upload any image with Devanagari script and get accurate text recognition. Free online OCR tool supporting JPG, PNG, PDF formats.
🌐
Type Hindi Bhasha
typehindibhasha.com › hindi image to text converter
Hindi Image To Text Converter (Online & Free)
Easily extract Hindi text from any image. This free online tool is very useful for extracting Hindi text from scanned pages and documents.
🌐
GitHub
github.com › manavrawat10 › OCR--ImageToLanguage
GitHub - manavrawat10/OCR--ImageToLanguage: Image to Any foreign language Text using python · GitHub
Additionally, if used as a script, Python-tesseract will print the recognized text instead of writing it to a file. ... Declaring object class for Translator. ... Calling a PIL function "image_to_string" that will convert text from image.
Author   manavrawat10
🌐
HindiTyping.info
hindityping.info › image-to-text › hindi-ocr
Online Hindi OCR | Hindi Image to Text Converter
Here you can upload Image file containing Hindi Characters by pressing "Choose file" Button then press the "Convert to Text" button. Our software will process depending on the characters in the uploaded image file and you can get the text in output box. from where you can copy or print it.
🌐
FastOCR
fastocr.org › home › hindi ocr
Hindi OCR Online — Extract Hindi Text from Images & PDFs Free | FastOCR
3 days ago - Free Hindi OCR tool to extract हिन्दी text from images and PDFs. Handles Devanagari script, conjuncts, and matras. AI-powered with 95% accuracy on Hindi.
🌐
Hindityping
hindityping.co.in › hindi-ocr
Hindi OCR Online - Extract Text from Hindi Images Instantly
Convert Hindi images to editable text effortlessly with our online OCR tool. Extract and use Hindi text from images for translation, content creation, and more. i2ocr Hindi!
🌐
Mathpix
mathpix.com › blog › hindi-ocr
The best OCR for Hindi images and PDFs with math and science
Easily convert printed and handwritten images with Hindi characters using our simple OCR-powered tool. Just take a screenshot of an image and instantly get your editable result. You can also upload PDFs with Hindi and convert them to Word, LaTeX, ...