[Dec 2021 - Jan 2022]
This project presents an Arduino-based real-time system for detecting the ripeness of various fruits and vegetables by analyzing their spectral (color) composition. Utilizing a TCS34725 color sensor to capture Red, Green, and Blue (RGB/RGBA) intensity values, a trained Multinomial Logistic Regression model classifies the produce into four distinct ripeness categories: Early Ripe, Partially Ripe, Ripe, and Decay. The system provides immediate visual feedback via LEDs.
To access a comprehensive and detailed methodology, please refer to our publication in IEEE CONIT 2022: IEEE Explore: https://ieeexplore.ieee.org/document/9847917
The ripening process in fruits and vegetables is inherently linked to changes in their color. These color transitions are primarily driven by the alteration of various pigments such as Chlorophyll, Carotenoids, and Flavonoids. As produce ripens over time, the concentration of these pigments shifts, leading to observable changes in color. This project leverages this fundamental relationship: by analyzing the spectral composition (RGB values) of the produce, we can infer its ripeness stage. Research has shown that different color spaces can yield varying results in spectral analysis, underscoring the importance of accurate data acquisition and modeling.
The primary objective of this project is to accurately determine the ripeness of fruits and vegetables by analyzing their spectral composition. Specifically, based on measured Red, Green, and Blue intensity values, our system aims to classify produce into one of four ripeness classes: Early Ripe, Partially Ripe, Ripe, or Decay, using a Multinomial Logistic Regression model.
The system's operation involves data acquisition, model training, and real-time deployment:
-
Read Color Intensity: The TCS34725 color sensor is used to read and capture the spectral components of the fruit or vegetable, yielding raw Red, Green, and Blue (RGB) intensity values. (Refer to .csv files for collected data examples.)
-
Map to 8-bit values: The raw sensor readings are mapped and scaled to standard 8-bit values (0-255) to represent color intensity.
-
Manual Labeling: Each set of processed RGB/RGBA values is manually assigned a corresponding ripeness level (Early Ripe, Partially Ripe, Ripe, or Decay), creating a labeled dataset for supervised learning.
- Train Multinomial Logistic Regression Model: A Multinomial Logistic Regression model is trained using the collected and labeled RGB/RGBA data. The model learns the statistical relationship between the color intensities and the four distinct ripeness classes. This model allows for the classification of new, unseen produce based on its color. (Refer to Model Training.ipynb for the training process.)
- The hardware setup involves an Arduino board integrated with the TCS34725 color sensor and four indicator LEDs (Red, White, Green, Yellow), each corresponding to a distinct ripeness category. A Python script establishes the interface with the Arduino to read real-time RGB values from the sensor, feed this data into the pre-trained Multinomial Logistic Regression model for classification (Early Ripe (0) through Decay (3)—see main.ipynb), and finally, trigger the illumination of the unique corresponding LED to provide immediate visual feedback.
If you use our study in your research, consider citing us, Thanks:
@INPROCEEDINGS{9847917,
author={Pawar, Shital and Meshram, Jayant and Mondhe, Ajinkya and Nachan, Akash and Nilangekar, Tejas and Patil, Aditya},
booktitle={2022 2nd International Conference on Intelligent Technologies (CONIT)},
title={Ripeness Detector for Vegetables and Fruits},
year={2022},
volume={},
number={},
pages={1-5},
doi={10.1109/CONIT55038.2022.9847917}
}


