Content uploaded by De Rosal Ignatius Moses Setiadi
Author content
All content in this area was uploaded by De Rosal Ignatius Moses Setiadi on Jun 26, 2023
Content may be subject to copyright.
XXX-X-XXXX-XXXX-X/XX/$XX.00 ©20XX IEEE
Javanese Script Recognition based on Metric,
Eccentricity and Local Binary Pattern
Ajib Susanto
Department of Informatics Engineering
Dian Nuswantoro University
Semarang, Indonesia
ajib.susanto@dsn.dinus.ac.id
Ibnu Utomo Wahyu Mulyono
Department of Informatics Engineering
Dian Nuswantoro University
Semarang, Indonesia
ibnu.utomo.wm@dsn.dinus.ac.id
Christy Atika Sari
Department of Informatics Engineering
Dian Nuswantoro University
Semarang, Indonesia
atika.sari@dsn.dinus.ac.id
Eko Hari Rachmawanto
Department of Informatics Engineering
Dian Nuswantoro University
Semarang, Indonesia
eko.hari@dsn.dinus.ac.id
De Rosal Ignatius Moses Setiadi
Department of Informatics Engineering
Dian Nuswantoro University
Semarang, Indonesia
moses@dsn.dinus.ac.id
Abstract—Handwriting recognition is one of the most
interesting researches in computer vision. Some previous
research has developed and implemented Javanese script
recognition in digital fonts and handwritten, but handwriting
recognition is still not optimal. The contribution to this research
is to improve the recognition accuracy in handwritten Javanese
scripts. The proposed method is to combine metric feature
extraction, eccentricity, and local binary pattern (LBP) which is
further classified with k-Nearest Neighbor (KNN). Several
preprocessing stages are carried out so that the features are
extracted optimally. After testing the proposed method
succeeded in improving recognition performance with 92.5%
accuracy, 92.5% recall, and 100% precision on 200 training
data and 40 testing data.
Keywords—OCR, Object Recognition, Classification,
Javanese Script, LBP
I. INTRODUCTION
Research on object recognition in images is very
interesting on the topic of computer vision. Various methods
are proposed to perform object recognition, such as machine
learning or deep learning to perform object classification[1].
In certain objects, there is not much training data so that it can
be used for deep learning training processes, for example on
Javanese script data. Javanese Script is Javanese regional
writing in Indonesia that is increasingly unpopular due to the
development of the era, so it is rarely used. However, the
Javanese Script needs to be learned. With the help of
computers, learning about Javanese Script will be easier to do,
so further research is needed to improve the accuracy of
recognition in Javanese Script.
Some research, such as [2]–[6] has developed the Javanese
Script recognition method and has even carried out a
translation process such as research [7]–[9]. In carrying out
recognition, classification is one of the most widely used
methods, in which several steps need to be considered, from
the process of data collection, pre-processing, feature
extraction, training, testing, and evaluation. Where each stage
has an important role. It should be noted that a good image
input will facilitate each classification process to produce
good accuracy. But if the preprocessing and feature extraction
processes are not suitable, the classifier will find it difficult to
classify so that it produces non-optimal accuracy.
After the data is collected, several preprocessing stages are
carried out on object recognition. Because the object used in
this research is a handwritten Javanese script, it is necessary
to do some enhancements to get the features of the
handwritten object. Handwriting should be a simple object
because there are not many components there, so there is no
need for a combination of features such as color, texture, and
shape for recognition. Logically, a script does not need color
and texture features, but the shape and pattern features have
more influence on its recognition so that at the end of the pre-
processing, a grayscale or binary image is generally produced.
So it is necessary to carry out various processes that can
produce images that are clean from noise so that objects can
be seen more clearly and features can be extracted properly.
Feature extraction will also be better if it is only done in the
region of interest (ROI) so that the recognition results obtained
are more appropriate.
Bounding box crop is one method to get ROI or important
parts of an image that has been developed in various studies
such as detecting license plates. [10], to visual aesthetic
enhancement [11]–[13]. By using a bounding box, only the
ROI area will be taken, so that the extracted feature will be
centered on the object to be recognized. In this way, you will
get better recognition accuracy, one of the simplest methods
using functions such as regionprops in Matlab.
As discussed earlier, because handwriting does not require
sharing a complex combination of features for recognition. So
to recognize patterns from handwriting features such as
metric, eccentricity [6], and local binary pattern (LBP)[14]
possible be a good feature to recognize. On research Sari et.
al. [6], Hand-written Javanese script has been recognized with
an accuracy of 87.5%. While the research conducted by
Partiningsih et. al.[14] can recognize handwriting ownership
with an accuracy of up to 96.67%. Both of these studies use
K-Nearest Neighbor (KNN) as the classifier. From the
literature that has been described, this research proposes a
Javanese Script handwriting recognition method with a
combination of metric, eccentricity, and LBP features based
on the KNN classifier which aims to improve the performance
of object recognition of Javanese Script characters.
II. RELATED RESEARCH
Several studies were to investigate beyond that Javanese
script of which is research Herwanto et. al. [2], in his research,
a feature extraction technique based on zones is proposed.
Initially, an image is preprocessed using several processes
such as grayscaling, thresholding, noise removal, crop edge,
and resizing. Next is the process of dividing the zone on the
image to get its feature extraction.
2021 International Seminar on Application for Technology of Information and Communication (iSemantic)
978-1-6654-2804-0/21/$31.00 ©2021 IEEE 118
Another research using Tesseract to recognize Javanese
script in android applications was proposed by Abdul Robby
et. al.[4]. In his research, he used a total of 5880 Javanese
script characters written by hand or in digital fonts. In this
research, the dataset is divided into 6 data sets, wherein one of
the most commonly used sets, namely “ha na ca ra ka”, has
the best accuracy is up to 92.62% for digital fonts, but the best
accuracy in handwriting is only around 61.25%.
Zhangrila [5], proposed the $P algorithm to recognize
Javanese Script. In his research, digital fonts were used as
training data, to recognize handwriting written on the touch
screen of an Android smartphone. This method can produce
up to 80.65% accuracy to recognize the Javanese script “ha na
ca ra ka”. In his research, he also compared Latin alphabet
recognition with an accuracy of 94.91%. This shows that there
is a different accuracy because the Javanese script is more
complex.
Another more detailed research was carried out by Sari
et.al.[6], in her research, it is proposed to extract form features,
namely metric and eccentricity and K-Nearest Neighbor
(KNN) to recognize Javanese script. For the features to be
extracted properly, several preprocessing stages were carried
out such as manually cropping the image, converting to a
binary image with thresholding, filter media to reduce image
noise, converting to a negative image, and dilation process to
strengthen the Javanese script character. The recognition
results are quite high, namely 87.5% of 40 testing data and 200
Javanese script handwritten image training data. Seeing the
relatively small amount of data, the data concluded that the
accuracy produced was relatively very good.
Contrast enhancement, LBP feature, and KNN classifier
proposed by Partiningsih et.al.[14] to recognize handwriting
possession. The handwritten image is subjected to several
preprocessing such as RGB to Grayscale conversion and the
addition of 1% contrast. Furthermore, the LBP feature is
extracted with a cell size of 128 pixels. The recognition
accuracy reached 96.67% for 3 classes with 300 training data
and 60 testing data.
From some of the research above, it can be seen that in
research [2] the zoning process still needs to be identified
further, research [4] and [5], just implement the algorithm.
While on [6] and [14] The proposed method can still be
optimized. This research proposes a combination of feature
extraction metrics, eccentricity, and LBP with a KNN
classifier.
III. PROPOSED METHOD
In this research, a metric and eccentricity feature
extraction method with a KNN classifier is proposed to
perform recognition. To optimize the results, a bounding box
crop function is used. The proposed method consists of several
main stages, namely data collection, preprocessing, feature
extraction, training, testing, and evaluation, which are
described in detail in Fig. 1.
A. Data Collection
The dataset used in this research is the same as the research
[6]. There are 240 images, which are divided into 20 classes,
namely, ha na ca ra ka da ta sa wa la pa dha ja ya nya, sample
data can be seen in Fig. 2. All images are images with the
extension png, with a size of 200×120 pixels. The image is a
scanned handwritten Javanese script.
Fig. 1. Proposed Method
Fig. 2. Sample image dataset
B. Preprocessing and Feature Extraction
Preprocessing performed on an image is carried out with
two kinds of treatment as depicted in Fig. 1. The RGB input
image is converted to grayscale, then two different processes
are carried out for two feature extractions. To extract the
metric and eccentricity features, conversion is done to a binary
image, complement image, median filter, and image dilation.
To get the metric features, the area and perimeter values
obtained from the regionprops function are used. The
eccentricity feature can be directly generated by the
Image input
RGB to grayscale
Convert to
binary image
Complement
image
Median Filter
Dilation
Contrast
enhancement
LBP feature
extraction
Metric and
Eccentricity feature
KNN Training
KNN Testing
Evaluation
2021 International Seminar on Application for Technology of Information and Communication (iSemantic)
119
regionprops function. LBP feature extraction is done by
increasing contrast with the imadjust function. Next is the
calculation of the LBP feature with a cell size of 64.
C. Classification and Evaluation
Classification is carried out using KNN, which is carried
out by training and testing processes. Prada training process
used 200 images, while the testing process used 40 images.
Evaluation is done by measuring accuracy, recall, and
precision.
IV. I
MPLEMENTATION AND
R
ESULTS
Following the proposed method, each handwritten image
of the Javanese script is read and converted to grayscale. The
conversion process is carried out so that the computation
becomes simpler. This is also because the LBP feature
extraction is performed on grayscale images, while the metric
and eccentricity feature on binary images. To obtain the metric
and eccentricity features, the grayscale image is converted into
a binary image as presented in Fig. 3. How to convert
grayscale to a binary image using im2bw function with
parameter 0.9. Furthermore, the binary image is converted to
a negative image, the goal is that the background is black and
the object is white. The median filter is carried out with the
medfilt2 function, its function is to reduce noise. Image noise
needs to be reduced so that the metric and eccentricity
measurements are more accurate. The last step before feature
extraction is to dilate objects with a size of 3×3 pixels.
The metric and eccentricity features are extracted by
utilizing the regionprops function with the area, perimeter, and
eccentricity properties. The feature metric is calculated by Eq.
1. While the eccentricity feature can directly use the
regionprops function property
Fig. 3. Sample preprocessing to get metric and eccentricity features
Fig. 4. Illustration of LBP calculation by dividing the grayscale image into
64×64 cell sizes
4
(1)
LBP feature extraction was performed on grayscale
images with 64×64 cell sizes as illustrated in Fig. 4. After the
LBP, metric, and eccentricity features have been extracted, the
extraction results can then be measured using a confusion
matrix to get accuracy, precision, and recall which can be
calculated with Eq. 2, Eq. 3, and Eq. 4. Detailed image
recognition results are presented in Table 1.
100%
(2)
100%
(3)
100%
(4)
Where TP is true positive, FP is false positive, TN is a true
negative, and FP is a false positive.
TABLE I. R
ECOGNITION
R
ESULTS
Character/
Class TP TN FP FN
Ha 2 0 0 0
Na 2 0 0 0
Ca 2 0 0 0
Ra 2 0 0 0
Ka 2 0 0 0
Da 2 0 0 0
Ta 1 0 0 1
Sa 2 0 0 0
Wa 1 0 0 1
La 2 0 0 0
Ma 1 0 0 1
Ga 2 0 0 0
Ba 2 0 0 0
Tha 2 0 0 0
Nga 2 0 0 0
Pa 2 0 0 0
Dha 2 0 0 0
Ja 2 0 0 0
Ya 2 0 0 0
Nya 2 0 0 0
Sum 37 0 0 3
Ta
Ha
Fig. 5. Sample of recognition error on one of the Javanese Script characters
Grayscale Image
Binary Image
Negative Image
After median filter
After dilation
2021 International Seminar on Application for Technology of Information and Communication (iSemantic)
120
TABLE II. COMPARISON WITH EXISTING METHOD
Method Accuracy Recall Precision
Sari et. al. [6] 87.5% 87.5% 100%
Partiningsih et. al. [14] 90.0% 90.0% 100%
Proposed Method 92.5% 92.5% 100%
Based on the recognition results presented in Table 1, an
accuracy value of 92.5% can be calculated for accuracy and
recall, while the precision is 100%. It should be noted that the
recognition results presented in Table 1 are the best accuracy
results with a value of K=3. Several errors occur in writing
that are quite similar when viewed visually by humans, for
example in the character "ta" it is detected as the character
"ha" (see Fig. 5), this is possible due to the quality of
handwriting which tends to be poor and inconsistent. Writing
the character “ta” should have a sharper angle in one of the
sections as shown in Fig. 2. This shows that this method
actually has a very good performance, due to recognition
errors due to poor writing quality, and this is also normal and
can happen to humans.
Furthermore, this research was also tested by doing a
comparison with previous research by replicating the same
method and dataset, which used 200 training data and 40
testing data where the results presented were the best K values.
The results of the comparison of the proposed methods are
presented in Table 2. Based on the comparative results
presented in Table 2, it appears that the proposed method has
succeeded in obtaining higher accuracy and recall than
previous research. The combination of the three features is
proven to improve recognition performance.
V. CONCLUSIONS
This research proposes a recognition method that
combines several extraction features, namely metric,
eccentricity, and LBP. Classification is done with the KNN
classifier on the Javanese script handwritten image. Based on
the experimental results, the proposed method can improve
recognition performance which is 92.5% accuracy. These
results can be better than the previous two methods, i.e. 87.5%
and 90.0%. This proves that handwriting recognition is
suitable for using shape and pattern features. For further
research, feature extraction can be combined with deep
learning methods such as deep neural networks or combine
feature extraction with convolution neural networks to
improve recognition performance. In addition, it can also be
tested on datasets with more records and the number of
classes.
ACKNOWLEDGMENT
Authors are grateful for the support for research funding
in 2021 provided by the Ministry of Research and Technology
/ National Research and Innovation Agency of Indonesia with
number 6/061031/PG/SP2H/JT/2021.
REFERENCES
[1] A. Khalil, M. Jarrah, M. Al-Ayyoub, and Y. Jararweh, “Text detection
and script identification in natural scene images using deep learning,”
Comput. Electr. Eng., vol. 91, p. 107043, May 2021.
[2] H. W. Herwanto, A. N. Handayani, K. L. Chandrika, and A. P.
Wibawa, “Zoning Feature Extraction for Handwritten Javanese
Character Recognition,” in ICEEIE 2019 - International Conference
on Electrical, Electronics and Information Engineering: Emerging
Innovative Technology for Sustainable Future, 2019, pp. 264–268.
[3] F. Damayanti, Y. K. Suprapto, and E. M. Yuniarno, “Segmentation of
Javanese Character in Ancient Manuscript using Connected
Component Labeling,” in CENIM 2020 - Proceeding: International
Conference on Computer Engineering, Network, and Intelligent
Multimedia 2020, 2020, pp. 412–417.
[4] G. Abdul Robby, A. Tandra, I. Susanto, J. Harefa, and A. Chowanda,
“Implementation of optical character recognition using tesseract with
the Javanese script target in android application,” in Procedia
Computer Science, 2019, vol. 157, pp. 499–505.
[5] L. L. Zhangrila, “Accuracy Level of $p Algorithm for Javanese Script
Detection on Android-Based Application,” in Procedia Computer
Science, 2018, vol. 135, pp. 416–424.
[6] C. A. Sari, M. W. Kuncoro, D. R. I. M. Setiadi, and E. H.
Rachmawanto, “Roundness and eccentricity feature extraction for
Javanese handwritten character recognition based on K-nearest
neighbor,” in 2018 International Seminar on Research of Information
Technology and Intelligent Systems, ISRITI 2018, 2018, pp. 5–10.
[7] A. Nursetyo and D. R. I. M. Setiadi, “LatAksLate: Javanese script
translator based on Indonesian speech recognition using sphinx-4 and
google API,” in 2018 International Seminar on Research of
Information Technology and Intelligent Systems, ISRITI 2018, 2018,
pp. 17–22.
[8] A. R. Widiarti, A. Harjoko, Marsono, and S. Hartati, “The model and
implementation of Javanese script image transliteration,” in
Proceedings - 2017 International Conference on Soft Computing,
Intelligent System and Information Technology: Building Intelligence
Through IOT and Big Data, ICSIIT 2017, 2017, vol. 2018-Janua, pp.
51–57.
[9] A. R. Widiarti and R. Pulungan, “A method for solving scriptio
continua in Javanese manuscript transliteration,” Heliyon, vol. 6, no.
4, p. e03827, Apr. 2020.
[10] K. M. Babu and M. V. Raghunadh, “Vehicle number plate detection
and recognition using bounding box method,” in Proceedings of 2016
International Conference on Advanced Communication Control and
Computing Technologies, ICACCCT 2016, 2017, pp. 106–110.
[11] G. Guo, H. Wang, C. Shen, Y. Yan, and H. Y. M. Liao, “Automatic
Image Cropping for Visual Aesthetic Enhancement Using Deep
Neural Networks and Cascaded Regression,” IEEE Trans. Multimed.,
vol. 20, no. 8, pp. 2073–2085, Aug. 2018.
[12] W. Wang, J. Shen, and H. Ling, “A Deep Network Solution for
Attention and Aesthetics Aware Photo Cropping,” IEEE Trans.
Pattern Anal. Mach. Intell., vol. 41, no. 7, pp. 1531–1544, Jul. 2019.
[13] W. Wang and J. Shen, “Deep Cropping via Attention Box Prediction
and Aesthetics Assessment,” in Proceedings of the IEEE International
Conference on Computer Vision, 2017, vol. 2017-October, pp. 2205–
2213.
[14] N. D. A. Partiningsih, R. R. Fratama, C. A. Sari, D. R. I. M. Setiadi,
and E. H. Rachmawanto, “Handwriting Ownership Recognition using
Contrast Enhancement and LBP Feature Extraction based on KNN,”
in International Conference on Information Technology, Computer,
and Electrical Engineering, 2018, pp. 342–346.
2021 International Seminar on Application for Technology of Information and Communication (iSemantic)
121