## 1 Introduction  
With the continuous development of the global economy and society, the surging worldwide demand for agricultural products has led to increasingly arduous tasks in monitoring and controlling agricultural pests and diseases. These trends are driving intensifying challenges to global food security and sustainable agricultural production [1, 2, 3]. Thanks to the rapid development of computer vision technology in recent years, the application of image recognition to agricultural pests and diseases is also gradually increasing, promoting the transformation of agricultural pest and disease detection from labor-intensive approaches to a machine-based one [4, 5], and has received extensive attention from scholars at home and abroad [6]. In China, annual crop pests, diseases, weeds, and rodent species exceed 1600. Among these, over 100 species cause severe damage, resulting in annual grain losses of 14 million tons. As a result, image recognition research for crop pests and diseases has become increasingly critical. With the rapid development of deep learning technology [7], especially the rise of models such as convolutional neural networks (CNNs) [8, 9], image recognition has made significant progress; these deep learning models can learn the features in the image and carry out efficient classification and recognition, and many resultshave been achieved in the field of crop image recognition at home and abroad. [PERSON] and [PERSON] et al. [10] proposed a causal inference-based crop-pest identification, innovatively constructed the decoupled feature learning framework (DFL), and utilized the central ternary loss to strengthen the model's ability to capture the core features of the category, effectively overcoming the difficulty of adapting to the distributional bias of the pest training set in the existing identification techniques. [PERSON] et al. [11] proposed an improved U-Net model to address incomplete feature extraction and low accuracy in remote sensing crop classification, leveraging U-Net's proven spatial dependency modeling capabilities widely adopted in remote sensing tasks like land-use mapping and agricultural monitoring. The proposed solution bridges this technical gap by integrating adaptive attention mechanisms to dynamically weight spectral channels and spatial regions, addressing U-Net's limitation in prioritizing discriminative features in complex agricultural landscapes. Recent studies have validated attention-enhanced U-Nets in remote sensing, achieving 8-12% accuracy improvements over baselines, making this approach well suited to optimize spectral-spatial feature learning for crop classification [12]. Through network structure optimization, the study introduces the Spatial Feature Attention Module (SFAM) to enhance spatial context modeling and the Atrous Spatial Pyramid Pooling (ASPP) module to capture multi-scale contextual information, combined with a multilevel feature aggregation pyramid algorithm. This improved U-Net model achieves accurate classification of crops, including Job's tears grains and corn. The proposed method provides a novel technical framework for remote sensing-based recognition of crop pest and disease symptoms, addressing the challenge of distinguishing parasite-related features from healthy plant tissues in complex agricultural scenes. This research results from the model construction, algorithm improvement, and other perspectives to improve the accuracy and intelligence level of crop pest and disease image recognition; however, there are still some challenges in the current research, such as data diversity and scale, to be further expanded to improve the model generalization ability to better agricultural production of the actual needs. This study proposes an improved YOLOv7-U-Net combined network to enable real-time recognition and early warning of crop pest and disease symptoms in farmland monitoring.