Corn crop coefficient calculation method, device, equipment, medium and program product
Through multiple machine learning models combining information about soil and environmental factors, the voting fusion strategy is adopted to solve the problem of low accuracy in calculating corn crop coefficients, and more accurate crop coefficient results are achieved, improving the effectiveness of irrigation strategies.
Patent Information
- Application Number
- CN202411028277.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-30
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2044-07-30
Smart Images

Figure CN118551341B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of agricultural production technology, and in particular to a method, device, equipment, medium and program product for calculating a corn crop coefficient. Background Art
[0002] The crop coefficient is a core calculation parameter that affects the water requirement of corn. Accurately measuring the corn crop coefficient is conducive to implementing effective irrigation strategies and ensuring the healthy growth of corn.
[0003] Machine learning models have strong adaptability and generalization capabilities. No matter how the environment changes, they can quickly adjust themselves. Therefore, machine learning models are used to evaluate the crop coefficient of corn. However, the analysis object of machine learning models is mainly the moisture content data measured by soil sensors in real time, which leads to low accuracy in the calculation of corn crop coefficient. Summary of the invention
[0004] The present invention provides a corn crop coefficient calculation method, device, equipment, medium and program product, which are used to solve the defect of low accuracy of corn crop coefficient calculation in the prior art and improve the accuracy of corn crop coefficient calculation.
[0005] The present invention provides a method for calculating a corn crop coefficient, comprising:
[0006] When corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are combined, and then respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model;
[0007] Voting and fusing the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0008] When the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0009] The calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model are voted and fused to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0010] In some embodiments, before merging the first environmental data, the first surface soil moisture content and the canopy coverage, the method further includes:
[0011] Acquire the first canopy image of corn at the growth stage from seedling stage to ear stage;
[0012] Inputting the first canopy image into the trained first spatial pyramid attention network model to obtain a measurement result of the canopy coverage rate;
[0013] The first canopy image is input into the trained second spatial pyramid attention network model to obtain the measurement result of the first surface soil moisture content.
[0014] In some embodiments, the method further comprises:
[0015] Annotating the first canopy image with respect to canopy coverage and surface soil moisture content to obtain a canopy image sample;
[0016] Based on the canopy image samples, the first spatial pyramid attention network model and the second spatial pyramid attention network model are trained respectively to obtain the trained first spatial pyramid attention network model and the trained second spatial pyramid attention network model.
[0017] In some embodiments, before merging the second environmental data, the second surface soil moisture content and the leaf area index, the method further includes:
[0018] Acquire the second canopy image of corn at the growth stage from flowering and kernel stage to harvest stage;
[0019] The second canopy image is input into the trained third spatial pyramid attention network model to obtain the measurement result of the leaf area index.
[0020] In some embodiments, before merging the second environmental data, the second surface soil moisture content and the leaf area index, the method further includes:
[0021] Taking the first environmental data and the first surface soil moisture content as objects, based on a multiple linear regression model, a relationship model between the environmental data and the surface soil moisture content is constructed;
[0022] Based on the relationship model and the second environmental data, a measurement result of the moisture content of the second surface soil is obtained.
[0023] In some embodiments, the first environmental data and the second environmental data both include: daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data.
[0024] The present invention also provides a corn crop coefficient measuring device, comprising:
[0025] A first input module is used to combine the first environmental data, the first surface soil moisture content and the canopy coverage when the corn is in the growth stage from the seedling stage to the ear stage, and input them into the random forest model, the XGBoost model and the first deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the random forest model, the calculation result of the crop coefficient corresponding to the XGBoost model and the calculation result of the crop coefficient corresponding to the first deep neural network model;
[0026] A first voting module is used to vote and fuse the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0027] A second input module is used to combine the second environmental data, the second surface soil moisture content and the leaf area index, and input them into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively when the corn is in the growth stage from the flowering and grain stage to the harvest stage, so as to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0028] The second voting module is used to vote and fuse the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model, and the calculation results of the crop coefficient corresponding to the second deep neural network model to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0029] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, any of the above-mentioned corn crop coefficient calculation methods is implemented.
[0030] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for calculating the corn crop coefficient as described in any one of the above is implemented.
[0031] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements any of the above-mentioned methods for calculating the corn crop coefficient.
[0032] The corn crop coefficient calculation method, device, equipment, medium and program product provided by the present invention take into account the different growth stages of corn, comprehensively integrate the multi-element information of soil, crop growth conditions and environmental factors at different growth stages, comprehensively consider the factors affecting corn growth from multiple dimensions, and use multiple machine learning models to calculate the crop coefficient. A voting fusion strategy is adopted to superimpose the calculation results of each machine learning model to generate the final calculation result, which can not only make full use of the advantages of each model, but also significantly reduce the calculation deviation caused by a single model, thereby improving the calculation accuracy of the corn crop coefficient. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0034] Figure 1 This is one of the flow charts of the corn crop coefficient calculation method provided by the present invention;
[0035] Figure 2 This is the second flow chart of the corn crop coefficient calculation method provided by the present invention;
[0036] Figure 3 It is a structural schematic diagram of a corn crop coefficient measuring device provided by the present invention;
[0037] Figure 4 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0038] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0039] Figure 1 It is one of the flow charts of the method for calculating the corn crop coefficient provided by the present invention, such as Figure 1 As shown, the present invention provides a method for calculating a corn crop coefficient, comprising the following steps:
[0040] Step 110, when the corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are merged, and then input into the random forest model, the XGBoost model and the first deep neural network model respectively, to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model;
[0041] Step 120, voting and fusing the calculation results of the crop coefficients corresponding to the random forest model, the calculation results of the crop coefficients corresponding to the XGBoost model, and the calculation results of the crop coefficients corresponding to the first deep neural network model, to obtain the calculation results of the first crop coefficients corresponding to the seedling stage to the heading stage;
[0042] Step 130, when the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively, to obtain the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model;
[0043] Step 140, voting fusion is performed on the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model, and the calculation results of the crop coefficient corresponding to the second deep neural network model to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0044] Specifically, due to the different growth stages, the characteristics of crops and the required environmental conditions are different. Therefore, the growth stages of corn are divided into the seedling stage to the ear stage and the flowering and grain stage to the harvest stage, and the crop coefficients at different growth stages are calculated separately, thereby significantly improving the scientificity and accuracy of the crop coefficient calculation results.
[0045] Soil, crop growth conditions and environment are the three main factors that determine crop growth. Soil provides the necessary nutrients for crops, crop growth conditions can directly reflect the quality of crop growth, and environmental factors have a direct impact on the growth process of crops.
[0046] Table 1 Characteristics of corn selected at different growth stages
[0047]
[0048] When corn is in the growth stage from seedling stage to ear stage, as shown in Table 1, canopy coverage, surface soil moisture content and environmental data (daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data) are selected as the characteristics of crop coefficient analysis at this stage. Canopy coverage and surface soil moisture content are the most direct determining factors. Canopy coverage can reflect the growth of crops, and surface soil moisture content directly affects the growth of crops.
[0049] The first environmental data is collected using an environmental sensor, the first canopy image is obtained using an image sensor, and the first surface soil moisture content and canopy coverage are obtained based on the first canopy image. In order to ensure the accuracy of the data, the sensor is calibrated regularly to check whether the data is within a reasonable range and whether there are any abnormal values.
[0050] The first environmental data, the first surface soil moisture content and the canopy coverage rate obtained are combined to obtain the first combined data. The first combined result is respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model.
[0051] The voting fusion strategy of integrated learning is adopted to vote and fuse the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model, and the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage are obtained.
[0052] The voting calculation formula is as follows:
[0053]
[0054] in, Indicates the number of models; For the The calculation results of the crop coefficients corresponding to the models; Final crop coefficient calculated for soft voting.
[0055] When corn is in the growth stage from the flowering and grain stage to the harvest stage, the corn has been closed and the canopy coverage has not changed much. Therefore, as shown in Table 1, leaf area index, surface soil moisture content and environmental data (daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data) are selected as the characteristics of the crop coefficient for analyzing this stage.
[0056] The acquired second environmental data, the second surface soil moisture content and the leaf area index are combined to obtain second combined data. The second combined data are respectively input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model to obtain the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model.
[0057] The calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model are voted and fused to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0058] In some embodiments, the first deep neural network model and the second deep neural network model can be the same type of deep neural network models or different types of deep neural network models, which is determined according to actual conditions.
[0059] In some embodiments, the first environmental data and the second environmental data both include: daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data.
[0060] The corn crop coefficient calculation method provided by the present invention takes into account the different growth stages of corn, comprehensively integrates the multi-element information of soil, crop growth conditions and environmental factors at different growth stages, comprehensively considers the characteristics that affect corn growth from multiple dimensions, and adopts multiple machine learning models to calculate the crop coefficient. A voting fusion strategy is adopted to superimpose the calculation results of each machine learning model to generate the final calculation result. This method can not only make full use of the advantages of each model, but also significantly reduce the calculation deviation caused by a single model, thereby improving the calculation accuracy of the corn crop coefficient.
[0061] In some embodiments, before merging the first environmental data, the first surface soil moisture content and the canopy coverage, the method further includes:
[0062] Acquire the first canopy image of corn at the growth stage from seedling stage to ear stage;
[0063] The first canopy image is input into the trained first spatial pyramid attention network model to obtain the canopy coverage measurement result;
[0064] The first canopy image is input into the trained second spatial pyramid attention network model to obtain the measurement result of the first surface soil moisture content.
[0065] Specifically, the core technical points of the spatial pyramid attention network model include spatial pyramid pooling and attention mechanism. Spatial pyramid pooling makes the model robust to the scale and proportion of the input image by pooling images at different scales, and can capture the multi-scale information of the image. The attention mechanism allows the model to automatically learn which parts to pay more attention to when processing image data, so as to focus on the parts of the image that have the greatest impact on the prediction results. Using the spatial pyramid attention network model, key information representing crop growth conditions in the image, such as canopy coverage, surface soil moisture content, and leaf area index, can be accurately mined and efficiently extracted.
[0066] The first canopy image obtained is input into the trained first spatial pyramid attention network model to extract the canopy coverage, and obtain the canopy coverage measurement result. The first canopy image obtained is input into the trained second spatial pyramid attention network model to measure the surface soil moisture content, and obtain the first surface soil moisture content.
[0067] The corn crop coefficient calculation method provided by the present invention extracts the calculation results of the canopy coverage and the surface soil moisture content through a trained spatial pyramid attention network model, which is beneficial to improving the accuracy and efficiency of the calculation results, and further beneficial to improving the accuracy of subsequent crop coefficients.
[0068] In some embodiments, the corn crop coefficient calculation method provided by the present invention further includes:
[0069] The canopy coverage and surface soil moisture content are annotated on the first canopy image to obtain a canopy image sample;
[0070] Based on the canopy image samples, the first spatial pyramid attention network model and the second spatial pyramid attention network model are trained respectively to obtain the trained first spatial pyramid attention network model and the trained second spatial pyramid attention network model.
[0071] Specifically, a small number of first canopy images are selected to annotate the canopy coverage and surface soil moisture content, thereby obtaining canopy image samples for model training.
[0072] The canopy image sample is input into the first spatial pyramid attention network model, and the first spatial pyramid attention network model outputs the measured value of the canopy coverage. The loss value is calculated according to the measured value of the canopy coverage and the labeled value of the canopy coverage. If the loss value of the canopy coverage is lower than the first preset threshold, the trained first spatial pyramid attention network model is obtained.
[0073] The loss function calculation formula is:
[0074]
[0075] in, is the loss function; is the marked value; is the calculated value, Indicates the number of samples.
[0076] The canopy image samples are input into the second spatial pyramid attention network model, and the second spatial pyramid attention network model outputs the measured value of the surface soil moisture content. According to the measured value of the surface soil moisture content and the labeled value of the surface soil moisture content, the loss value of the surface soil moisture content is calculated. If the loss value of the surface soil moisture content is lower than the second preset threshold, the trained second spatial pyramid attention network model is obtained.
[0077] The corn crop coefficient calculation method provided by the present invention respectively trains the first spatial pyramid attention network model and the second spatial pyramid attention network model by using canopy image samples with marked canopy coverage and surface soil moisture content, so as to obtain an accurate trained first spatial pyramid attention network model and a trained second spatial pyramid attention network model.
[0078] In some embodiments, before merging the second environmental data, the second surface soil moisture content and the leaf area index, the method further includes:
[0079] Acquire the second canopy image of corn at the growth stage from flowering and kernel stage to harvest stage;
[0080] The second canopy image is input into the trained third spatial pyramid attention network model to obtain the leaf area index measurement result.
[0081] Specifically, when the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second canopy image is acquired.
[0082] A small number of second canopy images are selected for leaf area index annotation. The second canopy images annotated with leaf area index are input into the third spatial pyramid attention network model, and the third spatial pyramid attention network model outputs the calculated value of the leaf area index. According to the annotated value of the leaf area index and the calculated value of the leaf area index, the loss value of the leaf area index is calculated. If the loss value of the leaf area index is lower than the third preset threshold, a trained third spatial pyramid attention network model is obtained.
[0083] By inputting the second canopy image into the trained third spatial pyramid attention network model, the leaf area index measurement result can be obtained.
[0084] The corn crop coefficient calculation method provided by the present invention extracts the calculation result of the leaf area index through a trained spatial pyramid attention network model, which is beneficial to improving the accuracy and efficiency of the calculation result, and further beneficial to improving the accuracy of subsequent crop coefficients.
[0085] In some embodiments, before merging the second environmental data, the second surface soil moisture content and the leaf area index, the method further includes:
[0086] Taking the first environmental data and the first surface soil moisture content as objects, a relationship model between the environmental data and the surface soil moisture content is constructed based on a multiple linear regression model;
[0087] Based on the relationship model and the second environmental data, the measurement result of the second surface soil moisture content is obtained.
[0088] Specifically, according to the first environmental data and the first surface soil moisture content in the growth stage from the seedling stage to the heading stage, a relationship model between the environmental data and the surface soil moisture content is constructed through a multiple linear regression model.
[0089] The expression of the relationship model between environmental data and surface soil moisture content is as follows:
[0090]
[0091] in, is the surface soil moisture content, is the corresponding regression coefficient, is the daily average temperature, is the daily average relative humidity, is the daily average wind speed, is the daily precipitation, is the error term.
[0092] The corn crop coefficient calculation method provided by the present invention uses the first environmental data from the seedling stage to the ear stage and the first surface soil moisture content, and adopts a multivariate linear regression model to construct a relationship model between the environmental data and the surface soil moisture content, thereby improving the accuracy of the relationship model so as to obtain an accurate calculation result of the second surface soil moisture content based on the relationship model.
[0093] According to the corn crop coefficient calculation method provided by the present invention, a specific embodiment is provided below.
[0094] Figure 2 This is the second flow chart of the corn crop coefficient calculation method provided by the present invention. Figure 2 As shown, the corn crop coefficient calculation method includes three stages: data collection, feature acquisition and feature processing.
[0095] Environmental sensors and image sensors are installed in the field for data collection. Environmental sensors collect a series of environmental data, including daily average temperature, daily average relative humidity, daily average wind speed, and daily precipitation. Image sensors capture canopy images of corn plant canopies. After the data are collected, cleaning operations are performed, such as removing outliers and filling missing values with the mean.
[0096] When corn is in the seedling and ear stages, the spatial pyramid attention network model is used to extract features from corn canopy images at the seedling and ear stages. First, the model is applied to the canopy images acquired by the image sensor, and the canopy coverage and surface soil moisture content in the canopy images are annotated. Then, two spatial pyramid attention network models are trained using the annotated data to measure the canopy coverage and surface soil moisture content of the image, respectively. The training process is as follows:
[0097] Step 1: Before starting training, randomly initialize the model weights and biases to small random values.
[0098] Step 2: Calculate the loss between the model's measured value and the labeled value.
[0099] Step 3: Calculate the gradient of the loss value to the model parameters through the back propagation algorithm. Then, update the model parameters according to these gradients to reduce the calculation error of the model.
[0100] Step 4: Repeat steps 2 to 3 until the model loss converges to a smaller value or reaches the preset number of iterations.
[0101] In this process, the model needs to be trained for canopy coverage and surface soil moisture content respectively, so two spatial pyramid attention network models need to be trained. After training, the two models can be used to measure the canopy coverage and surface soil moisture content of the image respectively.
[0102] These canopy coverage values, surface soil moisture values, and environmental data were integrated together to form a modeling data set. Subsequently, the modeling data set was divided into a training set and a test set in a ratio of 7:3, and the training set was input into the random forest model, XGboost model, and deep neural network model for training. The test set was then input into the three trained models to obtain three measurement results. Finally, the final crop coefficients of corn seedling and ear stages were obtained through the voting fusion strategy.
[0103] When corn is in the flowering and harvesting stages, the spatial pyramid attention network model is trained to calculate the leaf area index, and the training steps are the same as those in the seedling and ear stages.
[0104] At the same time, based on the surface soil moisture content and environmental data from the corn seedling stage to the ear stage, a multiple linear regression model was constructed to calculate the surface soil moisture content at the flowering and grain stage and the harvest stage. The training process of the multiple linear regression model is as follows:
[0105] Step 1: Divide the surface soil moisture content, daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data from the seedling stage to the heading stage into a training set and a test set in a ratio of 7:3. These data will be used to train the model and verify the performance of the model.
[0106] Step 2: The model uses the above data to train a multivariate linear regression model and determine the optimal parameter values.
[0107] Step 3: Use the Bayesian optimizer to independently tune the model's hyperparameters to further improve the model's performance.
[0108] Step 4: Record and save the optimal parameters of the model to provide a basis for subsequent model application and analysis.
[0109] Then, the leaf area index, surface soil moisture content, and environmental parameters were integrated together to form a modeling data set. Then, the modeling data set was divided into a training set and a test set in a ratio of 7:3, and the training set was input into the support vector machine, gradient boosting decision tree, and deep neural network model respectively. Then, the test set was input into the three trained models to obtain three measurement results. Finally, through the voting fusion strategy, the mean of the three measurement values was taken to obtain the final crop coefficient of corn at the flowering and harvesting stages.
[0110] The corn crop coefficient calculation device provided by the present invention is described below. The corn crop coefficient calculation device described below and the corn crop coefficient calculation method described above can be referred to each other.
[0111] Figure 3 Schematic diagram of the structure of the corn crop coefficient measuring device provided by the present invention. Figure 3 As shown, the present invention provides a corn crop coefficient measuring device, comprising:
[0112] The first input module 310 is used to combine the first environmental data, the first surface soil moisture content and the canopy coverage rate, and input them into the random forest model, the XGBoost model and the first deep neural network model respectively when the corn is in the growth stage from the seedling stage to the ear stage, so as to obtain the calculation result of the crop coefficient corresponding to the random forest model, the calculation result of the crop coefficient corresponding to the XGBoost model and the calculation result of the crop coefficient corresponding to the first deep neural network model;
[0113] A first voting module 320 is used to vote and fuse the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0114] The second input module 330 is used to combine the second environmental data, the second surface soil moisture content and the leaf area index, and input them into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively when the corn is in the growth stage from the flowering and grain stage to the harvest stage, so as to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0115] The second voting module 340 is used to vote and fuse the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model, and the calculation results of the crop coefficient corresponding to the second deep neural network model to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0116] In some embodiments, the apparatus further comprises:
[0117] A first acquisition module is used to acquire a first canopy image of corn when the corn is in the growth stage from the seedling stage to the ear stage;
[0118] A third input module is used to input the first canopy image into the trained first spatial pyramid attention network model to obtain the measurement result of the canopy coverage rate;
[0119] The fourth input module is used to input the first canopy image into the trained second spatial pyramid attention network model to obtain the measurement result of the first surface soil moisture content.
[0120] In some embodiments, the apparatus further comprises:
[0121] A labeling module, used to label the first canopy image with respect to canopy coverage and surface soil moisture content, to obtain a canopy image sample;
[0122] A training module is used to train the first spatial pyramid attention network model and the second spatial pyramid attention network model based on canopy image samples, respectively, to obtain the trained first spatial pyramid attention network model and the trained second spatial pyramid attention network model.
[0123] In some embodiments, the apparatus further comprises:
[0124] The second acquisition module is used to acquire a second canopy image of corn when the corn is in a growth stage from a flowering and grain stage to a harvest stage;
[0125] The fifth input module is used to input the second canopy image into the trained third spatial pyramid attention network model to obtain the measurement result of the leaf area index.
[0126] In some embodiments, the apparatus further comprises:
[0127] A construction module, for taking the first environmental data and the first surface soil moisture content as objects, and constructing a relationship model between the environmental data and the surface soil moisture content based on a multiple linear regression model;
[0128] An obtaining module is used to obtain a measurement result of the moisture content of the second surface soil based on the relationship model and the second environmental data.
[0129] In some embodiments, the first environmental data and the second environmental data both include: daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data.
[0130] It should be noted here that the above-mentioned corn crop coefficient measuring device provided by the present invention can implement all the method steps implemented by the above-mentioned method embodiment, and can achieve the same technical effect. The parts and beneficial effects that are the same as the method embodiment in this embodiment will not be specifically described here.
[0131] Figure 4 is a schematic diagram of the structure of the electronic device provided by the present invention, such as Figure 4 As shown, the electronic device may include: a processor 410, a communications interface 420, a memory 430 and a communication bus 440, wherein the processor 410, the communications interface 420 and the memory 430 communicate with each other through the communication bus 440. The processor 410 may call the logic instructions in the memory 430 to execute the corn crop coefficient estimation method, which includes:
[0132] When corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are combined, and then respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model;
[0133] Voting and fusing the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0134] When the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0135] The calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model are voted and fused to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0136] In addition, the logic instructions in the above-mentioned memory 430 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0137] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored in a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute the corn crop coefficient calculation method provided by the above methods, the method includes:
[0138] When corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are combined, and then respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model;
[0139] Voting and fusing the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0140] When the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0141] The calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model are voted and fused to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0142] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for calculating the corn crop coefficient provided by the above methods is implemented, and the method comprises:
[0143] When corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are combined, and then respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model;
[0144] Voting and fusing the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage;
[0145] When the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model;
[0146] The calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation results of the crop coefficient corresponding to the second deep neural network model are voted and fused to obtain the calculation results of the second crop coefficient corresponding to the flowering and grain stage to the harvest stage.
[0147] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0148] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0149] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for calculating corn crop coefficient, characterized in that: include: When corn is in the growth stage from the seedling stage to the ear stage, the first environmental data, the first surface soil moisture content and the canopy coverage are combined, and then respectively input into the random forest model, the XGBoost model and the first deep neural network model to obtain the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model and the calculation results of the crop coefficient corresponding to the first deep neural network model; Voting and fusing the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage; When the corn is in the growth stage from the flowering and grain stage to the harvest stage, the second environmental data, the second surface soil moisture content and the leaf area index are combined and input into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model; Voting and fusing the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model, and the calculation results of the crop coefficient corresponding to the second deep neural network model to obtain the calculation results of the second crop coefficient corresponding to the flowering and seeding period to the harvesting period; Before the second environmental data, the second surface soil moisture content and the leaf area index are combined, the method further includes: Taking the first environmental data and the first surface soil moisture content as objects, based on a multiple linear regression model, a relationship model between the environmental data and the surface soil moisture content is constructed; Based on the relationship model and the second environmental data, a measurement result of the moisture content of the second surface soil is obtained.
2. The method for calculating the corn crop coefficient according to claim 1, characterized in that: Before merging the first environmental data, the first surface soil moisture content and the canopy coverage, the method further includes: Acquire the first canopy image of corn at the growth stage from seedling stage to ear stage; Inputting the first canopy image into the trained first spatial pyramid attention network model to obtain a measurement result of the canopy coverage rate; The first canopy image is input into the trained second spatial pyramid attention network model to obtain the measurement result of the first surface soil moisture content.
3. The method for calculating the corn crop coefficient according to claim 2, characterized in that: The method further comprises: Annotating the first canopy image with respect to canopy coverage and surface soil moisture content to obtain a canopy image sample; Based on the canopy image samples, the first spatial pyramid attention network model and the second spatial pyramid attention network model are trained respectively to obtain the trained first spatial pyramid attention network model and the trained second spatial pyramid attention network model.
4. The method for calculating the corn crop coefficient according to claim 1, characterized in that: Before the second environmental data, the second surface soil moisture content and the leaf area index are combined, the method further includes: Acquire the second canopy image of corn at the growth stage from flowering and kernel stage to harvest stage; The second canopy image is input into the trained third spatial pyramid attention network model to obtain the measurement result of the leaf area index.
5. The method for calculating the corn crop coefficient according to claim 1, characterized in that: The first environmental data and the second environmental data both include: daily average temperature, daily average relative humidity, daily average wind speed and daily precipitation data.
6. A corn crop coefficient measuring device, characterized in that: include: A first input module is used to combine the first environmental data, the first surface soil moisture content and the canopy coverage when the corn is in the growth stage from the seedling stage to the ear stage, and input them into the random forest model, the XGBoost model and the first deep neural network model respectively to obtain the calculation result of the crop coefficient corresponding to the random forest model, the calculation result of the crop coefficient corresponding to the XGBoost model and the calculation result of the crop coefficient corresponding to the first deep neural network model; A first voting module is used to vote and fuse the calculation results of the crop coefficient corresponding to the random forest model, the calculation results of the crop coefficient corresponding to the XGBoost model, and the calculation results of the crop coefficient corresponding to the first deep neural network model to obtain the calculation results of the first crop coefficient corresponding to the seedling stage to the heading stage; A second input module is used to combine the second environmental data, the second surface soil moisture content and the leaf area index, and input them into the support vector machine, the gradient boosting decision tree model and the second deep neural network model respectively when the corn is in the growth stage from the flowering and grain stage to the harvest stage, so as to obtain the calculation result of the crop coefficient corresponding to the support vector machine, the calculation result of the crop coefficient corresponding to the gradient boosting decision tree model and the calculation result of the crop coefficient corresponding to the second deep neural network model; A second voting module is used to perform voting fusion on the calculation results of the crop coefficient corresponding to the support vector machine, the calculation results of the crop coefficient corresponding to the gradient boosting decision tree model, and the calculation results of the crop coefficient corresponding to the second deep neural network model, so as to obtain the calculation results of the second crop coefficient corresponding to the flowering and seeding period to the harvesting period; Before the second environmental data, the second surface soil moisture content and the leaf area index are combined, the method further includes: Taking the first environmental data and the first surface soil moisture content as objects, based on a multiple linear regression model, a relationship model between the environmental data and the surface soil moisture content is constructed; Based on the relationship model and the second environmental data, a measurement result of the moisture content of the second surface soil is obtained.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the corn crop coefficient calculation method as described in any one of claims 1 to 5 is implemented.
8. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the corn crop coefficient calculation method as described in any one of claims 1 to 5 is implemented.
9. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the corn crop coefficient calculation method as described in any one of claims 1 to 5 is implemented.
