Journals / Tekirdağ Ziraat Fakültesi Dergisi / 2026 / Cilt: 23 Sayı: 5

Classification of Pistachio Varieties Using Transfer Learning and a Custom MobileNet Architecture

Transfer Öğrenme Yaklaşımı ve Özel Tasarlanmış MobileNet Mimarisi Kullanılarak Antep Fıstığı Çeşitlerinin Sınıflandırılması

Y. Benal Öztekin(ONDOKUZ MAYIS ÜNİVERSİTESİ)0000-0003-2387-2322
Omsalma Alsadig Adam Gadalla(ONDOKUZ MAYIS ÜNİVERSİTESİ)0000-0001-6132-4672
Geofrey Prudence Baitu(ONDOKUZ MAYIS ÜNİVERSİTESİ)0000-0002-3243-3252
Pages
1726–1739
Publication Date
2026-10-01
🏛️Bibliographic metadata and full text access for this article are provided via DergiPark.
DergiPark Record ↗
✨

AI Summary & Key Takeaways

AI Insight
⚡ TL;DR(Too Long; Didn't Read)

Such limitations negatively affect sorting accuracy, packaging efficiency, and overall product value.

📌 3 Key Takeaways

🎯
Objective & Hypothesis:Pistachio nuts are widely recognized as one of the most valuable agricultural commodities, playing a significant role in both domestic and international markets.
📊
Key Findings & Data:Experimental results demonstrate that the custom MobileNet model outperforms well-known pre-trained architectures, including VGG16, Inception-V3, and the original MobileNet, in terms of both accuracy and efficiency.
💡
Conclusion & Impact:Such limitations negatively affect sorting accuracy, packaging efficiency, and overall product value.
🔬Design:Modeling & Simulation
📍Scope:Comprehensive Sample
⚙️Variables:Tarımsal emtialar · Yenilikçi teknolojiler · Otomatik sınıflandırma

Abstract

Pistachio nuts are widely recognized as one of the most valuable agricultural commodities, playing a significant role in both domestic and international markets. Turkey cultivates eight main domestic pistachio varieties in addition to five foreign varieties, each targeting different consumer preferences, market demands, and price segments. Despite this diversity, the current classification process in the pistachio industry largely depends on manual inspection and basic experiential knowledge. This traditional approach is time-consuming and highly susceptible to misclassification due to the strong visual similarities among different pistachio varieties. Such limitations negatively affect sorting accuracy, packaging efficiency, and overall product value. To overcome these challenges and support the transition toward smart agricultural practices, this study proposes an efficient deep learning-based classification system for pistachio varieties. A customized MobileNet architecture is developed to classify seven pistachio varieties with high accuracy while maintaining low computational complexity. The proposed model is specifically designed to address the shortcomings of conventional pre-trained models when applied to fine-grained agricultural image classification tasks. Experimental results demonstrate that the custom MobileNet model outperforms well-known pre-trained architectures, including VGG16, Inception-V3, and the original MobileNet, in terms of both accuracy and efficiency. The proposed model achieves a test accuracy of 98.09%, representing an improvement of 1.66% over the standard pre-trained MobileNet model. Moreover, the number of model parameters is reduced by approximately 79%, resulting in a compact model size of 12.82 MB. This significant reduction lowers computational and storage requirements, shortens training time, and facilitates real-time deployment. Consequently, the proposed approach is highly suitable for implementation on low-computing-power smart farming and automated packaging systems, offering a practical and scalable solution for the pistachio industry.

Özet

Antep fıstığı, hem ulusal hem de uluslararası pazarlarda önemli bir rol oynayan, en değerli tarımsal ürünlerden biri olarak geniş çapta kabul edilmektedir. Türkiye, sekiz ana yerli Antep fıstığı çeşidine ek olarak beş yabancı çeşidi de yetiştirmekte olup, bu çeşitlerin her biri farklı tüketici tercihlerini, pazar taleplerini ve fiyat segmentlerini hedeflemektedir. Bu çeşitliliğe rağmen, Antep fıstığı endüstrisinde mevcut sınıflandırma süreci büyük ölçüde manuel incelemeye ve temel deneyimsel bilgiye dayanmaktadır. Bu geleneksel yaklaşım, farklı Antep fıstığı çeşitleri arasındaki güçlü görsel benzerlikler nedeniyle zaman alıcı olmakta ve yanlış sınıflandırmaya son derece açık hale gelmektedir. Bu tür sınırlılıklar, ayıklama doğruluğunu, paketleme verimliliğini ve genel ürün değerini olumsuz yönde etkilemektedir. Bu zorlukların üstesinden gelmek ve akıllı tarım uygulamalarına geçişi desteklemek amacıyla, bu çalışmada Antep fıstığı çeşitlerinin sınıflandırılmasına yönelik verimli bir derin öğrenme tabanlı sınıflandırma sistemi önerilmektedir. Düşük hesaplama karmaşıklığını korurken yedi farklı Antep fıstığı çeşidini yüksek doğrulukla sınıflandırmak üzere özelleştirilmiş bir MobileNet mimarisi geliştirilmiştir. Önerilen model, ince taneli tarımsal görüntü sınıflandırma görevlerinde geleneksel önceden eğitilmiş modellerin yetersizliklerini gidermek amacıyla özel olarak tasarlanmıştır. Deneysel sonuçlar, geliştirilen özel MobileNet modelinin doğruluk ve verimlilik açısından VGG16, Inception-V3 ve orijinal MobileNet dâhil olmak üzere yaygın olarak kullanılan önceden eğitilmiş mimarilerden daha üstün performans sergilediğini göstermektedir. Önerilen model, test aşamasında %98,09 doğruluk oranına ulaşarak standart önceden eğitilmiş MobileNet modeline kıyasla %1,66’lık bir iyileşme sağlamıştır. Ayrıca, model parametre sayısı yaklaşık %79 oranında azaltılarak 12,82 MB boyutunda kompakt bir yapı elde edilmiştir. Bu önemli küçülme, hesaplama ve depolama gereksinimlerini azaltmış, eğitim süresini kısaltmış ve gerçek zamanlı uygulamaları mümkün kılmıştır. Sonuç olarak, önerilen yaklaşım düşük hesaplama gücüne sahip akıllı tarım ve otomatik paketleme sistemlerinde uygulanabilir, pratik ve ölçeklenebilir bir çözüm sunmaktadır.

🔖

Cite This Article

Idress, K. A. D., Öztekin, Y. B., Gadalla, O. A. A., Eissa, M. O. S., Baitu, G. P. (2026). Classification of Pistachio Varieties Using Transfer Learning and a Custom MobileNet Architecture. Tekirdağ Ziraat Fakültesi Dergisi, Cilt: 23 Sayı: 5, 1726–1739. https://doi.org/10.33462/jotaf.1856718

📄 Full Text PDF Viewer

📄

PDF görüntüleyici hazırlanıyor...

References (21)

  1. Ak, B. E. and Acar, I. (2001). Pistachio production and cultivated varieties grown in Turkey. Project on Underutilized Mediterranean Species. Pistacia: Towards a Comprehensive Documentation of Distribution and Use of Its Genetic Diversity in Central and West Asia, North Africa and Mediterranean Europe. Report of the IPGRI Workshop, 14–17 December 1998, Irbid, Jordan.
  2. Aktaş, H., Kızıldeniz, T. and Ünal, Z. (2022). Classification of pistachios with deep learning and assessing the effect of various datasets on accuracy. Journal of Food Measurement and Characterization, 16(3): 1983–1996.
  3. Ataş, M. and Doğan, Y. (2015). Classification of Closed and Open Shell Pistachio Nuts by Machine Vision. International Conference on Advanced Technology Sciences, 280–284, Antalya, Türkiye.
  4. Beyaz, A. (2024). Low-cost classification of close and open shell Antep pistachio nuts based on image analysis and machine learning. Yuzuncu Yıl University Journal of Agricultural Sciences, 34(1): 87–105.
  5. Dini, A., Zadeh, H. G., Rahimifard, A., Fayazi, A., Eftekhari, M. and Abbaszadeh, M. (2020). Designing a hardware system to separate defective pistachios from healthy ones using deep neural networks. Iranian Journal of Biosystems Engineering, 51: 149–159.
  6. Farazi, M., Abbas-Zadeh, M. J. and Moradi, H. (2017). A Machine Vision Based Pistachio Sorting Using Transferred Mid-Level Image Representation of Convolutional Neural Network. 10th Iranian Conference on Machine Vision and Image Processing (MVIP), 22–23 November, Isfahan, Iran.
  7. Gerdan, D., Koç, C. and Vatandaş, M. (2023). Diagnosis of tomato plant diseases using pre-trained architectures and a proposed convolutional neural network model. Journal of Agricultural Sciences, 29(2): 618–629.
  8. Gulli, A., Kapoor, A. and Pal, S. (2019). Deep Learning with TensorFlow 2 and Keras: Regression, ConvNets, GANs, RNNs, NLP, and More with TensorFlow 2 and the Keras API. Packt Publishing Ltd., Birmingham, U. K.
  9. Hosseinpour-Zarnaq, M., Omid, M., Taheri-Garavand, A., Nasiri, A. and Mahmoudi, A. (2022). Acoustic signal-based deep learning approach for smart sorting of pistachio nuts. Postharvest Biology and Technology, 185: 111778. https://doi.org/10.1016/j.postharvbio.2021.111778
  10. Hossin, M. and Sulaiman, M. N. (2015). A review on evaluation metrics for data classification evaluations. International Journal of Data Mining & Knowledge Management Process, 5(2): 1–11.
  11. Idress, K. A. D., Öztekin, Y. B. and Gadalla, O. A. A. (2024). Classification of open and closed pistachio shells using machine vision approach. Journal of Tekirdag Agricultural Faculty, 21(4): 854–864.
  12. Idress, K. A. D., Öztekin, Y. B., Gadalla, O. A. A. and Baitu, G. P. (2023). Classification of Pistachio Varieties Using Pre-Trained Architectures and a Proposed Convolutional Neural Network Model. 15th International Congress on Agricultural Mechanization and Energy in Agriculture (ANKAgEng’2023), 29.10-01.11, Antalya, Türkiye.
  13. Kassem, H., El Hajjar, S., Abdallah, F. and Omrani, H. (2025). Multi-view deep embedded clustering: Exploring a new dimension of air pollution. Engineering Applications of Artificial Intelligence, 139: 109509.https://doi.org/10.1016/j.engappai.2024.109509
  14. Lisda, L., Kusrini, K. and Ariatmanto, D. (2023). Classification of pistachio nut using convolutional neural network. Inform: Jurnal Ilmiah Bidang Teknologi Informasi dan Komunikasi, 8(1): 71–77.
  15. Omid, M. (2011). Design of an expert system for sorting pistachio nuts through decision tree and fuzzy logic classifier. Expert Systems with Applications, 38(4): 4339–4347.https://doi.org/10.1016/j.eswa.2010.09.103
  16. Ozkan, I. A., Koklu, M. and Saraçoğlu, R. (2021). Classification of pistachio species using improved k-NN classifier. Progress in Nutrition, 23: e2021044.https://doi.org/10.23751/pn.v23i2.9686
  17. Rahimzadeh, M. and Attar, A. (2022). Detecting and counting pistachios based on deep learning. Iran Journal of Computer Science, 5(1): 69–81.
  18. Simonyan, K. and Zisserman, A. (2015). Very Deep Convolutional Networks for Large-Scale Image Recognition. International Conference on Learning Representations (ICLR), 07-09 May, San Diego, CA, U. S. A.
  19. Singh, D., Taspinar, Y. S., Kursun, R., Cinar, I., Koklu, M., Ozkan, I. A. and Lee, H.-N. (2022). Classification and analysis of pistachio species with pre-trained deep learning models. Electronics, 11(7): 981.https://doi.org/10.3390/electronics11070981
  20. Soleimanipour, A., Azadbakht, M. and Rezaei Asl, A. (2022). Cultivar identification of pistachio nuts in bulk mode through EfficientNet deep learning model. Journal of Food Measurement and Characterization, 16(4): 2545–2555.
  21. Yaghoubi, M. and Niknami, M. (2022). Challenges of precision agriculture application in pistachio orchards: Factor analysis from Iranian agricultural experts' perspective. Journal of Tekirdag Agricultural Faculty, 19(3): 473–482.