## 2 Literature Review
### Fruits and Vegetables Detections  
The preceding literature focuses on classification and recognition tasks in non-real-time settings. However, our proposed work requires the real-time recognition and classification of fruits and vegetables. Due to this, we had to employed an object detection model for carrying out the recognition and classification tasks in real time. In previous research, several researchers have explored object detection algorithms for fruits and vegetables recognition and classification in real time. In this section, we will provide a summary of these techniques. In one work, the idea of a billing mart was presented [26]. YOLOv2, an object detection algorithm, was utilized by the author for the detection and recognition of vegetables. The model was trained on three classes and an accuracy of 70% was achieved, which is not considered sufficient for real-time object detection. However, no graphical user interface (GUI) was developed for shopping purposes. In another study [27], YOLO algorithm was used for the classification and detection of vegetables. A dataset of 100 images of three different classes of vegetables was collected by the author. Out of these, 60 images were used for training purposes, while 40 images were utilized for testing. However, due to the limited size of the dataset, there was a lack of diversity in the orientation of the vegetables, resulting in poor performance in detecting unknown orientations. This poor performance was attributed to the absence of data augmentation. Consequently, an accuracy of only 61.6% was achieved by the model, which is deemed insufficient for real-time vegetable detection. These results highlight the necessity for larger and more diverse datasets in order to train robust and accurate models for vegetable classification and detection tasks. In another paper [28], the utilization of the deep learning model YOLOv4-tiny for the task of fruits and vegetables detection was described. A dataset was collected from various sources such as Google and Kaggle, and it was labeled using the Roboflow framework. The results obtained from the YOLOv4-tiny model showed a mean average precision (mAP) of 51% with an inference time of 18 milliseconds. However, upon further analysis, several reasons for the suboptimal performance of the model were identified. Firstly, the dataset used in this study was collected from multiple sources, which led to a lack of uniformity in the distribution of the dataset. Additionally, the number of examples per class varied, with some classes having a higher number of examples than others. In the research of reference [29], the author proposes an accurate and real-time image-based multi-class fruit detection system for smart farms. The framework utilizes an improved Faster R-CNN deep learning model, comprising a fruit image library, data augmentation techniques, an enhanced model, and performance evaluation. The work's notable contributions include a comprehensive outdoor orchard image library with 4000 real-world images and optimized convolutional and pooling layers for higher accuracy and faster detection. The test results demonstrate superior accuracy and processing time compared to traditional detectors. The proposed algorithm achieves over 91% mean average precision (mAP) for detecting apples, mangoes, and oranges, with improved image processing speed, making it suitable for autonomous harvesting and yield mapping systems. In another paper [30], a novel fruit detection algorithm is presented for a plum harvesting robot. The algorithm addresses the challenges of accurately recognizing plums, considering their small size, dense growth, and occlusions in the environment. The proposed approach is a lightweight plum detection procedure based on an improved version of the YOLOv7 algorithm. The methodology involves collecting plum images, establishing train/validation/test sets, and training the detection model with data augmentation.