Abstract:In order to achieve accurate detection of a wide range of tomato leaf diseases, an instance segmentation method was proposed based on improved SOLO v2 for tomato leaf diseases. The SOLO v2 model was adopted as the main framework, using ResNet-101 as the backbone network to fuse feature pyramid networks (FPN), optimize the convolutional structure by introducing deformable convolution, and integrate the loss factor δinto the mask loss function to detect and segment the instances on the category branch and the mask branches. By improving the model, it achieved accurate detection and segmentation of tomato leaves with complex and variable shapes, and the generalisation and robustness of the model were improved. On the basis of the public dataset of Plant Village, the data were cleaned and synthetic multi-instance images were added. The images were manually annotated to create a training set, a validation set and a test set with nine tomato leaf cases and healthy leaves. After setting the parameters and structure of the models, a performance comparison of SOLO v2 models with different depths of residual networks was carried out in the same experimental environment. Finally, model performance comparison tests of different models and the performance comparison tests of SOLO v2 models before and after optimisation were respectively conducted on the basis of the better performing residual networks. The experimental results showed that ResNet-101 performed better than ResNet-50 on SOLO v2. With the same backbone network, the SOLO v2 model reduced the processing time of a single image by 72.0% compared with Mask R-CNN and improved the mean average precision (mAP) metric by 3.2 percentage points. The enhanced model improved convergence in the training process and was less affected by the variable shape of the blade, with a final mAP of 42.3% and a single image processing time of 0.083s, ensuring real-time operation while improving detection accuracy. The research solved the problem of identification and segmentation of diseased tomato leaves, and provided a reference for the analysis of tomato disease conditions and symptoms in automated agricultural production.