You are on page 1of 39

CSE4019 – IMAGE PROCESSING

Summer Semester 2022-23

Project Report

TEXT TO BRAILLE CONVERSION

Under the guidance of


Prof. DIVYA LAKSHMI K-
SCOPE VIT, VELLORE

TEAM MEMBERS
19BCE2659: RAVI KASAUDHAN
19BCE2664: AAYUSH PARAJULI

19BCE2629: ABHISHEK KANDEL

19BCE2646: MANOHAR KUMAR SINGH


Table of Contents
I. ABSTRACT
......................................................................................................................................... 3
II. INTRODUCTION ...........................................................................................................................
4
III. LITERATURE SURVEY ...............................................................................................................
6 IV. PROBLEM STATEMENT
.......................................................................................................... 12
V. PROPOSED RESEARCH FRAMEWORK ...................................................................................
12 a. RESEARCH ARCHITECTURE:
................................................................................................... 12
b. MATHEMATICAL REPRESENTATION MODULES:
............................................................... 13
VI. MODULES DESCRIPTION: ...................................................................................................... 16
a. IMAGE TO TEXT MODULE ........................................................................................................
16
b. TEXT TO BRAILLE CONVERSION MODULE
......................................................................... 18
VII. IMPLEMENTATION .................................................................................................................. 20
VIII. RESULT (SCREENSHOTS) ................................................................................................... 35
IX. CONCLUSION
............................................................................................................................. 37
X. REFERENCES .................................................................................................................................. 37
I. ABSTRACT

The project's objective is to create a system that uses image processing


techniques to transform the English language (picture) into its matching
Braille representation, providing a single means of communication for
visually impaired individuals. A mapping table may be used to create a
Braille cell for text, which shows a Binary equivalent dot pattern for the
corresponding English text. Test documents are used as input, and the
program reads them letter by letter and maps them to the appropriate
Braille code. The development of a resulting Braille sheet will aid in
hardware implementation for real-time application of immediate
translation of scanned English text to Braille in the future.

Keywords: Braille, Visually Impaired, Image Processing, Noise, Image


Enhancement, Database Generation, Tesseract, Segmentation.
II. INTRODUCTION

Louis Braille's embossed writing method rapidly gained acceptance


across the world as the primary form of written communication for blind
people. Accessing data from documents is quite challenging for visually
impaired persons. Thus, in 1824, the Braille system was devised to
overcome the communication gap between the blind and the rest of the
world. Braille is a writing method that employs raised dot patterns to
inscribe characters on paper. As a result, visually challenged persons may
read and write without using their eyes. It is a means for blind individuals
to engage in literate society. Braille is a code, not a language, and these
Braille codes can be used in any language to represent Braille characters.
Significant advancements in the production of Braille and Braille media
as a useful tool for the blind and visually impaired have occurred since
the invention of Braille in 1829.
For visually impaired people, accessing text documents can be difficult in
a variety of situations, including understanding text on the go and
retrieving text in less-than-ideal circumstances. Text to speech converters
and screen readers are just a few of the devices that can help them access
the text. By using them visually impaired people only listen to the screen
reader, but they will not be able to know the correct grammar, spellings
of certain words which are not common example few medical terms, this
can be avoided by using screen reader for character by character but its
time consuming and also these screen readers use computer sounding
voice which may be inconvenient. Hence to overcome these drawbacks
braille display can be used. It, therefore, permits visually impaired people
to read and write using their sense of touch rather than vision. Writing and
reading Braille language is a form of literacy. Literacy is an important part
of modern knowledge and society, and the braille code allows visually
impaired people to read and write. The use of audio-only technology
deprives braille users of electricity.
Reading and writing Braille code is a form of literacy; literacy is an
important part of modern knowledge and society, and the braille code
allows blind people to read and write. The use of audio-only technology
deprives braille users of electricity.
The following are some of the benefits of using braille over other
technologies:
• Braille code is a silent alternative to braille that may not be usable in
older situations. Speech synthesizers and interpreters obstruct complete
privacy and have an impact on the surrounding environment. They
should not be worn in a professional setting, such as an office.
• Braille code is a quiet alternative to braille that may not be suitable for
older people. Speech synthesizers and interpreters intrude on one's
privacy and have a negative influence on the surroundings. In a
professional context, such as an office, they should not be worn.
• The Braille code allows the reader, not another person, to interpret the
text. Any reader who wants to interpret the text for themselves. –a
performer or a pleasure reader. It is possible that one would prefer to
form their own interpretation of text rather than being forced into that
of a disinterested computer program or a specific actor. It is possible
that there will be inaccuracies in the interpretation.
• Computer technology is more expensive than braille coding. This is a
simplified version of the situation. The technology for printing and
reproducing braille is costly, and the volume required to generate a text
and braille computer transliteration is large.
Braille symbols are created within Braille cells, which are predetermined
spaces. Each Braille cell is made up of six dots arranged in a 3 x 2 matrix.
It is made up of a system of six or eight different dot combinations
organized in a set matrix called a cell. Every dot in the six-dot and eightdot
Braille systems may be set or cleared, resulting in 64 potential
combinations in six-dot and 256 combinations in eight-dot Braille.
Despite the fact that the thickness of Braille sheets is regulated, it varies
from location to location. A Braille page is 11 inches by 11.5 inches in
size, with a maximum of 40 to 43 Braille cells per line. A typical 25 x 29
cm page can have 32 characters per line and 27 lines each page. A typical
dot is 1.8 mm in diameter. The primary motivation for creating a
technology that translates text to Braille is to conserve and multiply vast
quantities of hand-made books.

III. LITERATURE SURVEY

S.No Title of the Year Journal name Methodology Performanc Data set / Evaluation
resource / Conference (Key algorithms / e metrics Data used in observations/
(journal title/ approach) the resource
paper/conference Website link Comments
paper/ title of the
web page)
1 Development of 2021 International The paper System has There are 64 This
a Text to Braille Journal for represents performed possible application
Interpreter Research in complete extraction of combination converts an
through Optical Engineering methodology on text from an s as there are image
Image Processing Application how scanned input image no dots for document to
& images and how it and then word space. Braille
Management is translated into passing the Braille is a format and
(IJREAM) braille format. The text for series of thus this
scanned images conversion characters or application
are pre-processed into Braille "cells" can help a lot
and converted to Language. consisting of of visually
grayscale and then This process six extended impaired
passed through an benefits to point people. This
adaptive threshold schools, patterns and System will
function for parents or arranged in be an Open
conversion to anyone who a rectangle Source. So
binary image. can help with two that anyone
Translation to blind columns of can have
Braille includes people. three points. access to it as
conversion of there will be
numbers, no need of
alphabets, subscriptions
symbols and
compound letters, or purchase
translated text can required.
then be saved for
printing.
2 IEEE The camera will Percentage There were Despite the
DEVELOPMEN 2018 capture an image, accuracy 180 tests existence of
T OF A TEXT in tiff format, and Average gathered in different
TO BRAILLE which will be accuracy this study, laws,
INTERPRETER analyzed through was used as 30 tests each organizations
FOR PRINTED an optical image performanc for the fonts , and
DOCUMENTS processing e metrics. Times New movements
THROUGH integrated in a Roman, to help the
OPTICAL GUI. After Arial, and visually-
IMAGE analysis, a Futura for impaired
PROCESSING universal word-per- people to
asynchronous word mode cope up with
receiver/transmitte and this time and
r (UART) device continuous age, there is
will interface the mode. still a
communication Checking hindrance for
between the was done visually-
computer and the manually by impaired
microcontroller. letting the people to
The respondents have a fully
microcontroller spell out accessible
then sends the what they education
data to the read. due to
refreshable braille limitations of
cells. resources.
3 Text Translation Indian The translation of The A separate This paper
of Scanned Hindi 2017 Journal of scanned Hindi text performanc database of successfully
Document to Science and into Braille code e metrics Hindi presented the
Braille via Image Technology involves the were consonants conversion of
Processing following four analyzed on and matras scanned
processes: (i) the basis of is generated. Hindi text
Hindi database accuracy of A scanned into the
generation of image correspondin
letter
consonants and containing g Braille
matching
matras using all the Hindi using PCA
image with hindi alphabets and image
segmentation. database along with segmentation
(ii) Segmentation and hindi to matras is technique.
of test images into braille segmented The first part
lines followed by conversion. to obtain of the paper
words and finally individual is a
into letters. letters. generation of
(iii) Letter These Hindi
matching of individual database
segmented letters Hindi letters where the
with the generated of size 187 x size of every
Hindi database 128 are image is
using Principal stored in 187x128
Component MATLAB pixels which
Analysis (PCA). to generate a require very
(iv) Conversion of Hindi less memory
matched letter into database. of the
corresponding system.
Braille code.
4 CONVERSION IEEE This paper The model Custom The Support
OF HINDI 2020 explores the was run for dataset of Vector
BRAILLE TO conversion of several 34800 machine
SPEECH USING Devanagari Hindi times to find images was (SVM)
IMAGE AND Braille, first to that it would created by created had
SPEECH text, and be suitable taking the highest
PROCESSING subsequently to at 15 pictures of accuracy.
speech. The epochs.The braille texts
authors achieved loss and from a book
an accuracy of accuracy for using a
100 percent using random and phone
the conventional stratified camera.The
method. Also splits were dataset
validated the measured consists of
quality of Hindi and a macro 600 images
speech generated average for each of
from the text-to- performance the 58
speech model. metrics braille
table was characters.
used for
both the
splits.
Finally the
percentage
of accuracy
was checked
for all the
SVM
approach,
Alex
net(random
split and
stratified
split)
V. PROPOSED RESEARCH FRAMEWORK
a. RESEARCH ARCHITECTURE:

Our project is principally divided into two sections. the primary section is
especially concerned with preprocessing of a picture and image to string
conversion. The second section deals with translating the resultant output
text from image to Grade 2 braille. The important thing that ought to be
taken into consideration is to get a picture suitable for extraction of strings
from them. For this we have applied many pre-processing image
techniques which are rescaling the input image, converting the image into
grayscale, eliminating any shadows that are present on the image. For the
noise removal dilation and erosion is implemented. Finally, image
thresholding is executed to maintain the intensity of black and white
pixels. This follows to section two where nation characters are recognized
and mapped to the corresponding braille characters using tesseract.
Fig: Research Architecture

b. MATHEMATICAL REPRESENTATION MODULES:


In our project we've used the subsequent image processing techniques to
convert the given image (input) to text (output):
1. Uniform Scaling
The model of a picture as a set of vectors is particularly nice for
representing operations in image space. Let M be a group of vectors and
colours representing an image. To enlarge or shrink a picture (known as
uniform scaling), one simply has to multiply each vector in M by a
multiple of the scalar matrix.

2. Binarization
In our project we've used Otsu’s algorithm for binarization. Otsu’s
thresholding method corresponds to the linear discriminant criteria that
assumes that the image consists of only object (foreground) and
background, and therefore the heterogeneity and variety of the
background is ignored. Otsu set the brink so on attempt to minimize the
overlapping of the category distributions. This method gives a threshold
for the entire image considering the varied characteristics of the full image
(like lighting conditions, contrast, sharpness etc.) and that threshold is
employed for Binarizing image.

3. Noise Removal
a. Erosion
Erosion is one amongst two fundamental operations in morphological
image processing from which all other morphological operations are
based. The erosion operation usually uses a structuring element for
probing and reducing the shapes contained in the input image.
For sets A and B in Z2, erosion is denoted by:

b. Dilation

Dilation is another basic operation in mathematical morphology. The


dilation operation usually uses a structuring element for probing and
expanding the shapes contained within the input image.
For sets A and B in Z2, dilation is denoted by:

4. Smoothing (Gaussian Blur)

The Gaussian smoothing operator may be a 2-D convolution operator


that's wont to ‘blur’ images and take away detail and noise. This works
similarly to averaging, but it uses a Gaussian kernel, rather than a
normalized box filter, for convolution. Here, the scale of the kernel and
standard deviations in both directions may be determined
independently. Gaussian blurring is extremely useful for removing
gaussian noise from the image.
VI. MODULES DESCRIPTION:

a. IMAGE TO TEXT MODULE

This module covers two parts:


a) Pre-processing of an image
Image pre-processing is an important step since it's going to have
dramatic positive effects on the standard of feature extraction and also
the results of image analysis. Pre-processing is employed to improve
image data by suppressing undesired distortions or enhancing certain
visual qualities that are relevant for later processing. First, we've got
re-scaled the input image. Second the input image is converted into a
grayscale image. Reducing the image to grayscale makes computations
much easier and eliminates redundancy. Binary images also are
fantastic, but they sacrifice too much information to be helpful in many
situations. When there are noise elements in an image, you will need
additional information to tell apart text from noise, which is where
grayscale comes in handy. Furthermore, the sides and textures are the
foremost commonly used and dependable information for stylish
image processing. Both of those things can be derived from a grayscale
image. The third step applied is removing the shadows on the image
which could cause disturbances for extraction of text. For removing
any noises dilation and erosion techniques are implemented. Dilation
and erosion are the foremost fundamental morphological operations.
Dilation increases the quantity of pixels on the edges of objects in a
picture, whereas erosion reduces the number of pixels on the
perimeters of objects. The proportions and shape of the structuring
division determines the number of pixels added or off from the objects
within the image. The state of any given pixel within the output image
is defined by applying a rule to the relevant pixel and its neighbors
within the input image within the morphological dilation and erosion
operations. Lastly image thresholding is applied which is a simple, yet
effective, way of partitioning an image into a foreground and
background. This image analysis technique could be a sort of image
segmentation that isolates objects by changing grayscale pictures into
binary pictures. Image thresholding is best in images with high levels
of contrast.

b) Image to string conversion


The tesseract Python package is used to extract the text information
from the image. Tesseract is a text recognition (OCR) engine that is
free to use. Tesseract can be used with a wide variety of programming
languages and frameworks. In our case we have used it with Jupyter. It
can be used in conjunction with the existing layout analysis to
recognize text inside a huge document, or with an external text detector
to recognize text from a single text line image.
Fig: Working of Tesseract

b. TEXT TO BRAILLE CONVERSION MODULE

This module covers two parts:


a) Mapping the image text
For mapping the derived image text, we have created dictionaries in
python to store different kinds of text patterns.
▪ Firstly, for collection of the normal alphabets we have created a
dictionary named letters.
▪ Secondly, for collection of some commonly used words such as
and, the, but, for, etc. we have created a dictionary named
contractions which includes all the common words.
▪ Thirdly, for collection of punctuations we have created a
dictionary named punctuation.
▪ Finally, for collection of numbers we have created a dictionary
named numbers.
The letters, words, punctuations, and numbers extracted from the
image are mapped into these dictionaries and the corresponding match
is printed.
b) Converting the given text to braille:
For converting the retrieved text to braille, we follow the steps
described below: ▪ Splitting the words:
The words of the text are splitted and divided based on whitespace
characters (‘ ’, newlines).
▪ Handling numbers:
First and foremost, the numbers are handled. Numbers in braille use
the same symbols as the first 10 letters of the alphabet. To differentiate
between numbers and letters, an escape code (⠼) is placed before
groups of numbers. In this process, the numbers are dealt with, so there
will be a mix of both braille and alphabet symbols. For example: 1-K
becomes: ⠼⠁- ⠋.

▪ Handling capitals:

Similar to numbers in braille, capital letters also need an escape code


(⠠). Each capital letter has an escape code appended to the beginning
of it, and the letter is then transformed to lowercase. For example:
HELLO becomes: .h.e.l.l.o

▪ Trimming the word

The words extracted might contain punctuation such as commas or


brackets. So, the words need to be trimmed such that they can be
converted to contractions. For example: The word ‘the’ is represented
by a single braille (⠮) instead of representing‘t’,’h’,’e’.

▪ Putting the translation together:


To create the translation, we must first complete the following steps:
i. Check to see whether the trimmed word can be made shorter.
ii. Complete the remaining alphabetic characters by translating them.
iii. Make a translation of the trimmed words.
Exceptions include: (‘’) does not have any braille. There are just two
types of quotations: open (“) and closed (”).

VII. IMPLEMENTATION

PROJECT CODES:
IMAGE TO TEXT
Fig: Input image
Fig: Resultant Text from the input image

RESULT OBTAINED FROM PRE-PROCESSING OF IMAGE:


Fig 1: Sample Blur Fig 2:Sample Boxes
Fig: Sample Dilated Fig: Sample Gray
Fig: Sample Threshold
CODES:

Main.py
mapAlphaToBraille.py
mapBrailleToAlpha.py
brailleToAlpha.py
alphaToBraille.py
Printer.py
VIII. RESULT (SCREENSHOTS)
Fig: The text file obtained from the image

Fig: The Output


Fig: Running the main.py file

Fig: Converting text.txt file into Braille

Fig: Converting the obtained braille to text file

IX. CONCLUSION

In our project we have designed a system which enhances the present


system in terms of features and capabilities in translating image text
into braille code. Our goal is to enable image to text and text to braille
code conversions among the functionalities that can be implemented.
X. REFERENCES

[1] Padmavathi, S., Reddy, S. S., & Meenakshy, D. (2013). Conversion of braille
to text in english, hindi and tamil languages. arXiv preprint arXiv:1307.2997.
[2] Cruz, J. L. D., Ebreo, J. A. D., Inovejas, R. A. J. P., Medrano, A. R. C., &
Bandala, A. A. (2017, December). Development of a text to braille interpreter for
printed documents through optical image processing. In 2017IEEE 9th International
Conference on Humanoid, Nanotechnology, Information Technology,
Communication and Control, Environment and Management (HNICEM) (pp. 1-6).
IEEE.
[3] Parvathi, K., Samal, B. M., & Das, J. K. (2015, February). Odia Braille: Text
transcription via image processing. In 2015 International Conference on Futuristic
Trends on Computational Analysis and Knowledge Management (ABLAZE) (pp.
138-143). IEEE.
[4] Kaur, P., Ramu, S., Panchakshari, S., & Krupa, N. (2020, November).
Conversion of Hindi Braille to Speech using Image and Speech Processing. In 2020
IEEE 7th Uttar Pradesh Section International Conference on Electrical, Electronics
and Computer Engineering (UPCON) (pp. 1-6). IEEE.
[5] Murthy, V. V., & Hanumanthappa, M. (2018, February). Improving Optical
Braille Recognition in Pre- processing Stage. In 2018 International Conference on
Soft-computing and Network Security (ICSNS) (pp. 1-3). IEEE.
[6] Beg, U., Parvathi, K., & Jha, V. (2017). Text translation of scanned Hindi
document to braille via image processing. Indian journal of science and technology,
10(33).
[7] Pilu, M., & Pollard, S. (2002, September). A light-weight text image
processing method for handheld embedded cameras. In bmvc (Vol. 2, pp. 547-556).
[8] Zhang, S., & Yoshino, K. (2007, September). A braille recognition system by
the mobile phone with embedded camera. In Second International Conference on
Innovative Computing, Information and Control (ICICIC 2007) (pp. 223-223).
IEEE.
[9] Singh, M., & Bhatia, P. (2010). Automated conversion of English and Hindi
text to Braille representation. International Journal of Computer Applications, 4(6),
25-29.

[10] S, S., S K, S., Ranjini, S., N, V., & M C, P. (2018, June). Text Image to Braille
Code Converter. International Journal of Engineering Research in Electronics and
Communication Engineering (IJERECE),5(6),66-69.

You might also like