| Accurate identification and localization of pests can provide basic data for scientific pest control,which is an important basis for effective pest investigation,pest forecasting,and appropriate pesticide application.In addition,the accurate identification and localization of pests is the fundamental prerequisite for the precise killing of pests,which is of great significance for integrated pest control.At present,the identification and localization of pests mainly rely on manual labor,which is costly and inefficient.How to quickly,conveniently and accurately identify and locate pests is an urgent problem to be solved in related research and application fields.In this paper,taking Pieris rapae as the research object,by analyzing the characteristics of Pieris rapae and its host plants(cabbage),a method for identifying and locating Pieris rapae in the field based on machine vision is proposed.The main research contents are as follows:(1)By analyzing the spectral characteristics of Pieris rapae and cabbage,an image acquisition technology based on near-infrared technology was proposed,which effectively reduced the identification difficulty caused by the protective color of Pieris rapae.On this basis,a binocular stereo vision system was built to collect a large number of images of field Pieris rapae under natural conditions,and then the dataset of Pieris rapae was constructed and optimized.(2)On the basis of analyzing the research status of pest identification at home and abroad,YOLOv5,Mask R-CNN and SSD models were used to train the dataset of Pieris rapae.Comparing the detection speed and identification accuracy of the three methods,the experimental results show that the Mask R-CNN model with the Res Net50 network as the backbone network has the best identification effect,with an identification accuracy of 0.942,and an average detection time of 0.459 s.At the same time,for the identified target of Pieris rapae,its contour was extracted to provide a basis for pest localization.(3)A multi-constraint stereo matching algorithm based on epipolar geometry was proposed.By extracting the midpoints of the Pieris rapae skeleton n the binocular images for stereo matching and sub-pixel parallax calculation,the three-dimensional coordinates of the midpoint of each Pieris rapae worm skeleton were calculated by the principle of triangulation.The experimental results show that the maximum absolute error of the localization algorithm is 1.293 mm,the mean absolute errors is 0.684 mm,the root mean square error is 0.756 mm,and the average relative error is 0.14%.The average time-consuming of the overall algorithm for identification and localization is 0.61 s. |