A method, system, device and medium for identifying the growth period of rice in the field

By adopting a deep extraction method of full-dimensional dynamic convolution and coordinate attention mechanism in image processing during field rice growth, the problems of low recognition accuracy and relying on large-scale annotation data are solved, and higher recognition accuracy and stronger model generalization capabilities are achieved.

CN119295951BActive Publication Date: 2025-03-07NORTHWEST A & F UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411803363.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-10
Publication Date
2025-03-07
Estimated Expiration
2044-12-10

AI Technical Summary

Technical Problem

Traditional deep learning methods use low recognition accuracy and over-reliance on large-scale labeled datasets when processing crop growth images in complex field backgrounds.

Method used

The deep extraction method combined with full-dimensional dynamic convolution and coordinate attention mechanism is adopted to process the extracted features through full-connection classification to improve the recognition accuracy of rice growth stages in complex field backgrounds.

Benefits of technology

It improves the recognition accuracy of rice at different growth stages, reduces the dependence on large-scale labeled data sets, and enhances the generalization ability and learning efficiency of the model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119295951B_ABST
    Figure CN119295951B_ABST
Patent Text Reader

Abstract

The present invention belongs to the technical field of image processing, and specifically relates to a method, system, device, and medium for identifying the growth period of rice in a field. After image data of different growth periods are deeply extracted by combining full-dimensional dynamic convolution with a coordinate attention mechanism, the extracted features are combined and classified through full connection to improve the recognition accuracy of different growth stages of rice under a complex field background; the data set is divided to facilitate classification training, so as to enhance the generalization ability of the model, reduce dependence on large-scale labeled data sets, further improve the recognition accuracy of the model, and enhance the learning efficiency of the model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of image processing, and in particular relates to a method, system, device and medium for identifying the growth period of field rice. Background Art

[0002] In agricultural production, accurate identification of crop growth periods is crucial for effective farming operations. However, traditional deep learning methods have problems with low recognition accuracy and over-reliance on large-scale labeled datasets when processing crop growth period images in complex field backgrounds.

[0003] For example, the paper "In-field rice panicles detection and growth stages recognition based on RiceRes2Net" proposed a RiceRes2Net based on the improved Cascade RCNN (Region-CNN) architecture to detect rice panicles and identify growth stages in complex field environments. However, this method only recognizes the booting stage, heading stage, and filling stage. The recognition accuracy for the entire growth stage of rice still needs to be further improved. Summary of the invention

[0004] In order to solve the problems raised by the background technology, the present invention provides a method, system, device and medium for identifying the growth period of rice in the field.

[0005] The technical solution of the present invention is as follows:

[0006] The present invention provides a method for identifying the growth period of rice in a field, comprising the following steps:

[0007] S1: Obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage, mark some of the image data, and construct an image dataset marked with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset respectively;

[0008] S2: The image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model.

[0009] The deep extraction includes the following operations:

[0010] The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map;

[0011] After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively;

[0012] The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map;

[0013] The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map;

[0014] The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map;

[0015] After the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained;

[0016] The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, random dropout processing, linear processing, and the second activation function to obtain a sixth extracted feature map;

[0017] The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained;

[0018] S3: importing the image data of different growth stages in the second data set into the first model for recognition to obtain recognition results, marking the image data of different growth stages in the second data set according to the recognition results, and constructing an image data set marked with pseudo labels, which is recorded as the third data set;

[0019] S4: importing the image data of different growth stages in the third data set to the pre-recognition model for training to obtain a second model;

[0020] S5: Obtain the field rice image to be identified, guide it to the second model, and obtain the identification result of the growth period.

[0021] In step S2, the feature map to be processed is sequentially subjected to full-dimensional dynamic convolution processing, batch normalization processing, and first activation function processing to obtain a second extracted feature map, and the full-dimensional dynamic convolution processing includes the following operations:

[0022] The feature map to be processed is processed by global average pooling, full connection processing, and the first activation function processing in sequence to obtain the feature map to be enhanced;

[0023] The feature map to be enhanced is processed by four parallel attention mechanisms, specifically:

[0024] The feature map to be enhanced is processed by full connection, the third activation function, and the first attention mechanism in sequence to obtain a first enhanced feature map;

[0025] The feature map to be enhanced is processed by full connection, the third activation function, and the second attention mechanism in sequence to obtain a second enhanced feature map;

[0026] The feature map to be enhanced is processed by full connection, the third activation function, and the third attention mechanism in sequence to obtain a third enhanced feature map;

[0027] The feature map to be enhanced is processed by full connection, the third activation function, and the fourth attention mechanism in sequence to obtain a fourth enhanced feature map;

[0028] After the first enhanced feature map, the second enhanced feature map, the third enhanced feature map, and the fourth enhanced feature map are sequentially subjected to convolution operations to obtain attention scalars of different enhanced feature maps, the convolution kernel weights are adjusted according to the attention scalars, and the convolution kernel with adjusted weights performs a convolution operation on the feature map to be processed.

[0029] In step S2, after the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained, which is specifically:

[0030] The fourth extracted feature map is subjected to residual processing to obtain a first processed feature map;

[0031] The first processed feature map is average pooled in the vertical direction and the horizontal direction respectively to obtain a first vertical processed feature map and a first horizontal processed feature map;

[0032] After the first vertical processing feature map is concatenated with the first horizontal processing feature map, two-dimensional convolution, batch normalization, and nonlinear processing are performed in sequence to obtain an intermediate feature map;

[0033] After the intermediate feature map is separated and processed in the vertical direction and the horizontal direction, a second vertical processing feature map and a second horizontal processing feature map are obtained;

[0034] The second vertical processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain a feature weight of the vertical processing feature map;

[0035] The second horizontal processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain the feature weight of the horizontal processing feature map;

[0036] The feature weight of the vertical processing feature map and the feature weight of the horizontal processing feature map are respectively multiplied by each pixel of the first processing feature map to obtain a fifth extracted feature map.

[0037] In step S2, the deep extraction feature map obtained is processed by full connection classification to obtain the recognition result, which is specifically:

[0038] The obtained deep extraction feature map is processed by average pooling, random dropout, and linear processing in turn, and then classified by the fourth activation function to obtain the recognition result.

[0039] The four parallel attention mechanism processes are: spatial level attention, channel level attention, filter level attention, and core level attention.

[0040] In step S2, the preliminary extraction of the features includes the following operations:

[0041] The image data of different growth stages in the first data set are processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a first feature map;

[0042] The first feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a second feature map;

[0043] The second feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a third feature map;

[0044] After the third feature map is processed by maximum pooling, a preliminary extracted feature map is obtained.

[0045] In step S3, the image data of different growth stages in the second data set are marked according to the recognition result to construct an image data set marked with pseudo labels, which is recorded as the third data set, specifically:

[0046] According to the recognition results, the image data of different growth periods in the second data set are marked to generate pseudo labels. Based on the pseudo-labeled image data set, the first three thousand image data with the highest confidence in each category are selected to construct a rice growth period data set marked with pseudo labels, which is recorded as the third data set.

[0047] The present invention also provides a system for identifying the growth period of rice in a field, comprising:

[0048] The first dataset and the second dataset construction module: obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage, mark some image data, and construct an image dataset marked with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset respectively;

[0049] The first model training module: the image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model;

[0050] The deep extraction includes the following operations:

[0051] The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map;

[0052] After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively;

[0053] The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map;

[0054] The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map;

[0055] The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map;

[0056] After the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained;

[0057] The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, random dropout processing, linear processing, and the second activation function to obtain a sixth extracted feature map;

[0058] The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained;

[0059] The third data set construction module: imports the image data of different growth stages in the second data set into the first model for recognition to obtain recognition results, labels the image data of different growth stages in the second data set according to the recognition results, and constructs an image data set with pseudo labels, which is recorded as the third data set;

[0060] The second model training module: imports the image data of different growth stages in the third data set into the pre-recognition model for training to obtain the second model;

[0061] Rice growth period recognition module: obtains the field rice image to be recognized, imports it into the second model, and obtains the recognition result of the growth period.

[0062] The present invention also provides a device for identifying the growth period of field rice, comprising a processor and a memory, wherein the processor implements the method for identifying the growth period of field rice when executing a computer program stored in the memory.

[0063] The present invention also provides a field rice growth period identification medium for storing a computer program, wherein the computer program implements the field rice growth period identification method when executed by a processor.

[0064] Beneficial effect: In the present invention, after deep extraction of image data of different growth stages combining full-dimensional dynamic convolution with coordinate attention mechanism, the extracted features are combined and classified through full connection, thereby improving the recognition accuracy of different growth stages of rice under complex field background.

[0065] The present invention divides the data set to facilitate subsequent classification training, so as to enhance the generalization ability of the model, reduce the dependence on large-scale labeled data sets, further improve the recognition accuracy of the model, and enhance the learning efficiency of the model.

[0066] The present invention adopts full-dimensional dynamic convolution processing, which can automatically adjust the size and shape of the convolution kernel according to the image content processed by spatial level, channel level, filter level and kernel level attention, so as to more effectively extract the key features in the image and enhance the perception ability of the target.

[0067] The present invention integrates the input feature information in the horizontal and vertical directions respectively through coordinate attention processing, and then encodes the feature maps in these two directions into two attention maps to capture the long-range dependency of the input feature maps in different spatial directions and fully extract the position information, which is convenient for determining the position of rice in the image and the positions of different categories of features in the rice. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] Figure 1 The figure is a flow chart of a method for identifying the growth period of rice in a field in an embodiment. DETAILED DESCRIPTION

[0069] The following examples are intended to illustrate the present invention rather than to further limit the present invention.

[0070] The present invention provides a method for identifying the growth period of rice in the field, such as Figure 1 As shown, the following steps are included:

[0071] S1: Obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage. Label some of the image data to construct an image dataset labeled with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset, respectively.

[0072] In order to improve the accuracy of model recognition, the present invention first collects image data of rice at different growth stages under complex field backgrounds. In addition to different growth stages, it also includes complex field backgrounds and rice in different growth states, providing a data basis for model construction.

[0073] On this basis, the data set is divided to facilitate subsequent classification training, so as to enhance the generalization ability of the model, reduce dependence on large-scale labeled data sets, further improve the model recognition accuracy, and enhance the learning efficiency of the model.

[0074] S2: The image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature map is fully connected to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model.

[0075] In the pre-recognition model, image data marked with real labels undergo preliminary extraction, deep extraction of location information and key features, and then the extracted features are combined and classified through full connection.

[0076] Preferably, the preliminary extraction of features includes the following operations:

[0077] The image data of different growth stages in the first data set are processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a first feature map;

[0078] The first feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a second feature map;

[0079] The second feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a third feature map;

[0080] After the third feature map is processed by maximum pooling, a preliminary extracted feature map is obtained.

[0081] After extracting the primary features, considering the complex field background and different growth conditions of the image data, it is necessary to extract deep features.

[0082] Preferably, the deep extraction includes the following operations:

[0083] The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map;

[0084] After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively;

[0085] The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map.

[0086] In order to overcome the challenges brought by the complexity of the rice field background, it is necessary to enhance the convolution kernel's perception of the target. Therefore, the present invention adopts full-dimensional dynamic convolution processing to automatically adjust the size and shape of the convolution kernel according to the image content to more effectively extract the key features in the image.

[0087] Specifically, the full-dimensional dynamic convolution processing includes the following operations:

[0088] First, the feature map to be processed is processed by global average pooling, full connection processing, and the first activation function processing in sequence to obtain the feature map to be enhanced.

[0089] Among them, global average pooling helps to compress the input feature x of the feature map to be processed into a length of The feature vector of effectively captures the global information of the feature map to be processed in the channel dimension.

[0090] The fully connected processing maps the obtained feature vector to a lower dimensional space, such as a dimensionality reduction ratio of 1 / 16. This mapping process helps to reduce the computational complexity while retaining the main information of the feature.

[0091] The first activation function processing, such as the ReLU activation function, is used to introduce nonlinearity and enhance the expressiveness of the model.

[0092] Then, the feature map to be enhanced is processed by four parallel attention mechanisms to calculate the attention scalars of four dimensions respectively. Each branch contains a full connection process and a third activation function process (Sigmoid activation function or Softmax activation function) to generate normalized attention. Specifically:

[0093] The feature map to be enhanced is processed by full connection, the third activation function, and the first attention mechanism in sequence to obtain a first enhanced feature map;

[0094] The feature map to be enhanced is processed by full connection, the third activation function, and the second attention mechanism in sequence to obtain a second enhanced feature map;

[0095] The feature map to be enhanced is processed by full connection, the third activation function, and the third attention mechanism in sequence to obtain a third enhanced feature map;

[0096] The feature map to be enhanced is processed by full connection, the third activation function, and the fourth attention mechanism in sequence to obtain a fourth enhanced feature map;

[0097] Finally, the first enhanced feature map, the second enhanced feature map, the third enhanced feature map, and the fourth enhanced feature map are sequentially convolved to obtain attention scalars of different enhanced feature maps. The convolution kernel weights are dynamically adjusted according to the attention scalars, and the convolution kernel with adjusted weights is convolved on the feature map to be processed to generate an adaptive dynamic convolution result.

[0098] Four parallel attention mechanisms process, in the order of spatial level (spatial dimension), channel level (input channel dimension), filter level (output channel dimension), and kernel level (convolution kernel dimension).

[0099] That is, the above four types of attention are multiplied to the convolution kernel in the order of spatial level, channel level, filter level and kernel level attention, ensuring that the convolution operation changes all spatial positions, input channels, filters and kernels of the input x, thereby dynamically adjusting the weight of each convolution kernel. In principle, these four types of attention complement each other and are multiplied to the convolution kernel step by step in the order of position level, channel level, filter level and kernel level, so that the convolution operation is different for all spatial positions, all input channels, all filters and all kernels of the feature map to be enhanced, thereby realizing dynamic adjustment of the weight of each convolution kernel.

[0100] The present invention adopts full-dimensional dynamic convolution processing, which can automatically adjust the size and shape of the convolution kernel according to the image content processed by spatial level, channel level, filter level and kernel level attention, so as to more effectively extract the key features in the image and enhance the perception ability of the target.

[0101] The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map;

[0102] The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map.

[0103] For field rice growth stage image data, due to the complex background and different rice growth states, it is particularly important to determine the location of rice in the image and the location of different categories of features in the rice. Therefore, the ability to extract location information is necessary for field rice growth stage classification.

[0104] The attention mechanism enables the model to focus on specific parts of the input, which helps to extract key features. However, some attention mechanisms (such as BAM and CBAM) try to utilize spatial location information by reducing the channel dimension of the feature vector, and then use regular convolution to calculate the attention of the spatial dimension. However, this method often can only capture the relationship between local features and cannot well model the long-range dependencies required for visual tasks.

[0105] Furthermore, the fourth extracted feature map is processed by coordinate attention to obtain the fifth extracted feature map. This process integrates the input feature information in the horizontal and vertical directions respectively through two one-dimensional global pooling operations, and then encodes the feature maps in these two directions into two attention maps to capture the long-range dependencies of the input feature maps in different spatial directions. Specifically:

[0106] First, the fourth extracted feature map is subjected to residual processing to obtain a first processed feature map.

[0107] Then, the global pooling formula is factored to obtain the channel pooling formulas of the vertical direction formula and the horizontal direction formula. The first processed feature map is averagely pooled in the vertical direction and the horizontal direction respectively to obtain the first vertical processing feature map and the first horizontal processing feature map. In this way, the output of each feature point only contains information along the vertical direction or the horizontal direction. The transformation of the vertical and horizontal channels allows the network to locate the target of interest more accurately.

[0108] Next, the first vertical processing feature map is concatenated with the first horizontal processing feature map, and then subjected to two-dimensional convolution, batch normalization, and nonlinear processing to obtain an intermediate feature map. The new feature map obtained after concatenation contains both vertical and horizontal global information; two-dimensional convolution integrates information and reduces the number of channels; batch normalization is used to accelerate the training process and improve the stability of the model.

[0109] Afterwards, the intermediate feature map is subjected to a channel segmentation operation, and is separated and processed in the vertical direction and the horizontal direction respectively, to obtain a second vertical processing feature map and a second horizontal processing feature map;

[0110] The second vertical processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain a feature weight of the vertical processing feature map;

[0111] The second horizontal processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain the feature weight of the horizontal processing feature map;

[0112] The feature weights of the vertical processing feature map and the feature weights of the horizontal processing feature map are multiplied by each pixel of the first processing feature map through a broadcast mechanism to obtain a fifth extracted feature map containing position information.

[0113] The present invention integrates the input feature information in the horizontal and vertical directions respectively through coordinate attention processing, and then encodes the feature maps in these two directions into two attention maps to capture the long-range dependency of the input feature maps in different spatial directions and fully extract the position information, which is convenient for determining the position of rice in the image and the positions of different categories of features in the rice.

[0114] The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, Dropout (random inactivation) processing, linear processing, and the second activation function processing to obtain a sixth extracted feature map;

[0115] The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained.

[0116] After feature extraction, the features need to be integrated and classified to identify the rice growth period. Preferably, in step S2, the deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result, which is specifically:

[0117] The obtained deep extraction feature map is processed by average pooling, Dropout (random inactivation), and linear processing in turn, and then classified through the fourth activation function, such as the Softmax activation function. The classification result is the probability distribution of each category, and the category with the largest probability is taken as the rice growth stage, thereby obtaining the recognition result.

[0118] S3: The image data of different growth stages in the second data set are introduced into the first model for recognition to obtain recognition results, and the image data of different growth stages in the second data set are labeled according to the recognition results to construct an image data set labeled with pseudo labels, which is recorded as the third data set. Specifically:

[0119] According to the recognition results, the image data of different growth periods in the second data set are marked to generate pseudo labels. Based on the pseudo-labeled image data set, the first three thousand image data with the highest confidence in each category are selected to construct a rice growth period data set marked with pseudo labels, which is recorded as the third data set.

[0120] S4: The image data of different growth stages in the third data set are introduced into the pre-recognition model for training to obtain the second model.

[0121] Although machine vision and deep learning have made great progress in crop growth period recognition, existing perception algorithms are mainly based on supervised learning methods, which require manual annotation of large-scale data sets, which is time-consuming and laborious. The present invention uses the label-efficient learning form of the unlabeled sample enhancement learning process, and uses the information contained in the unlabeled data to provide additional learning signals for the model, thereby enhancing the generalization ability of the model and reducing the dependence on labeled data.

[0122] S5: Obtain the field rice image to be identified, guide it to the second model, and obtain the identification result of the growth period.

[0123] Furthermore, in order to improve recognition accuracy, the second model may be fine-tuned using image data of different growth stages in the first data set.

[0124] In the present invention, image data of different growth stages are deeply extracted by combining full-dimensional dynamic convolution with coordinate attention mechanism, and the extracted features are combined and classified through full connection to improve the recognition accuracy of different growth stages of rice under complex field background.

[0125] The present invention also provides a system for identifying the growth period of rice in a field, comprising:

[0126] The first dataset and the second dataset construction module: obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage, mark some image data, and construct an image dataset marked with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset respectively;

[0127] The first model training module: the image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model;

[0128] The preliminary extraction of the features includes the following operations:

[0129] The image data of different growth stages in the first data set are processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a first feature map;

[0130] The first feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a second feature map;

[0131] The second feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a third feature map;

[0132] After the third feature map is processed by maximum pooling, a preliminary extracted feature map is obtained;

[0133] The deep extraction includes the following operations:

[0134] The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map;

[0135] After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively;

[0136] The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map;

[0137] The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map;

[0138] The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map;

[0139] After the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained;

[0140] The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, random dropout processing, linear processing, and the second activation function to obtain a sixth extracted feature map;

[0141] The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained;

[0142] The third data set construction module: imports the image data of different growth stages in the second data set into the first model for recognition to obtain recognition results, labels the image data of different growth stages in the second data set according to the recognition results, and constructs an image data set with pseudo labels, which is recorded as the third data set;

[0143] The second model training module: imports the image data of different growth stages in the third data set into the pre-recognition model for training to obtain the second model;

[0144] Rice growth period recognition module: obtains the field rice image to be recognized, imports it into the second model, and obtains the recognition result of the growth period.

[0145] The present invention also provides a device for identifying the growth period of field rice, comprising a processor and a memory, wherein the processor implements the method for identifying the growth period of field rice when executing a computer program stored in the memory.

[0146] The present invention also provides a field rice growth period identification medium for storing a computer program, wherein the computer program implements the field rice growth period identification method when executed by a processor.

Claims

1. A method for identifying the growth period of rice in a field, characterized in that: The following steps are involved: S1: Obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage, mark some of the image data, and construct an image dataset marked with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset respectively; S2: The image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model. The deep extraction includes the following operations: The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map; After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively; The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map; The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map; The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map; After the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained; The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, random dropout processing, linear processing, and the second activation function to obtain a sixth extracted feature map; The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained; In step S2, after the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained, which is specifically: The fourth extracted feature map is subjected to residual processing to obtain a first processed feature map; After the global pooling formula is factorized to obtain the channel pooling formulas of the vertical direction formula and the horizontal direction formula, the first processing feature map is averagely pooled in the vertical direction and the horizontal direction respectively to obtain the first vertical processing feature map and the first horizontal processing feature map; After the first vertical processing feature map is concatenated with the first horizontal processing feature map, two-dimensional convolution, batch normalization, and nonlinear processing are performed in sequence to obtain an intermediate feature map; The intermediate feature map is subjected to a channel segmentation operation, and is separated and processed in the vertical direction and the horizontal direction respectively, so as to obtain a second vertical processing feature map and a second horizontal processing feature map; The second vertical processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain a feature weight of the vertical processing feature map; The second horizontal processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain the feature weight of the horizontal processing feature map; The feature weights of the vertical processing feature map and the feature weights of the horizontal processing feature map are multiplied by each pixel of the first processing feature map through a broadcasting mechanism to obtain a fifth extracted feature map; S3: importing the image data of different growth stages in the second data set into the first model for recognition to obtain recognition results, marking the image data of different growth stages in the second data set according to the recognition results, and constructing an image data set marked with pseudo labels, which is recorded as the third data set; S4: importing the image data of different growth stages in the third data set to the pre-recognition model for training to obtain a second model; S5: Obtain the field rice image to be identified, guide it to the second model, and obtain the identification result of the growth period.

2. The method for identifying the growth period of rice in the field according to claim 1, characterized in that: In step S2, the feature map to be processed is sequentially subjected to full-dimensional dynamic convolution processing, batch normalization processing, and first activation function processing to obtain a second extracted feature map, and the full-dimensional dynamic convolution processing includes the following operations: The feature map to be processed is processed by global average pooling, full connection processing, and the first activation function processing in sequence to obtain the feature map to be enhanced; The feature map to be enhanced is processed by four parallel attention mechanisms, specifically: The feature map to be enhanced is processed by full connection, the third activation function, and the first attention mechanism in sequence to obtain a first enhanced feature map; The feature map to be enhanced is processed by full connection, the third activation function, and the second attention mechanism in sequence to obtain a second enhanced feature map; The feature map to be enhanced is processed by full connection, the third activation function, and the third attention mechanism in sequence to obtain a third enhanced feature map; The feature map to be enhanced is processed by full connection, the third activation function, and the fourth attention mechanism in sequence to obtain a fourth enhanced feature map; After the first enhanced feature map, the second enhanced feature map, the third enhanced feature map, and the fourth enhanced feature map are sequentially subjected to convolution operations to obtain attention scalars of different enhanced feature maps, the convolution kernel weights are adjusted according to the attention scalars, and the convolution kernel with adjusted weights performs a convolution operation on the feature map to be processed.

3. The method for identifying the growth period of rice in the field according to claim 1, characterized in that: In step S2, the deep extraction feature map obtained is processed by full connection classification to obtain the recognition result, which is specifically: The obtained deep extraction feature map is processed by average pooling, random dropout, and linear processing in turn, and then classified by the fourth activation function to obtain the recognition result.

4. The method for identifying the growth period of rice in the field according to claim 2, characterized in that: The four parallel attention mechanism processes are: spatial level attention, channel level attention, filter level attention, and core level attention.

5. The method for identifying the growth period of rice in the field according to claim 1, characterized in that: In step S2, the preliminary extraction of the features includes the following operations: The image data of different growth stages in the first data set are processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a first feature map; The first feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a second feature map; The second feature map is processed by two-dimensional convolution, batch normalization, and the first activation function in sequence to obtain a third feature map; After the third feature map is processed by maximum pooling, a preliminary extracted feature map is obtained.

6. The method for identifying the growth period of rice in the field according to claim 1, characterized in that: In step S3, the image data of different growth stages in the second data set are marked according to the recognition result to construct an image data set marked with pseudo labels, which is recorded as the third data set, specifically: According to the recognition results, the image data of different growth periods in the second data set are marked to generate pseudo labels. Based on the pseudo-labeled image data set, the first three thousand image data with the highest confidence in each category are selected to construct a rice growth period data set marked with pseudo labels, which is recorded as the third data set.

7. A system for identifying the growth period of rice in a field, characterized in that: include: The first dataset and the second dataset construction module: obtain image data of rice in different growth stages in the field, including leaf development stage, tillering stage, stem elongation stage, booting stage, inflorescence appearance stage, fruit development stage, and maturity stage, mark some image data, and construct an image dataset marked with real labels and an unlabeled image dataset, which are recorded as the first dataset and the second dataset respectively; The first model training module: the image data of different growth stages in the first data set are introduced into the pre-recognition model, and the features are extracted initially and deeply. The deep extraction feature graph obtained is processed by full connection classification to obtain the recognition result and the trained pre-recognition model. The trained pre-recognition model is recorded as the first model; The deep extraction includes the following operations: The initial extracted feature map is processed by average pooling, two-dimensional convolution, and batch normalization in sequence to obtain the first extracted feature map; After the data is copied, the first extracted feature map is recorded as the initial feature map and the feature map to be processed respectively; The feature map to be processed is processed by full-dimensional dynamic convolution, batch normalization, and the first activation function in sequence to obtain a second extracted feature map; The second extracted feature map is sequentially processed by two-dimensional convolution, batch normalization, and the first activation function to obtain a third extracted feature map; The third extracted feature map is processed by two-dimensional convolution and batch normalization in sequence to obtain a fourth extracted feature map; After the fourth extracted feature map is processed by coordinate attention, a fifth extracted feature map is obtained; The fifth extracted feature map is sequentially processed by adaptive average pooling, linear processing, random dropout processing, linear processing, and the second activation function to obtain a sixth extracted feature map; The sixth extracted feature map is added to the initial feature map, and after being processed by the first activation function, a deep extracted feature map is obtained; After the fourth extracted feature map is processed by coordinate attention, the fifth extracted feature map is obtained, which is specifically: The fourth extracted feature map is subjected to residual processing to obtain a first processed feature map; After the global pooling formula is factorized to obtain the channel pooling formulas of the vertical direction formula and the horizontal direction formula, the first processing feature map is averagely pooled in the vertical direction and the horizontal direction respectively to obtain the first vertical processing feature map and the first horizontal processing feature map; After the first vertical processing feature map is concatenated with the first horizontal processing feature map, two-dimensional convolution, batch normalization, and nonlinear processing are performed in sequence to obtain an intermediate feature map; The intermediate feature map is subjected to a channel segmentation operation, and is separated and processed in the vertical direction and the horizontal direction respectively, so as to obtain a second vertical processing feature map and a second horizontal processing feature map; The second vertical processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain a feature weight of the vertical processing feature map; The second horizontal processing feature map is processed by two-dimensional convolution and the second activation function in sequence to obtain the feature weight of the horizontal processing feature map; The feature weights of the vertical processing feature map and the feature weights of the horizontal processing feature map are multiplied by each pixel of the first processing feature map through a broadcasting mechanism to obtain a fifth extracted feature map; The third data set construction module: imports the image data of different growth stages in the second data set into the first model for recognition to obtain recognition results, labels the image data of different growth stages in the second data set according to the recognition results, and constructs an image data set with pseudo labels, which is recorded as the third data set; The second model training module: imports the image data of different growth stages in the third data set into the pre-recognition model for training to obtain the second model; Rice growth period recognition module: obtains the field rice image to be recognized, imports it into the second model, and obtains the recognition result of the growth period.

8. A device for identifying the growth period of rice in a field, characterized in that: The method comprises a processor and a memory, wherein when the processor executes the computer program stored in the memory, the method for identifying the growth period of field rice as described in any one of claims 1 to 6 is implemented.

9. A medium for identifying the growth period of rice in the field, characterized in that: Used to store a computer program, wherein when the computer program is executed by a processor, the method for identifying the growth period of field rice according to any one of claims 1 to 6 is implemented.