This is a preview and has not been published.

Classification of Arabic Alphabets Using a Combination of a Convolutional Neural Network and the Morphological Gradient Method


  • Mouhssine EL ATILLAH Computer science, Signals, Automation and Cognitivism laboratory (LISAC), FSDM, USMBA, Fes, Morocco";}
  • Khalid EL FAZAZY Computer Science, Signals, Automation and Cognitivism Laboratory (LISAC), FSDM, USMBA, Fes, Morocco
  • Jamal Riffi Computer Science, Signals, Automation and Cognitivism Laboratory (LISAC), FSDM, USMBA, Fes, Morocco



Handwritten Arabic characters, Deep learning, Morphological gradient, Convolutional neural network, Optical character recognition


The field of Optical Character Recognition (OCR) is the process of converting an image of text into a machine-readable text format. The classification of Arabic manuscripts in general is part of this field. In recent years, the processing of Arabian image databases by deep learning architectures has experienced a remarkable development. However, this remains insufficient to satisfy the enormous wealth of Arabic manuscripts. In this research, a deep learning architecture is used to address the issue of classifying Arabic letters written by hand. The method based on a convolutional neural network (CNN) architecture as a self-extractor and classifier. Considering the nature of the dataset images (binary images), the contours of the alphabets are detected using the mathematical algorithm of the morphological gradient. After that, the images are passed to the CNN architecture. The available database of Arabic handwritten alphabets on Kaggle is utilized for examining the model. This database consists of 16,800 images divided into two datasets: 13,440 images for training and 3,360 for validation. As a result, the model gives a remarkable accuracy equal to 99.02%.


Download data is not yet available.


Singh H, Sharma RK, Singh VP. Online handwriting recognition systems for Indic and non-Indic scripts: a review. Artif Intell Rev. 2021; 54: 1525–1579.

Ríos-Vila A, Esplà-Gomis M, Rizo D, Ponce de León PJ, Iñesta JM. Applying Automatic Translation for Optical Music Recognition’s Encoding Step. Appl Sci. 2021; 11(9): 3890. .

USHIODA E. The Impact of Global English on Motivation to Learn Other Languages: Toward an Ideal Multilingual Self. Mod Lang J. 2017; 101: 469-482. .

IPAC Team. Quelles sont les 10 langues les plus parlees au monde. IPAC . 2018 Jun. .

Andrea Z. Developing a Heritage Database for the Middle East and North Africa. J Field Archaeol. 2018; 43:sup1 S9-S18.

Chaabane S, Chaabna K, Abraham A, Mamtani R, Cheema S. Physical activity and sedentary behaviour in the Middle East and North Africa: An overview of systematic reviews and meta-analysis. Sci Rep 10. 2020; 9363. .

Abdalkafor AS. Survey for Databases on Arabic Off-line Handwritten Characters Recognition System. In 2018 1st International Conference on Computer Applications & Information Security (ICCAIS). 2018; 1-6. .

A AL-Saffar, S Awang, W Al-Saiagh, S Tiun, A S Al-khaleefa. Deep learning algorithms for arabic handwriting recognition. IJET (UAE) . 2018; 7: 344-353. .

Dargan S, Kumar M. Gender Classification and Writer Identification System based on Handwriting in Gurumukhi Script. Int Conf comp commun intell Syst. 2021; 388-393. .

AL-Shareeda M, Manickam S, Saare M. DDoS attacks detection using machine learning and deep learning techniques: analysis and comparison. Bull Electr Eng Inform. 2023; 12(2): 930-939.

Al-Mekhlafi Z G, Al-Shareeda M A, Manickam S, Mohammed B A, Qtaish A. Lattice-Based Lightweight Quantum Resistant Scheme in 5G-Enabled Vehicular Networks. Mathematics. 2023; 11(399). .

Mahmood A, Al-Shareeda M, Selvakumar M, Murtaja Ali, Navaneethan C A. Proposed security mechanism for preventing fake router advertisement attack in IPv6 link-local network. Indones. J Electr Eng Comput. 2023; 518-526. .

Loey Mohamed. Arabic Handwritten Characters Dataset. Kaggle. 2017 jun. .

El-Sawy A, Loey M, El-Bakry H. Arabic handwritten characters recognition using convolutional neural network. WSEAS Trans Comput. 2017 [cited 2022 Oct. 23]; 5(1): 11-19.

Younis K S. Arabic handwritten caracter recoghition based on deep convolutional neural networks. Jordanian J Comput Inf Technol. 2017; 3(3): 186. .

Alani Ali A. Arabic Handwritten Digit Recognition Based on Restricted Boltzmann Machine and Convolutional Neural Networks. Information. 2017; 8(4): 142.

Asroni A, Ku-Mahamud KR, Damarjati C, Slamat HB. Arabic Speech Classification Method Based on Padding and Deep Learning Neural Network. Baghdad Sci J. 2021 Jun. 20 ;18(2(Suppl.): 0925.

David Sh, Sebastien L, Jonathan W. La morphologie mathematique binaire pour l’extraction automatique des b atiments dans les images THRS. Revue internationale de Géomatique. 2007; 17(3-4): 333-352.

El Atillah M, El fazazy K. Deep Morphological Gradient for Recognition of Handwritten Digits. Association for Computing Machinery. BDIoT'19: Proc 4th Int Conf Big Data Int Things. 2019.

Thakare A, Gondane S, Prasad N, Chigale S. A Machine Learning-Based Approach to Password Authentication Using Keystroke Biometrics. Deep Learning and Computational Intelligence for Wireless Communication. Lecture Notes in Electrical Engineering Machine Learning. Singapore. 2022; 749.

Siddiqui N, Dave R, Vanamala M, Seliya N. Machine and Deep Learning Applications to Mouse Dynamics for Continuous User Authentication. Mach Learn Knowl Extr. 2022; 4(2): 502-518. .

Gholamalinezhad H, Khosravi H, S L. Pooling Methods in Deep Neural Networks, a Review CoRR . 2020 arXiv:2009.07485. .

Nagi J, Ducatelle F, Di Caro G A, Cireşan D, Meier U, Giusti A, et al. Max-pooling convolutional neural networks for vision-based hand gesture recognition. IEEE Int Conf Signal Image Processing Appl. 2011; 342-347. .

Basha S S, Dubey S R, Pulabaigari V, Mukherjee S. Impact of fully connected layers on performance of convolutional neural networks for image classification. Neurocomputing. 2020; 378: 112-119.

Al-Shareeda M A, Manickam S, Laghari S A, Jaisan A. Replay-Attack Detection and Prevention Mechanism in Industry 4.0 Landscape for Secure SECS/GEM Communications. Sustainability. 2022; 14(23): 15900. .

Al-Shareeda M A, Manickam S. COVID-19 Vehicle Based on an Efficient Mutual Authentication Scheme for 5G-Enabled Vehicular Fog Computing. Int J Environ Res Public Health. 2022; 19(23): 15618. .

Hussien Z, Dhannoon Ban. Anomaly Detection Approach Based on Deep Neural Network and Dropout. Baghdad Sci J . 2020 Jun. 23; 17(2) : 0701.