Abstract:Citrus Huanglongbing is known as the “cancer” of citrus, which seriously affects the yield and quality of citrus. Therefore, accurate detection of citrus Huanglongbing is of great significance for timely protection and management of citrus. However, in the natural background, there are problems of mutual occlusion and large size changes among citrus leaves, which makes the occlusion and small-sized leaves of Huanglongbing easy to miss. In addition, because the color and texture characteristics of the leaves of Huanglongbing are very similar to other diseases of citrus, there is a problem of false detection. Therefore, when the background is complex, it is difficult for the existing algorithms to accurately detect and identify the leaves of Huanglongbing. In response to the above problems, a natural background citrus Huanglongbing detection method was proposed based on shearing mixed splicing and two-way feature fusion. The method proposed used Cascade RCNN as the baseline network and used LabelImg to manually label the Huanglongbing samples in training and validation images. Firstly, in order to reduce the impact of complex background on the detection of Huanglongbing, the training set and validation set were augmented with the shearing mixed splicing method, mirror flips and rotations, which increased the number and diversity of background objects in the training set and validation set images. Secondly, deformable convolution was used to replace all standard convolutions in the backbone network Conv3~Conv5 to reduce the influence of irregular leaf shape and increase the effective receptive field and adaptively change the local sampling points in the detection of citrus Huanglongbing. Thirdly, in order to reduce the influence of the natural background on the detection results of citrus Huanglongbing and enhance the ability of the backbone network to extract the detailed features of the citrus Huanglongbing disease area, the global context block was used to enhance the feature map output by Conv3~Conv5 to establish an effective long-term distance dependence, so that the network can better learn the global context information. Finally, in order to reduce the influence of large changes in the size of the leaves of Huanglongbing on the detection results, two-way fusion feature pyramid networks was used to improve the information exchange path between shallow features and deep features, thereby improving the detection accuracy of small-sized blades. To verify the rationality and effectiveness of the method, in the training phase, the stochastic gradient descent strategy was adopted to train the network model. The initial learning rate was 0.02, the momentum was 0.9, the weight decay was 0.0001, and the number of iterations was 500. During the testing phase, the method proposed achieved 85.0% recall, 86.4% precision, and 84.8% average precision on the test set. The proposed method was compared with other detection algorithms (SSD, RetinaNet, YOLO v3, YOLO v5s, Faster RCNN, Cascade RCNN). Comparative experiments showed that the mean average precision of this method was 30.5 percentage points higher than that of SSD, 21.9 percentage points higher than that of RetinaNet, 13.2 percentage points higher than that of YOLO v3, 6.8 percentage points higher than that of YOLO v5s, and 20.1 percentage points higher than that of Faster RCNN, which was 3.2 percentage points higher than that of Cascade RCNN, and the detection result of this method was better than other classical deep learning methods.