CHAPTER
-
3
REQUIREMENT SPECIFICATION
3.1
Introduction
This project aims to develop software which will detect handwritten
character in an applet. The application is basically confined to English and
numbers. The software is developed using Kohonen Neural network concepts.
This application will dynamically det
ect the character.
Scope
The project will be developed to recognize the Hand Written characters of
English and numbers, also the operands and special characters.
3.2
G
eneral
D
escription
3.2.1 P
roduct
F
unctions
O
verview
Feature Extraction
The neural network
is presented a pattern, this could be an image and hand
written data.
One
level
Data
Flow
Diagram
Feature extraction consists of three steps:
Extreme coordinate measurement
Grabbing character into grid
Character digitization.
The
handwritten character is captured by its extreme coordinates from
left /right
and top/bottom and is subdivided into a rectangular grid of specific rows and
columns.
Then it searches the presence of character pixels in every box of the grid. The
boxes fou
nd with character pixels are considered “on” (1) and the rest are
marked as “off” (0).
3.2.2
User
Characteristics
Intended user no need to have any background knowledge of the
application.
Installation is necessary for the user in his computer.
General
Constraints
The system should have Drawing Editor to draw different characters. The
system should have a database to store the characters and display the
characters present in the database. The system should add new characters and
must display the trained
characters.
The trained characters can be
English Letters
Numerical
Special Characters
After the training, the system should display a message “Ready to Recognize”.
The system must recognize the drawn character in the editor. The system should
be able to
delete all the characters present in the database at a time. It should
also be able to delete a single chosen character present i
n the database. At a
time only
a single character can be detected.
3.3
F
easibility Analysis
Reliability
The system is more
reliable as it is a standalone system.
Portability
The application can be run on any Operating System as it is based on
Java Virtual Machine.
Maintainability
The application can adapt to any of the pattern as trained by the user.
Availability
The application can run 24×7 without any restriction to Operating System.
3.4 Functional R
equirements
3.4.1 G
eneral description of modules with inputs and outputs
Add
module
This module takes the character entered in the textfield
and also the
character drawn on the drawing panel as the input. Firstly it checks for the length
of the character entered, if the length is less than one then the message “Add a
character” is displayed. If the length is greater than one then “Add only a s
ingle
character” message is displayed.
Then if the length of the character entered is one, it continues with
downsampling the character entered in the drawing panel. Later the character
added is compared with the characters present in the database. Now, if
the
character already present in the database then the message “Character already
defined, delete it first” is displayed. Otherwise the character added i
s checked
and compared for ASCII
value with the characters in the database to get the
correct position
so as to place the newly entered character in the database. Then
the database is updated with the newly added character.
Recognize
module
This module takes the character drawn on the drawing panel as the input.
It firstly checks whether the character drawn has been previously trained or not.
Then the character drawn is downsampled and the input values are set which are
given to the kohonen n
etwork to get the winning neuron. Later the input values
are set for every character in the database which is given to the kohonen network
to get the winning neuron of each character. Next the index of the winning
neuron of the character drawn is mapped wi
th the index of the winning neuron of
each character and checks for the ASCII range to print the appropriate message
(Ex:
-
“English letter : entered character”).
Train
module
This module takes all the characters in the database as the input. Firstly,
the in
put neuron and output neuron count and also
the input values for each
character is set, then the weights are initialized using random methods defined in
the Math library of Java. Next, the neurons are trained in an infinite loop to get
the winning neuron
of each character in the database. The loop runs until the
error rate is acceptable and the desired correction is obtained.
Delete
module
This module is mainly used for deleting a character which is selected by
the user and after deleting it updates the
database.
Clear
module
This module is mainly used for clearing the draw panel and the grid values
in the downsample panel.
3.4.2
Functional Description
The functions involved in each module are as follows:
Splash Screen
•
Used to get an introductory screen
before the project begins.
BaseClassKNetwork
•
Acts as a base class to all the modules which comprises of the
abstract functions.
•
This class is the base class for the Kalgo class, which will ultimately
provide the Kohonen neural network.
•
The
BaseClassKnetwork class is declared abstract so that it cannot be
instantiated by itself.
•
To make use of the BaseClassKnetwork class a child class must be
derived. The KohonenNetwork class is provided as a child class.
DrawLetters
•
The drawing area that al
lows the user to draw letters.
•
Most of the actual drawing is handled by the
processMouseMotionEvent. If the mouse is being drug, then a line will
be drawn from the last reported mouse drag position to the current
mouse position.
•
The mouse moves faster than
the program has time to accept all values
for. By drawing the line, we will cover any missed pixels as best we
can.
•
The line is drawn to the off
-
screen image, and then updated to the
users screen.
•
As the program runs, this method is called repeatedly. T
his causes
whatever the user is drawing to be saved to the off
-
screen image.
Kalgo
•
Describes the functionality of Kohonen Neural Network.
•
Management of weight arrays is a very important aspect of
implementing the Kohonen neural network.
•
. The value for
each output neuron is calculated by taking the dot
product of the normalized to input that are and the weights.
•
The winning neuron is the neuron that determines which class the
network recalled the pattern has been part of.
•
The main loop presents the train
ing patterns to the neural network and
calculates errors based on the results obtained from the neural
network.
•
The evaluate errors method is used to evaluate how well the network is
training and to create a correction array that contains the corrections
t
hat will be made by the adjust Weights method stored in a correction
array.
RecogChar
This module consists of the user interface characteristics which
connects all other modules.
This module creates the panels for drawing a character, to display the
grid
values, to display the trained character database and also panel for
buttons.
The is a source module that calls other modules based
on the action
response to an event, when any button is clicked.
Sample Data
Used to hold a down sampled image.
All down sampled images will be stored in SampleData class.
This class also includes methods to set and get the data associated
with the downsampled grid.
The SampleData class also contains a method, named clone that will
create an exact duplicate of this
image.
Sample
The Sample module is used to display the grid values in the
downsample panel of the output by getting the values from containment
SampleData module.
TrainingSet
The training data for a neural network where all the neurons are
trained.
To train the Kohonen neural network training sets must be provided.
This training data will be stored in the TrainingSet class.
This class is designed to be a container class that could potently be
used for other neural network architectures as well as t
he Kohonen
neural network.
3.5
External Requirements
3.5.1 User Interface
Hardware
Interface
Processor
:
Pentium IV 2.6 GHz
RAM
:
512 MB
Monitor
:
15”
Hard Disk
:
20 GB
CD Drive
:
52X
Keyboard
:
Standard 102 Keys
Software
Interfaces
Front End
:
JAVA, Swings, Applet
Tools Used
:
MyEcli
pse 7.1
Operating System
:
Any OS with JVM installed.
3.5.2
Error message
If a user clicks the add button without entering any character in the
textfield, it will display a message as “You should enter a single
character”.
If a user clicks the add button by entering more than one character in
the textfield, it will display a message as “You should enter only a single
character”.
If the user tries to add any character previously trained then a message
“Letter already defined,
delete it first!” appears.
If a user clicks the delete button without selecting any character in the
database, it will display a message as “Please select a letter to delete”.
If a user clicks the recognize button before training the entered
character, it
will display a message as “I need to be trained first!”
3.6
Design Constraints
Software
Constraints
To run this project Java Runtime Environment with JDK 1.5 and above is
required. The system will run under windows operating system.
Hardware
Constraints
The system requires minimum of 512MB RAM and a Hard disk space of
40GB and more.
Enter the password to open this PDF file:
File name:
-
File size:
-
Title:
-
Author:
-
Subject:
-
Keywords:
-
Creation Date:
-
Modification Date:
-
Creator:
-
PDF Producer:
-
PDF Version:
-
Page Count:
-
Preparing document for printing…
0%
Comments 0
Log in to post a comment