Skip to main content
Log in

Traditional Machine Learning and Deep Learning Modeling for Legume Species Recognition

  • Original Research
  • Published:
SN Computer Science Aims and scope Submit manuscript

Abstract

Legumes or beans are protein-rich vegetables that are cultivated in many parts of the world. More than fifty local legume varieties are available in Bangladesh, where all these legumes do not have the same level of nutrition and taste. In this paper, classic machine learning and deep learning techniques are used to develop a machine learning model for legume species recognition. After discussing with some researchers of Bangladesh Agricultural Research Institute (BARI) about the essential factors of legume species, we start collecting data from BARI, local markets, legume fields, and the Internet. After the completion of data collection, image preprocessing, i.e. resizing and augmentation takes place. Then the images are segmented out and some features are extracted to be fed to traditional machine learning models. To categorize the legume species, three classic machine learning models, k-nearest neighbors, support vector machines, and decision trees, and three deep learning, i.e. convolutional neural network models, VGG-16, Inception-v3, and ResNet-50, are utilized. The corresponding parameters of each of these models are tuned to reach the optimum configured model. The performances of each of these models are evaluated using six noteworthy performance metrics. Inception-v3 outflanks all other models not only exhibiting an accuracy of about 98.6% but also providing the best results in terms of the rest five indicative performance metrics.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6

Similar content being viewed by others

References

  1. Representative, Gazipur, New varieties of desi bean. (2021). [Online]. Available: https://www.prothomalo.com/bangladesh/district/দেশি-শিমের-নতুন-জাত

  2. Ais.gov.bd. 2022. কৃষি তথ্য সার্ভিস (এআইএস). (2021) [Online]. Available: http://www.ais.gov.bd/site/ekrishi/4498ff78-53bb-468a-acc1-01780e56f3a3/শিম

  3. Mayo Clinic Staff, Mixed bean salad. 2021. [Online] Available: https://www.mayoclinic.org/healthy-lifestyle/recipes/mixed-bean-salad/rcp-20049682.

  4. Mayo clinic staff, nutrition and healthy eating. 2021. [Online]. Available: https://www.mayoclinic.org/healthy-lifestyle/nutrition-and-healthy-eating/in-depth/fiber/art-20043983.

  5. Bean. (2021). [Online] Available: https://en.wikipedia.org/wiki/Bean

  6. Chung DTP, Van Tai D. A fruit recognition system based on a modern deep learning technique. J Phys: Conf Ser. 2019;1327: 012050.

    Google Scholar 

  7. Pacheco WDN, López FRJ. Tomato classification according to organoleptic maturity (coloration) using machine learning algorithms K-NN, MLP, and K-Means Clustering, Computer Science. In: XXII Symposium on Image, Signal Processing and Artificial Vision (STSIVA) 2019

  8. S. P, J. K. Intra class vegetable recognition system using deep learning. In: 4th International Conference on Intelligent Computing and Control Systems IICCS), 2020.

  9. Sakai Y, Oda T, Ikeda M, Barolli L. A vegetable category recognition system using deep neural network. In: 2016 10th International Conference on Innovative Mobile and Internet Services in Ubiquitous Computing (IMIS),2016.

  10. Pinto C, Furukawa J, Tamura S. Classification of Green coffee bean images based on defect types using convolutional neural network (CNN). In: Computer Science, International Conference on Advanced Informatics, Concepts, Theory, and Applications (ICAICTA), 2017.

  11. Huang N, Chou D, Lee C. Real-time classification of green coffee beans by using a convolutional neural network. In: Computer Science, 3rd International Conference on Imaging, Signal Processing and Communication (ICISPC), 2019.

  12. Li Z, Li F, Zhu L, Yue J. Vegetable recognition and classification based on improved VGG deep learning network model. Int J Comput Intell Syst. 2020;13(1):559–64.

    Article  Google Scholar 

  13. Franczyk B, Hernes M, Kozierkiewicz A, Kozina A, Pietranik M, Roemer I, Schieck M. Deep learning for grape variety recognition. Proc Comput Sci. 2020;176:1211–20.

    Article  Google Scholar 

  14. Mia M, Mia M, Majumder A, Supriya S, Habib MT. Computer vision based local fruit recognition. Int J Eng Adv Technol. 2019.

  15. Hridoy R, Akter F, Mahfuzullah M, Ferdowsy F. A computer vision based food recognition approach for controlling inflammation to enhance quality of life of psoriasis patients. In: 10th International Conference on Information Technology (ICIT 2021), 2021.

  16. Nuruzzaman M, Hossain MS, Rahman MM, Shoumik ASHC, Khan MAA, Habib MT. Machine vision based potato species recognition. In: 2021 5th International Conference on Intelligent Computing and Control Systems (ICICCS), 2021.

  17. Rahman M, Prodhan SA, Mia MJ, Habib MT, Ahmed F. Pigeon breed recognition using convolutional neural network. In: 2021 Third International Conference on Intelligent Communication Technologies and Virtual Mobile Networks (ICICV), 2021.

  18. Tan P, Steinbach M, Kumar V. Introduction to data mining (1st ed.), Pearson. 2005

  19. An open-source machine learning framework for everyone. 2021. [Online]. Available at https://www.tensorflow.org/

  20. Keras: The Python Deep Learning library. 2021. [Online]. Available at https://keras.io/

  21. Ilya AK, Geoffrey S, Hinton E. ImageNet classification with deep convolutional neural networks. Commun ACM CACM Homep Arch. 2017; 60(6)

  22. Portal B. শিমবৈচিত্র্য: প্রায়োগিক কৃষি গবেষণা, Barcik News Portal. 2021. [Online]. Available at https://barciknews.com/archives/11715/

  23. Rashmi R, Snekhaltha U, Krishnan PT, Dhanraj V. Fat-based studies for computer-assisted screening of child obesity using thermal imaging based on deep learning techniques: a comparison with quantum machine learning approach. Soft Comput Springer Nat. 2021.

  24. Chatterjee C. Basics of the Classic CNN—towards data science. Medium. 2021. [Online] Available: https://towardsdatascience.com/basics-of-the-classic-cnn-a3dce1225add

  25. Han J, Kamber M, Pei J. Data mining concept and technique, 3rd Edition, Morgan Kaufmann. 2012; 332–398.

  26. Understanding Confusion Matrix. 2021. [Online]. Available: https://towardsdatascience.com/understanding-confusionmatrix-a9ad42dcfd62/. [Accessed 6 December 2021].

  27. Difference between AlexNet, VGGNet, Resnet, and Inception, Medium. 2021. [Online]. Available: https://towardsdatascience.com/the-w3h-of-alexnet-vggnet-resnet-and-inception-7baaaecccc96/

  28. Habib MT, Majumder A, Jakaria A, Akter M, Uddin MSA. Machine vision-based papaya disease recognition. J King Saud Univ Comput Inform Sci. 2020;32(3):300–9.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Iffat Firozy Rimi.

Ethics declarations

Conflict of Interest

The authors have no conflict of interest regarding the publication of this article.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

This article is part of the topical collection “Intelligent Systems” guest edited by Geetha Ganesan, Lalit Garg, Renu Dhir, Vijay Kumar and Manik Sharma.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Rimi, I.F., Habib, M.T., Supriya, S. et al. Traditional Machine Learning and Deep Learning Modeling for Legume Species Recognition. SN COMPUT. SCI. 3, 430 (2022). https://doi.org/10.1007/s42979-022-01268-w

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: https://doi.org/10.1007/s42979-022-01268-w

Keywords

Navigation