High-yield rape breeding screening method and system

CN122657727APending Publication Date: 2026-08-28CHONGQING ACAD OF AGRI SCI
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610838985.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-11
Publication Date
2026-08-28

AI Technical Summary

Technical Problem

尽管目标检测与计数研究已取得显著进展,但在离体考种场景下,面对角果密集簇生、局部重叠且果喙尺寸微小等客观形态,在资源受限的边缘计算设备上实现高精度实时计数仍面临严峻挑战

Benefits of technology

[0019] To address the challenge of accurate detection caused by the dense overlapping of rapeseed pods and their tiny beaks, this invention proposes an improved model, YOLOv11n-A. 3(YOLOv11n with Area Attention and Aligned Fusion) The main body adopts the lightweight convolutional structure of YOLOv11n. To further enhance the global representation ability of the rapeseed pod beak detection model for pod features, a Cross-Stage Partial with Spatial Attention (C2PSA) module is embedded in the high-level backbone network to jointly model channels and space. While retaining the advantage of Spatial Pyramid Pooling Fast (SPPF) module in expanding the receptive field, it significantly improves the representation ability of multi-scale features without significantly increasing computational cost. Secondly, an Area Attention (A2) module is introduced to locally enhance the neck feature fusion network. Some convolutions in the original network are replaced with A2 modules to maintain controllable training and deployment risks while leveraging their local area perception capabilities to improve the network's feature extraction and anti-interference ability for densely overlapping small targets. Finally, a bidirectional feature alignment and fusion structure consisting of an Aligned Feature Pyramid Network (Align-FPN) and an Aligned Path Aggregation Network (Align-PAN) was constructed to replace the original standard feature fusion path. In the Align-FPN stage, the Area-Attention Enhanced Cross-Feature module (A2C2f) and the Tiny Multi-Scale Context (TMC) module (P3) are used to effectively transfer high-level semantic features to low-level features. A Soft Nearest Neighbor Interpolation (SNI) module is introduced to alleviate the inconsistency in the spatial distribution of features at different scales. In the Align-PAN stage, an Extended Spatial-window Down-sampling (ESD) module is further combined to separate and enhance features. An adaptive weighted fusion mechanism highlights key scale features, thereby significantly enhancing the interaction and consistency between multi-scale features.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122657727A_ABST
    Figure CN122657727A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of agricultural planting, and discloses a high-yield rape intelligent breeding screening method and system, which comprises the following steps: S1: obtaining multiple rape plant branch images; S2: labeling the top end of the mature rape silique beak region and dividing it into a training set, a validation set and a test set; S3: uniformly scaling the sample size to a preset pixel to form a standardized network input tensor; S4: inputting the standardized network input tensor into a rape silique beak detection model for forward propagation; S5: repeating the operations of S3 and S4, and stopping training when the maximum training round is reached; S6: after each training round ends, inputting the validation set into the current rape silique beak detection model for forward evaluation; S7: inputting the test set into the saved optimal model for independent testing; and S8: obtaining multiple rape plant branch images, and obtaining the number of rape silique corresponding to the images through the rape silique beak detection model. The present application realizes accurate and efficient counting of rape silique by accurately identifying tiny beaks.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of agricultural planting technology, specifically to a smart breeding and screening method and system for high-yield rapeseed. Background Technology

[0002] Rapeseed is my country's largest oilseed crop, and increasing its yield is the core objective of breeding work. The number of effective siliques per plant, as a core factor in rapeseed yield, is an essential key trait parameter in the breeding process, and its accurate counting is crucial for the selection of high-yielding and superior varieties.

[0003] However, traditional manual in vitro seed testing faces limitations such as low efficiency and high labor intensity. Especially when dealing with densely clustered, overlapping pods, operators are prone to visual fatigue from prolonged staring at the tiny pod beaks, leading to frequent errors and omissions, and making it difficult to guarantee data accuracy. Furthermore, the low throughput of manual counting can easily cause seed testing to miss critical growth periods, resulting in invalid phenotypic data and serious delays in the breeding cycle. Therefore, developing an accurate, efficient, and real-time rapeseed pod detection and counting technology is of great significance for reducing the labor intensity of seed testing and accelerating the breeding process.

[0004] In the research on rapeseed pod identification and counting, scholars have mainly explored the field from the perspective of 3D reconstruction and analysis based on point clouds. Xu Shengyong et al. used an RGB-D camera to collect multi-view depth maps of rapeseed branches, and achieved high-precision 3D reconstruction through curvature feature pairing and an improved ICP algorithm. They then combined Euclidean clustering to complete pod localization, achieving a pod identification accuracy of 96.76%. Xie Zhonghong et al. proposed a rapeseed branch point cloud registration method based on ISS-LCG combined feature points and RANSAC+ICP, reducing the registration error to 0.066mm and improving efficiency by 50%–70%. Jiajun Liu et al. proposed a lightweight semantic segmentation model, KAN-GLNet, which achieved high-precision counting of rapeseed pods through NeRF point cloud reconstruction and an optimized DBSCAN algorithm, achieving a semantic segmentation mIoU of 94.50% and a counting accuracy of 97.45%. The number of rapeseed pods on branches and individual plants can be accurately identified through the 3D reconstruction and analysis of point clouds. However, the complex acquisition and processing process of point cloud technology has high requirements for the operating environment and hardware equipment, and the data processing takes a long time, making it difficult to meet the application needs of field seed testing for operational flexibility and real-time efficiency.

[0005] In recent years, deep learning-driven object detection and counting algorithms have been widely implemented and applied in the field of smart agriculture. Regarding improvements to convolutional neural networks, most high-performance convolutional models currently improve accuracy by increasing network depth or introducing structures such as multi-scale feature fusion and attention mechanisms. However, these methods often lead to a significant increase in the number of model parameters and computational cost, limiting their real-time deployment capabilities on embedded or edge devices. Furthermore, their robustness in real-world, complex agricultural scenarios still needs further improvement.

[0006] The YOLO series of algorithms has become a focus of academic attention due to its high efficiency, lightweight nature, strong generalization ability, and robust stability. Although significant progress has been made in target detection and counting research, achieving high-precision real-time counting on resource-constrained edge computing devices still faces severe challenges in in vitro specimen testing scenarios, given the objective morphology of densely clustered siliques, local overlap, and small beak size. Summary of the Invention

[0007] To overcome the shortcomings of existing technologies, one of the objectives of this invention is to provide a smart breeding and screening method for high-yield rapeseed, which achieves accurate and efficient counting of rapeseed pods by precisely identifying tiny fruit beaks, in order to provide technical support for rapeseed variety testing and the selection of high-yield and high-quality varieties.

[0008] The technical solution adopted in this invention is as follows: a smart breeding and screening method for high-yield rapeseed, comprising the following steps:

[0009] S1: Collect mature rapeseed plants, cut the collected rapeseed plants, obtain rapeseed plant branches, and use a mobile device to collect multiple images of rapeseed plant branches in various scenes, including indoor, outdoor shaded areas and natural field light.

[0010] S2: Label the top of the beak region of mature rapeseed pods in multiple rapeseed plant branching images, and divide the labeled images into training set, validation set and test set according to the proportion;

[0011] S3: The training set uses an online augmentation strategy to randomly generate new augmented samples in real time, and the size of the new augmented samples is uniformly scaled to a preset pixel to form a standardized network input tensor.

[0012] S4: The standardized network input tensor is input into the rapeseed pod and beak detection model for forward propagation. Specifically, multi-scale features are extracted layer by layer through the backbone network, top-down and bottom-up features are extracted through the neck network, and the detection head outputs the predicted bounding box coordinates and category score vector of the pod and beak. The error between the output result and the label is calculated through the loss function. Then, the gradient of each parameter of the rapeseed pod and beak detection model is calculated through backpropagation, and the parameters of the rapeseed pod and beak detection model are updated using the optimizer.

[0013] S5: Repeat steps S3 and S4 until the maximum number of training rounds is reached;

[0014] S6: After each training round, the validation set is input into the current rapeseed pod and beak detection model for forward evaluation. The weighted comprehensive index on the validation set is calculated. When the weighted comprehensive index corresponding to multiple validations does not improve, the adaptive learning rate decay mechanism is triggered. If the learning rate has dropped to the minimum threshold and the index is still stagnant, the early stopping mechanism is triggered to stop training. When the current weighted comprehensive index exceeds the historical weighted comprehensive index, the current rapeseed pod and beak detection model is saved as the optimal rapeseed pod and beak detection model.

[0015] S7: Independently test the optimal rapeseed pod beak detection model with the test set input. If the detection accuracy and counting error of the test set meet the preset requirements, the model training is completed; otherwise, the training rounds are adjusted.

[0016] S8: Collect mature rapeseed plants, cut the collected rapeseed plants, obtain rapeseed plant branches, collect images of rapeseed plant branches through a mobile device, obtain multiple rapeseed plant branch images, and then obtain the number of rapeseed pods corresponding to the images through a trained rapeseed pod beak detection model.

[0017] The second objective of this invention is to provide a high-yield rapeseed intelligent breeding and screening system. Employing the aforementioned high-yield rapeseed intelligent breeding and screening method, the system includes an acquisition module, an analysis module, and an output module. The acquisition module acquires images of rapeseed plants. The analysis module uses a trained rapeseed pod beak detection model to sequentially extract multi-scale features layer by layer through the backbone network, top-down and bottom-up feature extraction through the neck network, and outputs the predicted bounding box coordinates and category score vectors of the pod beak from the detection head. Subsequently, non-maximum suppression is performed on the predicted bounding boxes of the same category in descending order of confidence to remove redundant overlapping boxes. The final number of retained detection boxes represents the number of rapeseed pods in the image. The output module outputs the rapeseed pod beak count value.

[0018] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0019] To address the challenge of accurate detection caused by the dense overlapping of rapeseed pods and their tiny beaks, this invention proposes an improved model, YOLOv11n-A. 3(YOLOv11n with Area Attention and Aligned Fusion) The main body adopts the lightweight convolutional structure of YOLOv11n. To further enhance the global representation ability of the rapeseed pod beak detection model for pod features, a Cross-Stage Partial with Spatial Attention (C2PSA) module is embedded in the high-level backbone network to jointly model channels and space. While retaining the advantage of Spatial Pyramid Pooling Fast (SPPF) module in expanding the receptive field, it significantly improves the representation ability of multi-scale features without significantly increasing computational cost. Secondly, an Area Attention (A2) module is introduced to locally enhance the neck feature fusion network. Some convolutions in the original network are replaced with A2 modules to maintain controllable training and deployment risks while leveraging their local area perception capabilities to improve the network's feature extraction and anti-interference ability for densely overlapping small targets. Finally, a bidirectional feature alignment and fusion structure consisting of an Aligned Feature Pyramid Network (Align-FPN) and an Aligned Path Aggregation Network (Align-PAN) was constructed to replace the original standard feature fusion path. In the Align-FPN stage, the Area-Attention Enhanced Cross-Feature module (A2C2f) and the Tiny Multi-Scale Context (TMC) module (P3) are used to effectively transfer high-level semantic features to low-level features. A Soft Nearest Neighbor Interpolation (SNI) module is introduced to alleviate the inconsistency in the spatial distribution of features at different scales. In the Align-PAN stage, an Extended Spatial-window Down-sampling (ESD) module is further combined to separate and enhance features. An adaptive weighted fusion mechanism highlights key scale features, thereby significantly enhancing the interaction and consistency between multi-scale features.

[0020] This invention uses an improved YOLO11n algorithm to detect and count rapeseed siliques. Given the high density and multi-angle overlap of siliques, direct detection of the entire silique can easily lead to blurred boundaries and duplicate counting. In contrast, the beak, as the only slender end of the silique, is not only distinctive but also lacks seed filling, showing a clear difference from the filled area. Therefore, this study selects the beak of the silique as the detection target to reduce the false negative and false positive rates in densely populated scenes. Attached Figure Description

[0021] Figure 1 This is a flowchart of the intelligent breeding and screening method for high-yield rapeseed according to the present invention;

[0022] Figure 2 This is a structural diagram of the rapeseed horn beak detection model for the intelligent breeding and screening method for high-yield rapeseed of this invention;

[0023] Figure 3 This is a structural diagram of the A2C2F module of the intelligent breeding and screening method for high-yield rapeseed of this invention;

[0024] Figure 4 This is a structural diagram of the TMC module of the intelligent breeding and screening method for high-yield rapeseed of this invention;

[0025] Figure 5 This is an example image of rapeseed pod acquisition in the intelligent breeding and screening method for high-yield rapeseed of this invention;

[0026] Figure 6 This is an example image annotation of rapeseed pods in the intelligent breeding and screening method for high-yield rapeseed of the present invention;

[0027] Figure 7 This is a comparison chart (mAP) of YOLO series model training in the intelligent breeding and screening method for high-yield rapeseed of this invention. 0.5 Change curve graph;

[0028] Figure 8 This is a comparison chart (mAP) of YOLO series model training in the intelligent breeding and screening method for high-yield rapeseed of this invention. 0.5-0.95 Change curve;

[0029] Figure 9 This is a comparison chart of YOLO series model training and accuracy change curves in the intelligent breeding and screening method for high-yield rapeseed of this invention;

[0030] Figure 10 This is a comparison chart of YOLO series model training and recall rate changes in the intelligent breeding and screening method for high-yield rapeseed of this invention. Detailed Implementation

[0031] The present invention will now be described in detail with reference to the accompanying drawings and embodiments.

[0032] In this embodiment, the C3K2 module is a lightweight cross-stage local network feature extraction module, the SPPF module is a fast spatial pyramid pooling module, the C2PSA module is a cross-stage local spatial attention module, the SNI module is a scalable neighborhood interaction module, the A2C2F module is a region attention-enhanced cross-feature module, the TMC module is a context enhancement module, and the ESD module is an efficient spatial downsampling module.

[0033] This embodiment discloses a smart breeding and screening method for high-yield rapeseed, such as... Figure 1 , 2 As shown, it includes the following steps:

[0034] S1: Collect mature rapeseed plants, cut the collected rapeseed plants, and obtain rapeseed branches, such as... Figure 5 As shown, multiple images of rapeseed plant branches were acquired by using a mobile device in various scenarios, including indoors, in shaded outdoor areas, and under natural light in the field.

[0035] In this embodiment, mature rapeseed plants are collected, and the branches of the rapeseed plants are manually cut off, such as... Figure 1 As shown, multiple scene images of rapeseed plant branches were collected in indoor, outdoor shaded areas and under natural light in the field. The images were taken using a mobile device at a distance of about 30-50cm from the branches, and a total of 3842 RGB images (4032 pixels × 3024 pixels) were obtained.

[0036] S2: Label the top of the beak region of mature rapeseed pods in multiple rapeseed plant branching images, and divide the labeled images into training set, validation set and test set in a ratio of 8:1:1.

[0037] In this embodiment, as Figure 6 As shown, bounding boxes were labeled at the top of the mature rapeseed beak region in the original image. A total of 3842 images and 97348 bounding boxes were labeled, and categories were defined as beak, background and other. The images were saved as YOLO format files. The labeled images were divided into a training set of 3074 images, a validation set of 384 images and a test set of 384 images in a ratio of 8:1:1.

[0038] S3: The training set uses an online augmentation strategy to randomly generate new augmented samples in real time. The size of the new augmented samples is uniformly scaled to 960×960 pixels to form a standardized network input tensor.

[0039] Before each training session, the training set generates new augmented samples in real time using an online augmentation strategy. Specifically, spatial transformation, blending enhancement, color and flip operations are performed on the labeled images to obtain the transformed images.

[0040] Specifically, firstly, multiple training images are mosaicked to increase the target density in a single frame. Then, random perspective / affine transformations (including rotation, translation, scaling, shearing, and perspective distortion) are superimposed to simulate different shooting angles and distances. Next, the spatially transformed images are stitched together to further enrich the sample diversity. Then, the hue, saturation, and brightness of the enhanced images are perturbed, and the images are randomly flipped horizontally and vertically to enhance robustness to different imaging conditions. For example, the hue perturbation hsv_h is set to 0.015, the saturation perturbation hsv_s is set to 0.7, the brightness perturbation hsv_v is set to 0.4, and the mirror perturbation fliplr is set to 0.5.

[0041] In this embodiment, unlike traditional offline enhancement before training (which pre-generates a fixed set of enhanced samples), an online enhancement strategy is adopted during training. Randomly transformed samples are generated in real time in each training round, so that the rapeseed pod beak detection model is continuously exposed to rapeseed branch image variants under different lighting, angle and scale conditions during the training process.

[0042] The online augmentation strategy dynamically increases the equivalent size of the training data with the combination of training epochs and random augmentation. In this embodiment, the maximum number of training epochs in the training record is 100. In each training epoch, different variants of the training images are generated according to the above-mentioned online augmentation strategy before being fed into the network, thereby enhancing the generalization ability under limited sample conditions.

[0043] S4: The standardized network input tensor is input into the rapeseed pod and beak detection model for forward propagation. Specifically, multi-scale features are extracted layer by layer through the backbone network, top-down and bottom-up features are extracted through the neck network, and the detection head outputs the predicted bounding box coordinates and category score vector of the pod and beak. The error between the output result and the label is calculated through the loss function. Then, the gradient of each parameter of the rapeseed pod and beak detection model is calculated through backpropagation, and the parameters of the rapeseed pod and beak detection model are updated using the optimizer.

[0044] In this embodiment, the maximum number of training rounds is 100.

[0045] In this embodiment, the corresponding weights and biases are automatically obtained during training. After each training is completed, the weights and biases of the rapeseed horn beak detection model are updated by the optimizer through backpropagation.

[0046] Specifically, S4 includes the following:

[0047] S41: The standardized network input tensor is processed layer by layer through the backbone network to extract multi-scale features, resulting in a first shallow feature map with a downsampling step size of 8, a second shallow feature map with a downsampling step size of 16, and a third shallow feature map with a downsampling step size of 32.

[0048] Specifically, S41 includes the following:

[0049] First, the standardized network input tensor undergoes feature extraction and downsampling through several convolutional layers and the C3K2 module, with a downsampling stride of 8, to obtain the first shallow feature map. First shallow feature map The pixel size is 120×120, and this is the first shallow feature map. It retains relatively rich spatial detail information, which is used to detect tiny fruit beak targets.

[0050] In this embodiment, the standardized network input tensor first passes through the first convolutional layer, the second convolutional layer, the third C3K2 module, the fourth convolutional layer, and the fifth C3K2 module sequentially for feature extraction and downsampling, with a downsampling stride of 8, to obtain the first shallow feature map. As shown in the formula below,

[0051] ,

[0052] ,

[0053] ,

[0054] ,

[0055] ,

[0056] ,

[0057] In the formula, For the standardized network input tensor, , , , These are the input feature maps after the corresponding operations. , , , , These are the weights for the corresponding levels. , , , , These are the biases for the corresponding levels. It is a non-linear activation function.

[0058] , , All are convolutional kernels with a size of Step size is The convolutional downsampling operation is used to extract local features while reducing spatial resolution by a factor of two.

[0059] In this implementation, the standardized network input tensor undergoes three consecutive convolutional downsampling operations with a stride of 2, followed by two alternating C3K2 module operations, ultimately generating a spatial resolution equal to the original tensor. Figure 8 One-third of the first shallow layer feature map This feature map preserves relatively clear edge and spatial texture information of rapeseed pods, which will provide key low-level feature input for multi-scale feature alignment and fusion in the subsequent neck network.

[0060] In this embodiment, the input feature map is divided into two paths through the fifth-layer C3K2 module. One path directly uses a 1×1 convolution to preserve the original details, while the other path extracts local texture and shape features through a depthwise convolution. Finally, these are merged along the channel dimension. Its function is to rapidly reduce spatial resolution while allowing shallow features to simultaneously carry two types of information: "fine-grained details" and "preliminary semantics"—the former used to depict the edges and contours of small objects such as fruit beaks, and the latter to provide sufficient channel bandwidth for the deep network. When the current sampling stride reaches 8, the first shallow feature map is output. (120×120) serves as a high-resolution detail source for subsequent detection of tiny fruit beaks.

[0061] Second, the first shallow feature map The features are then extracted and downsampled through the sixth convolutional layer and the seventh C3K2 module, with a downsampling stride of 16, to obtain the second shallow feature map. As shown in the formula below,

[0062] ,

[0063] ,

[0064] ,

[0065] In the formula, It is the input feature map after the corresponding operations. , These are the weights for the corresponding levels. , These are the biases for the corresponding levels. This is the activation function.

[0066] In this embodiment, the first shallow feature map Spatial downsampling is performed after a convolutional layer with a 3×3 kernel and a stride of 2, followed by further feature enhancement through the seventh C3K2 module to generate a second shallow feature map. Second shallow feature map The total downsampling step size of the normalized network input tensor relative to the initial input reaches 16, and its feature map space size is reduced to 60×60.

[0067] In this embodiment, the second shallow layer feature map It plays a crucial role in connecting the upper and lower layers, and is specifically designed to extract and carry the semantic features and spatial location information of medium-sized rapeseed pods. It has a larger receptive field and is used to detect medium-sized beak targets, thereby providing high-quality mid-level feature representations for subsequent multi-scale feature fusion of the neck network.

[0068] Third, the second shallow feature map The feature map is then extracted and downsampled sequentially through the eighth convolutional layer, the ninth SPPF module, and the tenth C2PSA module, with a downsampling stride of 32, resulting in the third shallow feature map. As shown in the formula below,

[0069] ,

[0070] ,

[0071] ,

[0072] ,

[0073] ,

[0074] ,

[0075] ,

[0076] In the formula, , These are the input feature maps after global context integration operations via convolution and pyramid pooling, respectively. , , , , These are the weights for the corresponding levels. , , , , These are the biases for the corresponding levels. This is the activation function.

[0077] In this embodiment, the second shallow layer feature map Spatial downsampling is performed through a convolutional layer with a kernel size of 3×3 and a stride of 2. Multi-scale contextual information is effectively aggregated through the SPPF module, and the C2PSA module is connected in series to jointly model channel and spatial features, thereby significantly enhancing the spatial attention expression of high-level semantic features.

[0078] In this embodiment, the third shallow layer feature map The total downsampling stride of the standardized network input tensor relative to the initial input reaches 32, and the feature map space size is reduced to 30×30. As the highest layer feature of the backbone network, the third shallow layer feature map... It possesses extremely rich global semantics and macroscopic receptive field, providing core high-level feature support for the rapeseed pod beak detection model to cope with complex scenarios such as dense distribution and severe occlusion of rapeseed pods, greatly increasing the receptive field for detecting large pod beak targets.

[0079] In this embodiment, the ninth-layer SPPF module performs global context integration through pyramid pooling of equivalent receptive fields of 5×5 / 9×9 / 13×13, and the tenth-layer C2PSA module enhances the ability of high-level semantics to focus on the beak region through position-aware spatial attention.

[0080] In the ninth-layer SPPF module, the second shallow layer feature map is first... Channel compression is performed using 1×1 convolution; then, three 5×5 max pooling operations are performed on the compressed feature map in sequence, with the output of each pooling operation serving as the input for the next pooling operation, thereby progressively obtaining spatial context features of three different receptive field ranges (5×5, 9×9, 13×13); finally, the original compressed features and the output of the three pooling operations are concatenated along the channel dimension (expanding the number of channels to 4 times), and then fused using 1×1 convolution to restore the original number of channels before output.

[0081] In the rapeseed pod detection scenario, the multi-scale pooling of the ninth-layer SPPF module enables each feature location to aggregate multi-level spatial information from local (single pod neighborhood) to global (the entire branch region), providing global context support for the subsequent accurate determination of tiny pod targets.

[0082] In this embodiment, in the tenth-layer C2PSA module, the input features are first divided into two equal branches along the channel dimension using a 1×1 convolution: one branch is directly passed as a cross-stage connection, preserving the original feature information; the other branch is processed by a location-aware spatial attention submodule—this submodule calculates attention weights for each spatial location of the feature, adaptively highlighting the region where the rapeseed pods are located and suppressing branch gaps and background interference through Sigmoid activation. Subsequently, the attention-enhanced features are concatenated with the directly passed original features along the channel dimension and fused and output through a 1×1 convolution.

[0083] While ensuring computational efficiency, the sensitivity of high-level semantic features to the spatial location of rapeseed pods is enhanced, enabling the rapeseed pod beak detection model to more accurately focus on the effective region where the beak is located in the branched image.

[0084] S42: Then, features are extracted from top to bottom through the neck network to obtain the first middle layer feature map, the second middle layer feature map, and the first deep layer feature map.

[0085] Specifically, S42 includes the following:

[0086] Third shallow layer feature map Upsampled and amplified by the eleventh-layer SNI module to match the second shallow layer feature map At the same spatial scale, and then compared with the second shallow feature map The layers are spliced ​​at the twelfth layer channel dimension and then fused by the thirteenth layer A2C2F module. This process enhances the spatial feature reshaping during the transmission of high-level semantics to the middle layer, resulting in an enhanced second middle-layer feature map. As shown in the formula below,

[0087] ,

[0088] ,

[0089] In the formula, It is the fusion feature after splicing.

[0090] Second middle layer feature map The feature map is upsampled and amplified by the fourteenth layer SNI module to match the first shallow layer feature map. The same spatial scale, and then compared with the first shallow feature map After being stitched together at the fifteenth layer channel dimension, the fusion is completed by the sixteenth layer A2C2F module, which is used for refined feature modeling at the scale of the smallest target to obtain the enhanced first middle-layer feature map. As shown in the formula below,

[0091] ,

[0092] ,

[0093] In the formula, It is the fusion feature after splicing.

[0094] Subsequently, as Figure 4 As shown, the final first deep feature map is obtained by deep convolution of the seventeenth layer TMC module to supplement multi-scale context. As shown in the formula below,

[0095] ,

[0096] ,

[0097] In the formula, For the input feature tensor, , These represent 2×2 depthwise convolutions with dilation rates of 1 and 2, respectively. These two convolutions are performed in parallel to extract spatial features from different receptive fields and then summed element-wise. It uses 2×2 pointwise convolution for cross-channel information exchange and dimensionality reduction projection. For batch normalization processing.

[0098] The seventeenth-layer TMC module supplements the first intermediate layer feature map with a convolutional paradigm. By leveraging the small target context, high-level semantic information can be effectively transferred to low-level high-resolution features.

[0099] The 17th layer TMC module, while strictly maintaining the feature map spatial size and number of channels, effectively captures richer multi-receptive field contextual information through parallel fusion of multi-dilation rate convolutions. This design is specifically designed for rapeseed fruit beak targets that are small in shape and easily confused. Without introducing excessive computational burden, it significantly reduces the risk of missed detection in densely occluded scenes and greatly improves the stability of the network in locating small targets.

[0100] In this embodiment, the third shallow layer feature map Second shallow feature map Second middle layer feature map and the first shallow feature map The purpose of cross-scale stitching is to merge the semantic information in high-level features with the spatial detail information in low-level features along the channel dimension, such as the third shallow feature map. This helps determine the semantic region where the fruit beak is located; low-level features (e.g., the first shallow feature map) are helpful. Preserving details such as the edge and end contour of the fruit beak, the fusion of the two can reduce missed detections and false detections in dense horned fruit scenarios.

[0101] In this embodiment, the purpose of upsampling and channel stitching is to preserve complementary information at two scales. The high-level features after upsampling provide stronger semantic context, while the low-level features provide more refined spatial positioning information. Together, they improve the positioning stability in dense fruit beak scenes.

[0102] In this embodiment, the eleventh-layer SNI module and the fourteenth-layer SNI module are used to alleviate the numerical mismatch problem during cross-scale feature fusion. Specifically, when high-level features (such as the third shallow feature map) are fused, the SNI module is used to alleviate the numerical mismatch problem during cross-scale feature fusion. (30×30 pixels) needs to be upsampled to match lower-level features (such as the second shallow feature map). When the spatial resolution is the same as that of a 60×60 pixel size, the SNI module performs two steps: First, it enlarges the feature map to the target size (magnification factor s=2, size from 60×60) using standard nearest neighbor interpolation. Become The first step involves copying each feature point into four 2×2 pixel blocks with the same value, expanding the feature map from 30×30 to 60×60. The second step is to multiply the enlarged feature map by a normalization coefficient. In this embodiment, the value is taken as... The SNI module performs the operation as shown in the following formula.

[0103] ,

[0104] In the formula, The normalization coefficient is... Nearest neighbor interpolation sampling.

[0105] In this embodiment, as Figure 3 As shown, the A2C2F module has the following input features. First through one Convolution completes channel projection and generates initial features. The module then concatenates several sub-units composed of stacked A2 units (in the diagram, "AreaAttention×2" indicates that a single sub-unit contains two attention transformations), resulting in a series of progressively updated intermediate features. Unlike layer-by-layer overlay stacking, A2C2f adopts a C2f-style feature convergence strategy: ... Output at each stage The splicing is performed in the channel dimension, and then through the end... Convolution performs fusion and compression, thus explicitly preserving representational information at different depths while maintaining computational control. Finally, the module can optionally introduce residual paths to transform the input... The result is summed with the fused output to enhance training stability and promote gradient propagation. Overall, this design combines the contextual modeling capabilities of the attention mechanism with the efficient feature aggregation of C2F, making it suitable as a lightweight yet expressive feature extraction unit in detection networks. The A2C2F module performs the operation as shown in the following formula.

[0106] ,

[0107] ,

[0108] In the formula, Indicates the first indivual Sub-units, each containing two attention shifts. , These are the weights of the corresponding convolutional layers. , These are the biases of the corresponding convolutional layers.

[0109] Through the A2C2f module, this local replacement design approach improves the characterization and detection capabilities of densely distributed, mutually occluded small fruit beak targets while keeping training and deployment risks under control.

[0110] Throughout the fusion process, the 13th and 16th layer A2C2F modules primarily handle the convolutional fusion and feature reshaping after cross-scale stitching, while the 17th layer TMC module provides contextual supplementation from two different receptive fields at the P3 scale for the tiny fruit beak target. These two types of modules work together to ensure that the fused features retain spatial details while possessing sufficient semantic contextual information.

[0111] In this embodiment, in the top-down path of the neck network, the A2C2F module and the TMC module are used to effectively transfer high-level semantic features to low-level features, and the SNI module is used to alleviate the problem of inconsistent spatial distribution of features at different scales.

[0112] S43: Then, features are extracted from the bottom up through the neck network to obtain the second deep feature map and the third deep feature map.

[0113] Specifically, S43 includes the following:

[0114] First, the first deep feature map After multi-branch downsampling by the eighteenth-layer ESD module, it is then compared with the feature map of the second middle layer. The final second-deep feature map is obtained by stitching together the nineteenth-layer channel dimension and then fusing it through the twentieth-layer A2C2F module to maintain spatial consistency of features during the bottom-up backpropagation path. As shown in the formula below,

[0115] ,

[0116] ,

[0117] ,

[0118] In the formula, For learnable parameter vectors, To prevent small constants from being divided by zero, These represent the learnable scalar weight parameters for dense feature branches, global feature branches, and local feature branches, respectively. To activate the constraint.

[0119] In this embodiment, the twentieth layer A2C2F module enables a region attention mechanism to enhance the feature representation of the target-related region in the second deep feature map P4 fusion stage.

[0120] In this embodiment, the ESD module includes three parallel branches: dense feature branch, global feature branch, and local feature branch.

[0121] The dense feature branch performs standard convolution downsampling on the input features through a 3×3 convolution (stride 2, padding 1), outputting a 60×60 feature map. This branch preserves the spatial detail features learned by the convolution kernel within the local 3×3 receptive field, and is able to capture local discriminative information such as the outline of the beak edge and the texture of the silique surface.

[0122] The global feature branch performs region mean downsampling on the input features using a 4×4 average pooling window (stride of 2, padding of 1), and outputs... Average pooling aggregates global statistical information within a larger spatial window, which can suppress high-frequency noise interference in the silique gap region and extract smoother spatial distribution features.

[0123] The local feature branch performs region-wide downsampling on the input features using a 4×4 max-pooling window (stride of 2, padding of 1), and outputs... Max pooling selects the feature value with the strongest response within the window, effectively preserving the peak activation response of small targets such as rapeseed beaks during downsampling, and preventing them from being diluted by the surrounding low-response regions when the resolution decreases.

[0124] This structure introduces a global-local dual pooling branch on top of dense convolutional features, which improves the ability of high-level features to discriminate dense fruit beak regions after downsampling.

[0125] Through the above multi-branch design, the ESD module enables the rapeseed pod beak detection model to obtain high-resolution first deep feature maps. When features are downsampled to a lower resolution, the peak response of the fruit beak (max pooling branch), the suppression of branch background noise (average pooling branch), and the capture of the learned local spatial patterns (convolutional branch) can be preserved at the same time. This effectively alleviates the problem of loss of small target information caused by reduced resolution in standard downsampling and improves the quality and detection accuracy of subsequent cross-scale fusion.

[0126] Second, the second deep feature map After multi-branch downsampling by the 21st layer ESD module, the feature map is compared with the 3rd shallow layer feature map. Same spatial scale, and with the third shallow feature map By stitching together the twenty-second layer channel dimensions and then passing through the twenty-third layer C3K2 module, the final third-layer deep feature map is obtained. As shown in the formula below,

[0127] ,

[0128] In this embodiment, features are extracted from the bottom up through the neck network, enabling the backpropagation of low-level detailed information to high-level semantics.

[0129] In this embodiment, the ESD module extracts complementary downsampling features from different spatial ranges through three parallel branches, and then outputs them through adaptive weighted fusion, thereby preserving the key feature information of rapeseed pods to the maximum extent during the resolution reduction process.

[0130] S44: The first deep feature map, the second deep feature map, and the third deep feature map are input into the detection head, and the detection head outputs the predicted bounding box of the fruit beak and the category score vector. Then, non-maximum suppression is performed on the predicted bounding boxes of the same category in descending order of confidence to remove redundant overlapping boxes. The number of detection boxes that are finally retained is the number of rapeseed pods in the image.

[0131] In this embodiment, the predicted bounding box of the fruit beak output by the detection head includes the corresponding coordinates.

[0132] Specifically, S44 includes the following:

[0133] First, the first, second, and third deep feature maps are input into the detection head, which then outputs the predicted beak bounding box and the category score vector, as shown in the following formula.

[0134] ,

[0135] ,

[0136] ,

[0137] ,

[0138] ,

[0139] In the formula, , , These are three detection heads of different sizes. For the first The predicted bounding box of the fruit beak output by the layer detection head. For the first The category score vector output by the layer detection head. , The first The weights and biases of the regression branch in the layer detection head. , The first Weights and biases of the classification branches in the layer detection head.

[0140] Second, the maximum value in the category score vector is taken as the confidence level. The predicted beak bounding boxes output by the detector are categorized by category. For each category, the predicted beak bounding boxes are sorted from high to low confidence levels. The predicted beak bounding box with the highest confidence level is selected as the retained box. The intersection-union ratio (IUU) of this retained box and the remaining predicted bounding boxes is calculated, as shown in the following formula.

[0141] ,

[0142] In the formula, To calculate the area of ​​the region, The intersection region of the reserved bounding box and any remaining predicted bounding box. The region is the union of the reserved bounding box and any remaining predicted bounding box. To retain the frame, For any predicted bounding box;

[0143] When the intersection-union ratio is greater than a preset threshold (in this embodiment, the preset threshold is 0.7), the predicted bounding box is deleted.

[0144] Repeat the above operation to obtain the final retained predicted bounding boxes. The number of the final retained predicted bounding boxes is the number of rapeseed pods detected.

[0145] S45: The error between the output and the label is calculated using the loss function. Then, the gradients of each parameter of the rapeseed pod and beak detection model are calculated using backpropagation. Finally, the parameters of the rapeseed pod and beak detection model are updated using the optimizer, as shown in the following formula.

[0146] ,

[0147] ,

[0148] ,

[0149] ,

[0150] ,

[0151] In the formula, For intersection, union, and comparison, Euclidean distance. These are the center points of the predicted bounding box and the ground truth bounding box, respectively. To predict the diagonal length of the minimum bounding rectangle of the bounding box and the true bounding box, These are the weighting coefficients. As a measure of length-to-consistency ratio, To fully compare the loss, The number of positive samples. For the first Layer detection head The predicted bounding boxes (i.e., the predicted bounding box coordinates) of each positive sample. For the corresponding ground truth bounding box coordinates, For the first Total number of samples from the layer detection head. For the first Layer detection head The true label of the predicted bounding box of each sample (if the predicted bounding box is a real target, it is a positive sample and assigned a value of 1; if the predicted bounding box is not a target, it is a negative sample and assigned a value of 0). For the first Layer detection head The predicted probability of a sample. For the total loss, , These are regression loss (the difference between the predicted bounding box and the ground truth box) and classification loss (the difference between the predicted category and the ground truth label). , To balance the weighting coefficients of each loss term, This refers to all learnable parameters in the rapeseed pod beak detection model (including the weights and biases of the backbone network, neck network, and detection head). , For learning rate, For gradient calculation.

[0152] S5: Repeat steps S3 and S4 until the maximum number of training rounds is reached, then stop training.

[0153] S6: After each training round, the validation set is input into the current rapeseed pod and beak detection model for forward evaluation. The weighted comprehensive index on the validation set is calculated. When the weighted comprehensive index corresponding to multiple validations does not improve, the adaptive learning rate decay mechanism will be triggered. If the learning rate has dropped to the minimum threshold and the index is still stagnant, the early stopping mechanism will be triggered to stop training. When the current weighted comprehensive index exceeds the historical weighted comprehensive index, the current rapeseed pod and beak detection model will be saved as the optimal rapeseed pod and beak detection model.

[0154] The weighted composite index is shown in the following formula.

[0155] ,

[0156] In the formula, As a weighted composite indicator, express Mean accuracy when the threshold is 0.5 express The average precision is calculated with a threshold of 0.5 to 0.95 in a step of 0.05.

[0157] In this embodiment, the weighted composite index has not improved, meaning that the current weighted composite index is smaller than the historical weighted composite index.

[0158] S7: Independently test the optimal rapeseed pod and beak detection model by inputting the test set into the saved test set. If the detection accuracy and counting error of the test set meet the preset requirements, the training of the rapeseed pod and beak detection model is completed; otherwise, the training rounds are adjusted.

[0159] In this embodiment, the optimal rapeseed pod beak detection model, which is stored in the test set, is tested independently, and the detection accuracy on the test set is calculated. , And counting errors (such as mean absolute error) Root mean square error ).

[0160] If the detection accuracy of the test set is greater than or equal to the preset accuracy threshold (e.g.) And the counting error is less than or equal to the preset error threshold (e.g.) If the rapeseed pod beak detection model meets the preset requirements, the model training is completed, and the current rapeseed pod beak detection model is used as the final rapeseed pod beak detection model.

[0161] If the above conditions are not met, it is determined that the rapeseed pod beak detection model has not met the preset requirements, triggering a training strategy adjustment. The adjustment methods include increasing the number of training rounds, continuing training on the basis of the original training, increasing the number of rounds by 20 to 50 each time, and re-dividing the training set and validation set.

[0162] S8: Collect mature rapeseed plants, cut the collected rapeseed plants, obtain rapeseed plant branches, collect images of rapeseed plant branches through a mobile device, obtain multiple rapeseed plant branch images, and then obtain the number of rapeseed pods corresponding to the images through a trained rapeseed pod beak detection model.

[0163] The training and testing of the rapeseed pod beak detection model were both completed in an Ubuntu 22.04 LTS workstation environment. Hardware-wise, an Intel Xeon Platinum 8259 L-series processor (approximately 2.5 GHz) was used, configured with 4 vCPUs and 16GB of RAM, and equipped with one NVIDIA T4 Tensor Core GPU (16 GB VRAM). Software-wise, a complete development platform was built based on the PyTorch 2.5.0 deep learning framework. Python 3.11 was used as the programming language. For training strategies, the learning rate was set to 0.002, the Adam optimizer was used, the random seed was fixed at 1337, and the input image size was uniformly adjusted to 960×960 pixels. The entire training process consisted of 100 epochs, employing an early stopping strategy: training stopped when the validation set metrics did not improve within 30 consecutive epochs. The batch size was 8, and other hyperparameters remained at default settings. Finally, the model performance metrics were statistically analyzed based on the test set data.

[0164] In this embodiment, to further verify the rapeseed pod beak detection model (i.e., the improved model YOLOv11n-A) 3 To demonstrate the superiority of YOLO, using test set data, it is compared and analyzed with EfficientDet, Real-Time Detection Transformer (RT-DETR), YOLOv8n, and the baseline model YOLOv11n. The experimental results of each model are as follows: Figure 7-10 As shown in Table 1 below, the experimental results of rapeseed pods are compared.

[0165] As shown in Table 1, YOLOv11n-A 3 In terms of precision, recall, and mAP 0.5-0.95 The accuracy rates reached 92.6%, 85.1%, and 47.1% respectively, representing improvements of 1.8, 2.5, and 12.5 percentage points compared to the baseline model. Compared to EfficientDet, RT-DETR, and YOLOv8n, YOLOv11n-A... 3 mAP 0.5 The scores were 9.9, 2.1, and 12.4 percentage points higher, respectively; the accuracy rates were 9.5, 2.0, and 6.7 percentage points higher, respectively; and the F1 scores were 8.1, 0.4, and 7.6 percentage points higher, respectively. In the more rigorous mAP... 0.5-0.95 In terms of recall, YOLOv11n-A³ ranks second only to RT-DETR. The structural difference lies in their respective capabilities: RT-DETR relies on the global self-attention mechanism of the Transformer, exhibiting significant advantages in global context capture and high-threshold localization; while YOLOv11n-A³... 3Despite the support of A2, its global modeling capability is slightly inferior due to the limitations of CNN's local perception.

[0166]

[0167] Table 1

[0168] However, thanks to the efficient inductive bias of the CNN architecture, YOLOv11n-A 3 It exhibits significant advantages in model lightweighting, with only 2.58 M parameters and a low computational cost of 6.39 GFLOPs. Compared to EfficientDet, RT-DETR, and YOLOv8n, its parameter count is reduced by 60.9%, 92.1%, and 14.3%, respectively, and its computational cost is drastically reduced by 94.1% compared to RT-DETR's 107.99 GFLOPs. In terms of detection speed, YOLOv11n-A3 achieves a detection speed of 625.3 frames / s. Although its single-image processing frame rate is slightly lower than the baselines YOLOv11n and YOLOv8n, its detection speed is 2.3 times that of RT-DETR. In silique counting, YOLOv11n-A3 achieved MAE, RMSE, MAPE, and R² of 2.61, 3.7, 11.37%, and 0.937, respectively, demonstrating significantly higher counting accuracy than EfficientDet and RT-DETR. Although its regression error slightly increased compared to YOLOv8n due to its lightweight design, it still maintained high overall counting accuracy and stability. In summary, YOLOv11n-A3... 3 It achieves a good balance between detection accuracy, counting accuracy and computational overhead, fully demonstrating its advantages of being lightweight and efficient, and is more suitable for real-time detection and counting of tiny rapeseed beaks on edge mobile devices.

[0169] This embodiment also discloses a high-yield rapeseed intelligent breeding and screening system, which adopts the high-yield rapeseed intelligent breeding and screening method described above. It includes an acquisition module, an analysis module, and an output module. The acquisition module is used to acquire rapeseed plant images. The analysis module is used to extract multi-scale features layer by layer through the backbone network, the neck network for top-down and bottom-up feature extraction, and the detection head outputs the predicted bounding box coordinates and category score vectors of the pods and beaks. Then, non-maximum suppression is performed on the predicted bounding boxes of the same category in descending order of confidence to remove redundant overlapping boxes. The number of detection boxes retained is the number of rapeseed pods in the image. The output module is used to output the number of rapeseed pods and beaks.

[0170] To further verify the effectiveness and stability of the high-yield rapeseed intelligent breeding screening system in practical applications, this study randomly selected four rapeseed branches from the field and placed them in four different scenarios: indoor with lights off, indoor with lights on, outdoor in shade, and in the field. The system was then tested using a YOLOv11n-A... 3 The model was validated in real-world scenarios using a mobile app. The counting test results in different scenarios are shown in Table 2. The experiments demonstrate that the counting strategy yields results similar to manual counting, confirming the effectiveness of this method.

[0171] Table 2 Summary of silique count results for rapeseed branch samples under different scenarios

[0172]

[0173] Note: The test covered real branch samples with four density gradients (containing 40, 58, 74, and 99 horns respectively), and the single-graph inference time on the mobile device was consistently 0.3 seconds.

[0174] The above embodiments are merely preferred embodiments of the present invention and should not be construed as limiting the scope of protection of the present invention. Any non-substantial changes and substitutions made by those skilled in the art based on the present invention shall fall within the scope of protection claimed by the present invention.

Claims

1. A smart breeding and screening method for high-yield rapeseed, characterized in that, Includes the following steps: S1: Collect mature rapeseed plants, cut the collected rapeseed plants, obtain rapeseed plant branches, and use a mobile device to collect multiple images of rapeseed plant branches in various scenes, including indoor, outdoor shaded areas and natural field light. S2: Label the top of the beak region of mature rapeseed pods in multiple rapeseed plant branching images, and divide the labeled images into training set, validation set and test set according to the proportion; S3: The training set uses an online augmentation strategy to randomly generate new augmented samples in real time, and the size of the new augmented samples is uniformly scaled to a preset pixel to form a standardized network input tensor. S4: The standardized network input tensor is input into the rapeseed pod and beak detection model for forward propagation. Multi-scale features are extracted layer by layer through the backbone network, and top-down and bottom-up features are extracted through the neck network. The detection head outputs the predicted bounding box coordinates and category score vector of the pod and beak. The error between the output result and the label is calculated through the loss function. Then, the gradient of each parameter of the model is calculated through backpropagation, and the parameters of the rapeseed pod and beak detection model are updated using the optimizer. S5: Repeat steps S3 and S4 until the maximum number of training rounds is reached; S6: After each training round, the validation set is input into the current rapeseed pod and beak detection model for forward evaluation. The weighted comprehensive index on the validation set is calculated. When the weighted comprehensive index corresponding to multiple validations does not improve, the adaptive learning rate decay mechanism is triggered. If the learning rate has dropped to the minimum threshold and the index is still stagnant, the early stopping mechanism is triggered to stop training. When the current weighted comprehensive index exceeds the historical weighted comprehensive index, the current rapeseed pod and beak detection model is saved as the optimal rapeseed pod and beak detection model. S7: Independently test the optimal rapeseed pod beak detection model with the test set input. If the detection accuracy and counting error of the test set meet the preset requirements, the model training is completed; otherwise, the training rounds are adjusted. S8: Collect mature rapeseed plants, cut the collected rapeseed plants, obtain rapeseed plant branches, collect images of rapeseed plant branches through a mobile device, obtain multiple rapeseed plant branch images, and then obtain the number of rapeseed pods corresponding to the images through a trained rapeseed pod beak detection model.

2. The intelligent breeding and screening method for high-yield rapeseed according to claim 1, characterized in that, S4 includes the following steps: S41: The standardized network input tensor is processed layer by layer through the backbone network to extract multi-scale features, resulting in a first shallow feature map with a downsampling step size of 8, a second shallow feature map with a downsampling step size of 16, and a third shallow feature map with a downsampling step size of 32. S42: Then, features are extracted from top to bottom through the neck network to obtain the first middle layer feature map, the second middle layer feature map, and the first deep layer feature map; S43: Then, features are extracted from the bottom up through the neck network to obtain the second deep feature map and the third deep feature map respectively; S44: The first deep feature map, the second deep feature map, and the third deep feature map are input into the detection head, and the detection head outputs the predicted bounding box of the fruit beak and the category score vector. Then, non-maximum suppression is performed on the predicted bounding boxes of the same category in descending order of confidence to remove redundant overlapping boxes. The number of detection boxes that are finally retained is the number of rapeseed pods in the image. S45: Calculate the error between the output result and the label through the loss function, then calculate the gradient of each parameter of the rapeseed pod beak detection model through backpropagation, and use the optimizer to update the parameters of the rapeseed pod beak detection model.

3. The intelligent breeding and screening method for high-yield rapeseed according to claim 2, characterized in that, S41 includes the following: First, the standardized network input tensor is sequentially passed through the first convolutional layer, the second convolutional layer, the third C3K2 module, the fourth convolutional layer, and the fifth C3K2 module for feature extraction and downsampling, with a downsampling stride of 8, resulting in the first shallow feature map, as shown in the following formula. , , , , , , In the formula, For the standardized network input tensor, , , , These are the input feature maps after the corresponding operations. , , , , These are the weights for the corresponding levels. , , , , These are the biases for the corresponding levels. It is a non-linear activation function. This is the first shallow feature map; Second, the first shallow feature map is then passed through the sixth convolutional layer and the seventh C3K2 module for feature extraction and downsampling, with a downsampling stride of 16, to obtain the second shallow feature map, as shown in the following formula. , , , In the formula, It is the input feature map after the corresponding operations. , These are the weights for the corresponding levels. , These are the biases for the corresponding levels. For activation function, This is the second shallow feature map; Third, the second shallow feature map is then passed through the eighth convolutional layer, the ninth SPPF module, and the tenth C2PSA module for feature extraction and downsampling, with a downsampling stride of 32, to obtain the third shallow feature map. As shown in the formula below, , , , , , , , In the formula, , These are the input feature maps after global context integration operations via convolution and pyramid pooling, respectively. , , , , These are the weights for the corresponding levels. , , , , These are the biases for the corresponding levels. For activation function, This is the third shallow layer feature map.

4. The intelligent breeding and screening method for high-yield rapeseed according to claim 2, characterized in that: S42 includes the following: The third shallow feature map is upsampled and amplified by the eleventh-layer SNI module until it is the same as the second shallow feature map. At the same spatial scale, it is concatenated with the second shallow feature map at the twelfth layer channel dimension, and then fused through the thirteenth layer A2C2F module. This is used to enhance the spatial feature reshaping when high-level semantics are transmitted to the middle layer, resulting in an enhanced second middle-layer feature map. As shown in the formula below, , , In the formula, It is the fusion feature after splicing. This is the second middle layer feature map; The second middle-layer feature map is upsampled and amplified by the fourteenth-layer SNI module until it is comparable to the first shallow-layer feature map. The same spatial scale, and then compared with the first shallow feature map After concatenation at the fifteenth layer channel dimension, the fusion is completed by the sixteenth layer A2C2F module, which is used for refined feature modeling at the scale of the smallest target, resulting in an enhanced first mid-layer feature map, as shown in the following formula. , , In the formula, It is the fusion feature after splicing. This is the first shallow feature map. This is the first middle layer feature map. This is the second middle layer feature map; Subsequently, the multi-scale context is supplemented by deep convolution in the seventeenth layer TMC module to obtain the final first deep feature map. As shown in the formula below, , , In the formula, For the input feature tensor, , These represent 2×2 depthwise convolutions with dilation rates of 1 and 2, respectively. These two convolutions are performed in parallel to extract spatial features from different receptive fields and then summed element-wise. It uses 2×2 pointwise convolution for cross-channel information exchange and dimensionality reduction projection. For batch normalization processing, This is the first deep feature map.

5. The intelligent breeding and screening method for high-yield rapeseed according to claim 2, characterized in that: S43 includes the following: First, the first deep feature map After multi-branch downsampling by the 18th-layer ESD module, the feature map is concatenated with the second middle-layer feature map through the 19th-layer channel dimension, and then fused by the 20th-layer A2C2F module to maintain spatial consistency of features in the bottom-up backpropagation path, resulting in the final second deep feature map, as shown in the following formula. , , , In the formula, For learnable parameter vectors, To prevent small constants from being divided by zero, These represent the learnable scalar weight parameters for dense feature branches, global feature branches, and local feature branches, respectively. To activate constraints, This is the first deep feature map. This is the second middle layer feature map. This is the second deep feature map; Second, the second deep feature map is downsampled to the same spatial scale as the third shallow feature map through multiple branches of the twenty-first layer ESD module, and then concatenated with the third shallow feature map through the twenty-second layer channel dimension. Finally, it passes through the twenty-third layer C3K2 module to obtain the final third deep feature map, as shown in the following formula. , In the formula, This is the second deep feature map. This is the third shallow layer feature map. This is the third deep feature map.

6. The intelligent breeding and screening method for high-yield rapeseed according to claim 2, characterized in that: S44 includes the following: First, the first, second, and third deep feature maps are input into the detection head, which then outputs the predicted beak bounding box and the category score vector, as shown in the following formula. , , , , , In the formula, , , These are three detection heads of different sizes. For the first The predicted bounding box of the fruit beak output by the layer detection head. For the first The category score vector output by the layer detection head. , The first The weights and biases of the regression branch in the layer detection head. , The first Weights and biases of the classification branches in the layer detection head; Second, the maximum value in the category score vector is taken as the confidence level. The predicted beak bounding boxes output by the detector are categorized by category. For each category, the predicted beak bounding boxes are sorted from high to low confidence levels. The predicted beak bounding box with the highest confidence level is selected as the retained box. The intersection-union ratio (IUU) of this retained box and the remaining predicted bounding boxes is calculated, as shown in the following formula. , In the formula, To calculate the area of ​​the region, The intersection region of the reserved bounding box and any remaining predicted bounding box. The region is the union of the reserved bounding box and any remaining predicted bounding box. To retain the frame, For any predicted bounding box; If the intersection-union ratio is greater than a preset threshold, the predicted bounding box is deleted. Repeat the above operation to obtain the final retained predicted bounding boxes. The number of the final retained predicted bounding boxes is the number of rapeseed pods detected.

7. The intelligent breeding and screening method for high-yield rapeseed according to claim 2, characterized in that: In S45, the error between the output and the label is calculated using a loss function, the gradients of each model parameter are calculated through backpropagation, and the optimizer is used to update the rapeseed pod beak detection model parameters, as shown in the following formula. , , , , , In the formula, For intersection, union, and comparison, Euclidean distance. These are the center points of the predicted bounding box and the ground truth bounding box, respectively. To predict the diagonal length of the minimum bounding rectangle of the bounding box and the true bounding box, These are the weighting coefficients. As a measure of length-to-consistency ratio, To fully compare the loss, The number of positive samples. For the first Layer detection head Predicted bounding boxes for each positive sample. For the corresponding ground truth bounding box coordinates, For the first Total number of samples from the layer detection head. For the first Layer detection head The predicted bounding box ground label for each sample. For the first Layer detection head The predicted probability of a sample. For the total loss, , Regression loss and classification loss are respectively. , These are the weighting coefficients for balancing the various loss terms. For all learnable parameters in the model, , For learning rate, For gradient calculation.

8. A high-yield rapeseed intelligent breeding and screening system, characterized in that, The high-yield rapeseed intelligent breeding screening method according to any one of claims 1-7 includes an acquisition module, an analysis module, and an output module. The acquisition module is used to acquire rapeseed plant images. The analysis module is used to extract multi-scale features layer by layer through the rapeseed plant images via a trained rapeseed pod beak detection model, and extract features from the neck network layer by layer through the backbone network, and output the predicted bounding box coordinates and category score vector of the beak from the detection head. Then, non-maximum suppression is performed on the predicted bounding boxes of the same category in descending order of confidence to remove redundant overlapping boxes. The number of detection boxes retained is the number of rapeseed pods in the image. The output module is used to output the number of rapeseed pod beaks.