# Disease and Defect Detection System for Raspberries Based on Convolutional Neural Networks
## 5 Conclusions and Future Work  
It can be concluded that the main objective of the project was fully met. It was possible to develop functional equipment to determine the quality of raspberry trays using computer vision techniques and convolutional neural networks from images captured in the visible RGB spectrum. Effectively integrating both hardware and software and thus achieving an automatic onboard evaluation of raspberry tray quality. The software developed based on object-detection algorithms, originally designed for autonomous driving, is able to adapt appropriately for the detection of raspberries with defects or diseases present in the harvesting trays with raspberries on entering the fruit processing plant, according to the parameters and standards of agribusiness, obtaining the quality of the fruit accurately, automatically and in real time. For this, individual object detectors are trained for each class to be detected; in this case, we trained 4 detectors for 4 predefined classes. This process is done in this way, because each object detector can individually adjust its training parameters, optimizing the model training process. These class-based raspberry detection models generally achieve excellent results. Another important advantage of the modular per-class development of the software is that another model can be incorporated that has better results for a particular class, without affecting the models of the rest of the classes. Regarding future work for the optimization of the complete system, it is necessary to work together with the industry, placing the device in the reception area of the fruit processing plant and jointly performing the evaluation with a human expert from the  
Figure 16: Confusion matrices of the results of the evaluation of the conceptual test images of raspberry trays. company to evaluate the prototype quality for the raspberries in trays. In this way, we create a comprehensive database, having the image capture available together with evaluation made by an expert and jointly evaluate the results of both estimates, detailing similarities and errors to optimize the process, both in handling the equipment and in the accuracy of the quality assessment performed by the software. Likewise, regarding future work with the objective of improving the detection of objects in the raspberry tray, the adaptation of depth cameras (RGB-D) is proposed. These would provide additional information for better image processing. Along with providing the image in the visible spectrum, it would provide the distance from the camera to the object, which would allow definition of a structure and achieve better segmentation or detection of edges of each object in the tray, and thus improve the results of the classification of raspberries contained in the tray. J.N.-T. Investigation, Software, Resources and Writing--original draft; M.M. Funding acquisition, Conceptualization, Methodology and Writing--review and editing; C.F. Writing --review and Funding acquisition; A.V. Writing--review, Funding acquisition and editing. All authors have read and agreed to the published version of the manuscript. This research was funded by Innovation Fund for Competitiveness--FIC, Government of Maule, Chile--Project Transfer Development Equipment Estimation Quality of Raspberry, code 40.001.110-0. (Esta investigacion fue financada por el Fondo de Innovacion para la Competitividad--FIC, Gobierno de Maule, Chile--Proyecto de Transferencia de Desarrollo de Equipo de Estimacion de Calidad de la Frambuesa, codigo 40.001.110-0.) Not applicable. The data used in this study is available upon direct request to [PERSON] ([EMAIL_ADDRESS]) head of the Laboratory of Technological Research in Recognition of Patterns (www.litrp.cl, accessed on 2 June 2021). The authors thank the Laboratory of Technological Research in Recognition of Patterns (www.litrp.cl, accessed on 2 June 2021) of the Universidad Catolica del Maule, Chile, for providing the computer servers where the experiments were carried out.