Abstract:
Abstract: The identifying of a center line in a crop and the realization of an automatic alignment of a spraying nozzle is the key technology in a precision pesticide. Machine vision has great advantage in path automatic identification, and has been widely used in the study of modern precision agriculture. To overcome the low adaptability in a navigation line extraction algorithm, we used middle growing corn as the goal of the research and got an algorithm with a higher adaptability. In this paper, the image background segmentation was the first part. In this part, the comparison of a traditional gray transformation and an improved one was realized, and showed the effect of the traditional method and an improved method, the results showed that the improved algorithm had certain advantages in the processing of such images, so we used the improved gray-scale transformation as the first step of segmentation. Then the improved middle filter algorithm was used to filter the noise in an image which has been changed in the method of obtaining the middle value to reduce the processing time. Then the image was binarized by an OTSU algorithm instead of the threshold method, which processed automatically with little interference and made the crop row black, and the background white, so to achieve the image background segmentation. Crop line extraction was the second part. The purpose was to use the line to indicate the crop rows, so we used the following method to extract a line in a binary image as far as possible to represent the crop rows and the central position of the image. We used a morphological algorithm to remove the noise, and the 3×3 template of erosion and dilation to operate on the two value image, and determined the number of erosion and dilation by experiment, and then the thinning algorithm and scanning filtration was adopted to keep the middle of the crop rows only, in order to represent navigation information and reduce the computation in line recognition. The third part was deviation calculation. We fit out the navigation line, and got the navigation information by a randomized Hough transform that determined a point in the parameter space by any two points in an image space and transformed the dispersed mapping of one to many to merge the mapping of many to one, which reduced the amount of computation effectively and improved the velocity of calculation. According to the transformation between the world coordinate system and the image coordinate system and the deviation distance between bottom center of crop rows, the pixel center of the image and the spray nozzle position relative to the information of camera, we could get the actual deviation in this image. Finally, we realized the hardware structures and composition of this system. And the experimental results suggested that this algorithm had better generality, and it had a certain advantage in background segmentation, crop line, and navigate information extraction. We have proved that the algorithm can effectively avoid the effects of weeds by the experiment of different images and process, and it can adapt to the line extraction of different crops.