Binary-Class Tabular Model for Pistachio Identification Using Python and Scikit-Learn

Template Credit: Adapted from a template made available by Dr. Jason Brownlee of Machine Learning Mastery.

SUMMARY: The project aims to construct a predictive model using various machine learning algorithms and document the end-to-end steps using a template. The Pistachio Identification dataset is a binary-class modeling situation where we attempt to predict one of two possible outcomes.

INTRODUCTION: Pistachio nut has an important place in the agricultural economy; the efficiency of post-harvest industrial processes is crucial to maintaining its economic value. The industry needs new methods and technologies for separating and classifying pistachios to provide this efficiency. In this study, the research team aimed to develop a classification model different from traditional separation methods based on image processing and artificial intelligence techniques.

A computer vision system (CVS) has been developed to distinguish two species of pistachios with different characteristics that address additional market types. The research team took 2148 sample images for these two kinds of pistachios with a high-resolution camera. They applied image processing, segmentation, and feature extraction techniques to the images of the pistachio samples.

ANALYSIS: The average performance of the machine learning algorithms achieved an accuracy benchmark of 88.65% using the training dataset. Furthermore, we selected Extra Trees as the final model as it processed the training dataset with a final accuracy score of 90.21%. When we processed the test dataset with the final model, the model achieved an accuracy score of 89.53%.

CONCLUSION: In this iteration, the Extra Trees model appeared to be a suitable algorithm for modeling this dataset.

Dataset Used: Pistachio Dataset

Dataset ML Model: Binary classification with numerical features

Dataset Reference: https://www.muratkoklu.com/datasets/

One source of potential performance benchmarks: https://doi.org/10.23751/pn.v23i2.9686

The HTML formatted report can be found here on GitHub.