Prediction method for occurrence condition of rice-stem borers
Through the random forest model and grid search cross-verification technology, combined with meteorological environmental data standardization and decision tree contribution sorting, the subjectivity and dependence problems of traditional rice pest prediction methods are solved, and the accurate nonlinearity of rice borer is achieved Prediction and meteorological environmental factor importance analysis improve the robustness and scientificity of prediction.
Patent Information
- Application Number
- CN202410970666.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2044-07-19
AI Technical Summary
Traditional rice pest prediction methods are subjective and dependable, and it is difficult to effectively deal with nonlinear relationships, resulting in inaccurate prediction results and overfitting, especially under small sample data.
The random forest model is used to combine grid search and cross-validate to determine the input parameters, and nonlinear prediction of the occurrence of rice borer by standardizing meteorological environmental data and sorting of contributions in decision trees is achieved.
Improve the robustness and noise resistance of prediction, overcome the dependence and inefficiency of traditional methods, realize the accurate cumulative number prediction of the time series of rice borer borer, and provide the importance of meteorological environmental factors. , provide a scientific basis for prevention and control policies.
Smart Images

Figure CN118916782A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of agricultural information technology, and more specifically, to a method for predicting the occurrence of rice stem borer. Background Art
[0002] Monitoring and early warning of rice pests is a basic work of rice protection and a prerequisite for reasonable and scientific guidance of pest and disease control. As one of the main pests of rice production, the larvae of the Chilo suppressalis bore into the stems, causing sheath dryness, heart dryness, and panicle whitening to the rice, seriously affecting rice yield and quality. Therefore, timely and accurate prediction of the occurrence of the Chilo suppressalis is of great guiding significance for ensuring food security and for the plant protection department to formulate effective prevention and control policies.
[0003] Traditional rice pest prediction methods are mainly based on empirical prediction methods, experimental prediction methods, and mathematical statistics prediction methods. They are somewhat subjective, and in most cases, they construct a simple linear relationship between prediction factors and pests, and the prediction results are highly dependent on the input data. In fact, the relationship between prediction factors and pests is not a simple linear relationship, but a highly nonlinear one. In addition, historical data on rice pests are often a typical small sample data, and traditional prediction methods are prone to poor performance and overfitting problems.
[0004] The random forest method can identify key features through feature screening in small sample analysis, and reduce the risk of overfitting by integrating multiple decision tree structures and randomness, which can avoid the shortcomings of traditional prediction methods and realize nonlinear prediction of the occurrence of rice stem borer, with strong robustness and noise resistance. However, the performance of the random forest model is sensitive to its parameter settings, and the model is integrated by multiple decision trees, which easily makes the calculation process and results difficult to explain. Summary of the invention
[0005] The purpose of the invention is to address the deficiencies of the prior art and to propose a method for predicting the occurrence of rice stem borer.
[0006] In a first aspect, a method for predicting the occurrence of rice stem borer is provided, comprising:
[0007] Step 1, obtaining information on the number of Chilo suppressalis and the date of rice growth and development in the study area;
[0008] Step 2, obtaining meteorological and environmental data during the growth and development of rice, and performing standardization on the meteorological and environmental data;
[0009] Step 3, constructing a data set according to the rice growth and development period date, the number information of the Chilo suppressalis and the meteorological environment data, and dividing the data set into a training set and a test set;
[0010] Step 4: Based on the random forest model, grid search and cross validation are used to determine the input parameters and parameter thresholds of the random forest model, and the optimal numerical combination of the model input parameters is determined based on the evaluation indicators;
[0011] Step 5, using the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set, and outputting the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set;
[0012] Step 6: Use the evaluation indicators to evaluate the training set and the test set respectively to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value;
[0013] Step 7: Use the test set to analyze the cumulative number trend of Chilo suppressalis to predict the occurrence of Chilo suppressalis.
[0014] Step 8: According to the contribution of meteorological environmental factors to the decision tree in the random forest model, rank the meteorological environmental factors that affect the cumulative number of Chilo suppressalis and quantify the importance of meteorological environmental factors.
[0015] Preferably, in step 2, the meteorological environment data is composed of a number of meteorological environment factors, including air temperature, air humidity, dew point temperature, soil temperature, soil moisture, wind speed, wind direction, atmospheric pressure, rainfall, light intensity, average temperature and relative humidity.
[0016] Preferably, in step 2, the meteorological environment data is standardized, including: eliminating the dimensional differences between different meteorological environment factors through range standardization, so that each meteorological environment factor is at the same order of magnitude; the calculation formula for the standardized processing is:
[0017]
[0018] Among them, X' is the standardized value, X is the original data value, and X max is the maximum value in the data, X min is the minimum value in the data.
[0019] Preferably, in step 3, the date of rice growth and development period is used as the time series, the number information of Chilo suppressalis is used as the dependent variable, and the meteorological environment data is used as the independent variable; the ratio of the training set to the test set is 7:3.
[0020] Preferably, step 4 comprises:
[0021] Step 4.1, determine the input parameters and parameter value range of the random forest model; the input parameters include the number of trees, the maximum depth of the tree, the number of samples for the minimum node segmentation, and the minimum number of samples for the leaves;
[0022] Step 4.2: Use grid search to traverse each parameter combination in the parameter grid of step 4.1;
[0023] Step 4.3: For each parameter combination, perform 3-fold cross validation, which is to divide the data set into 3 non-overlapping subsets. For each subset, use the current subset as the validation set and the other two subsets as the training set. Repeat this process 3 times, each time selecting a different subset as the validation set.
[0024] Step 4.4: The average value of the root mean square error of the three validations is used as the performance evaluation index of the parameter combination. The smaller the value, the better the prediction performance of the model. The calculation formula of the root mean square error is:
[0025]
[0026] Where n is the number of samples, y i is the actual observation value of the ith is the i-th prediction value, and RMSE is the average of the squares of the prediction errors;
[0027] Step 4.5: Based on the evaluation results of cross-validation, select the combination with the smallest RMSE on the validation set as the optimal numerical combination of the input parameters of the random forest model.
[0028] Preferably, in step 6, the evaluation indicators include root mean square error, mean absolute error, determination coefficient and Pearson correlation coefficient, and the calculation formula is:
[0029]
[0030] Where n is the number of samples, y i is the actual observation value of the ith is the i-th predicted value, and MAE measures the mean absolute error between the predicted value and the actual value;
[0031]
[0032] Where n is the number of samples, y i is the actual observation value of the ith is the ith predicted value, is the mean of the actual observations, R 2 is the coefficient of determination, which is between 0 and 1. The closer it is to 1, the better the model fit is;
[0033]
[0034] Among them, x i is the predicted value, y i is the actual observed value, and are the means of the predicted values and the actual observed values, respectively. r is the Pearson correlation coefficient. The value of r is between -1 and 1, where 1 indicates a perfect positive correlation, -1 indicates a perfect negative correlation, and 0 indicates no correlation.
[0035] Preferably, in step 8, the contribution to the meteorological environment factor is calculated by the formula:
[0036]
[0037] Where FI(j) is the importance of feature j, T is the number of decision trees, and N t are all nodes in tree t, v(n) is the feature used to split node n, p(n) is the proportion of samples passing through node n, and Δi(n,t) is the purity change at node i n.
[0038] In a second aspect, a prediction system for the occurrence of rice stem borer is provided, which is used to execute any of the prediction methods for the occurrence of rice stem borer described in the first aspect, comprising:
[0039] The first acquisition module is used to acquire information about the Chilo suppressalis and rice during the growth and development of rice in the study area; the Chilo suppressalis information includes Chilo suppressalis image information and Chilo suppressalis quantity information;
[0040] The second acquisition module is used to obtain meteorological and environmental data during the growth and development of rice, and to perform standardization on the meteorological and environmental data;
[0041] A construction module is used to construct a data set according to the date of rice growth and development period, the number information of Chilo suppressalis and meteorological environment data, and divide the data set into a training set and a test set;
[0042] A determination module is used to determine the input parameters and parameter thresholds of the random forest model based on the random forest model by using grid search and cross validation, and to determine the optimal numerical combination of the model input parameters according to the evaluation index;
[0043] A prediction module is used to use the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set respectively, and output the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set;
[0044] The evaluation module is used to evaluate the training set and the test set using evaluation indicators to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value;
[0045] The analysis module is used to analyze the cumulative number trend of the Chilo suppressalis using the test set to predict the occurrence of the Chilo suppressalis;
[0046] The sorting module is used to sort the meteorological and environmental factors that affect the cumulative number of Chilo suppressalis according to the contribution of meteorological and environmental factors to the decision tree in the random forest model, and to quantify the importance of meteorological and environmental factors.
[0047] In a third aspect, a computer-readable storage medium is provided, the computer-readable storage medium comprising a stored executable program, wherein when the executable program is run, the device where the computer-readable storage medium is located is controlled to execute any method for predicting the occurrence of rice stem borer as described in the first aspect.
[0048] The beneficial effects of the present invention are as follows: the present invention obtains the Chilo suppressalis data and meteorological environment data in the sex attractant device, and standardizes the meteorological environment data to eliminate the dimensional differences of different meteorological environment factors, so that each meteorological environment factor is at the same order of magnitude, thereby having the effect of analyzing the meteorological environment factors on the occurrence of Chilo suppressalis. On this basis, the present invention predicts the cumulative number of Chilo suppressalis based on the random forest model, introduces grid search and cross-validation to find the optimal numerical combination of random forest input parameters, and solves the problem that the random forest model is sensitive to the input parameter setting. In addition, the present invention ranks the importance of meteorological environment factors that affect the cumulative number of Chilo suppressalis, and provides a reference for the formulation of Chilo suppressalis pest control policies. Compared with the traditional Chilo suppressalis prediction method, the prediction method for the occurrence of rice Chilo suppressalis provided by the present invention can overcome the problems of traditional pest prediction relying on experience, low efficiency, high uncertainty, etc., and realize the prediction of the cumulative number of rice Chilo suppressalis time series. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1a It is a flow chart of a method for predicting the occurrence of rice stem borer;
[0050] Figure 1b This is a schematic diagram of the Chilo suppressalis data and meteorological environment data;
[0051] Figure 1c Schematic diagram for standardization processing;
[0052] Figure 1d Schematic diagram for adjusting model parameters;
[0053] Figure 1e Schematic diagram of experimental results;
[0054] Figure 2a This is a schematic diagram of the study area in the embodiment of the present invention; Figure 2b This is a diagram of the number analysis of Chilo suppressalis in an embodiment of the present invention; Figure 3 This is a standardized processing diagram of meteorological environmental factors in Jiulongwang, the study area in the embodiment of the present invention; Figure 4 This is a forecast diagram of the cumulative number of Chilo suppressalis in the study area in the embodiment of the present invention; Figure 5 This is a trend chart of the cumulative number of Chilo suppressalis in the study area in the embodiment of the present invention; Figure 6 This is a characteristic ranking diagram of meteorological environmental factors in an embodiment of the present invention. DETAILED DESCRIPTION
[0055] The present invention is further described below in conjunction with embodiments. The description of the following embodiments is only used to help understand the present invention. It should be noted that for ordinary persons in the art, without departing from the principle of the present invention, the present invention can also be modified in some ways, and these improvements and modifications also fall within the scope of protection of the claims of the present invention.
[0056] Embodiment 1:
[0057] As one of the main pests of rice, the larvae of the Chilo suppressalis feed by boring into the internal tissues of rice, resulting in symptoms such as dead tips, dead hearts, and white ears, which seriously affect rice yield and quality. The prediction of the Chilo suppressalis can provide information on the potential threats of pests, provide scientific data for the formulation of prevention and control measures, and reduce the damage of the Chilo suppressalis to rice. In this regard, Example 1 of the present application provides a prediction method for the occurrence of the Chilo suppressalis. When constructing a prediction model for the occurrence of the Chilo suppressalis based on random forests, a grid search method and cross-validation are used to systematically determine the optimal combination of input parameters and parameter values, and the meteorological environmental factors that affect the cumulative number of the Chilo suppressalis are ranked, thereby ensuring that the model can achieve accurate prediction performance.
[0058] like Figure 1a As shown, the embodiment of the present application sequentially obtains prediction results through data acquisition, data processing, modeling and optimization. Specifically, the method provided in the embodiment of the present application includes:
[0059] Step 1: Obtain information about the Chilo suppressalis and rice during the growth and development of rice in the study area; the Chilo suppressalis information includes Chilo suppressalis image information and Chilo suppressalis quantity information.
[0060] Specifically, information about the Chilo suppressalis is mainly obtained through the Top Digital Agriculture Cloud, which obtains IoT sex-induced detection data, such as Figure 1b As shown, it includes the image information and the number of Chilo suppressalis. Among them, sexual luring is carried out according to the habits of Chilo suppressalis using sexual attractants. Sexual luring photos are taken at 10:30 am every day, and the artificial intelligence AI recognition system is used to automatically identify and count the Chilo suppressalis.
[0061] Step 2: Obtain meteorological and environmental data during the growth and development of rice, and standardize the meteorological and environmental data.
[0062] Meteorological and environmental data are collected by the meteorological monitoring component set up by Top Digital Agriculture Cloud. Meteorological and environmental data include hourly data and daily data, and the study uses daily meteorological and environmental data.
[0063] The meteorological environment data is composed of a number of meteorological environment factors, including air temperature, air humidity, dew point temperature, soil temperature, soil moisture, wind speed, wind direction, atmospheric pressure, rainfall, light intensity, average temperature and relative humidity.
[0064] The meteorological environment data is standardized, such as Figure 1c As shown, it includes: through range standardization, the dimensional differences between different meteorological environmental factors are eliminated, so that each meteorological environmental factor is at the same order of magnitude; the calculation formula for standardization is:
[0065]
[0066] Among them, X' is the standardized value, X is the original data value, and X max is the maximum value in the data, X min is the minimum value in the data.
[0067] Step 3: construct a data set according to the rice growth and development period date, the number information of the Chilo suppressalis and the meteorological environment data, and divide the data set into a training set and a test set.
[0068] In step 3, the date of rice growth and development period is used as the time series, the number of rice stem borers is used as the dependent variable, and the meteorological environment data is used as the independent variable; the ratio of the training set to the test set is 7:3.
[0069] Step 4: Based on the random forest model, grid search and cross validation are used to determine the input parameters and parameter thresholds of the random forest model, and the optimal numerical combination of the model input parameters is determined based on the evaluation indicators.
[0070] Step 4 includes:
[0071] Step 4.1, determine the input parameters and parameter value range of the random forest model; the input parameters include the number of trees, the maximum depth of the tree, the number of samples for the minimum node split and the minimum number of samples for the leaves; define the parameter values as follows;
[0072] Number of trees: based on the number of trees in the decision tree ensemble method, 100, 200, and 400 respectively;
[0073] The maximum depth of the tree: the number of nodes on the longest path from the root node to the farthest leaf node, which are 10, 20, and 30 respectively;
[0074] Minimum number of samples for node splitting: The minimum number of samples that an internal node must contain before splitting, which are 2, 5, and 10 respectively;
[0075] Minimum number of samples for leaves: The minimum number of samples that a leaf node must contain, which are 1, 2, and 4 respectively;
[0076] Step 4.2: Use grid search to traverse each parameter combination in the parameter grid of step 4.1;
[0077] Step 4.3: For each parameter combination, perform 3-fold cross validation, which is to divide the data set into 3 non-overlapping subsets. For each subset, use the current subset as the validation set and the other two subsets as the training set. Repeat this process 3 times, each time selecting a different subset as the validation set.
[0078] Step 4.4: The average value of the root mean square error of the three validations is used as the performance evaluation index of the parameter combination. The smaller the value, the better the prediction performance of the model, that is, the smaller the difference between the predicted value and the actual value. The calculation formula of the root mean square error is:
[0079]
[0080] Where n is the number of samples, y i is the actual observation value of the ith is the i-th prediction value, and RMSE is the average of the squares of the prediction errors;
[0081] Step 4.5: Based on the evaluation results of cross-validation, select the combination with the smallest RMSE on the validation set as the optimal numerical combination of the input parameters of the random forest model to achieve accurate prediction effect of the random forest model on the validation set.
[0082] Step 5: Use the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set respectively, and output the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set.
[0083] Step 6: Use evaluation indicators to evaluate the training set and test set respectively to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value.
[0084] Step 7: Use the test set to analyze the cumulative number trend of Chilo suppressalis to predict the occurrence of Chilo suppressalis.
[0085] Step 8: According to the contribution of meteorological environmental factors to the decision tree in the random forest model, rank the meteorological environmental factors that affect the cumulative number of Chilo suppressalis and quantify the importance of meteorological environmental factors.
[0086] In step 8, the contribution to the meteorological environment factor is calculated as follows:
[0087]
[0088] Where FI(j) is the importance of feature j, T is the number of decision trees, and N t are all nodes in tree t, v(n) is the feature used to split node n, p(n) is the proportion of samples passing through node n, and Δi(n,t) is the purity change at node i n.
[0089] Embodiment 2:
[0090] Based on Example 1, Example 2 of the present application provides a more specific prediction method for the occurrence of rice stem borer, which is applied in reality: Ningbo City, Zhejiang Province is a typical rice multiple planting pattern area, where single-season rice and double-season rice are planted, and the rice planting patterns are diverse and the planting structure is complex; a prediction method for the occurrence of rice stem borer is applied to Ningbo City, Zhejiang Province, and the study area is mainly Jiulongwang, Modern Seed Incubation Base, and Mailang Farm, three experimental fields, which are located in Zhenhai District, Yinzhou District and Fenghua District of Ningbo City respectively; and the random forest method is used to combine meteorological environment information and related pest information to construct a cumulative quantity prediction model for the rice stem borer time series.
[0091] Specifically, the above method includes:
[0092] Step 1, as shown in FIG2 , obtain information about the Chilo suppressalis and rice during the growth and development of rice in the study area; the Chilo suppressalis information includes Chilo suppressalis image information and Chilo suppressalis quantity information.
[0093] Step 2: Figure 3 As shown, the meteorological and environmental data during the growth and development of rice are obtained and standardized.
[0094] Step 3: construct a data set according to the rice growth and development period date, the number information of the Chilo suppressalis and the meteorological environment data, and divide the data set into a training set and a test set.
[0095] Step 4: Based on the random forest model, grid search and cross validation are used to determine the input parameters and parameter thresholds of the random forest model, and the optimal numerical combination of the model input parameters is determined based on the evaluation indicators.
[0096] Step 5: Figure 4 As shown, the optimal input parameter combination of the random forest model is used to predict the cumulative number of Chilo suppressalis for the training set and the test set, and the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set are output.
[0097] Step 6: Figure 1eAs shown in the figure, the evaluation indicators are used to evaluate the training set and the test set respectively to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value.
[0098] In step 6, the evaluation indicators include root mean square error, mean absolute error, determination coefficient and Pearson correlation coefficient, and the calculation formula is:
[0099]
[0100] Where n is the number of samples, y i is the actual observation value of the ith is the i-th predicted value, and MAE measures the mean absolute error between the predicted value and the actual value;
[0101]
[0102] Where n is the number of samples, y i is the actual observation value of the ith is the ith predicted value, is the mean of the actual observations, R 2 is the coefficient of determination, which is between 0 and 1. The closer it is to 1, the better the model fit is;
[0103]
[0104] Among them, x i is the predicted value, y i is the actual observed value, and are the means of the predicted values and the actual observed values, respectively. r is the Pearson correlation coefficient. The value of r is between -1 and 1, where 1 indicates a perfect positive correlation, -1 indicates a perfect negative correlation, and 0 indicates no correlation.
[0105] Step 7: Figure 5 As shown in the figure, the test set is used to analyze the cumulative number trend of Chilo suppressalis to predict the occurrence of Chilo suppressalis.
[0106] Step 8: Figure 6 As shown in the figure, according to the contribution of meteorological and environmental factors to the decision tree in the random forest model, the meteorological and environmental factors that affect the cumulative number of Chilo suppressalis are ranked, and the importance of meteorological and environmental factors is quantified.
[0107] In step 8, the contribution to the meteorological environment factor is calculated as follows:
[0108]
[0109] Where FI(j) is the importance of feature j, T is the number of decision trees, and N tare all nodes in tree t, v(n) is the feature used to split node n, p(n) is the proportion of samples passing through node n, and Δi(n,t) is the purity change at node i n.
[0110] It should be noted that the parts in this embodiment that are the same or similar to those in Embodiment 1 can be referenced to each other and will not be described in detail in this application.
[0111] Embodiment 3:
[0112] On the basis of Example 1, Example 3 of the present application provides a prediction system for the occurrence of rice stem borer, which is used to execute any of the prediction methods for the occurrence of rice stem borer described in the first aspect, including:
[0113] The first acquisition module is used to acquire information about the Chilo suppressalis and rice during the growth and development of rice in the study area; the Chilo suppressalis information includes Chilo suppressalis image information and Chilo suppressalis quantity information;
[0114] The second acquisition module is used to obtain meteorological and environmental data during the growth and development of rice, and to perform standardization on the meteorological and environmental data;
[0115] A construction module is used to construct a data set according to the date of rice growth and development period, the number information of Chilo suppressalis and meteorological environment data, and divide the data set into a training set and a test set;
[0116] A determination module is used to determine the input parameters and parameter thresholds of the random forest model based on the random forest model by using grid search and cross validation, and to determine the optimal numerical combination of the model input parameters according to the evaluation index;
[0117] A prediction module is used to use the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set respectively, and output the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set;
[0118] The evaluation module is used to evaluate the training set and the test set using evaluation indicators to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value;
[0119] The analysis module is used to analyze the cumulative number trend of the Chilo suppressalis using the test set to predict the occurrence of the Chilo suppressalis;
[0120] The sorting module is used to sort the meteorological and environmental factors that affect the cumulative number of Chilo suppressalis according to the contribution of meteorological and environmental factors to the decision tree in the random forest model, and to quantify the importance of meteorological and environmental factors.
[0121] Specifically, the system provided in this embodiment is a system corresponding to the method provided in Embodiment 1. Therefore, the parts in this embodiment that are the same or similar to those in Embodiment 1 can be referenced to each other and will not be repeated in this application.
Claims
1. A method for predicting the occurrence of rice stem borer. It is characterized in that include: Step 1, obtaining information on the number of Chilo suppressalis and the date of rice growth and development in the study area; Step 2, obtaining meteorological and environmental data during the growth and development of rice, and performing standardization on the meteorological and environmental data; Step 3, constructing a data set according to the rice growth and development period date, the number information of the Chilo suppressalis and the meteorological environment data, and dividing the data set into a training set and a test set; Step 4: Based on the random forest model, grid search and cross validation are used to determine the input parameters and parameter thresholds of the random forest model, and the optimal numerical combination of the model input parameters is determined based on the evaluation indicators; Step 5, using the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set, and outputting the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set; Step 6: Use the evaluation indicators to evaluate the training set and the test set respectively to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value; Step 7: Analyze the cumulative number trend of Chilo suppressalis using the test set to predict the occurrence of Chilo suppressalis; Step 8: According to the contribution of meteorological environmental factors to the decision tree in the random forest model, rank the meteorological environmental factors that affect the cumulative number of Chilo suppressalis and quantify the importance of meteorological environmental factors.
2. The method for predicting the occurrence of rice stem borer according to claim 1, It is characterized in that In step 2, the meteorological environment data is composed of a number of meteorological environment factors, including air temperature, air humidity, dew point temperature, soil temperature, soil moisture, wind speed, wind direction, atmospheric pressure, rainfall, light intensity, average temperature and relative humidity.
3. The method for predicting the occurrence of rice stem borer according to claim 2, It is characterized in that In step 2, the meteorological environment data is standardized, including: eliminating the dimensional differences between different meteorological environment factors through range standardization, so that each meteorological environment factor is at the same order of magnitude; the calculation formula for the standardized processing is: Among them, X' is the standardized value, X is the original data value, and X max is the maximum value in the data, X min is the minimum value in the data.
4. The method for predicting the occurrence of rice stem borer according to claim 3, It is characterized in that In step 3, the date of rice growth and development period is used as the time series, the number of rice stem borers is used as the dependent variable, and the meteorological environment data is used as the independent variable; the ratio of the training set to the test set is 7:
3.
5. The method for predicting the occurrence of rice stem borer according to claim 4, It is characterized in that Step 4 includes: Step 4.1, determine the input parameters and parameter value range of the random forest model; the input parameters include the number of trees, the maximum depth of the tree, the number of samples for the minimum node segmentation, and the minimum number of samples for the leaves; Step 4.2: Use grid search to traverse each parameter combination in the parameter grid of step 4.1; Step 4.3: For each parameter combination, perform 3-fold cross validation, which is to divide the data set into 3 non-overlapping subsets. For each subset, use the current subset as the validation set and the other two subsets as the training set. Repeat this process 3 times, each time selecting a different subset as the validation set. Step 4.4: The average value of the root mean square error of the three validations is used as the performance evaluation index of the parameter combination. The smaller the value, the better the prediction performance of the model. The calculation formula of the root mean square error is: Where n is the number of samples, y i is the actual observation value of the ith is the i-th prediction value, and RMSE is the average of the squares of the prediction errors; Step 4.5: Based on the evaluation results of cross-validation, select the combination with the smallest RMSE on the validation set as the optimal numerical combination of the input parameters of the random forest model.
6. The method for predicting the occurrence of rice stem borer according to claim 5, It is characterized in that In step 6, the evaluation indicators include root mean square error, mean absolute error, determination coefficient and Pearson correlation coefficient, and the calculation formula is: Where n is the number of samples, y i is the actual observation value of the ith is the i-th predicted value, and MAE measures the mean absolute error between the predicted value and the actual value; Where n is the number of samples, y i is the actual observation value of the ith is the ith predicted value, is the mean of the actual observations, R 2 is the coefficient of determination, which is between 0 and 1. The closer it is to 1, the better the model fit is; Among them, x i is the predicted value, y i is the actual observed value, and are the means of the predicted values and the actual observed values, respectively. r is the Pearson correlation coefficient. The value of r is between -1 and 1, where 1 indicates a perfect positive correlation, -1 indicates a perfect negative correlation, and 0 indicates no correlation.
7. The method for predicting the occurrence of Chilo suppressalis of rice according to claim 5, It is characterized in that In step 8, the contribution to the meteorological environment factor is calculated as follows: Where FI(j) is the importance of feature j, T is the number of decision trees, and N t are all nodes in tree t, v(n) is the feature used to split node n, p(n) is the proportion of samples passing through node n, and Δi(n,t) is the purity change at node i n.
8. A prediction system for the occurrence of rice stem borer. It is characterized in that The method for predicting the occurrence of rice stem borer according to any one of claims 1 to 7 comprises: The first acquisition module is used to acquire information about the Chilo suppressalis and rice during the growth and development of rice in the study area; the Chilo suppressalis information includes Chilo suppressalis image information and Chilo suppressalis quantity information; The second acquisition module is used to obtain meteorological and environmental data during the growth and development of rice, and to perform standardization on the meteorological and environmental data; A construction module is used to construct a data set according to the date of rice growth and development period, the number information of Chilo suppressalis and meteorological environment data, and divide the data set into a training set and a test set; A determination module is used to determine the input parameters and parameter thresholds of the random forest model based on the random forest model by using grid search and cross validation, and to determine the optimal numerical combination of the model input parameters according to the evaluation index; A prediction module is used to use the best input parameter combination of the random forest model to predict the cumulative number of Chilo suppressalis for the training set and the test set respectively, and output the predicted values of the cumulative number of Chilo suppressalis for the training set and the test set; The evaluation module is used to evaluate the training set and the test set using evaluation indicators to obtain the goodness of fit of the model and the correlation between the predicted value and the actual value; The analysis module is used to analyze the cumulative number trend of the Chilo suppressalis using the test set to predict the occurrence of the Chilo suppressalis; The sorting module is used to sort the meteorological and environmental factors that affect the cumulative number of Chilo suppressalis according to the contribution of meteorological and environmental factors to the decision tree in the random forest model, and to quantify the importance of meteorological and environmental factors.
9. A computer-readable storage medium, It is characterized in that The computer-readable storage medium includes a stored executable program, wherein when the executable program is executed, the device where the computer-readable storage medium is located is controlled to execute the method for predicting the occurrence of rice stem borer according to any one of claims 1 to 7.
Citation Information
Patent Citations
A model and a method for predicting the occurrence of heat stroke based on machine learning
CN109359770A
Short-term load demand prediction method based on random forest regression and multi-step optimization
CN110135630A
Marine main engine spare part prediction method based on improved random forest
CN114386697A
Application of multi-mode integrated forecasting in ground temperature forecasting based on random forest
CN115032720A
Decision tree model feature importance calculation method and device and storage medium
CN115510981A
Cited By
Crop pest space-time prediction method and device based on meteorological soil factors
CN119670943A
