A rice ear recognition method based on MLCA-YOLOv11s, an electronic device and a storage medium

CN122990499APending Publication Date: 2026-10-27YANGTZE UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611308252.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-27
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

检测精度与鲁棒性不足:在密集遮挡、尺度多变、背景干扰严重的复杂田间环境下,现有模型对小目标稻穗和相互遮挡稻穗的识别能力较弱,漏检问题较为突出

Benefits of technology

本发明公开了一种基于MLCA-YOLOv11s的稻穗识别方法、电子设备和存储介质,所述方法通过引入混合局部通道注意力模块MLCA,在不增加模型参数量的前提下,有效融合了局部通道交互与全局上下文信息,显著提升了模型对复杂田间环境下稻穗特征的提取能力。该方法针对不同氮肥与株行距下的多样化稻穗形态具有极强的适应性,有效解决了密集遮挡及小目标稻穗的漏检问题。结合精细化的数据预处理流程,实现了轻量化与高精度的平衡,能够满足农业嵌入式设备的实时检测需求,为水稻产量预测与精准育种提供了可靠的技术支撑。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122990499A_ABST
    Figure CN122990499A_ABST
Patent Text Reader

Abstract

The application discloses a rice ear recognition method based on MLCA-YOLOv11s, an electronic device and a storage medium, and relates to the technical field of image analysis. The method comprises the following steps: a diversified rice ear image dataset covering different rice varieties, nitrogen fertilizer concentrations and plant row spacing combinations is constructed, and fine cutting and labeling preprocessing are performed. Based on the YOLOv11 model, a mixed local channel attention module MLCA is introduced at the end of the backbone network, local features are captured by using grouped convolution and one-dimensional convolution, adaptive attention weights are generated by combining global average pooling information, and the feature map is recalibrated. Finally, the processed dataset is used to train the model and generate the final recognition result. Through multi-source data enhancement and structure optimization, the application significantly improves the precision and robustness of rice ear recognition in a complex background without increasing the calculation cost, and realizes lightweight deployment and real-time detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image analysis technology, and in particular to a rice ear recognition method, electronic device, and storage medium based on MLCA-YOLOv11s. Background Technology

[0002] Rice, as a major food crop, has rice panicles as a core element of yield composition. The quantity, distribution, and morphological characteristics of these panicles are crucial for yield prediction, breeding evaluation, and precision cultivation management. With the development of deep learning technology, using object detection algorithms for field crop identification has become a research hotspot in smart agriculture. Currently, single-stage detectors, represented by the YOLO (You Only LookOnce) series, have gradually replaced two-stage detectors, such as Faster R-CNN, as the mainstream method for field crop identification due to their good balance between detection accuracy and inference speed.

[0003] Early rice ear identification research mostly used two-stage detectors such as Faster R-CNN. Although the detection accuracy was high, the computational cost was large and the inference speed was slow. YOLO series algorithms, such as YOLOv3 and YOLOv7 for rice ear counting, and improved models such as YOLOv8 and YOLOv9 for seed setting rate estimation or detection based on UAV imagery.

[0004] Despite some progress in rice panicle detection technology, the following significant drawbacks remain: Insufficient detection accuracy and robustness: In complex field environments with dense occlusion, varying scales, and severe background interference, existing models have weak ability to identify small target rice ears and rice ears that are mutually occluded, resulting in significant missed detections.

[0005] Imbalance between lightweight and accuracy: High-precision models often have a large number of parameters and high computational costs, making them difficult to deploy in real time on embedded devices in the field (such as UAV onboard computing platforms); while lightweight models may sacrifice too much detection accuracy.

[0006] Poor adaptability of attention mechanisms: Existing attention mechanisms are mostly designed for general visual tasks and lack customized designs for the slender shape and local texture features of rice ears, which limits the model's ability to extract features in complex backgrounds.

[0007] Therefore, how to improve the detection accuracy and robustness of rice ears in complex field environments (especially dense occlusion and multi-scale scenarios) while ensuring the model is lightweight to meet the needs of real-time field detection, and reduce missed detections and false detections, is a technical problem that needs to be solved by researchers in this field. Summary of the Invention

[0008] The purpose of this invention is to provide a rice ear identification method, electronic device, and storage medium based on MLCA-YOLOv11s, aiming to solve or improve at least one of the above-mentioned technical problems.

[0009] To achieve the above objectives, the present invention provides the following solution: A rice panicle identification method based on MLCA-YOLOv11s includes: The dataset of rice ear images was obtained, preprocessed, and divided into training, validation, and test sets. Based on the YOLOv11 model, the MLCA-YOLOv11s model is improved, in which the Hybrid Local Channel Attention (MLCA) module is introduced at the end of the backbone network. The MLCA-YOLOv11s model is trained using the training set and validation set, and the performance of the MLCA-YOLOv11s model is tested using the test set to generate the final MLCA-YOLOv11s model. The image of the rice ear to be detected is input into the final MLCA-YOLOv11s model to generate the rice ear recognition result.

[0010] Furthermore, different rice varieties, nitrogen fertilizer application concentrations, and plant spacing combinations were used as data collection objects.

[0011] Furthermore, the nitrogen fertilizer application concentration includes: setting four pure nitrogen application concentration gradients, each 12 kg / hm². 2 15 kg / hm 2 18 kg / hm 2 and 21 kg / hm 2 .

[0012] Furthermore, the plant spacing combinations include: four combinations: 30cm×20cm, 30cm×18cm, 30cm×16cm and 30cm×14cm.

[0013] Further preprocessing includes cropping and labeling the collected rice ear images.

[0014] Further cropping includes: using Adobe Photoshop as the image cropping tool, using the four inner edges of the white frame as the cropping boundaries, the cropped image includes the entire area inside the white frame but does not include the frame itself, and the images are uniformly exported as JPEG format with the quality parameter set to 95%.

[0015] Further annotation includes: after initial annotation of the rice ear images using the AnyLabeling tool, fine-tuning is performed through human interaction.

[0016] Furthermore, the Hybrid Local Channel Attention Module (MLCA) includes: The input feature map is divided into groups using group convolution. There are 1 group; within each group, local channel attention weights are generated using one-dimensional convolution, expressed as: In the formula, Local channel attention weights; Use the Sigmoid activation function; This is a one-dimensional convolution operation; This is a grouped convolution operation; For the input feature map Perform global average pooling to generate a global feature vector, expressed as: In the formula, This is the global feature vector; This is a global average pooling operation; The attention weights of the local channels are weighted and combined with the global feature vector to generate an attention weight vector, expressed as follows: In the formula, This is the attention weight vector; These are learnable weight coefficients; The attention weight vector is multiplied element-wise by the original input feature map X, as shown in the expression: In the formula, The output features are those after adaptive calibration.

[0017] According to specific embodiments provided by the present invention, the present invention discloses the following technical effects: This invention discloses a rice panicle identification method, electronic device, and storage medium based on MLCA-YOLOv11s. The method, by introducing a Hybrid Local Channel Attention (MLCA) module, effectively integrates local channel interactions and global contextual information without increasing the number of model parameters, significantly improving the model's ability to extract rice panicle features under complex field conditions. This method exhibits strong adaptability to diverse rice panicle morphologies under different nitrogen fertilizer and row spacing conditions, effectively solving the problems of missed detection due to dense occlusion and small target rice panicles. Combined with a refined data preprocessing workflow, it achieves a balance between lightweight design and high precision, meeting the real-time detection needs of agricultural embedded devices and providing reliable technical support for rice yield prediction and precision breeding. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 This is a schematic flowchart of the method of the present invention; Figure 2 This is a schematic diagram comparing the structures of the YOLOv11s model and the MLCA-YOLOv11s model in this embodiment; Figure 3 This is a schematic diagram of the training curves of mAP50 for different YOLO models in this embodiment; Figure 4 This is a comparative diagram of the 250-300 iteration counts of different YOLO models in this embodiment; Figure 5 This is a schematic diagram of some detection results of the MLCA-YOLOv11s model on the validation set in this embodiment; Figure 6 This is a schematic diagram comparing the detection results of the YOLOv11s model and the MLCA-YOLOv11s model in this embodiment; Figure 7 This is a schematic diagram of the loss and accuracy changes during the training process of the MLCA-YOLOv11s model in this embodiment. Detailed Implementation

[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0021] The purpose of this invention is to provide a rice ear identification method, electronic device, and storage medium based on MLCA-YOLOv11s, aiming to solve or improve at least one of the above-mentioned technical problems.

[0022] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0023] like Figure 1 As shown, this invention provides a rice ear identification method based on MLCA-YOLOv11s, comprising: Step 1: Obtain the rice ear image dataset, perform preprocessing, and divide it into training set, validation set, and test set; In this embodiment, different rice varieties, different nitrogen fertilizer application concentrations, and different plant spacing combinations were used as data collection objects.

[0024] The nitrogen fertilizer treatment included four pure nitrogen application concentration gradients, each with a concentration of 12 kg / hm². 2 15 kg / hm 2 18 kg / hm 2 and 21 kg / hm 2 ; Four combinations of plant spacing were set: 30cm×20cm, 30cm×18cm, 30cm×16cm and 30cm×14cm.

[0025] Combinations of different varieties, nitrogen fertilizer levels, and plant spacing aim to obtain rice panicle images with diverse morphological characteristics, enhance the representativeness of the training dataset, and enable the model to adapt to the differences in rice panicle morphology under different cultivation conditions.

[0026] The preprocessing involves cropping and labeling the collected rice ear images, specifically including: Image cropping was performed using Adobe Photoshop (PS) as the image cropping tool. The four inner edges of the white frame were used as the cropping boundaries to ensure that the cropped image exactly included the entire area inside the white frame, excluding the frame itself. All images were exported as JPEG format with a quality parameter set to 95%.

[0027] Image annotation: The AnyLabeling tool was used for initial annotation of the rice ear images, followed by fine-tuning through human interaction to ensure efficiency and consistency. This included: The category label is uniformly set to "rice". Only complete and clearly identifiable rice ears are labeled, ignoring rice ears with incomplete main body at the image edge, extremely blurry, or with more than 50% of the area invisible.

[0028] Use an axis-aligned bounding box. The box should be flush with the outer rectangle of the rice ear, and the distance between the boundary and the edge of the rice ear should be controlled within 1-2 pixels. It is strictly forbidden to exceed the actual range of the rice ear.

[0029] The unified category label is "rice".

[0030] For rice ears that overlap, as long as they are identified as independent individuals, they must be labeled separately even if less than 50% of them are visible. When a rice ear intersects with the boundary of a white reference box, only the visible portion within the box is labeled.

[0031] After labeling is completed, a full manual review is performed to remove falsely detected targets (such as leaf tips, light spots, etc.), fill in any missed rice ears, and adjust any inaccurately positioned detection frames to ensure they are close to the target edge. For labeling frames that are stuck together or incorrectly split, a deletion and relabeling operation is performed to ensure that each detection frame accurately corresponds to a single rice ear.

[0032] After annotation, the images and corresponding annotation files are divided into training, validation, and test sets according to a certain ratio. In this embodiment, a 70% training set, 20% validation set, and 10% test set partitioning method is adopted to ensure that the proportion of samples of different varieties and under different lighting conditions in each set is basically consistent, preventing evaluation bias caused by uneven data distribution. The training set is used to learn model parameters, the validation set is used for hyperparameter optimization and early model stopping, and the test set is only used for final performance evaluation after the model training is completed, ensuring the objectivity and fairness of the test results.

[0033] like Figure 2 As shown, in step 2, the YOLOv11 model is improved to obtain the MLCA-YOLOv11s model; wherein, the Hybrid Local Channel Attention (MLCA) module is introduced at the end of the backbone network. The execution flow of the MLCA module is as follows: The input feature map is divided into groups using grouped convolution. There are 1 group; within each group, 1D convolution is used to capture local cross-channel interaction information, generating local channel attention weights, expressed as: In the formula, Local channel attention weights; Use the Sigmoid activation function; This is a one-dimensional convolution operation; This is a grouped convolution operation; For the input feature map Perform Global Average Pooling (GAP) to obtain the global context information of the entire feature map and generate a global feature vector. The expression is as follows: In the formula, This is the global feature vector; This is a global average pooling operation; The attention weights of the local channels are weighted and combined with the global feature vector to generate an attention weight vector, expressed as follows: In the formula, This is the attention weight vector; These are learnable weight coefficients used to balance local and global information; The attention weight vector is element-wise multiplied with the original input feature map X to achieve adaptive recalibration of the feature map, enhancing the response of key features of the rice ear and suppressing background noise. The expression is as follows: In the formula, The output features are those after adaptive calibration.

[0034] The aforementioned hybrid local channel attention module effectively improves the model's ability to focus on rice ear features by utilizing a hybrid attention mechanism of local and global channels without introducing additional learnable parameters (the number of parameters is consistent with the baseline).

[0035] like Figure 2 As shown, the MLCA module is located after the SPPF module and before the detection head. This position is at the highest-level feature map of the backbone (with the largest receptive field), which can gather all semantic information and use attention to emphasize the feature channels related to rice ears, thereby improving the model's detection accuracy for dense occlusion and complex backgrounds.

[0036] Step 3: Train the MLCA-YOLOv11s model using the training set, validation set, and test set to generate the final MLCA-YOLOv11s model.

[0037] Step 4: Input the image of the rice ear to be detected into the final MLCA-YOLOv11s model to generate the rice ear recognition result.

[0038] In one embodiment, to verify the beneficial effects of the method of the present invention, precision ("P"), recall ("R"), F1-score, mAP50, mAP50-95 (average precision when the intersection-union ratio reaches 0.5 to 0.95), number of parameters, giga-floating-point-of-operations per second ("GFLOPs"), and model size are used as comprehensive performance indicators to evaluate the model, and the model is evaluated from multiple dimensions such as recognition accuracy, computational efficiency, and resource consumption.

[0039] in, (True Positive) indicates that the rice seedlings were correctly detected. (False Positive) indicates that the background or clutter was incorrectly identified as rice seedlings (false detection). (False Negative) represents rice seedlings that were not detected (missed detection). mAP50 represents the average accuracy of target detection when the IoU threshold is set to 0.5. mAP50-95 represents the average of 10 average accuracies calculated when the IoU ranges from 0.5 to 0.95 (in increments of 0.05).

[0040] To select the most suitable YOLOv11 version for the rice ear recognition task, four versions of YOLOv11 (nano, small, medium, and large) were systematically trained and tested on the same rice ear dataset. The results are shown in Table 1.

[0041] Table 1

[0042] YOLOv11n, YOLOv11s, YOLOv11m, and YOLOv11l represent the four versions: nano, small, medium, and large, respectively.

[0043] In terms of the core evaluation metric mAP50, YOLOv11n, YOLOv11s, YOLOv11m, and YOLOv11l achieved mAP50 of 82.40%, 84.42%, 85.93%, and 85.73%, respectively. Overall, detection accuracy showed an upward trend with increasing model size. However, YOLOv11l's mAP50 (85.73%) was slightly lower than YOLOv11m's (85.93%), indicating that accuracy improvement tends to saturate after the model size exceeds a certain level. Specifically, YOLOv11m achieved the highest mAP50 value (85.93%), but its parameter count was 20.03M, approximately 2.1 times that of YOLOv11s. YOLOv11s achieved an mAP50 of 84.42%, only 1.51% lower than YOLOv11m, but with approximately 53% fewer parameters. This result is consistent with the findings of Wang Xue et al. In the rice ear detection task, the lightweight version can maintain high accuracy and greatly reduce the complexity of the model.

[0044] In terms of precision and recall, YOLOv11m is more precise and has a higher recall than other versions. YOLOv11l has the highest recall (81.36%), but its precision (82.24%) is lower than YOLOv11m and YOLOv11s, indicating that while YOLOv11l "finds more comprehensive" samples, its false positive rate is also relatively high. This phenomenon may be due to the distribution characteristics of rice ears in field images. While increasing the model capacity improves the model's sensitivity to positive samples, its ability to suppress background interference is not correspondingly enhanced. YOLOv11n has the lowest precision across all metrics, with mAP50 at only 82.40%, 2.02% lower than YOLOv11s. The reason for this is that YOLOv11n has only 2.58M parameters, limiting its model capacity and making it difficult to fully learn the morphological features of rice ears in complex scenarios such as dense occlusion and varying scales. This is consistent with the observations of Long Yongbing et al.: small parameter models have limited feature representation capabilities in complex field environments.

[0045] Attention mechanisms can guide the model to focus on key feature regions in an image and suppress irrelevant background interference, thereby effectively improving the accuracy of object detection. To investigate the impact of different attention modules on the performance of the YOLOv11s model in rice ear detection, this study integrated five attention mechanisms—AFGCAttention, CoordAttention, ELA, EMA, and MLCA—on YOLOv11s and trained and tested them under the same parameter settings. The impact of different attention mechanisms on model performance is shown in Table 2.

[0046] Table 2

[0047] As shown in Table 2, the MLCA module performed best across all evaluation metrics. Compared to the baseline YOLOv11s, MLCA improved mAP50 from 84.42% to 85.10%, a 0.68% increase, the largest improvement among all attention modules; mAP50-95 improved from 50.44% to 50.47%, also outperforming the baseline and other modules. Precision, recall, and F1 score were 83.66%, 78.29%, and 80.89%, respectively, all showing stable improvements. Furthermore, MLCA maintained a constant parameter count of 9.41M, GFLOPs of 21.3, and a model size of 18.3MB, identical to the baseline, demonstrating extremely high parameter and computational efficiency. This indicates that MLCA effectively improved the accuracy of rice spike detection without increasing model complexity.

[0048] AFGCAttention showed the most significant improvement in precision, reaching 85.41%, a 2.14% increase from the baseline. However, its parameter count and model size increased slightly, and its mAP50-95 was lower than the baseline, indicating a decrease in localization accuracy under a stricter IoU threshold. The EMA module showed the most significant improvement in recall (78.66%), but its precision was low (82.79%), and its inference speed was slow, resulting in poor real-time performance. The ELA module saw a significant increase in parameter count (11.25M) and model size to 21.8MB, but its accuracy improvement was limited, making it the least cost-effective overall. The CoordAttention module showed only minor improvements across various metrics, with little noticeable effect.

[0049] To comprehensively evaluate the effectiveness and advantages of the improved YOLOv11s+MLCA model in this study, its performance is compared with that of the current mainstream single-stage detectors YOLOv6s, YOLOv8s, YOLOv10s, YOLOv11s, and YOLOv12s, as shown in Table 3.

[0050] Table 3

[0051] As shown in Table 3, in terms of detection accuracy, YOLOv11s+MLCA achieved an mAP50 of 85.10%, the highest among all comparative models, which is 0.68% higher than the original YOLOv11s and 0.11% higher than YOLOv8s (84.99%). In the more stringent mAP50-95 metric, this model achieved 50.47%, which is better than YOLOv11s (50.44%) and YOLOv12s (50.09%), but slightly lower than YOLOv8s (51.22%) and YOLOv10s (50.80%), though the difference is within an acceptable range. In terms of precision, YOLOv11s+MLCA achieved 83.66%, which is higher than YOLOv11s (83.27%), but lower than YOLOv8s and YOLOv10s; the recall rate was 78.29%, which is 1.03% higher than YOLOv11s, showing a significant improvement, indicating that the MLCA module effectively alleviated the missed detection problem of the original model.

[0052] In terms of model efficiency, YOLOv11s+MLCA has 9.41M parameters, 21.3 GFLOPs, and a model size of 18.3MB, almost identical to the original YOLOv11s, with no increase in computation. Compared to YOLOv6s, the number of parameters is reduced by 42.2%, computation by 51.6%, and model size by 41.7%; compared to YOLOv8s, the number of parameters is reduced by 15.4%, computation by 25.0%, and model size by 14.9%; compared to YOLOv10s, the number of parameters increases by approximately 31.3%, but the model size only increases by 3.7MB, and mAP50 improves by 0.28%; compared to YOLOv12s, the number of parameters and model size are basically the same, but mAP50 improves by 0.66%. This indicates that the improved YOLOv11s+MLCA model maintains excellent detection performance while possessing computational efficiency comparable to lightweight models, making it suitable for deployment on embedded devices with limited computing resources.

[0053] like Figure 3 As shown in the results, the overall detection performance of YOLOv11s+MLCA on the validation set is relatively good. Figure 4 As shown in the comparison images before and after the improvement, YOLOv11s exhibits some missed detections in densely packed rice panicles. YOLOv11s+MLCA can perform more complete detection of adjacent or partially obscured rice panicles, thus improving the missed detection rate to some extent. like Figure 5 As shown, the YOLOv11s+MLCA model exhibits good convergence characteristics during training. In the early stages of training, the bounding box loss (Box Loss), classification loss (Cls Loss), and distribution focus loss (DFL Loss) all decrease rapidly, indicating that the model can quickly learn effective feature representations from the data. Around the 120th epoch, the various training losses begin to enter a stable convergence state, and the corresponding loss curves on the validation set are basically synchronized with the training loss curves, without obvious overfitting, indicating that the selected training parameters are reasonable.

[0054] Furthermore, precision and recall increased rapidly in the early stages of training and then stabilized at around 0.83 and 0.78, respectively. The model's mAP50 reached 85.10%, and mAP50-95 stabilized at 50.47%, indicating that the model maintained good detection and localization capabilities even under relatively strict IoU thresholds. Compared with the baseline model YOLOv11s, the improved model showed a slightly faster convergence speed and higher final accuracy, demonstrating the effective enhancement of model performance by the MLCA attention mechanism.

[0055] like Figure 6As shown in the precision-recall curves, the area under the PR curve (mAP50) of the YOLOv11s+MLCA model is 0.854, which is an improvement compared to the baseline model. The overall curve shape indicates that the model can maintain a relatively high combination of precision and recall at different confidence thresholds.

[0056] like Figure 7 As shown in the F1-confidence curve, the F1 value of the YOLOv11s+MLCA model exhibits a typical unimodal characteristic under different confidence thresholds. The model's optimal F1 value reaches 0.81, corresponding to an optimal confidence threshold of 0.458.

[0057] In summary, MLCA was introduced into the backbone of YOLOv11s to enhance the model's ability to focus on key channel features of rice panicles and suppress background interference. A comparative analysis was conducted with four versions of YOLOv11. The results show that among the four versions of the YOLOv11 series, YOLOv11s achieves the optimal balance between detection accuracy and model complexity. Its mAP50 reaches 84.42%, only 1.51% lower than the highest-accurate YOLOv11m (85.93%), but with approximately 53% fewer parameters and a 68.5% reduction in computational cost. Considering that in practical field applications, the model needs to be deployed on embedded devices with limited computing resources (such as UAV-borne computing platforms or field monitoring terminals), YOLOv11s' lightweight advantage, while maintaining high detection accuracy, is more practically significant. Therefore, choosing YOLOv11s as the baseline model for subsequent improvements is reasonable.

[0058] By comparing the performance of five attention mechanisms (AFGCAttention, CoordAttention, ELA, EMA, and MLCA) with the baseline model, it was found that MLCA performed better overall. After embedding MLCA into the backbone of YOLOv11s, while keeping the number of parameters and computational cost basically unchanged, the model's mAP50 increased to 85.10%, which is 0.68% higher than the baseline, and the recall rate increased from 77.26% to 78.29%, which improved the false negative problem to some extent. Compared with mainstream single-stage detectors such as YOLOv6s, YOLOv8s, YOLOv10s, and YOLOv12s, the improved YOLOv11s+MLCA in this study achieves an mAP50 of 85.10%, while maintaining a relatively low model size and computational cost. Although YOLOv12s is the latest model released in 2025 and has the lowest computational cost (19.3 GFLOPs), its mAP50 is only 84.44%, 0.66% lower than our model. This indicates that simply pursuing model lightweighting may come at the cost of detection accuracy, while our model achieves a better balance between accuracy and efficiency. Visualization also shows that the improved YOLOv11s+MLCA performs relatively well in identifying rice ears, improving the accuracy of rice ear identification under extremely dense and severely occluded conditions to some extent.

[0059] In one embodiment, the present invention provides an electronic device including a memory and a processor, the memory being used to store a computer program, and the processor running the computer program to enable the electronic device to perform the rice ear identification method based on MLCA-YOLOv11s, the electronic device, and the storage medium described above.

[0060] The detailed steps are the same as those described above for rice ear identification method, electronic device and storage medium based on MLCA-YOLOv11s, and will not be repeated here.

[0061] In one embodiment, the present invention provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the rice ear identification method, electronic device, and storage medium based on MLCA-YOLOv11s.

[0062] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, electronic devices, or computer-readable storage media. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-readable program code. The solutions in the embodiments of the present invention can be implemented using various computer languages, such as the object-oriented programming language Java and the interpreted scripting language JavaScript.

[0063] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, electronic devices, and computer-readable storage media according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0064] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0065] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0066] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.

[0067] This document uses specific examples to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the core ideas of the present invention. Furthermore, those skilled in the art will recognize that, based on the ideas of the present invention, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A rice panicle identification method based on MLCA-YOLOv11s, characterized in that, include: The dataset of rice ear images was obtained, preprocessed, and divided into training, validation, and test sets. Based on the YOLOv11 model, the MLCA-YOLOv11s model is improved, in which the Hybrid Local Channel Attention (MLCA) module is introduced at the end of the backbone network. The MLCA-YOLOv11s model is trained using the training set and validation set, and the performance of the MLCA-YOLOv11s model is tested using the test set to generate the final MLCA-YOLOv11s model. The image of the rice ear to be detected is input into the final MLCA-YOLOv11s model to generate the rice ear recognition result.

2. The rice panicle identification method based on MLCA-YOLOv11s according to claim 1, characterized in that, The rice ear image dataset uses different rice varieties, nitrogen fertilizer application concentrations, and plant spacing combinations as data collection objects.

3. The rice panicle identification method based on MLCA-YOLOv11s according to claim 2, characterized in that, The nitrogen fertilizer application concentration includes: setting four pure nitrogen application concentration gradients, each 12 kg / hm². 2 15 kg / hm 2 18 kg / hm 2 and 21kg / hm 2 .

4. The rice panicle identification method based on MLCA-YOLOv11s according to claim 2, characterized in that, The plant spacing combinations include four combinations: 30cm×20cm, 30cm×18cm, 30cm×16cm, and 30cm×14cm.

5. The rice panicle identification method based on MLCA-YOLOv11s according to claim 1, characterized in that, The preprocessing includes cropping and labeling the collected rice ear images.

6. The rice panicle identification method based on MLCA-YOLOv11s according to claim 5, characterized in that, The cropping process includes: using Adobe Photoshop as the image cropping tool, using the four inner edges of the white frame as the cropping boundaries, the cropped image includes the entire area inside the white frame but does not include the frame itself, and the image is uniformly exported as a JPEG format with the quality parameter set to 95%.

7. The rice panicle identification method based on MLCA-YOLOv11s according to claim 5, characterized in that, The annotation process includes: initially annotating the rice ear image using the AnyLabeling tool, and then refining it through manual interaction.

8. The rice panicle identification method based on MLCA-YOLOv11s according to claim 1, characterized in that, The Hybrid Local Channel Attention Module (MLCA) includes: The input feature map is divided into groups using group convolution. There are 1 group; within each group, local channel attention weights are generated using one-dimensional convolution, expressed as: In the formula, Local channel attention weights; Use the Sigmoid activation function; This is a one-dimensional convolution operation; This is a grouped convolution operation; For the input feature map Perform global average pooling to generate a global feature vector, expressed as: In the formula, This is the global feature vector; This is a global average pooling operation; The attention weights of the local channels are weighted and combined with the global feature vector to generate an attention weight vector, expressed as follows: In the formula, This is the attention weight vector; These are learnable weight coefficients; The attention weight vector is multiplied element-wise by the original input feature map X, as shown in the expression: In the formula, The output features are those after adaptive calibration.

9. An electronic device, characterized in that, The device includes a memory and a processor, the memory being used to store a computer program, and the processor running the computer program to cause the electronic device to perform the rice ear identification method based on MLCA-YOLOv11s according to any one of claims 1-8.

10. A computer-readable storage medium, characterized in that, It stores a computer program that, when executed by a processor, implements the rice ear identification method based on MLCA-YOLOv11s as described in any one of claims 1-8.