Litchi leaf diseases and pests can lead to issues such as a decreased Litchi yield, reduced fruit quality, and decreased farmer income. In this study, we aimed to explore a real-time and accurate method for identifying Litchi leaf diseases and pests. We selected three different orchards for field investigation and identified five common Litchi leaf diseases and pests (Litchi leaf mite, Litchi sooty mold, Litchi anthracnose, Mayetiola sp., and Litchi algal spot) as our research objects. Finally, we proposed an improved fully convolutional one-stage object detection (FCOS) network for Litchi leaf disease and pest detection, called FCOS for Litch (FCOS-FL). The proposed method employs G-GhostNet-3.2 as the backbone network to achieve a model that is lightweight. The central moment pooling attention (CMPA) mechanism is introduced to enhance the features of Litchi leaf diseases and pests. In addition, the center sampling and center loss of the model are improved by utilizing the width and height information of the real target, which effectively improves the model’s generalization performance. We propose an improved localization loss function to enhance the localization accuracy of the model in object detection. According to the characteristics of Litchi small target diseases and pests, the network structure was redesigned to improve the detection effect of small targets. FCOS-FL has a detection accuracy of 91.3% (intersection over union (IoU) = 0.5) in the images of five types of Litchi leaf diseases and pests, a detection rate of 62.0/ms, and a model parameter size of 17.65 M. Among them, the detection accuracy of Mayetiola sp. and Litchi algal spot, which are difficult to detect, reached 93.2% and 92%, respectively. The FCOS-FL model can rapidly and accurately detect five common diseases and pests in Litchi leaf. The research outcome is suitable for deployment on embedded devices with limited resources such as mobile terminals, and can contribute to achieving real-time and precise identification of Litchi leaf diseases and pests, providing technical support for Litchi leaf diseases’ and pests’ prevention and control.
It is necessary to develop automatic picking technology to improve the efficiency of litchi picking, and the accurate segmentation of litchi branches is the key that allows robots to complete the picking task. To solve the problem of inaccurate segmentation of litchi branches under natural conditions, this paper proposes a segmentation method for litchi branches based on the improved DeepLabv3+, which replaced the backbone network of DeepLabv3+ and used the Dilated Residual Networks as the backbone network to enhance the model’s feature extraction capability. During the training process, a combination of Cross-Entropy loss and the dice coefficient loss was used as the loss function to cause the model to pay more attention to the litchi branch area, which could alleviate the negative impact of the imbalance between the litchi branches and the background. In addition, the Coordinate Attention module is added to the atrous spatial pyramid pooling, and the channel and location information of the multi-scale semantic features acquired by the network are simultaneously considered. The experimental results show that the model’s mean intersection over union and mean pixel accuracy are 90.28% and 94.95%, respectively, and the frames per second (FPS) is 19.83. Compared with the classical DeepLabv3+ network, the model’s mean intersection over union and mean pixel accuracy are improved by 13.57% and 15.78%, respectively. This method can accurately segment litchi branches, which provides powerful technical support to help litchi-picking robots find branches.