Handwritten Pattern Recognition Using Kohonen Neural Network Based on Pixel Character

—Handwriting is the human way in communicating each other using written media. By the advancement in technology and development of science, there are a lot of changes of technology in terms of communication with computer through handwriting. Therefore, it is needed computer able to receive input in the form of handwriting data and able to recognize the handwriting input. Therefore, this research focuses on handwritten character recognition using Kohonen neural network. The purpose of this research is to find handwriting recognition algorithm which can receive handwriting input and recognize handwritten character directly inputted in computer using Kohonen neural network. This method studies the distribution of a set of patterns without any class information. The basic idea of this technique is understood from how human brain stores images/patterns that have been recognized through eyes, and then able to reveal the images/patterns back. This research has been successful in developing an application to recognize handwritten characters using Kohonen neural network method, and it has been tested. The application is personal computer based and using a canvas as input media. The recognition process consist of 3 stages layer: Input layer, Training Layer and Hidden Layer. The Kohonen neural network method on handwritten character recognition application has good similarity level of character patterns in character mapping process.


INTRODUCTION
Handwriting is the human way in communicating using written media.Nowadays, there are a lot of changes of technology in terms of communication.Handwriting offers an attractive and efficient method to interact with computer, such as a tool developed at this time that is able to receive input in the form of handwriting data.The tool also requires a method to recognize input in the form of handwriting data.Research on handwriting recognition issue becomes important to provide solutions of the problems above.
There is difference of writing patterns for each person's writing so that the way the computers recognize writing patterns should be noted.Writing pattern recognition [1] is intended for computer to be able to recognize the letters/characters by converting images, either printed or handwritten, into codes [1].Handwriting pattern recognition can be done online or offline [2].There are many methods that can be used to identify patterns of writing, one of method is neural network [3].There are many methods that can be used to recognize writing patterns such as template matching, character decomposition, wavelets, neural network, etc.
Ralph Niels and Louis VUURPIJL, did a research of handwritten character recognition using template matching method.This method's advantage is that this method produces a higher level of recognition.And this method's disadvantage is that users should be able to specify templates to compare characters to be tested [4].Template matching method was also performed by Jakob Sternby that results in the recognition rate of 82.4%.The method developed by Sternby is suitable for handwriting recognition based on graph segmentation system but it requires a long processing time because it should match input characters with all templates [5].Recognition by decomposing character was conducted by E. Gómez Sánchez, et al.Their method's advantage is that it is suitable for realtime processing, consistently, for the combination of curvature multiple forms particularly on character segmentation of upper case characters, however, this method depends on how the character is written, and handwriting which is written very fast provides troubles.The recognition rate of digit is 82.52%, for uppercase character is 76.39% and for lowercase character recognition is 58.92% [6].
Neural network has an ability to learn information already received.Based on this method, neural network is divided into two, namely supervised learning and unsupervised learning.The difference of the two methods is in terms of target output.In supervised learning there is target output while unsupervised learning has no target output.From both methods, the most appropriate method to recognize patterns is unsupervised learning.The example of unsupervised learning is Kohonen network method.
Kohonen Neural Network method studies the distribution of a set of patterns without any class information.The basic idea of this technique is understood from how human brain stores images/patterns that have been recognized through eyes, then human brain is able to reveal the images/ patterns back.Therefore, this model is widely used in object recognition or visual images.There are a lot of interesting problems in pattern recognition; some of them are fingerprint pattern recognition, facial pattern recognition, handwritten character pattern recognition and so on.
Based on the pattern recognition problems, it has been developed handwritten character pattern recognition application with neural network [7].The handwritten character pattern recognition is aimed for computer in order to be able to www.ijacsa.thesai.orgrecognize handwritten character by converting images of characters, either printed or handwritten into digital data.The data are saved into data file so the data can be edited and manipulated on a computer.
To solve handwriting pattern recognition problems in neural network, it is used kohonen algorithms; neural network is analysed in terms of the accuracy of handwriting recognition on patterns and time required for training of handwriting patterns.
This research is aimed to recognize handwritten characters from characters "a-z", uppercase and lowercase characters using Kohonen Neural Network in order to allow users to recognize handwritten character patterns of character drawing process

A. Kohonen Neural Network
Kohonen Neural Network method is an unsupervised learning process studying distribution of a set of patterns without any class information.The basic idea of this technique is understood from how human brain stores images/patterns that have been recognized through eyes, and then human brain is able to reveal the images/ patterns back.Therefore, the application of this model is widely used in object recognition or visual image.A brief description of the form of a series of kohonen network can be seen in Fig. 1. [8] There are several studies on the use of Kohonen Neural Networks in Handwriting.The study on Online Recognition of handwritten Arabic Characters Using a Kohonen Neural Network was conducted by Mezghani, et al [9].This study used 18 arabic alphabet character forms, with 7400 samples.The kohonen neural network used was Kohonen memory (known as Kohonen Self Organizing feature map) used to represent all points of a source into a smaller number of points in the target space.The memory was organized as 2 dimensional arrays.This study resulted in 88.38% recognition rate on writing characters without limitation of writers.

Fig. 1. KohonenNeural Network
Another study using Kohonen Neural Network was Vishwaas, et al [10].Vishwass combined Direction Based Stroke Density (DSD) with Kohonen Neural Network for Kannada Writing Recognition.The study used 49 characters and 10 numbers of Kannada (Kannada Language) written by 20 different people.This study resulted in 94.4% recognition accuracy.

B. Handwriting Recognition
Handwriting recognition is an ability of a computer to receive input in the form of understandable handwriting.Principally, handwriting recognition requires optical character recognition.The handwriting recognition system completely handles formatting, performs segmentation, and finds the most appropriate word.Handwriting recognition is used for editing, annotation, other applications that are difficult to interact directly, and applications using direct manipulation and pointing.Tablet is a powerful tool as the input of handwriting because tablet can receive both text and graphics.There are many electronic devices that can be used as a tool in Handwriting recognition such as a mobile device/smartphone [11,12,13].Research on the utilization of input devices such as electronic pen was also conducted by Sreeraj [14].
Handwriting consists of a time sequence of stroke (movement), i.e. movement of writing started from pen down to pen up, character writing is usually formed in a sequence, one character is complete before starting the next one, a character usually starts from left to right.In some cases there are exceptions.For example in English script, crosses (for t and x) and point (for i and j) tend to be a delay in writing.

III. PROPOSED METHOD
The method proposed in this research was handwritten character recognition written on canvas using Kohonen neural network.Canvas is an area to write input characters.The application is operated on a personal computer.The application is built using Java programming language.The research stages proposed are outlined in Fig. 2 as follows.This process is the main layer which does drawing and the core of subsequent processes.This layer will scan character from image.Each image formed is a collection of x-coordinate and y-coordinate points.When mouse touches canvas, the initial value of x-coordinates and y-coordinates will be saved in the memory, and when mouse is released the initial values of xcoordinates and y-coordinates are saved.Between initial value and final value of coordinates there will be whole-values of x and y coordinates saved in memory when mouse is pressed (Mouse Pressed) and mouse is dragged (Mouse Dragging).Clipping process is performed when mouse is released from dragging process; image will be framed by a box along with parsing of coordinate values to mapping process and data recognition.The results of clipping image process save coordinate value result from process of mouse pressed and mouse dragging.To frame image with a box it has to take the largest and smallest values of x coordinates and y coordinates.The program will form a straight line connected between the largest value and the smallest value.The next step is mapping characters, i.e. the taking process of image cutting results in which its values are adjusted to the resolution of existing map size.The map size is made with the resolution of 7x5 pixels.For example, in Fig. 4 character "F" has been already processed in mapping process, its value is F={1,1,1,1,1,1,0,0,0,0,1,0,0,0,0,1,1,1,1,0,1,0,0,0,0,1,0,0,0,0,1,0 ,0,0,0}.This value is obtained from the results of 7x5 pixels of pixel box in which the allocated value has 1 value and the unallocated has 0 value.The value is calculated based on columns from top to bottom.
Next, the value of mapping process is saved in a text file with .datextension.Thirty-five pixels value of each character saved in this process.

The second stage is training process (training layer).
Training layer process will train and scan character depicted in input layer process.This scanning process will read and save image pixels into database.The information read by this layer will be saved in hidden layer.
The third stage is the process where characters are entered, can also be saved and taken whenever required while information saved is required, the character taking happens from hidden layer process.The character scanned by training layer can be saved in this layer.This layer is not visible by users, so that when character is drawn, the character will be scanned in this layer and if the image character matches to the existing data, the result will be displayed.In this hidden layer process character will be taken and saved.All information will be taken and applied for further proceedings.
The final step is character recognition and selected character approach process (matching and output).Matching and output is the final process where the matching operation is done.If there is image formed in drawing process, training layer will scan the image and character matching is done, after character matching is finished, the output result will be displayed to users.A procedure to display the scanning result will be conducted on layer output with a clear and efficient way.

IV. RESULT
The data used in this research are characters a-z and characters A-Z written on canvas.The size of handwritten character data is 7x5 pixels.The recognition process of some handwritten characters as follow:

1) Drawing Characters
The first step of handwritten character recognition process is drawing characters on canvas.The character drawing process canseen in Fig. 5, when mouse is released from canvas, there will be formed a straight line at the top, right, left, and bottom of image then the image is framed in a box.

2) Mapping Image
When mouse is released, there will be performed mapping image process into canvas map; the result can be seen in Fig. 6.

3) Saving Character Data
To add character data, it can be performed by pressing plus sign button, and there will be a form of character input, the result will be shown in Fig. 7.After character input form is filled, the input character will appear on a list of data as in Fig. 8, to save the list of data into sample.datfile, it can be done by pressing save button.The result of character input can be seen in sample.datand the result can be seen in Fig. 9.The values saved in sample.datfile are in the form of characters of data and binary number of 0 and 1 Fig. 9. Data saved in sample.dat

4) Comparing Pixels
Pixel compared is the image pixel of handwritten character input result on canvas with the data saved previously in sample.datfile.

5) Character Recognition
Pixel comparison process is performed in order to be able to recognize characters.After that, a testing is done to recognize handwritten characters as shown in Fig. 10 and Fig. 11.www.ijacsa.thesai.orgThe complete results of testing done to users who write characters "a to z" as many as 10 times can be seen in Table 1:  From the testing results in the table above it shows that the recognizable characters are character "a, l, n, o, u, v, w and z".The characters can be recognized 100%.Whereas, the least recognizable character is "d", character d is more recognizable as character "o" and "q".The unrecognizable writing of character "d".
V. CONCLUSION Handwritten character recognition using Kohonen neural network can recognize characters based on handwriting pattern approach with the character data available.The recognition process consist of 3 stages layer: Input layer, Training Layer and Hidden Layer.In Input layer: user draw a character.On the testing, users asked to write characters "a, l, n, o, u, v, w to z " on canvas area as many as 10 times.The size of handwritten character data is 7x5 pixels.The data read and save in Training Layer.The recogniton result shown in the hidden layer.The experiment shows that character "a" is the most recognizable character and the most unrecognizable character is character "d".The handwritten character recognition with this method has similarity character pattern with mapping character process of 87.5%.The good results of handwriting recognition can be obtained by drawing process of character writing and can be adapted to the character data which saved in sample.datfile.The results will not be appropriate if the drawing process producing mapped images has inappropriate pixel values to the existing pixel values in sample.datfile.The contribution of this research is that it can be used to introduce the writing learning for early age children.

Fig. 2 .
Fig. 2. Stages of Handwritten Character RecognitionIn general, there are six steps of handwritten character recognition process.: The first step is drawing character on canvas; the 2 nd step is mapping image of character; the 3 rd steps is saving image of character data; the 4 th step: training data; the 5 th steps is matching data by comparing the results of mapping images with character data which have been saved at the preceding step, finally the last step is recognition: the characters can be recognized or not.The steps could be divided in the 3 stages layer: Input layer, Training Layer and hidden layer.In the first stage is Input layer.Drawing character on canvas process becomes the input layer process.Input layer is

Fig. 8 .
Fig. 8. Character Data in List of Data

TABLE I .
CHARACTER "A-Z" RECOGNITION TESTING RESULTS