Analisis Perbandingan CNN dan Vision Transformer untuk Klasifikasi Biji Kopi Hasil Sangrai - Leonardi, M. Anjas; Chandra, Albert Yakobus (Universitas Budi Darma, 2024)
Coffee is a globally cherished beverage, popular among various segments of society, including in Indonesia. The coffee processing procedure plays a pivotal role in determining the taste and final quality of the beverage. One crucial stage in this process is selecting the maturity level of coffee beans after the roasting process. However, determining this maturity level often faces challenges, particularly in large-scale processing contexts. This research focuses on evaluating two main approaches in classifying the maturity level of roasted coffee beans: Convolutional Neural Network (CNN) and Vision Transformer (ViT). The main issue encountered is the lack of studies comparing the effectiveness of these two methods in the context of coffee bean classification. Therefore, this study aims to fill this knowledge gap and provide better insights into which method is more suitable for this purpose. In this study, two CNN models, namely Xception and InceptionV3, as well as one ViT model, ViT-B16, are utilized. The dataset includes images of roasted coffee beans, raw coffee beans, and non-coffee bean images, with image sizes of 224 x 224 pixels. A comparison analysis is conducted based on classification accuracy and the ability of each model to capture characteristic features in coffee bean images. The experimental results show that the ViT-B16 model outperforms both CNN models with an accuracy of 99.33%, while the Xception and InceptionV3 models achieve accuracies of 96.67% and 96.00%, respectively. ViT-B16 demonstrates better capability in capturing global features in images, while CNN is more effective in detecting local features. However, both approaches face some challenges, including computational requirements and training time. In conclusion, although both methods have their own advantages, ViT-B16 offers significant potential for more accurate and efficient classification systems for images of roasted coffee beans. This research provides a crucial contribution to the development of coffee bean classification technology, which can enhance efficiency and consistency in the coffee processing industry.