| In order to realize the automatic picking of broccoli and effectively reduce the labor cost,this paper designs the automatic broccoli picking machine and conducts research on the structure design,path planning and vision algorithm of the picking machine.Firstly,the mechanical and electrical structures of the automatic broccoli picker are designed in this paper.Secondly,this paper implements the Simultaneous Localization And Mapping(SLAM)algorithm based on the Robot Operating System(ROS)for Li DAR and depth camera respectively,and combines them with the path planning algorithm to solve the realistic motion control problem of the picker.Finally,this paper proposes a scribing and counting algorithm based on improved YOLOv5 s target recognition and improved sequencing algorithm(Simple Online And Realtime Tracking,SORT)target tracking to solve the problem of counting on the conveyor belt after broccoli picking.The specific research of this paper contains the following points:(1)The mechanical structure and electrical structure of the automatic broccoli picker were designed.Firstly,the paper starts from the botanical characteristics of broccoli,and the structural design of the picker moving platform,the picking mechanical jaws,the mechanical jaws moving platform and the belt conveyor mechanism after picking are carried out respectively.Then,the electrical part of the motor and its driver,the vision upper computer solution,and the chassis control lower computer solution are designed according to the mechanical structure and the requirements of the control algorithm in the later paper.Finally,in terms of motor selection,this paper obtains a more reasonable motor combination by calculating the resistance torque and other conditions in the operation of the actual planting field.(2)The SLAM map building algorithm and path planning algorithm of broccoli automatic picker are implemented.Firstly,this paper explains the principle of global path planning based on A* algorithm,and clarifies that A* algorithm has the problem of selecting risky paths,and uses the discretization detection method to obtain the improved A* algorithm,and proves the effectiveness of this approach through simulation comparison.Then,this paper elaborates the Dynamic Window Approach(DWA)for the problem that global path planning cannot avoid the unknown obstacles.To solve the problem of falling into local optimal solutions brought by local path planning,this paper combines the above two approaches and proposes a path planning algorithm that mixes A* and dynamic window algorithm.Finally,based on the ROS system combined with the path planning algorithm,and based on the GMapping building algorithm with Li DAR,a 2D raster map is established to realize the path planning of the actual scene.For the problem of missing 3D information of GMapping building algorithm,this paper obtains 3D map information based on RTAB-SLAM algorithm using depth camera to obtain 3D raster map.(3)A scratch counting algorithm based on YOLOv5 s target recognition and SORT target tracking is proposed for target counting requirements on broccoli automatic picking machines.First,this paper uses YOLOv5 s deep learning network to solve the broccoli target recognition problem,which is improved based on the attention mechanism to obtain an improved YOLOv5s-Re SE network to enhance the target recognition effect.Second,SORT is used to solve the target tracking problem of broccoli on a conveyor belt.The overall tracking speed and stability are improved by updating the formula and position prediction improvement model by the Kalman filter algorithm in the SORT algorithm.Eventually,the accuracy of counting was improved by combining the above two improved algorithms,and it was obtained experimentally that,in terms of counting accuracy,the improved SORT algorithm proposed in this paper improved the average accuracy by 4.19 percentage points compared with the original model;in terms of target identification,using the improved YOLOv5s-Re SE model on the training set,m AP@0.5 was 0.995,m AP@0.5:0.95 was 0.775,accuracy was 0.827 with a recall of 1,which can perform the broccoli target recognition task better compared with other networks. |