Abstract
Autonomous navigation is an important guarantee for intelligent agricultural machinery to complete harvesting operations. Navigation line recognition is an important step in achieving autonomous navigation of intelligent agricultural machinery. Real-time and accurate detection of harvesting navigation lines can effectively accelerate the progress of operations and reduce crop loss rates. Visual sensors have the advantages of low cost and rich information acquisition, making them widely used in route detection. Frequent changes in lighting under cloudy weather make it difficult for a single feature to cope with wheat field environments. In this study, a wheat harvesting boundary detection method based on multi texture feature fusion was proposed. In the harvested area, the characteristics of low stubble and no top wheat ears result in differences in uniformity, density, and other aspects when harvesting under both light and backlight compared to the non-harvested area. At the same time, due to the exposed wheat stubble in the harvested area, it appears more regular on the image, and its gradient direction is more consistent than that in the non-harvested area. Therefore, a two-dimensional feature vector composed of image entropy and directional gradient was constructed to classify the harvested and unharvested areas of the wheat field, and then the harvesting boundary was extracted. Due to the susceptibility of image entropy features to perspective phenomena, this paper compared the entropy features of different regions in the image when fixing the camera installation angle and height, and ultimately selected the middle region of the image as the region of interest. After analyzing the characteristics of image entropy feature extraction, a histogram statistical method based on sliding windows was proposed to accelerate the speed of image entropy feature extraction. By further dividing the window to be calculated into several sub windows, sliding and combining these sub windows significantly reduced the computation. The entropy feature extraction in this paper took 0.53 seconds, which is 49.52% faster than the traditional method of directly extracting entropy from the entire window. After extracting two-dimensional features, based on the distribution characteristics of the feature histogram and combined with the maximum entropy threshold segmentation algorithm, the wheat field image was preliminarily classified. For entropy features, low noise points affected the threshold segmentation effect. By comparing the impact of discarding different proportions of low entropy points on the segmentation threshold, this paper discarded 10% of low entropy points, enhancing the threshold segmentation effect. The method of removing small connected regions was used to eliminate the misclassified regions in the initial classification binary image. Then, the Canny operator was used to extract edge contour points distributed near the harvesting boundary. Due to the consistent direction between the harvesting boundary and the agricultural machinery's forward direction, the Ransac algorithm was used to restrict the fitting line in the region, obtaining the accurate harvesting boundary. In order to verify the feasibility of the method proposed in this article, wheat field images under different lighting conditions were collected, including 2 200 weak light images, 758 local strong light images, and 1 134 strong light images. After selecting the region of interest, the size of the image to be processed was 240 pixels×1 280 pixels. The algorithm in this paper took an average of 0.88 s to process each image on laptops. The detection rates under weak light, local strong light, and strong light were 90.41%, 88.26%, and 89.68%, respectively, with an average of 89.45%. Compared with the traditional method of using Adaboost algorithm for machine learning, the detection speed of this algorithm was improved by 73.89%, and the detection rate was increased by 46.19 percentage points, 46.00 percentage points, and 49.64 percentage points under weak light, local strong light, and strong light, respectively. Compared with traditional algorithms, the method proposed in this paper significantly improved real-time performance and detection rate, which can provide reference for the detection of field agricultural machinery navigation lines.