Classification of Mango Ripeness Grades Using Machine Learning
摘要
The ripeness of mangos is a major factor in how long perishable fruits and vegetables may be stored. Human perception of ripeness, depend on visualizing skin colour, can be prone to error. This may result in incorrect sorting of mangos into ripeness categories (e.g., underripe, ripe, overripe). This research aims to develop a technique for detecting and classifying mango ripeness at various stages using computer vision and machine learning. The project begins by collecting RGB images of mangoes at different maturity levels. The RGB images are then converted to the HSV colour space, focusing on the “S” channel. Otsu’s thresholding technique is employed for background removal and to segment the images, from which essential features are extracted. Both texture and colour features are crucial in accurately assessing mango ripeness. Meanwhile, the colour features are derived from the segmented images in the HSV colour space. The classification of mango ripeness stages is performed using both a Support Vector Machine (SVM) and Random Forest to compare which classifier has the best performance. The results show that SVM has the highest accuracy, achieving 98.39%, while Random Forest achieves 96.77%. This research contributes to the development of an automated system for mango ripeness classification, with potential applications in improving fruit storage practices and reducing food waste.