You are on page 1of 8

Global Journal of Computer Science and Technology

Graphics & Vision

Volume 13 Issue 2 Version 1.0 Year 2013


Type: Double Blind Peer Reviewed International Research Journal
Publisher: Global Journals Inc. (USA)
Online ISSN: 0975-4172 & Print ISSN: 0975-4350

A Distance Based Hand Gesture Recognition Representing


Numbers
By Ashis Pradhan, Dr. M.K. Ghose & Mohan Pradhan
Sikkim Manipal Institute of Technology

Abstract - Information communication between two peers can be done using various mediums.
These mediums can be either linguistic or gestures. The development of procedure for realizing
gestures into meaningful information plays a pivotal role in instances where linguistic feature cannot
be taken as a basis and gestures can be used as the alternative for the conveying the same. This
project basically presents a very effective and efficient approach for recognizing the hand gesture
that represents numbers. The work basically represents the active and in-active fingers with Boolean
true or false respectively, in different combination for representing different numbers. The method of
representing the hand gesture in binary pattern contributes a lot for increasing the performance of
classification process. The binary Support Vector Machine (SVM) is considered as a recognition tool.

GJCST-F Classification : I.5.4

A Distance Based Hand Gesture Recognition Representing Numbers


Strictly as per the compliance and regulations of:

2013. Ashis Pradhan, Dr. M.K. Ghose & Mohan Pradhan. This is a research/review paper, distributed under the terms of the Creative
Commons Attribution-Noncommercial 3.0 Unported License http://creativecommons.org/licenses/by-nc/3.0/), permitting all noncommercial use, distribution, and reproduction inany medium, provided the original work is properly cited.

A Distance Based Hand Gesture Recognition


Representing Numbers

be done using various mediums. These mediums can be


either linguistic or gestures. The development of procedure for
realizing gestures into meaningful information plays a pivotal
role in instances where linguistic feature cannot be taken as a
basis and gestures can be used as the alternative for the
conveying the same. This project basically presents a very
effective and efficient approach for recognizing the hand
gesture that represents numbers. The work basically
represents the active and in-active fingers with Boolean true or
false respectively, in different combination for representing
different numbers. The method of representing the hand
gesture in binary pattern contributes a lot for increasing the
performance of classification process. The binary Support
Vector Machine (SVM) is considered as a recognition tool.

I.

Introduction

igital Cameras are now integrated into personal


computers, mobile cellular devices and handheld
systems. These devices usually include a
powerful microprocessor, capable of performing millions
of computations per second. The technology on digital
cameras and microprocessors are advancing rapidly
that it is possible to create a human computer interfaces
using these resources. The Gesture recognition system
acts as a communication channel between humans and
machines.
The human-machine interaction is similar to
human-human interaction, in which, the valuable
information are communicated using the human organs
like hand gesture, etc. The design of a gesture
recognition system should be based on common
hardware support such as web-cams or mobileintegrated cameras, to be applicable to current PCs,
mobile devices, Digital Cameras, etc. While designing
such systems, certain parameter like uniform or nonuniform background, different light intensity, etc. has to
be considered, so that the system functions correctly.
This paper presents the design of a hand
gesture recognition system that is divided into various
modules. Initially, system is designed taking into
consideration that the system is able to classify the input
hand gesture representing number given at vertical
position with respect to x-axis considering little or no
deviation to images stored in database. The system is
then modified again to recognize the hand gestures
Author : M.Tech, CSE Department SMIT, Majhitar, East-Sikkim.
E-mail : ashis.pradhan.2010@gmail.com
Author : HOD, CSE Department SMIT, Majhitar, East-Sikkim.
Author : Assistant Professor, CSE Department SMIT, Majhitar, EastSikkim.

given at specified range of angle to make the system


more flexible.
II.

Literature Survey

Several approaches have been already used to


design a hand gesture recognition system. All
approaches gave primary focus on feature extraction of
the hand gesture and was found that the better feature
extraction step is performed, better will be the
performance of classification. Ilan Steinberg et. al [4],
proposed a method of recognizing hand gesture, by
considering each pixel of the binary image as a feature.
Omlin and Vapnik et. al. in [5, 6], have recognized user
hand gesture using color histogram as their feature, in
which, the whole image was divided into smaller blocks
and plot the corresponding histogram, for classification.
Mokhtar M. Hasan et. al. [1], observed that the finger tip
can also be used as a feature for recognition.
Nasser H. Dardas in [3], used a bag of feature
for classifying hand gesture. In this approach, all the key
points of the training images were extracted and these
key points are mapped to its corresponding histogram
feature vector for classification. Oleg Rumyantsev et. al.
introduced an efficient method for recognizing hand
gesture, based on PCA method [2], in which, the test
image and database images were represented using
Eigen values and the hand gestures were correctly
classified using the Euclidean distance of these Eigen
values.
III.

Methodology

This paper basically deals with the design of a


system that acquires a users hand gesture and
classifies it based on the predefined hand gestures,
stored in a database. The figure 1 shown below is the
list of gestures that the system will recognize it correctly:

Figure 1 : Gesture Representing Numbers


2013 Global Journals Inc. (US)

Year 2 013

Abstract - Information communication between two peers can

19

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

Ashis Pradhan , Dr. M.K. Ghose & Mohan Pradhan

A Distance Based Hand Gesture Recognition Representing Numbers

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

Year 2 013

The work uses low-resolution web cam for


capturing the hand gestures and an algorithm that
processes the acquired images and then classifies the
hand gesture correctly. The work mainly emphasizes on
the feature extraction from the hand gestures and use
that features in the recognition algorithms. Initially, the
system will contain a setup procedure, in which, the
algorithm is trained based on significant feature
extracted for different hand gestures. Once the setup in
completed, the system will be able to classify the given
hand gesture based on the database knowledge.
The design of hand gesture recognition system
is broadly divided into two phase: preprocessing phase
and classification phase. The performance of
Classification phase is directly proportional to task
20 performed during preprocessing phase. The task of preprocessing stage is to:
i.
Extract the hand portion from an image
ii.
Remove the noises and unwanted feature
iii.
Convert processed image to binary image
iv.
Extract significant features from binary image to
form a feature set for classification.
The figure 2 represents general methodology
followed for each module during the design of a system.
For classification, the binary SVM (Support Vector
Machine) is used, which is a machine learning
algorithm.
Database-Hand
Gesture Images

Preprocessing
Feature Extraction
and Representation

Input Hand Gesture


to be classified

Preprocessing
Feature Extraction
and Representation
of Input Images
Classification based on
Feature Extracted
Verification&Validationn
Output

Figure 2 : General flow diagram of a System for each


module

The figure 3 below is describes abstract design


of system that is divided into different modules.
2013 Global Journals Inc. (US)

Figure 3 : Representation of different modules of a


system

a) Module 1: Creation of Database

Creation of dataset pertaining to the various


gestures is essential for any inferential studies related to
gesture recognition. This reference dataset created not
only store features related to gestures, it also ease the
process initiated for the gesture recognition. Hence the
dataset set created should be concise yet effective. This
module aims at creating reference dataset for various
gestures in which the gestures are represented with the
help of a Boolean trail, where each Boolean is set to
either true or false based on the requirement of a
gesture. In order to create a Boolean trail, the following
steps should be initiated.
Step 1: Image Acquisition: In this step, the
scene containing hand portion as a major object is
stored. Here, constrain is included in system, that is, the
images is taken at equidistant for both training and
testing.

Step 2: Color segmentation taking basis as tone


of human skin to remove unwanted feature: The second

step extract the hand portion from uniform or nonuniform background. This task was accomplished by
considering the tone of human hand.

Step 3: Converting the output of step 2 to binary


image and noise removal: To reduce computation

complexity for feature extraction, the processed image


was converted into binary image using a thresholding
technique. The noises were handled using median filter.
The morphological operator (erosion) is also used for
removing small unwanted details.
Step 4: Fingertip detection: The next immediate
process is the feature extraction. The paper focuses only
on identifying the active and in-active finger, represented
by 1 and 0 respectively. To identify the active and inactive finger, the first task performed was the finger tip
detection. First, skeletonization technique is used to thin
the finger portion. Then, for each 3x3 mask over whole
image, the number of neighbors is calculated with
respect to centered pixel. If the number of neighbor is
exactly equal to one then that center pixel is considered
as fingertip. For each fingertip detected, the coordinate
values for such pixels are stored.

A Distance Based Hand Gesture Recognition Representing Numbers

Step 6: Determination of distance between


centroid and finger tips: The distance between the

centroid and the fingertip is calculated using Euclidean


distance shown below:
Distance, D2 = (x2 x1)2 (y2 y1)2
Where (x1, x2) and (y1, y2) represent the two
co-ordinate values. Here one pair represents fingertip
location and other pair represents centroid location.

Step 7: Creating Boolean trails for gestures


taking distance as feature: Through manual process, it

was found that the distance from centroid to different


fingertip were different. So, this distance can be used as
a significant feature for identifying the active or in-active
finger. Based on predefined distance for each finger
from Centroid, the active fingers were represented by 1
and the in-active finger was represented by 0. Hence,
we extract Boolean trail for each gesture. For example,
the Boolean trail for gesture representing 1 is will be
01000. This Boolean trail for different gesture
representing different number will be different. For
consistency, the numbering of finger is done form left to
right. The following is the Boolean trails stored in
repository for different hand gestures representing a
number from 0 to 9.
Binary Code

Equivalent
Number

00000
01000
01100
11100
01111
11111
01110
01101
01011
00111

0
1
2
3
4
5
6
7
8
9

Table 1 : Lookup Table or Number Pattern


b) Module 2: Hand Gesture Recognition without
Rotation

In this module, the system is tested by


extracting the Boolean trail for any given input hand
gesture and matching that Boolean trail with the trails
stored in the repository. If there is any match found then
the corresponding equivalent number is displayed
otherwise the system will generate an invalid gesture
message. This module identifies hand gestures given in

Step 1: Repeat step 1 to 6 from module 1


Step 2: Extraction of Boolean trail for an input
hand gesture: Here certain range of distance is

considered to identify active and in-active finger and


hence to increase the efficiency of a sytem. So that,
system can also recognize the hand gesture correctly
even there is a small bents of finger during acquisition.
Hence, if the distance for any finger is within specified
range, then the corresponding bit is set to 1 else 0. In
this way, the Boolean trial is extracted for a given
gesture representing number.

Step 3: Comparison of Boolean trail for an input


hand gesture with repository: The Boolean trail extracted

from step 2, for input hand gesture is compared with the


each Boolean trail of repository created in step 7 of
module 1. Finally, if there is match with any one of the
binary pattern, the corresponding index value of the
matched binary pattern is displayed, which is
considered as the matched gesture. The Binary SVM is
used for classification, in which, the input image is
classified as either correct or incorrect. Therefore,
number of binary SVM comparison has to be made with
repository.

c) Module 3: Hand Gesture Recognition with Rotation

This method basically includes the recognition


of hand gestures given at any angle. This module is
included in system to include the property rotation
invariant. So, several tasks were performed, where, the
input hand gesture given at certain angle (i.e. gesture
formed by rotating palm in clockwise or anti-clockwise
direction) can also be identified correctly. The following
are the steps initiated to include the property rotation
invariant in the gesture recognition system:

Step 1: Repeat step 1 to 3 from module 1


Step 2: Identification of fist for any input

gesture: The fist of the hand is identified by scanning the


hand on row basis starting from the centroid of hand
onwards directly to reduce unnecessary computation. If
the number of continuous pixel representing hand
portion, is in the range 50-60, then that row is
considered as portion of fist. Here, we consider the fact
that in whichever angle the palm is oriented the fist of
hand is always coincide with horizontal axis. Once the
initial row value and final row value representing fist
region of a hand gesture is found, the mid-point for that
the initial row value and final row value representing fist
is to be calculated. Let (x, y) and (i, j) represents the
mid-point coordinate value for initial row value and final
row value representing fist of hand, respectively. An
imaginary line is drawn between points (x, y) and (i, j)
and let H represents this line, which basically represents
the deviation from imaginary vertical line.
2013 Global Journals Inc. (US)

Year 2 013

Where represents the centroid of the hand, xi


and yi are x and y coordinates of the ith pixel
representing hand region and k represents total pixels
representing hand.

an upright position, that is, fist of hand is approximately


perpendicular to horizontal x- axis. The following steps
are performed to during implementation:

21

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

Step 5: Determination of centroid: The centroid

of a hand is calculated as:

Year 2 013

A Distance Based Hand Gesture Recognition Representing Numbers

Step 3: Calculating the deviation of hand: For


calculating deviation, the angle between line H and an
imaginary horizontal line (i.e. x-axis) is calculated.
Consider an imaginary horizontal line along x-axis
starting from coordinate (i, j). Now, from analysis,
coordinate (x, y) and (x, j) represents the imaginary
horizontal line. Let B represents this line. Now, it can be
noted that line H and B meet at (x, y). Also, it is noted
that by drawing a line from (x, y) of line H to (i, y) of line
B forms a right angled triangle. Hence, a cosine law can
be used to find an angle between line H and B. Let
(theta) is the angle between line H and B.
So,

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

22

Figure 4 : Imaginary Triangle for Rotation


Step 4: Calculating deviation with respect to
vertical y-axis: Finally, the deviation of hand from vertical
axis is calculated using following expression:
Deviation= 90 (if is an acute angle).
Step 5: Performing rotation on the input gesture
by an angle Deviation: Finally, the output of Step 4 is
rotated using the rotating function of matlab with an
angle Deviation.
i.e. Output= imrotate (Input Image, Deviation);

Step 6: Repeat Step 4 to 6 from module 1: The


outcome of this step is the distance matrix that gives the
distance between active finger and the centroid.
Step 7: Extraction of Boolean pattern from
output of step 6: In this step, repeat the Step 2 of
module 2 considering the output from above Step
number 6, to extract the Boolean pattern.
Step 8: Repeat the Step 3 of Module 2
considering the output from above step 7 and display
the result.
IV.

Results and Discussion

The result of the hand gesture recognition


system is very simple, but the paper aims at the efficient
way of representing data or information for comparison
and focuses on the method to reduce the complexity
during comparison for a hand gesture image to be
tested and hence to increase the correctness of the
system. It not only follows a simple approach for
recognition but also include a feature like rotation
invariant and orientation independent. The figure 5
shown below is the abstract view of result of the system.

2013 Global Journals Inc. (US)

5
Figure 5 : Input Gesture and Output Gesture
The lots of task are carried out to design a
system that will correctly classify and give the above
sample output for its corresponding input. The first task
after image acquisition was to extract only the hand
portion from any complex or uniform background, which
was accomplished with the help of skin color of hand
and convert the resultant image to binary image. The
thresholding technique was used to convert image into
binary image. While working in real time, there exists
some noise in an image. This appearance of noise may
be due to low resolution cameras that it used during
image acquisition step or due to the environmental
factor. Hence, the image in which the hand portion is
extracted also contain some noises. So, the median
filtering technique, followed by erosion morphological
operation is used on the segmented image to remove
noise and to remove un-necessary small sharp detail in
an image, respectively. The outcome of these
operations is the noise free regularized image, in which,
the maximum area in an image is covered with the
object of interest only. Finally, the resultant image is
processed to determine the finger tips and store its coordinate values. The Skeletonization technique is used
to determine the finger tip. In the next step, the centroid
of a hand region is calculated. The significance for
calculating the centroid is to determine the actively
raised finger. The actively raised fingers were
determined by calculating the distance between the
centroid and the finger tip. Visually, it can be determined
that the distance between centroid and the different
fingers of a hand are different. Hence, this concept is
used to create a binary pattern for actively raised finger
in an image. The deviation of 10% (approximately) is
included in the system for distance to determine actively
raised finger. The active raised finger is marked 1 and
the in-active fingers is marked 0. These different
combinations of 0s and 1s represent any one number
between 0 and 9. Thus, a database is created for
different hand gesture that represents number. The table
1, table 2 and table 3 shown describes the result
achieved for module 1(i.e. Repository Creation for each
image representing gesture from number 1 to 9),
gesture recognition without rotation and gesture
recognition with rotation, respectively.

A Distance Based Hand Gesture Recognition Representing Numbers

Input

Output

RGB to
Binary

Process

Input

Output

Calculate
deviation

Noise
Removal

Year 2 013

Rotate Input
Image

Skeletoniz
ation

Repository
Creation

11111

Table 2 : Sample Result for Module 1

Process

Input

Output

23

Pattern
Extraction

11111

Pattern
Comparison

RGB to
Binary

11111

Table 4 : Sample Result for Module 2

Noise
Removal

Skeletoniza
-tion
01100
Pattern
Extraction
Pattern
Compariso
n

Centroid
and
Fingertip
Detection

Initially, the system is trained by extracting


binary pattern for different hand gestures representing
numbers and thus creating a repository that is used later
in recognition phase. After the creation of database, the
testing phase starts. In testing phase, any input image is
taken that represent number. Same tasks are carried out
for the input image, as described above, to extract the
binary pattern. Finally, this binary pattern is matched
with the repository to recognize it as correct gesture and
hence display the result.
V.

01100

Table 3 : Sample Result for Module 2

Conclusion

The hand gesture recognition system designed


is trained with different gestures and is able to classify it
correctly. Some assumption are considered while
designing a system, that is, the input image to be
classified during testing phase has to be taken at same
distance and at similar intensity as that of training
phase. Initially, system classify the hand gesture
representing number given at approximately upright
position which is further extended to recognize gesture
given at any angle between 0 to 180 degree, by
considering the fact, that, the base of the fist is always
coinciding with the horizontal x-axis. The system can be
further extended as future scope to recognize
alphabets, expressions, etc. Furthermore, the search
procedure can be enhanced to increase the
performance of the system. The designed system is
able to classify only the static images which can be
2013 Global Journals Inc. (US)

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

Process

Year 2 013

A Distance Based Hand Gesture Recognition Representing Numbers

Global Journal of Computer Science and Technology ( D


F ) Volume XIII Issue II Version I

24

extended more to recognize hand gesture in videos as


well. There are lots of applications for gesture
recognition system. For example, sometimes, it can also
be used as communication device. There is a rapid
growth on application development considering gesture
recognition system. For example, now days, in smart
T.V, gesture recognition system is included to change
channel, increase volume, etc. Lots of research is still
going on this related topic to ease the life of human
being and to enhance the technology.

References Rfrences Referencias


1. Mokhtar M. Hasan, Pramod K. Mishra Real Time
Fingers and Palm Locating using Dynamic Circle
Templates, International Journal of Computer
Applications
(0975 8887),
Vol: 41 No.6,
March 2012.
2. Oleg
Rumyantsev,
Matt
Merati,
Vasant
Ramachandran, Hand Sign Recognition through
Palm Gesture and Movement, Image Processing,
EE 368, Spring 2012.
3. Nasser H. Dardas and Nicolas D. Georganas,
Real-Time
Hand
Gesture
Detection
and
Recognition Using Bag-of-Features and SVM, IEEE
Transactions On Instrumentation and Measurement,
Vol.60, No.11, Nov 2011.
4. Ilan Steinberg, Tomer M. London, Hand Gesture
Recognition in Images and Video, Technion IIT,
January 5, 2010.
5. C.W. Omlin, M. Glaser, Vision Based Static Hand
Gesture Recognition, Art and Literature category,
DOP: 12/16/2009.
6. Olivier Chapelle, Patrick Haner and VladimirVapnik,
SVM for Histogram-BasedImage Classification,
IEEE, Vol. 10, No. 5, September 1999.
7. A. Malima, E. Ozgur, M. Cetin, A Fast Algorithm for
Vision-Based Hand Gesture Recognition for Robot
Control, 2006 IEEE 14th Conference, ISBN: 1-42440238-7, Date: 17-4-06.
8. E.
Sanchez-Nielsen,
et.al,
Hand
gesture
recognition for human machine interaction, Journal
of WSCG, Vol.12, No.1-3 (February 2003).
9. Aryuanto Soetedjo, Skin Color Segmentation Using
Coarse-to-Fine Region on Normalized RGB
Chromaticity Diagram for Face Detection, BIEICE
Trans. Inf. & Syst., Vol.E91-D, No.10, October 2008.

2013 Global Journals Inc. (US)

Global Journals Inc. (US) Guidelines Handbook


www.GlobalJournals.org

You might also like