Comparison of Support Vector Machine and Naïve Bayes Algorithms on Date Fruit Type Classification based on Hue Saturation Value Image

Mia Risa Br. Keliat, Muhammad Ikhsan

Abstract


Dates are a popular fruit in Indonesia, especially during the month of Ramadan. With the increase in consumption, an automated system is needed to classify different types of dates to avoid misidentification. This study compares two classification algorithms: Support Vector Machine (SVM) and Naïve Bayes. The research compares the performance of the Support Vector Machine (SVM) and Gaussian Naïve Bayes algorithms in classifying date fruits based on Hue, Saturation, Value (HSV) images. The dataset consists of 200 images of dates from four types: Ajwa Dates, Sukari Dates, Golden Valley Dates, and Deglet Nour Dates, with a 70% training data and 30% testing data split. The images were captured using a high-resolution smartphone camera under controlled lighting conditions to ensure consistent image quality. The segmentation process includes converting from RGB (original), grayscale, binary, complement operation, filling holes, and conversion to the HSV color space. MATLAB tools were used to implement the algorithms and evaluate model performance. The results show that Gaussian Naïve Bayes outperforms the SVM with a higher accuracy of 80.00%, precision of 79.74%, recall of 78.46%, and F1-score of 79.09%. In contrast, the SVM with a linear kernel only achieved an accuracy of 66.67%, precision of 52.49%, recall of 65.00%, and F1-score of 58.08%. Evaluation showed that neither model suffered from overfitting. Based on the GUI analysis, Naïve Bayes proved superior in classifying the types of dates. This study makes a significant contribution to the development of an automated image-based system for classifying agricultural products.

Keywords


Ilmu Komputer

Full Text:

PDF

References


M. Giamouzi, “City , University of London Institutional Repository,” vol. 34, no. 2019, pp. 51–79, 2008, doi: 10.1007/978-3-030-69717-4.

M. Fandi, “Aplikasi Identifikasi Jenis Buah Kurma dengan Metode GLCM Berbasis Android,” J. Pengemb. Rekayasa dan Teknol., vol. 16, no. 1, p. 34, 2020, doi: 10.26623/jprt.v16i1.2109.

R. Risna, F. Amanda, and S. Uyun, “Comparison of K-Nearest Neighbor (KNN) and Linear Discriminant Analysis (LDA) Algorithms for Mature Ajwa Date Fruit Classification,” Int. Conf. Inf. Sci. Technol. Innov., vol. 2, no. 1, pp. 11–16, 2023, doi: 10.35842/icostec.v2i1.29.

M. H. S. Ajat, “Klasifikasi SMS Spam dengan Komparasi Metode SVM dan Naïve Bayes,” Method. J. Tek. Inform. dan Sist. Inf., vol. 9, no. 1, pp. 31–34, 2023, doi: 10.46880/mtk.v9i1.1694.

R. Fazal, “Membandingkan Support Vector Machines dan Naive Bayes pada Analisis Sentimen Data Twitter,” J. Portal Data, vol. 2, no. 10, pp. 1–9, 2022, [Online]. Available: http://portaldata.org/index.php/portaldata/article/view/248%0Ahttp://portaldata.org/index.php/portaldata/article/download/248/218

Ellif, S. H. Sitorus, and R. Hidayati, “Naïve Bayes 1.,” Coding J. Komput. dan Apl., vol. 09, no. 01, pp. 66–75, 2021.

A. A. Muhammad, A. Arkadia, S. NaufalRifqi, Trianto, and D. S. Prasvita, “Klasifikasi Tingkat Kematangan Buah Pisang berdasarkan Fitur Warna dengan Metode SVM,” J. Ilmu Komput. dan Desain Komun. Vis., vol. 4, no. 1, pp. 9–16, 2019.

K. Ayuningsih, Y. A. Sari, and P. P. Adikara, “Klasifikasi Citra Makanan menggunakan HSV Color Moment dan LBP dengan Naïve Bayes Classifier,” J. Pengemb. Teknol. Informasii dan Ilmu Komputier Univ. Brawijaya, vol. 3, no. 4, pp. 3166–3173, 2019.

Milda, D. M. Sari, and M. Rafli, “Klasifikasi Kematangan Buah Pisang Kepok berdasarkan Citra HSV dengan K-Nearest Neighbors,” Pros. Semin. Nas. Rekayasa Keteknikan Inform. (SENARAI 2023), vol. 1, no. 1, pp. 1–11, 2023.

M. Afriansyah, J. Saputra, Y. Sa’adati, and V. Yoga P. Ardhana, “Optimasi Algoritma Naïve Bayes untuk Klasifikasi Buah Apel berdasarkan Fitur Warna RGB,” Bull. Comput. Sci. Res., vol. 3, no. 3, pp. 242–249, 2023, doi: 10.47065/bulletincsr.v3i3.251.

M. R. Saputra and H. Irsyad, “Klasifikasi Tingkat Kemanisan Alpukat berdasarkan Fitur Hue Saturation Value (HSV) dengan menggunakan Support Vector Machine (SVM),” J. Algoritm., vol. 2, no. 2, pp. 113–119, 2022, doi: 10.35957/algoritme.v2i2.2361.

J. Sisfotenika, “Implementasi Support Vector Machine ( SVM ) pada Klasifikasi Jenis Tanah memanfaatkan Fitur RGB Implementation of SVM in Soil Type Classification using RGB Features,” vol. 14, no. 2, pp. 175–184, 2024.

M. Afriansyah, J. Saputra, V. Y. P. Ardhana, and Yuan Sa’adati, “Algoritma Naive Bayes yang Efisien untuk Klasifikasi Buah Pisang Raja berdasarkan Fitur Warna,” J. Inf. Syst. Manag. Digit. Bus., vol. 1, no. 2, pp. 236–248, 2024, doi: 10.59407/jismdb.v1i2.438.

R. Rachman and R. N. Handayani, “Klasifikasi Algoritma Naive Bayes dalam memprediksi Tingkat Kelancaran Pembayaran Sewa Teras UMKM,” J. Inform., vol. 8, no. 2, pp. 111–122, 2021, doi: 10.31294/ji.v8i2.10494.

T. Widyanto, I. Ristiana, and A. Wibowo, “Komparasi Naïve Bayes dan SVM Analisis Sentimen RUU Kesehatan di Twitter,” SINTECH (Science Inf. Technol. J., vol. 6, no. 3, pp. 147–161, 2023, doi: 10.31598/sintechjournal.v6i3.1433.




DOI: https://doi.org/10.32520/stmsi.v14i1.4978

Article Metrics

Abstract view : 21 times
PDF - 11 times

Refbacks

  • There are currently no refbacks.


Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.