## 5 Conclusions  
This study was dedicated to expanding the practical application of binocular stereo vision in the detection and positioning of \(C\). _oleifera_ fruits and to improving the robustness of the binocular stereo vision system in natural environments. The YOLOv7 algorithm was used to train the \(C\). _oleifera_ fruits data set, and the obtained detection model was used to recognize \(C\). _oleifera_ fruits. The test accuracy rate \(P\) of the model was 97.3%, the recall rate \(R\) was 97.6%, the \(mAP\) was 97.7% and the comprehensive evaluation index \(F_{1}\) was 97.4%. The recognition experiments showed that the recognition rate of the model reached 93.13% under the condition in which the \(C\). _oleifera_ fruits were slightly shielded, the recognition rate reached 75.21% under the condition in which the \(C\). _oleifera_ fruits were seriously shielded. The recognition rate of the model was 90.64% under sunlight condition, and the recognition rate of the model was 91.34% under shading condition.  
The binocular stereo vision system was built on the basis of an industrial camera to carry out three-dimensional space positioning on the \(C\). _oleifera_ fruits. The anchor frame regions of the \(C\). _oleifera_ fruits were matched by applying epipolar line constraint and sequence consistency principles, and template-matching was carried out on the LBP maps of the central regions of the left and right anchor frame images of the same \(C\). _oleifera_ fruits. Compared with the full-image matching or multi-feature point matching of the traditional stereo matching algorithm, the calculation and the mismatching rate of the localization algorithm amount in the stereo matching process can be effectively reduced. Compared with the commonly used gray matching in one-dimensional direction, the localization algorithm has higher positioning accuracy. The indoor positioning experiment showed that the maximum comprehensive error was 4.06 mm, the minimum comprehensive error was 0.37 mm and the average comprehensive error was 2.306 mm in the depth range of 400-550 mm.  
In the orchard field experiment, the binocular stereo vision system had a maximum ranging error of 4.279 mm and an experimental standard deviation of 1.142 mm in the field of view with a depth of 400-600 mm, which basically met the working requirements of the precision picking robot. The binocular stereo vision system can be used for identifying and positioning fruits that are difficult to identify using traditional machine vision and can be applied to a harvesting robot for accurate picking, so the system has wide applicability. In future research, we will further study the activity range of the center point of \(C\). _oleifera_ fruits in the left and right images, reduce the size of the region to be matched and improve the running speed of the positioning algorithm. After completing this study, the binocular stereo vision system will be combined with the practical application of a \(C\). _oleifera_ fruit-picking robot.  
Conceptualization, X.L. and Y.X.; methodology, X.L. and Y.X.; software, X.L.; validation, X.L., Z.T. and S.C.; formal analysis, X.L.; investigation, X.L., Z.T. and A.L.; resources, Y.X. and Y.L.; data curation, X.L.; writing--original draft preparation, X.L.; writing--review and editing, Y.X.; visualization, X.L.; supervision, Y.X. and M.W.; project administration, Y.X.; funding acquisition, Y.X. All authors have read and agreed to the published version of the manuscript.  
This research was funded by the National Key Research and Development Plan Project (2022 YFD2002003).  
All data are presented in this article in the form of figures and tables.