A method, system, equipment, and storage medium for optimizing greenhouse crop habitats.
By using deep learning and machine learning models to predict and diagnose data inside and outside the greenhouse, predictive control schemes are generated, which solves the problems of lagging environmental control and low resource utilization in solar greenhouses, and realizes precise control of crop habitat and efficient resource utilization.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NORTHWEST A & F UNIV
- Filing Date
- 2025-10-27
- Publication Date
- 2026-05-26
AI Technical Summary
Existing greenhouse environmental control technologies rely on experience and real-time monitoring, which cannot accurately meet the needs of crop growth. They suffer from problems such as lag and low resource utilization, and cannot predictively control the coupling characteristics of multiple environmental factors.
By continuously acquiring environmental data inside and outside the greenhouse, soil moisture and equipment status data, and using deep learning and machine learning models for data diagnosis and prediction, predictive control plans are generated to optimize irrigation and environmental control, thereby achieving multi-factor coordinated control.
It enables precise and real-time control of crop habitats in greenhouses, reduces reliance on manual labor, improves crop yield and quality, reduces the risk of drastic habitat fluctuations, and enhances resource utilization efficiency.
Smart Images

Figure CN121300557B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of smart agriculture technology, specifically relating to a method, system, equipment, and storage medium for optimizing greenhouse crop habitats. Background Technology
[0002] A solar greenhouse is a simple agricultural facility consisting of two gable walls, a rear wall, a supporting frame, and covering materials. It efficiently intercepts solar radiation and blocks heat exchange between the inside and outside of the greenhouse, maintaining the indoor temperature and providing a relatively warm growing environment for crops. As a unique and widely used type of greenhouse in northern my country, solar greenhouses ensure the supply of major off-season fresh vegetables and fruits in the region, enriching the material lives of the general public and serving as an important source of employment and income for local farmers.
[0003] The healthy growth, yield formation, and quality improvement of crops in solar greenhouses depend on a favorable crop habitat. This requires considering the needs of the crop's photosynthetic physiological habitat, and taking into account the synergistic effects of multiple factors that constrain crop photosynthetic physiology, such as greenhouse temperature, light, air, and soil moisture, both at specific times and within specific time periods. This necessitates multi-factor regulation of the greenhouse environment and soil moisture in the crop root zone. However, in current local agricultural production, the regulation of the internal environment of solar greenhouses and soil moisture in the crop root zone relies on manual labor and experience, including rolling up and ventilating, closing and closing the covers, and irrigating. This experience-dependent and labor-intensive method cannot accurately meet the crop's growth needs. First, experiential differences and the lag caused by the unpredictability of future conditions reduce the timeliness and effectiveness of regulation. Second, the highly coupled nature of the multi-factor and multi-variable greenhouse system increases the difficulty of coordinated regulation of multiple greenhouse environmental factors. Furthermore, the disordered and inefficient irrigation reduces resource utilization. Finally, the drastic fluctuations in the greenhouse environment and crop habitat within a single day under low-frequency manual regulation exacerbate crop stress, reduce effective photosynthetic growth, and increase disease risk.
[0004] With the development of sensor and Internet of Things technologies, greenhouse regulation is rapidly developing towards digitalization, informatization, and intelligence. Existing methods include a technical solution (CN202410185270.8) that aims at energy consumption optimization and artificially sets the range of environmental factor regulation. However, this solution does not consider the photosynthetic physiological requirements of different crops at different growth stages, nor the impact of the strong coupling of multiple environmental factors on crop habitats, and it cannot perform advance predictive regulation. A technical solution of intelligent parameter regulation method and system for greenhouses with multiple environmental factors coupled (CN117724341A) considers the relationship between the coupling of multiple environmental factors and crop physiological characteristics, but it also fails to achieve advance predictive regulation. A technical solution of greenhouse environment multi-factor coordinated control method based on crop physiology and energy consumption optimization (CN106842923A) considers the coordinated control of crop physiology and energy consumption optimization, but it also has the possibility of delayed regulation. A technical solution of greenhouse environment regulation method and system with environmental factor prediction function (CN112527037A) proposes predictable advance regulation of greenhouse temperature and light, but it does not fully meet the needs of crop habitats by considering the coupling of multiple environmental factors.
[0005] Overall, existing technological solutions have greatly improved the ability to regulate greenhouses, but most of them focus on optimizing single environmental parameters (such as temperature and humidity), soil moisture, or target energy consumption. They rely on a passive regulation logic of real-time monitoring and threshold triggering, resulting in significant regulation lag and an inability to cope with dynamic environmental changes. Summary of the Invention
[0006] This invention provides a method, system, equipment, and storage medium for optimizing the habitat of greenhouse crops. It addresses the limitations of existing extensive greenhouse environmental control and irrigation methods, which are based on experience, randomness, and unpredictability. By proactively and dynamically optimizing and coordinating the control of the aboveground growth environment and soil moisture supply in the root zone, it reduces the labor demand in greenhouse production, thereby enhancing the effective photosynthetic growth and development of crops, increasing yield and quality, and further improving the production efficiency of greenhouses.
[0007] To achieve the above objectives, the present invention provides the following technical solution:
[0008] A method for optimizing greenhouse crop habitats includes the following steps:
[0009] Continuously acquire multi-element data on the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data;
[0010] Based on multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, pre-set irrigation data, and pre-set environmental control data, predict multi-factor data of the greenhouse environment in the future period; based on current soil moisture data of the crop root zone and pre-set irrigation data of the greenhouse environment in the future period, predict the soil moisture content of different soil layers in the crop root zone inside the greenhouse in the future period.
[0011] Based on multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the root zone of crops in the greenhouse, the photosynthetic physiological habitat of crops in the greenhouse will be predicted in the future.
[0012] Using the predicted photosynthetic physiological habitat of crops inside the greenhouse as the optimization target, the current irrigation and environmental multi-factor regulation are optimized and decision-making is made to generate control schemes and control decision parameters based on the control schemes.
[0013] Based on the generated control decision parameters, control signals are generated. Based on the equipment status data, the operation of greenhouse terminal equipment is controlled according to the control signals, and the working status of irrigation and environmental control equipment is adjusted.
[0014] Preferably, the multi-factor environmental data inside the greenhouse includes air temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, and air pressure;
[0015] The meteorological data outside the greenhouse includes air temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, light intensity, wind speed, visibility, and air pressure;
[0016] The current soil moisture data for the crop root zone includes soil moisture content at different soil depths within the crop root zone;
[0017] The equipment status data includes the opening degree of the ventilation vents, the coverage status of the insulation cotton, the status of the solenoid valve of the water filling equipment, and the flow meter reading data.
[0018] The multi-element environmental data inside the greenhouse, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data constitute multi-dimensional sequence data.
[0019] The preset irrigation data is the preset irrigation amount per unit area within a future control period, and the preset environmental control data is the preset data for the greenhouse quilt coverage rate and the opening size of the ventilation opening every 10 minutes within a future control period.
[0020] Preferably, before predicting the multi-factor data of the greenhouse internal environment and the soil moisture content of different soil layers in the crop root zone inside the greenhouse for future periods, the method further includes anomaly detection and diagnosis of the collected multi-dimensional sequence data, specifically including the following steps:
[0021] The collected multi-dimensional sequence data are aligned to form feature vectors;
[0022] The eigenvectors are decomposed using ensemble empirical mode decomposition to obtain modal data and trend terms, separating high-frequency noise and low-frequency trend terms in the trend terms; the trend terms refer to the regular changes in multiple environmental factors inside and outside the greenhouse and the current soil moisture data in the crop root zone over time.
[0023] High-frequency noise is processed using a dual-channel detection network; the high-frequency noise is based on deep learning anomaly detection constructed using a one-dimensional convolutional neural network and an autoencoder; the one-dimensional convolutional neural network is used to extract local temporal features from high-frequency noise and low-frequency trend terms, and burst noise is identified through local temporal features; the autoencoder is used to reconstruct feature vectors, and long-term anomalies are located through reconstruction errors.
[0024] By applying a fully connected neural network, the identified burst noise is classified through a fully connected layer to obtain diagnostic results for abnormal and normal data, and the abnormal data is labeled.
[0025] Preferably, the method also includes repairing abnormal data, specifically including the following steps:
[0026] For short-term missing data in labeled outliers and missing data, LSTM-Impute is used to predict and impute based on the temporal relationship between the preceding and following points; where short-term missing data refers to fewer than 3 consecutive points.
[0027] For long-term missing data in labeled anomalies and missing data, GAN is used to generate candidate data. By improving the generative adversarial network, physical constraints are introduced when generating data; where long-term missing refers to three or more consecutive points.
[0028] For sudden noise, the moving average of adjacent normal data is used as a substitute, and for sensor drift, the data baseline is recalibrated based on the trend term of EEMD decomposition.
[0029] Preferably, the prediction of multi-factor data of the greenhouse internal environment in the future period based on multi-factor data of the greenhouse internal environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, preset irrigation data and preset environmental control data specifically includes the following steps;
[0030] The greenhouse environment multi-factor data, greenhouse meteorological data, current soil moisture data in the crop root zone, irrigation preset data, and environmental control preset data are used as input data and input into the greenhouse environment multi-factor prediction model; the greenhouse environment multi-factor prediction model is constructed and trained using Bi-LSTM and Informer.
[0031] Specifically, the Bi-LSTM layer is used to capture local dependencies in the input data to generate a hidden state sequence containing temporal features; the probabilistic sparse self-attention mechanism in Informer is adopted to filter key time points related to the prediction results from the hidden state sequence through sparsification calculation, calculate the attention weight of key time points, and form weighted key temporal features.
[0032] A time autoencoder is used to reduce the dimensionality of the trend term and output the dimensionality-reduced periodic features; the weighted key time-series features and the dimensionality-reduced periodic features are then fused to form a comprehensive feature vector.
[0033] The fused integrated feature vector is input into the fully connected layer, and after linear transformation and nonlinear activation, multivariate prediction results are output. The multivariate prediction results include the greenhouse internal air temperature, greenhouse internal relative humidity, greenhouse internal photosynthetically active radiation intensity, greenhouse internal carbon dioxide concentration, and greenhouse internal air pressure.
[0034] Preferably, the prediction model for soil moisture content in different soil layers of the crop root zone inside the greenhouse during the future period is as follows:
[0035] ;
[0036] In the formula, This represents the soil moisture content of different soil layers in the root zone of crops inside the greenhouse during a future period. This refers to the current soil moisture data in the crop root zone at this stage; t Let z be the time, and z be the vertical spatial coordinate, which includes the current distribution of soil moisture in the crop root zone along the Z direction. It represents the water diffusivity; Hydraulic conductivity; For crop water absorption; δ (z) is the Dirac function, indicating that irrigation only affects the surface; q irr (t) represents the time-varying irrigation flux.
[0037] Preferably, the photosynthetic physiological habitat conditions of crops inside the greenhouse during the future period include crop net photosynthetic rate, crop transpiration rate, crop instantaneous water use efficiency, and crop habitat stress.
[0038] The prediction model for the net photosynthetic rate of the crop is as follows:
[0039] ;
[0040] in, For the maximum carboxylation rate, This refers to the photosynthetic electron transport rate. For the utilization rate of triose phosphate, C c This refers to the intercellular CO2 concentration. RH To predict the relative humidity inside the greenhouse, T To predict the internal temperature of the greenhouse, The predicted carbon dioxide concentration inside the greenhouse;
[0041] The prediction model for crop transpiration rate is as follows:
[0042] ;
[0043] Among them, VPD For saturated water vapor pressure difference, The stomatal conductance of crops is affected by carbon dioxide concentration and photosynthetically active radiation intensity. P Atmospheric pressure The limiting factor for soil moisture in the root zone;
[0044] The prediction model for crop instantaneous water use efficiency is as follows:
[0045] ;
[0046] in, P n The net photosynthetic rate of crops. E For crop transpiration rate;
[0047] The predictive model for integrated habitat stress in crops is as follows:
[0048] ;
[0049] in, The total stress of environmental factors, n This refers to the number of environmental elements in the habitat, which include the internal temperature of the greenhouse, the relative humidity inside the greenhouse, the carbon dioxide concentration inside the greenhouse, and the photosynthetically active radiation intensity. PAR Root zone soil moisture limiting factors The stress caused by a single environmental factor.
[0050] This invention also proposes a greenhouse crop habitat optimization system, comprising:
[0051] The data acquisition module is used to continuously acquire multi-element environmental data inside the greenhouse, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data;
[0052] The parameter prediction module is used to predict the multi-factor data of the greenhouse environment in the future period based on multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, irrigation preset data, and environmental control preset data; and to predict the soil moisture content of different soil layers in the crop root zone in the future period based on current soil moisture data of the crop root zone, irrigation preset data, and multi-factor data of the greenhouse environment in the future period.
[0053] The crop habitat prediction module is used to predict the photosynthetic physiological habitat status of crops in the greenhouse in the future period based on multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the root zone of crops in the greenhouse.
[0054] The regulation and decision-making module is used to optimize the current irrigation and environmental multi-factor regulation based on the predicted photosynthetic physiological habitat status of crops inside the greenhouse in the future period, generate control schemes, and generate control decision parameters based on the control schemes.
[0055] The control execution module is used to generate control signals based on the generated control decision parameters, and control the operation of greenhouse terminal equipment and adjust the working status of irrigation and environmental control equipment based on equipment status data and control signals.
[0056] The present invention also provides a greenhouse crop habitat optimization system, comprising:
[0057] The data acquisition module is used to continuously acquire multi-element environmental data inside the greenhouse, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data;
[0058] The parameter prediction module is used to predict the multi-factor data of the greenhouse environment in the future period based on multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, irrigation preset data, and environmental control preset data; and to predict the soil moisture content of different soil layers in the crop root zone in the future period based on current soil moisture data of the crop root zone, irrigation preset data, and multi-factor data of the greenhouse environment in the future period.
[0059] The crop habitat prediction module is used to predict the photosynthetic physiological habitat status of crops inside the greenhouse in the future period based on multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the root zone of crops inside the greenhouse in the future period.
[0060] The regulation and decision-making module is used to optimize the current irrigation and environmental multi-factor regulation based on the predicted photosynthetic physiological habitat status of crops inside the greenhouse in the future period, generate control schemes, and generate control decision parameters based on the control schemes.
[0061] The control execution module is used to generate control signals based on the generated control decision parameters, and control the operation of greenhouse terminal equipment and adjust the working status of irrigation and environmental control equipment based on equipment status data and control signals.
[0062] The present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement any of the steps in the greenhouse crop habitat optimization method.
[0063] The present invention also provides a computer-readable storage medium storing a computer program that, when loaded by a processor, can execute any of the steps in the greenhouse crop habitat optimization method.
[0064] The greenhouse crop habitat optimization method provided by this invention has the following beneficial effects:
[0065] This invention achieves multi-source coupled regulation from the perspective of the "soil-crop-environment" continuum. By continuously acquiring data on the greenhouse's internal and external environment, soil moisture, and equipment status, it replaces manual experience-based judgment, resulting in a more accurate data foundation. Based on multi-source data, it predicts future indoor environmental conditions and soil moisture content in different layers, overcoming the lag in existing control technologies and achieving predictive regulation. Simultaneously, by combining predicted environmental and soil data, it anticipates the crop's photosynthetic physiological habitat, optimizing irrigation and environmental regulation based on habitat conditions, achieving multi-factor synergy. Finally, based on the generated control decision parameters, it generates regulatory signals to control the operation of greenhouse terminal equipment, completing closed-loop execution. This reduces reliance on manual labor, improves the accuracy and real-time nature of regulation, solves the problem of insufficient multi-factor synergy, and avoids drastic habitat fluctuations through predictive regulation, enhancing effective photosynthetic growth of crops and ultimately improving crop yield, quality, and resource utilization efficiency. Attached Figure Description
[0066] To more clearly illustrate the embodiments and design schemes of the present invention, the accompanying drawings required for this embodiment will be briefly described below. The drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0067] Figure 1 Here is a flowchart of a greenhouse crop habitat optimization method provided by the present invention;
[0068] Figure 2 This is a schematic diagram of a greenhouse crop habitat optimization method provided in an embodiment of the present invention;
[0069] Figure 3 This is a flowchart of the equipment control and optimization decision-making process based on the moth-to-a-flame algorithm provided in an embodiment of the present invention;
[0070] Figure 4 This is a schematic diagram of a greenhouse crop habitat optimization system provided by the present invention;
[0071] Figure 5 This is a schematic diagram of the hardware architecture provided in an embodiment of the present invention;
[0072] Figure 6 A flowchart for predicting multi-factor data of the greenhouse internal environment in a future time period, provided by the present invention;
[0073] Figure 7 A comparison chart showing the effect of predicted and measured values of photosynthetically active radiation intensity;
[0074] Figure 8 A comparison chart showing the effect of predicted and measured values of the temperature inside the greenhouse;
[0075] Figure 9 A comparison chart showing the effect of predicted and measured values of relative humidity inside the greenhouse;
[0076] Figure 10 A comparison chart showing the predicted and measured values of carbon dioxide concentration inside the greenhouse;
[0077] Figure 11 A comparison chart showing the effect of predicted and measured values of air pressure inside the greenhouse;
[0078] Figure 12 A comparison chart showing the effect of predicted and measured values of soil moisture content in different soil layers inside the greenhouse;
[0079] Figure 13 A comparison chart showing the effect of predicted and measured values of crop net photosynthetic rate;
[0080] Figure 14 A comparison chart showing the effects of crop net photosynthetic rate and habitat stress before and after optimization.
[0081] Explanation of reference numerals in the attached figures:
[0082] Data acquisition module 10; data diagnosis and correction module 20; data storage module 30; parameter prediction module 40; crop habitat prediction module 50; regulation decision module 60; control execution module 70. Detailed Implementation
[0083] To enable those skilled in the art to better understand and implement the technical solutions of the present invention, the present invention will be described in detail below with reference to the accompanying drawings and specific embodiments. The following embodiments are only used to more clearly illustrate the technical solutions of the present invention and should not be construed as limiting the scope of protection of the present invention.
[0084] The following detailed description, in conjunction with the accompanying drawings, illustrates a greenhouse crop habitat optimization method provided by the present invention through specific implementation examples and application scenarios of multi-factor coupling optimization and control decision-making of irrigation in the greenhouse tomato production environment.
[0085] like Figure 1 and Figure 2 As shown, this invention proposes a method for optimizing greenhouse crop habitats, specifically a decision-making method for the dynamic coupling of multiple environmental factors and irrigation in a solar greenhouse based on the early prediction of crop habitats, comprising the following steps:
[0086] S1. Continuously and frequently collect key data inside and outside the greenhouse and upload it to the cloud platform in real time to provide a basic data source for subsequent analysis. The key data inside and outside the greenhouse includes three core types of data: multi-element data of the greenhouse environment, soil moisture data, and equipment status data. These three core types of data constitute multi-dimensional sequence data.
[0087] In this embodiment, the multi-element data of the greenhouse environment include the internal temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration and air pressure of the greenhouse, and the external temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, light intensity, wind speed, visibility and air pressure of the greenhouse.
[0088] Soil moisture data are collected from different soil depths by sensors arranged vertically every 10 cm in the crop root zone.
[0089] The equipment status data specifically includes the ventilation opening degree of ventilation equipment (0%-100%), the insulation cotton coverage status of insulation equipment (0 = not covered, 1 = covered), and the status of water filling solenoid valve of water filling equipment (0 = closed, 1 = open), etc., which are the operating information of the control equipment.
[0090] S2. Diagnose, correct, and verify the quality of the collected multi-dimensional sequence data, and store the qualified data. To address potential anomalies in the collected data, such as missing data, drift, or noise, this embodiment employs a three-level processing approach to ensure data reliability.
[0091] S21. This embodiment uses a hybrid model of Modal Decomposition (MD) and Deep Learning (DL) to detect and diagnose anomalies in the collected multi-dimensional sequence data, and to determine whether the currently received data has been missing or distorted. If missing or distorted data has been generated, the data is marked and corrected.
[0092] The specific process of anomaly detection and diagnosis using a hybrid model is as follows:
[0093] The high-frequency collected multi-dimensional sequence data is aligned to form a feature vector.
[0094] Ensemble Empirical Mode Decomposition (EEMD) is employed to add Gaussian white noise (with a standard deviation of 10% of the original data) to the original data. This decomposition is performed 100 times to eliminate mode aliasing. Fixed-length original multi-dimensional series data (such as temperature, humidity, and carbon dioxide concentration) are decomposed to obtain several intrinsic mode functions (IMFs) and residual trend terms. The IMFs capture high-frequency noise and short-term fluctuations, while the trend terms represent long-term drift. Finally, EEMD is used to separate high-frequency noise and low-frequency trends in the multi-dimensional series data.
[0095] A dual-channel detection network is constructed based on a one-dimensional convolutional neural network (1D-CNN) and an autoencoder (AE). The 1D-CNN uses a 30-minute input window (6 sampling points), a kernel size of 3, and a stride of 1. It extracts local temporal features through three convolutional layers and max pooling to identify sudden noise (such as instantaneous sensor malfunctions), outputting anomaly probabilities. The final output vector is then classified (abnormal data, normal data) to obtain the data diagnostic results. The autoencoder (AE) reconstructs the input data to locate long-term drift. The input is 1 hour of data (12 sampling points). The encoder contains two LSTM layers (64 units), and the decoder has a symmetrical structure. Anomalies are identified when the reconstruction error (MSE) exceeds a dynamic threshold (95th percentile of historical normal data). The detection results of sudden noise and long-term drift are combined using weighted voting (weights of 0.6 and 0.4, respectively) to determine the final anomaly. A series of fixed-length original multi-dimensional sequence datasets (manually labeled) are constructed using sliding sampling of historical normal data for supervised training to optimize the threshold determination rules. Finally, a fully connected layer classifies and labels abnormal and missing data.
[0096] S22. Repair abnormal and missing data based on the dynamic trend of data changes to obtain the repaired data.
[0097] Data repair strategies are divided into missing value imputation and outlier correction:
[0098] For short-term missing values (<3 consecutive points) in the missing value imputation, LSTM-Impute is used, which predicts and fills in missing values based on the temporal relationship between the preceding and following points. LSTM-Impute is a time series missing value imputation method based on bidirectional LSTM (Bi-LSTM) (32 units). Since there are certain dynamic dependencies between multiple factors in the solar greenhouse environment and the randomness of time differences in anomalies from different sensors, this method is particularly suitable for multivariate time series (such as temperature, humidity, carbon dioxide, etc. in the greenhouse environment). It can capture the dynamic dependencies between variables. By inputting contextual data from 5 points before and after the input, it predicts the value at the missing location by utilizing the past and future contextual information in the sequence.
[0099] For long-term missing data (≥3 consecutive points), WaSerstein GAN (WGAN) is used to generate reasonable data by combining physical constraints (such as energy conservation and correlation of environmental parameters). By improving the Generative Adversarial Network (GAN), physical constraints (such as negative correlation between temperature and humidity, energy conservation, etc.) are introduced when generating data to ensure that the generated data conforms to the laws of the actual environment. The generator is responsible for generating candidate data, and the discriminator, which is embedded in the physical constraint module, distinguishes between real and generated data through rule filtering and loss function penalty mechanism, further improving the ability to accurately supplement long-term missing data.
[0100] For outlier correction, burst noise is replaced with the median of a sliding window (window size 5 points). Sensor drift is recalibrated based on the trend term of EEMD decomposition. For example, if the trend term shows that the temperature continues to rise by 0.1℃ / hour, the original data is corrected proportionally.
[0101] S23. Verify the rationality of the repaired data.
[0102] This embodiment mainly ensures the rationality of the repaired data through statistical tests (such as box plot analysis and dynamic thresholding) and model back-validation (residual analysis). Specifically, it uses dynamic thresholding (based on the sliding window mean ± 3σ) and residual analysis (the residual between the predicted value and the repaired value must follow a normal distribution, KS test p>0.05) to ensure the physical rationality and statistical consistency of the repaired data, and then stores the verified data.
[0103] S3. Based on the data verified in S2, and the preset irrigation and environmental control data, predict the multi-factor data of the greenhouse internal environment and the trend of soil moisture changes in the future period. The multi-factor data of the greenhouse internal environment in the future period includes the greenhouse internal air temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, and air pressure. The trend of soil moisture changes in the greenhouse in the future period specifically refers to the trend of soil moisture content changes in different soil layers in the crop root zone. The preset irrigation data is the preset irrigation amount per unit area within a future control period (e.g., 1 hour), and the preset environmental control data is the preset data of greenhouse quilt coverage and ventilation opening size every 10 minutes within a future control period (e.g., 1 hour).
[0104] S31. Based on the data verified by S2, the preset data for irrigation and environmental control, and the preset data for environmental control, predict the multi-factor data of the greenhouse internal environment in the future period.
[0105] Before predicting multi-factor data of the greenhouse internal environment in the future, a prediction model capable of performing multi-factor time series data of the greenhouse internal environment is first constructed and trained, which includes the following steps:
[0106] (1) Pearson correlation analysis was used to select data combinations that were highly correlated with the various target prediction elements (greenhouse temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, and air pressure) and the multi-element data of the greenhouse internal environment in the predicted future period. Input data were collected in sequence using sliding sampling to construct a preliminary training dataset.
[0107] Then, mode decomposition (MD) is used to decompose the historical multi-dimensional sequence data of the target prediction elements (solar greenhouse temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, and air pressure) into multiple intrinsic mode functions (IMFs) and trend terms, and these are aligned and merged into the preliminary training dataset to construct the final training dataset.
[0108] (2) A multi-factor prediction model for greenhouse environment was constructed using a Bi-LSTM and Informer dual-channel multi-step prediction framework.
[0109] (3) The multi-factor prediction model for the greenhouse environment is trained using the final training dataset, as follows:
[0110] By using multi-factor spatiotemporal modeling, Bi-LSTM layers are used to extract local temporal dependencies in the final training dataset. The probabilistic sparse self-attention mechanism in Informer is used to calculate the attention weights at key time points to optimize computational efficiency. A temporal autoencoder is used to reduce the dimensionality of the trend and capture the global temporal dependencies of long-term periodic patterns such as cross-day / cross-week. A fully connected layer is used to output multivariate prediction results.
[0111] Within a fixed time period, the greenhouse environment multi-factor prediction model is periodically trained based on historical multi-dimensional sequence data, and the model is adaptively updated.
[0112] After the model training is completed, such as Figure 6 As shown, multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, preset irrigation data, and preset environmental control data are input into the trained greenhouse environment multi-factor prediction model. The Bi-LSTM layer is used to capture the local dependencies in the input data to generate a hidden state sequence containing temporal features. The probabilistic sparse self-attention mechanism in Informer is adopted to select key time points related to the prediction results from the hidden state sequence through sparsification calculation, and the attention weights of the key time points are calculated to form weighted key temporal features.
[0113] A time autoencoder is used to reduce the dimensionality of the trend term and output the dimensionality-reduced periodic features. The weighted key time-series features and the dimensionality-reduced periodic features are then fused to form a comprehensive feature vector.
[0114] The fused integrated feature vector is input into the fully connected layer, and after linear transformation and nonlinear activation, multivariate prediction results are output, which are multi-factor data of the greenhouse internal environment for the future period. The multivariate prediction results include greenhouse internal air temperature, greenhouse internal relative humidity, greenhouse internal photosynthetically active radiation intensity, greenhouse internal carbon dioxide concentration, and greenhouse internal air pressure.
[0115] Ultimately, the predicted results for the photosynthetically active radiation intensity inside the greenhouse are as follows: Figure 7 As shown, the prediction effect of the internal temperature of the greenhouse is as follows: Figure 8 As shown, the prediction effect of relative humidity inside the greenhouse is as follows: Figure 9 As shown, the prediction effect of carbon dioxide concentration inside the greenhouse is as follows: Figure 10 As shown, the predicted results of the air pressure effect inside the greenhouse are as follows: Figure 11 As shown.
[0116] S32. Using the multi-factor data of the greenhouse internal environment, the current soil moisture data of the crop root zone, and the preset irrigation data obtained in S31, predict the soil moisture content of different soil layers in the crop root zone of the greenhouse in the future period.
[0117] Specifically, this embodiment uses a mechanism-data driven hybrid model to predict crop root zone soil moisture. This mechanism-data driven hybrid model consists of a physical module and a data-driven module, including the following:
[0118] The physics module integrates irrigation and root water uptake to predict soil moisture dynamics. It simulates soil water transport based on the Richards equation. Inputs include soil texture parameters (such as porosity and hydraulic conductivity), crop apparent trait parameters (leaf area index and crop coefficient), and greenhouse climate data (temperature, humidity, photosynthetically active radiation, carbon dioxide concentration, and air pressure). The one-dimensional Richards equation is solved using the finite difference method.
[0119] ;
[0120] in, This represents the soil moisture content (cm) of different soil layers in the root zone of crops inside the greenhouse during a future period. 3 / cm 3 ), This refers to the current soil moisture data in the crop root zone; t Let z be time (s), and z be the vertical spatial coordinate (cm), which includes the current distribution of soil moisture in the crop root zone along the Z direction, usually downward is positive; Moisture diffusivity (cm) 2 / s), which is related to soil texture; Hydraulic conductivity (cm / s) varies with water content; This is the crop water absorption term (root density function × crop transpiration rate); δ (z) is the Dirac function, indicating that irrigation only affects the surface (z=0); q irr (t) represents the time-varying irrigation flux (cm / s), q irr (t) belongs to the preset data for irrigation.
[0121] The root water uptake model for crop water uptake is as follows:
[0122] ;
[0123] in, β ( z ) is the root distribution function, which describes the change of root density with depth (such as exponential distribution). T p Potential crop transpiration rate (m / s); θ max θ represents the soil moisture content corresponding to the upper limit of root water absorption, and the range of soil moisture content corresponding to crop root water absorption is θ. max ~θ 萎蔫 . This represents the soil volumetric water content of the soil layer at time t.
[0124] The formula for calculating hydraulic conductivity is:
[0125] ;
[0126] in, For effective saturation, θ r , θ s Residual and saturated moisture content, respectively. K s Saturated hydraulic conductivity (cm / s); m For shape parameters.
[0127] The root distribution function is:
[0128] ;
[0129] in, L r The characteristic depth of the root system is (m).
[0130] The potential crop transpiration rate is:
[0131] ;
[0132] in, K c For crop coefficients, ET 0 represents the reference crop evapotranspiration.
[0133] ;
[0134] in R n Net surface radiation (MJ / m²) 2 ·d); G Soil heat flux (MJ / m 2 ·d); T The average temperature (°C) is the average temperature inside the greenhouse predicted by S31. It represents the humidity constant (kPa / ℃), which is determined by the physical properties of air and corrects for the water vapor transport process; This represents the saturated vapor pressure (kPa), the maximum vapor pressure at the current temperature. This indicates the actual water vapor pressure (kPa), which represents the actual water vapor content in the air. This indicates the wind speed (m / s) at a height of 2 meters, which promotes the diffusion of water vapor.
[0135] To improve prediction accuracy, the method also compares the predicted soil moisture content with the actual soil moisture content detected by the soil moisture sensor, and optimizes the parameters of the soil moisture content physical module based on the comparison results.
[0136] The data-driven module is an online crop root zone soil moisture estimation algorithm based on an improved particle swarm optimization (PSO) algorithm. It uses data within a sliding time window (e.g., 6 hours) as the optimization objective, executes PSO iterative optimization of the parameters in the physics module, outputs the optimal parameters, and updates the physics module based on these optimal parameters. It includes the following:
[0137] 11) Obtain historical time series data on greenhouse internal environment, irrigation data, and soil moisture data for different soil layers within the most recent retrospective period.
[0138] 12) Define the dynamic parameter space: Define the physical module parameter vector to be estimated as X=[ K s , α , n , L r , θ max ] T ,in L r For root system characteristic depth, θ max This represents the soil moisture content corresponding to the upper limit of root water absorption.
[0139] 13) An adaptive inertia weighting strategy and multi-objective processing mechanism are adopted, and the specific process is as follows:
[0140] 14. Particle Initialization:
[0141] Parameter range constraints: X is defined based on prior knowledge. min X max (like K s ϵ [10 -6 , 10 -4 [m / s].
[0142] Velocity constraint: V max =0.1×(X max -X min ).
[0143] 15. Fitness Function Design:
[0144] ;
[0145] in θ model λ represents the simulated value of the Richards equation, and λ is the prior knowledge regularization weight. Represents the physical module parameter vector generated during the iteration process. This represents the physical module parameter vector generated during the previous iteration.
[0146] 16. Dynamic parameter adjustment:
[0147] Inertia weight:
[0148] ;
[0149] Learning factor c 1 , c 2 Adaptive adjustment based on particle dispersion (increases when dispersion is high) c 1 To enhance local search.
[0150] Constraint handling: For out-of-bounds examples, a boundary reflection strategy is adopted (bounce back to the boundary and reverse the velocity direction) to avoid premature convergence.
[0151] 17) Model update layer: This layer updates the optimal parameters. X * The data is input into the multi-step prediction sub-model for soil moisture in the crop root zone for model updates. The updated model receives multi-factor data on the greenhouse internal environment and preset irrigation data for future periods to predict the future state of soil moisture in the crop root zone. If parameter mutations exceed thresholds, sensor fault diagnosis or particle swarm re-initialization is triggered. The optimal parameters are obtained by using PSO to optimize the parameters in the physical module based on the most recently collected soil moisture data, greenhouse internal meteorological data, and irrigation data, resulting in the final optimal physical module parameter vector after iterative optimization.
[0152] Ultimately, the measured and predicted data on soil moisture content in different soil layers inside the greenhouse were compared with, for example... Figure 12 As shown.
[0153] S4. Based on the trends of changes in multiple greenhouse environmental factors and soil moisture in the future period, predict the photosynthetic physiological habitat status of crops inside the greenhouse in the future period. The photosynthetic physiological habitat status of crops inside the greenhouse in the future period in S4 includes the status of crop net photosynthetic rate, crop transpiration rate, comprehensive habitat stress, and crop instantaneous water use efficiency in the future period.
[0154] First, a mechanistic module is constructed based on the physical equations of photosynthetic biochemical reactions (Farquhar model) and stomatal conductance (Ball-Berry model) to generate baseline predictions. Machine learning (such as random forest and XGBoost) is then used to correct the residuals of the mechanistic model, capturing unmodeled nonlinear relationships, and coupling them to form a mechanistic-data-driven hybrid model. The crop net photosynthetic rate model is a mechanistic-data-driven hybrid model.
[0155] In the mechanism module, the Farquhar model is used to predict the net photosynthetic rate of crops. P n The Farquhar model is calculated based on biochemical constraints. P n It includes three stages:
[0156] RuBisCO carboxylase restriction phase:
[0157] ;
[0158] ;
[0159] in, T To predict the internal temperature of the greenhouse, K c is the half-saturation constant of RuBisCO with respect to CO2, reflecting the affinity of the enzyme for CO2; K o is the half-saturation constant of RuBisCO with respect to O2, reflecting the affinity of the enzyme for O2. This is the CO2 compensation point. Porous conductance. C c Intercellular CO2 concentration (ppm); C i The concentration of CO2 in the air is the carbon dioxide concentration inside the greenhouse predicted by S31. g ic Pore conductance affected by CO2 concentration; O i The concentration of oxygen in the intercellular spaces of the leaf (ppm); The maximum carboxylation rate (μmol·m -2 ·s -1 The value of ), increases first and then decreases with rising temperature, and the empirical formula is:
[0160] ;
[0161] in The baseline value at 25℃ (e.g., 32.93 μmol·m) -2 ·s -1 Shading conditions); E a The activation energy is approximately 65 kJ·mol⁻¹. -1 ); H d Enzyme inactivation enthalpy (approximately 200 kJ·mol⁻¹) -1 ); S It is an entropy change; RThe gas constant is 8.314 J / mol·K.
[0162] Г * The CO2 compensation point is calculated using the following formula:
[0163] ;
[0164] for of Specific factors, O The partial pressure of oxygen between leaf cells (kPa) is calculated using the following formula:
[0165] ;
[0166] P atm The pressure is the local atmospheric pressure (standard value 101.325 kPa), which is the air pressure inside the greenhouse predicted by S31.
[0167] g s The formula for calculating porosity is:
[0168] ;
[0169] in It is the largest pore conductance. ∆T It is an increase in leaf temperature, used to characterize water stress.
[0170] D represents a water vapor pressure deficit:
[0171] ;
[0172] in, RH The predicted relative humidity inside the greenhouse, i.e., the relative humidity inside the greenhouse predicted by S31; e s ( T () represents the saturated water vapor pressure, calculated using the following formula:
[0173] ;
[0174] K c and K o Temperature dependence: The Michaelis constant increases with increasing temperature, which can be expressed by the Arrhenius correction formula:
[0175] ;
[0176] ;
[0177] in, K c25 and K o25 The reference value is at 25℃. K c25 ≈40.4 μmol·mol -1 , K o25 ≈27.8kPa), ∆ H kc ∆ H ko This is the enthalpy change parameter for the combination of CO2 and O2.
[0178] RuBP regeneration limitation stage:
[0179] ;
[0180] in J Photosynthetic electron transport rate (μmol·m -2 ·s -1 ).
[0181] J ( T The calculation formula is:
[0182] ;
[0183] in, α Light energy conversion efficiency; I am The predicted photosynthetically active radiation intensity (PAR, μmol·m) -2 ·s -1 ), θ For curvature parameters, R d Dark respiration rate (μmol·m -2 ·s -1 ), J max ( T Let be the photosynthetic electron transport rate at temperature T, and the empirical formula is:
[0184] ;
[0185] in This represents the maximum electron transport rate at 25°C.
[0186] TPU (Triose Phosphate Utilization) Limitation Phase:
[0187] ;
[0188] The maximum TPU rate per unit leaf area, (μmol·m -2 ·s -1 ):
[0189] ;
[0190] The maximum TPU rate at 25℃ (μmol·m -2 ·s -1 ).
[0191] The net photosynthetic rate Pn of the crop takes the minimum value of the three limiting stages:
[0192] ;
[0193] in, Maximum carboxylation rate represents the maximum ability of RuBisCO enzyme to catalyze CO2 fixation per unit time, expressed in μmol·m⁻¹. -2 ·s -1 . Photosynthetic Electron Transport Rate (PST) represents the maximum capacity of the electron transport chain in the photoreaction, and its unit is μmol·m⁻². -2 ·s -1 . Triose phosphate utilization rate (TPU) represents the maximum capacity of photosynthesis to utilize triose phosphate (TPU), and its unit is μmol·m³. -2 ·s -1 . C c This refers to the intercellular CO2 concentration. RH To predict the relative humidity inside the greenhouse, T To predict the internal temperature of the greenhouse, This represents the predicted carbon dioxide concentration inside the greenhouse.
[0194] in:
[0195] ;
[0196] in The dark respiration rate at the reference temperature (μmol·m -2 ·s -1 Generally, this refers to the dark respiration rate at 25°C. Q 10The coefficient for predicting the internal temperature of the greenhouse represents the rate of increase in respiration rate for every 10°C increase in temperature, with a typical range of 1.5-2.5.
[0197] It is the humidity correction factor, which can be expressed as RH / RH opt , It is the CO2 concentration correction factor, which can be expressed as C. a / C a,ref , The limiting factor for soil moisture in the root zone:
[0198]
[0199] ;
[0200] RH opt and C a,ref These are the optimal humidity and the reference CO2 concentration, respectively. As it is limited by soil moisture, RLD i For the first i Crop root length density in soil (cm / cm) 3 ); RLD 0 This represents the maximum density of the surface root system. SWC optimal The optimal soil moisture content for the crop root zone; k This is the attenuation coefficient, which varies depending on the specific crop type and reflects the degree of concentration of the vertical distribution of the root system. k The larger the root system, the more concentrated it is on the surface. Let be the soil moisture content of the i-th layer.
[0201] Furthermore, to ensure the accuracy of the predicted photosynthetic physiological habitat conditions of crops inside the greenhouse in the future, the prediction results are also corrected using machine learning. Specifically:
[0202] The main steps in building a machine learning residual correction module are as follows:
[0203] (1) Calculate the residuals used for prediction by the machine learning model:
[0204] ;
[0205] Measured net photosynthetic rate of crops; : Mechanism model prediction value.
[0206] (2) Machine learning model training:
[0207] Input features: predicted greenhouse internal air temperature (T), predicted greenhouse internal relative humidity (RH), predicted greenhouse internal carbon dioxide concentration (CO2), and soil moisture content (T). The predicted photosynthetically active radiation intensity (PAR), crop parameters (growth period (seedling stage, flowering stage, fruiting stage, fruit enlargement stage, fruit ripening stage), leaf area index (LAI), root depth, variety type (e.g., tomato, cucumber), and diurnal cycle) were used to capture lag effects (e.g., the delayed effects of soil water content, temperature, photosynthetically active radiation intensity, and carbon dioxide concentration on photosynthesis). After normalization and One-Hot encoding of the categorical data, a regression task was established.
[0208] Target variable: Residual e is the difference between the predicted value and the measured value.
[0209] Model selection: The CatBoost algorithm is used to build a residual prediction model, and the hyperparameters are optimized by Bayesian optimization and the importance of features is analyzed by using SHAP values.
[0210] Ultimately, the coupling mechanism model and the machine learning residual formation mechanism - a data-driven hybrid model:
[0211] ;
[0212] in e ML This represents the residual from machine learning predictions.
[0213] The crop transpiration rate model is a hybrid model driven by mechanism and data.
[0214] In the mechanistic model, crop transpiration rate (E, mmol H2O.m) -2 .s -1 or kg H2O.m -2 .h -1 The calculation is based on the following formula:
[0215] ;
[0216] in VPD For saturated water vapor pressure difference, The stomatal conductance of crops is affected by carbon dioxide concentration and photosynthetically active radiation intensity. P Atmospheric pressure.
[0217] ;
[0218] in e sThe saturated vapor pressure (kPa) can be calculated using the Tetens formula:
[0219] ;
[0220] Where T is the air temperature, in °C;
[0221] ;
[0222] in C a To predict the carbon dioxide concentration inside the greenhouse, C base The baseline concentrations are for different crops. f(PAR) The opening and closing of stomata are affected by the intensity of photosynthetically active radiation.
[0223] The main process for building a machine learning residual correction module is as follows:
[0224] (1) Calculate the residuals used for prediction by the machine learning model:
[0225] ;
[0226] : Measured crop transpiration rate; : Mechanism model prediction value.
[0227] (2) Machine learning model training:
[0228] Input features: predicted greenhouse internal air temperature (T), predicted greenhouse internal relative humidity (RH), predicted greenhouse internal carbon dioxide concentration (CO2), and soil moisture content (T). The predicted photosynthetically active radiation intensity (PAR), crop parameters (growth period (seedling stage, flowering stage, fruiting stage, fruit enlargement stage, fruit ripening stage), leaf area index (LAI), root depth, variety type (e.g., tomato, cucumber), diurnal cycle), and previous environmental parameters and historical soil moisture data were introduced to capture lag effects (e.g., the delayed effect of soil moisture). After normalization and One-Hot encoding of the categorical data, a regression task was established.
[0229] Target variable: residual e.
[0230] Model selection: The CatBoost algorithm is used to build a residual prediction model, and the hyperparameters are optimized by Bayesian optimization and the importance of features is analyzed by using SHAP values.
[0231] Ultimately, the coupling mechanism model and the machine learning residual formation mechanism - a data-driven hybrid model:
[0232] ;
[0233] in e ML This represents the residual from machine learning predictions.
[0234] The prediction model for crop instantaneous water use efficiency is as follows:
[0235] ;
[0236] in P n The above refers to the net photosynthetic rate of the crops, in μmol CO2·m⁻¹. -2 .s -1 or g CO2.m -2 .h -1 L; E The above refers to the amount of water transpirated per unit time, i.e., the crop transpiration rate, expressed in mmol H₂O·m⁻¹. -2 .s -1 or kg H2O.m -2 .h -1 .
[0237] The predictive model for integrated habitat stress in crops is as follows:
[0238] ;
[0239] in, The total environmental stress includes both aboveground environmental stress and soil moisture stress. n This refers to the number of environmental elements in the habitat, including the predicted greenhouse internal temperature (T), predicted greenhouse internal relative humidity (RH), predicted greenhouse internal carbon dioxide concentration (CO2), predicted photosynthetically active radiation intensity (PAR), and root zone soil moisture limiting factor. f ( ), K s For stress from a single environmental factor, the calculation formula is as follows:
[0240] ;
[0241] in, X actual These are actual environmental parameters. X threshold The threshold for coercion triggering. X optimal This is the point where the crop's environmental factors are most suitable.
[0242] Comparison between measured and predicted data of crop net photosynthetic rate Figure 13 As shown in the figure, the comparison between crop net photosynthetic rate and habitat stress effects before and after optimization is as follows: Figure 14 As shown.
[0243] S5. Based on the photosynthetic physiological habitat status of crops inside the greenhouse in the future time period obtained from S4, generate corresponding control strategy parameters for the control equipment.
[0244] Specifically, this embodiment employs the "moth to a flame" algorithm for optimization decision-making. Using the predicted photosynthetic physiological habitat conditions of crops inside the greenhouse as the optimization target, the algorithm optimizes irrigation and environmental control decisions, generates a control scheme, generates control commands based on the control scheme, and sends the control commands to the control execution module 70. The optimization process is as follows: Figure 3 As shown, it includes the following steps:
[0245] S51. Initialization of Moth to Fire (MFO) Algorithm Parameters:
[0246] Core parameter definitions: Determine the number of moths m, the spiral constant b, and the flame attenuation coefficient γ;
[0247] Initialization: The initial number of flames equals the number of moths (N=m); the initial position is randomly generated within the equipment control range.
[0248] S52. Equipment Control Parameter Encoding and Conversion:
[0249] Definition of control parameters:
[0250] Table 1 Control Parameter Table
[0251]
[0252] Calculation of the upper limit of irrigation volume:
[0253] ;
[0254] in, Field water holding capacity (%) was determined by soil type. The current moisture content (%) of the i-th soil layer is obtained through a sensor. S Irrigated area (m²) 2 ); δ The irrigation efficiency coefficient is 0.8-1.0, taking into account water infiltration loss.
[0255] S53. Optimize the objective function design:
[0256] Target parameter combination:
[0257] Table 2 Target Parameter Table
[0258]
[0259] Fitness function:
[0260] ;
[0261] Normalization: Divide each parameter by its historical maximum value.
[0262] Penalty: If the soil moisture content exceeds the field capacity, the penalty will be increased.
[0263] S54. Algorithm Iteration and Optimization Process:
[0264] i. Population initialization:
[0265] Randomly generate m moth locations (each location contains...) x 1 , x 2 , x 3 (Parameter encoding).
[0266] The parameter prediction module predicts multiple environmental factors and soil moisture conditions.
[0267] Predict crop photosynthetic physiological status based on crop habitat prediction module.
[0268] The fitness value of a population is calculated based on the fitness function.
[0269] Sort the calculated fitness values and select the top N as the initial flames.
[0270] ii. Moth location update:
[0271] Each moth moves in a spiral around the flame, with its position updated using the following formula:
[0272] ;
[0273] in D i For moths i With flames j distance, D i =| F j - M i |, F j These are the position parameters of the flame, which are the local or global optimal solution candidates in the search space; t The spiral shape parameter is randomly selected from [-1, 1]. b The helical constant controls the search range.
[0274] iii. Flame decay and regeneration:
[0275] After each iteration, the number of flames decreases by the attenuation coefficient γ:
[0276] ;
[0277] Select the moths with the highest fitness from the current population. N new One as a new flame.
[0278] iv. Termination condition determination:
[0279] When the maximum number of iterations is reached (e.g., 50–100 times) or the fitness value converges (change <1% in 5 consecutive iterations), the optimal control parameters are output.
[0280] S6. Generation and execution of control commands: Generate control signals based on the generated control decision parameters, control the operation of greenhouse terminal equipment based on the control signals, and adjust the working status of irrigation and environmental control equipment.
[0281] Specifically, based on the generated control decision parameters, specific operation instructions are generated and formed into a specific format. The operation instructions are sent to the corresponding equipment controllers through the communication network. After parsing, the controllers drive the ventilation, heat preservation, and water filling equipment to perform actions, while simultaneously feeding back the real-time status of the equipment to complete closed-loop control.
[0282] In this embodiment, a hybrid database architecture is used to construct the data storage module, which includes a multi-dimensional sequence database (TSDB) (such as InfluxDB or TimescaleDB), a relational database (RDBMS) (such as PostgreSQL), and a distributed file storage system (such as Amazon or MinIO) to collect and store the data processed in each step, providing data support for each step of the process.
[0283] This invention proposes a method for optimizing greenhouse crop habitats by integrating high-frequency data acquisition, time-series environmental data, soil moisture data diagnostic and remediation verification, predictive modeling, crop photosynthetic physiological habitat response, and intelligent optimization decision-making. This method aims to optimize crop habitats and improve greenhouse production efficiency. Compared with existing technologies, this invention has the following advantages:
[0284] (1) Reasonable, efficient and highly applicable: This invention is based on the actual photosynthetic physiological habitat of crops in solar greenhouses. Based on the predictable dynamic optimization of crop habitat by multiple variables and strong coupling of internal and external environmental factors, it significantly improves the utilization of solar greenhouse resources and promotes effective photosynthetic growth of crops while reducing labor demand without significantly increasing operating costs. It avoids the reduction of crop photosynthetic efficiency at any time and the weakening of effective photosynthetic growth of crops during a certain period due to improper regulation.
[0285] (2) The system is robust and highly adaptable: In data detection, the present invention is based on multimodal fusion, and uses the combination of MD and DL to take into account the frequency domain characteristics and spatiotemporal correlation of data, thereby improving the detection accuracy of complex distortion scenarios; in missing value supplementation, the collaboration between GAN and physical constraints avoids the unreasonable physical meaning caused by pure data-driven repair (such as negative humidity value); in the multi-element multi-step prediction submodule of solar greenhouse environment, the model weights are updated regularly, making the model more adaptable.
[0286] (3) Strong interpretability and system coupling: Based on mechanism-data driven hybrid modeling, the model's mechanism is enhanced and its accuracy is improved. In terms of system coupling, based on real-time interaction of multiple models, the system has strong coupling of multiple factors and processes. Based on habitat prediction of soil-crop-environment continuum, it supports greenhouse environment-irrigation coupling optimization and regulation, which is more comprehensive and complete.
[0287] (4) Strong versatility and scalability: The method of this invention has strong applicability and can be used to predictably optimize any greenhouse crop for which a photosynthetic physiological growth model can be established, thus possessing a certain degree of versatility; the system has many spare interfaces, enabling the expansion of measures such as heating, supplemental lighting, and humidity control, thus possessing convenient scalability. It realizes the adaptive control of the dynamic coupling process of environment-irrigation-crop, bridging the gap between the aboveground and underground habitats of crops.
[0288] This invention solves the problems of traditional solar greenhouse environmental control and irrigation decision-making relying on human experience, strong lag, and insufficient multi-factor coordination. It significantly improves the accuracy, real-time performance, coordination, and intelligence of greenhouse environmental control and irrigation management, thereby increasing crop yield, quality, and resource utilization efficiency.
[0289] Based on the same inventive concept, this invention also provides a system for optimizing greenhouse crop habitats, such as... Figure 4 As shown, it includes:
[0290] The data acquisition module 10 is used to continuously acquire multi-element data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, and equipment status data.
[0291] The data diagnosis and correction module 20 is used to detect and diagnose anomalies in the collected multi-dimensional sequence data, determine whether the currently received data has produced missing or distorted data, and mark the data if missing or distorted data has occurred; repair the marked abnormal and missing data according to the dynamic change trend of the data to obtain the repaired data; and verify the rationality of the repaired data.
[0292] The data storage module 30 is used to store the data sent by the data acquisition module 10 and the data diagnosis and correction module 20.
[0293] The parameter prediction module 40 is used to predict the multi-factor data of the greenhouse environment in the future period based on the multi-factor data of the greenhouse environment, the meteorological data outside the greenhouse, the current soil moisture data of the crop root zone, the preset irrigation data and the preset environmental control data; and to predict the soil moisture content of different soil layers in the crop root zone in the future period based on the current soil moisture data of the crop root zone and the preset irrigation data and the multi-factor data of the greenhouse environment in the future period.
[0294] The crop habitat prediction module 50 is used to predict the photosynthetic physiological habitat status of crops inside the greenhouse in the future period based on multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the root zone of crops inside the greenhouse in the future period.
[0295] The regulation and decision module 60 is used to optimize the current irrigation and environmental multi-factor regulation based on the predicted photosynthetic physiological habitat status of crops inside the greenhouse in the future period, generate control schemes, and generate control decision parameters based on the control schemes.
[0296] The control execution module 70 is used to generate control signals based on the generated control decision parameters, and control the operation of greenhouse terminal equipment and adjust the working status of irrigation and environmental control equipment based on equipment status data and control signals.
[0297] Each module in the aforementioned greenhouse crop habitat optimization system can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the computer device's memory as software, so that the processor can call and execute the corresponding operations of each module.
[0298] The present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory. The processor executes the computer program to implement the steps in the embodiments of the greenhouse crop habitat optimization method. Specific implementation methods can be found in the method embodiments, and will not be repeated here.
[0299] Furthermore, the present invention also provides a non-transitory computer-readable storage medium containing instructions, on which a computer program is stored. For example, a memory containing instructions that can be executed by a processor of a computer device to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc. When the computer program is executed by the processor, it can implement the steps in the embodiments of the greenhouse crop habitat optimization method. Specific implementation methods can be found in the method embodiments, which will not be repeated here.
[0300] Furthermore, embodiments of the present invention also provide a hardware architecture for a greenhouse crop habitat optimization method, such as... Figure 5 As shown, it includes sensor networks, cloud platforms, and execution terminals.
[0301] The sensor network includes environmental sensors (temperature, humidity, carbon dioxide concentration, photosynthetically active radiation, wind speed, visibility, light intensity, and air pressure) and soil moisture sensors both inside and outside the greenhouse, used for real-time monitoring of multiple environmental factors and soil conditions. The environmental sensors deployed inside and outside the greenhouse include external environmental sensors (temperature, relative humidity, carbon dioxide concentration, photosynthetically active radiation, outdoor wind speed, visibility, light intensity, and air pressure) and internal environmental sensors (temperature, relative humidity, carbon dioxide concentration, photosynthetically active radiation, and air pressure). Soil moisture sensors are installed directly below the crop root zone, vertically arranged every 10 cm in the soil. All sensors inside and outside the greenhouse are electrically connected via wires to an integrated terminal with a UPS and a wireless transceiver module; the wireless transceiver module is a 4G signal module.
[0302] A cloud platform server includes a processor, memory, and a cloud platform that is stored on the memory and can run on the processor.
[0303] The data access interface connects the data acquisition module 10, data diagnosis and correction module 20, data storage module 30, parameter prediction module 40, crop habitat prediction module 50, regulation and decision-making module 60, and control execution module 70 to the cloud platform. The entire system is monitored in real-time and commands are issued via a central monitoring device, while the system's operating status can be viewed in real-time via a mobile device. The cloud platform communicates with components in the greenhouse, such as ventilation fans, greenhouse roll-up machines, solenoid valves, flow meters, and soil moisture sensors, via base stations to achieve data acquisition. The ventilation fans provide wind protection and dehumidification for the greenhouse, and the greenhouse roll-up machines control the greenhouse's insulation covering layer.
[0304] The data storage module 30 uses a hybrid database architecture, including multi-dimensional sequence databases (TSDBs) (such as InfluxDB or TimescaleDB), relational databases (RDBMS) (such as PostgreSQL), and distributed file storage (such as Amazon or MinIO).
[0305] The steps to implement the above method when the cloud platform is executed by the server.
[0306] In summary, this invention achieves comprehensive and real-time monitoring of key crop habitat parameters (such as environmental factors and soil characteristics) by continuously collecting high-frequency data on multiple greenhouse environmental elements and soil moisture using multiple sensors. After the collected data is uploaded to the cloud platform, it is processed using a multi-dimensional sequence data diagnosis and correction system, effectively diagnosing, repairing, and verifying the original data, thereby improving the accuracy and reliability of subsequent data analysis, model building, crop habitat assessment, and decision execution. A multi-element intelligent prediction model for the greenhouse environment, MD-Informer-BiLSTM, is constructed. This model extracts modal intrinsic features of multi-dimensional sequence data through multi-dimensional feature decomposition (MD), captures short-term correlations and local dependencies between sequences using the Informer architecture, and further enhances the model's learning ability and prediction accuracy by using a bidirectional long short-term memory network (BiLSTM) to deeply learn the dynamic associations between sequences from both positive and negative directions. Through an intelligent prediction model coupling multiple network structures, efficient and accurate prediction of future trends in multiple greenhouse environmental elements is achieved. This approach not only enhances the robustness and generalization ability of predictions but also provides strong technical support for scientific decision-making in greenhouse management, significantly promoting the intelligent and refined development of greenhouse agriculture. By coupling physical and biological mechanisms with data-driven modeling, greenhouse soil moisture models and crop photosynthetic physiological habitat models can deeply reveal the intrinsic mechanisms of soil moisture transport and crop photosynthetic physiology, and capture nonlinear relationships and uncertainties in the system through historical data based on data-driven models. This coupling method effectively compensates for the shortcomings of single models, making the prediction of greenhouse soil moisture dynamics and crop photosynthetic physiological habitat changes more accurate and reliable. The model quickly adapts to these changes through data-driven modeling, while maintaining the stability of predictions with the help of the theoretical foundation of the mechanistic model, thereby enhancing the robustness and generalization ability of the model and making it applicable to complex conditions in actual production. The prior knowledge provided by the mechanistic model reduces the dependence on a large amount of historical data, enabling the model to operate effectively even with limited data resources. At the same time, the mechanistic model provides physical and biological explanations for the prediction results, and this interpretability is easier for agricultural researchers and farmers to understand and accept compared to purely data-driven models. In decision-making, the MFO algorithm is introduced into the dynamic optimization of greenhouse environmental parameters through multi-model coupling and interaction, breaking through the limitations of traditional static or rule-driven control methods. With its efficient strategy optimization capabilities and stability, the MFO algorithm adapts to the variability and uncertainty of the greenhouse environment, improves the level of intelligent greenhouse management, significantly improves resource utilization efficiency and crop production benefits, and provides a new technological paradigm for the sustainable development of modern agriculture.
[0307] It should be noted that the specific embodiments described above enable those skilled in the art to more fully understand the present invention, but do not limit the present invention in any way. Therefore, although the present invention has been described in detail in this specification and embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the present invention; and all technical solutions and improvements that do not depart from the spirit and scope of the present invention are covered within the protection scope of the present invention patent. No reference numerals in the claims should be construed as limiting the scope of the claims. Any simple variations or equivalent substitutions of technical solutions that can be readily obtained by those skilled in the art within the scope of the technology disclosed in the present invention are within the protection scope of the present invention.
Claims
1. A method for optimizing the habitat of greenhouse crops, characterized in that, Includes the following steps: Continuously acquire multi-element data on the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data; Based on multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, pre-set irrigation data, and pre-set environmental control data, predict multi-factor data of the greenhouse environment in the future period; based on current soil moisture data of the crop root zone and pre-set irrigation data of the greenhouse environment in the future period, predict the soil moisture content of different soil layers in the crop root zone inside the greenhouse in the future period. Based on multi-factor data of the greenhouse internal environment in the future period and soil moisture content of different soil layers in the root zone of crops in the greenhouse, the photosynthetic physiological habitat status of crops in the greenhouse in the future period is predicted; the photosynthetic physiological habitat status of crops in the greenhouse in the future period includes crop net photosynthetic rate, crop transpiration rate, crop instantaneous water use efficiency and crop habitat stress. Using the predicted photosynthetic physiological habitat of crops inside the greenhouse as the optimization target, the current irrigation and environmental multi-factor regulation are optimized and decision-making is made to generate control schemes and control decision parameters based on the control schemes. Based on the generated control decision parameters, control signals are generated, and based on the equipment status data, the operation of greenhouse terminal equipment is controlled according to the control signals to adjust the working status of irrigation and environmental control equipment. Before predicting multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the crop root zone within the greenhouse for future periods, the process also includes anomaly detection and diagnosis of the collected multi-dimensional sequence data, specifically including the following steps: The collected multi-dimensional sequence data are aligned to form feature vectors; The eigenvectors are decomposed using ensemble empirical mode decomposition to obtain modal data and trend terms, separating high-frequency noise and low-frequency trend terms in the trend terms; the trend terms refer to the regular changes in multiple environmental factors inside and outside the greenhouse and the current soil moisture data in the crop root zone over time. High-frequency noise is processed using a dual-channel detection network; the high-frequency noise is based on deep learning anomaly detection constructed using a one-dimensional convolutional neural network and an autoencoder; the one-dimensional convolutional neural network is used to extract local temporal features from high-frequency noise and low-frequency trend terms, and burst noise is identified through local temporal features; the autoencoder is used to reconstruct feature vectors, and long-term anomalies are located through reconstruction errors. By applying a fully connected neural network, the identified burst noise is classified through a fully connected layer to obtain diagnostic results for abnormal and normal data, and the abnormal data is labeled.
2. The method for optimizing greenhouse crop habitats according to claim 1, characterized in that, The multi-factor data of the greenhouse environment include air temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, and air pressure; The meteorological data outside the greenhouse includes air temperature, relative humidity, photosynthetically active radiation intensity, carbon dioxide concentration, light intensity, wind speed, visibility, and air pressure; The current soil moisture data for the crop root zone includes soil moisture content at different soil depths within the crop root zone; The equipment status data includes the opening degree of the ventilation vents, the coverage status of the insulation cotton, the status of the solenoid valve of the water filling equipment, and the flow meter reading data. The multi-element environmental data inside the greenhouse, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data constitute multi-dimensional sequence data. The preset irrigation data is the preset irrigation amount per unit area within a future control period, and the preset environmental control data is the preset data for the greenhouse quilt coverage rate and the opening size of the ventilation opening every 10 minutes within a future control period.
3. The greenhouse crop habitat optimization method according to claim 2, characterized in that, It also includes repairing abnormal data, specifically including the following steps: For short-term missing data in labeled outliers and missing data, LSTM-Impute is used to predict and impute based on the temporal relationship between the preceding and following points; where short-term missing data refers to fewer than 3 consecutive points. For long-term missing data in labeled anomalies and missing data, GAN is used to generate candidate data. By improving the generative adversarial network, physical constraints are introduced when generating data; where long-term missing refers to three or more consecutive points. For sudden noise, the moving average of adjacent normal data is used as a substitute, and for sensor drift, the data baseline is recalibrated based on the trend term of EEMD decomposition.
4. The greenhouse crop habitat optimization method according to claim 3, characterized in that, The method of predicting multi-factor data of the greenhouse internal environment in the future period based on multi-factor data of the greenhouse internal environment, meteorological data outside the greenhouse, current soil moisture data of crop root zone, irrigation preset data and environmental control preset data specifically includes the following steps; The greenhouse environment multi-factor data, greenhouse meteorological data, current soil moisture data in the crop root zone, irrigation preset data, and environmental control preset data are used as input data and input into the greenhouse environment multi-factor prediction model; the greenhouse environment multi-factor prediction model is constructed and trained using Bi-LSTM and Informer. Specifically, the Bi-LSTM layer is used to capture local dependencies in the input data to generate a hidden state sequence containing temporal features; the probabilistic sparse self-attention mechanism in Informer is adopted to filter key time points related to the prediction results from the hidden state sequence through sparsification calculation, calculate the attention weight of key time points, and form weighted key temporal features. A time autoencoder is used to reduce the dimensionality of the trend term and output the dimensionality-reduced periodic features; the weighted key time-series features and the dimensionality-reduced periodic features are then fused to form a comprehensive feature vector. The fused integrated feature vector is input into the fully connected layer, and after linear transformation and nonlinear activation, multivariate prediction results are output. The multivariate prediction results include the greenhouse internal air temperature, greenhouse internal relative humidity, greenhouse internal photosynthetically active radiation intensity, greenhouse internal carbon dioxide concentration, and greenhouse internal air pressure.
5. The method for optimizing greenhouse crop habitats according to claim 4, characterized in that, The prediction model for soil moisture content in different soil layers of the crop root zone inside the greenhouse during the future period is as follows: ; In the formula, This represents the soil moisture content of different soil layers in the root zone of crops inside the greenhouse during a future period. This refers to the current soil moisture data in the crop root zone; t Let z be the time, and z be the vertical spatial coordinate, which includes the current distribution of soil moisture in the crop root zone along the Z direction. It represents the water diffusivity; Hydraulic conductivity; For crop water absorption; δ (z) is the Dirac function, indicating that irrigation only affects the surface; q irr ( t () represents the time-varying irrigation flux.
6. The method for optimizing greenhouse crop habitats according to claim 5, characterized in that, The prediction model for the net photosynthetic rate of the crop is as follows: ; ; in, For the maximum carboxylation rate, This refers to the photosynthetic electron transport rate. For the utilization rate of triose phosphate, C c This refers to the intercellular CO2 concentration. RH To predict the relative humidity inside the greenhouse, T To predict the internal temperature of the greenhouse, The predicted carbon dioxide concentration inside the greenhouse; The dark respiration rate at the reference temperature. Q 10 The coefficient for predicting the internal temperature of the greenhouse. It is a humidity correction factor. It is a CO2 concentration correction factor. The limiting factor for soil moisture in the root zone; The prediction model for crop transpiration rate is as follows: ; in, VPD For saturated water vapor pressure difference, The stomatal conductance of crops is affected by carbon dioxide concentration and photosynthetically active radiation intensity. P Atmospheric pressure; The prediction model for crop instantaneous water use efficiency is as follows: ; in, P n The net photosynthetic rate of crops. E For crop transpiration rate; The predictive model for integrated habitat stress in crops is as follows: ; in, The total stress of environmental factors, n This represents the number of environmental elements in the habitat, which include the greenhouse internal temperature, relative humidity, carbon dioxide concentration, photosynthetically active radiation intensity, and root zone soil moisture limiting factors. The stress caused by a single environmental factor.
7. A system for implementing the greenhouse crop habitat optimization method as described in claim 1, characterized in that, include: The data acquisition module is used to continuously acquire multi-element environmental data inside the greenhouse, meteorological data outside the greenhouse, current soil moisture data in the crop root zone, and equipment status data; The parameter prediction module is used to predict the multi-factor data of the greenhouse environment in the future period based on multi-factor data of the greenhouse environment, meteorological data outside the greenhouse, current soil moisture data of the crop root zone, irrigation preset data, and environmental control preset data; and to predict the soil moisture content of different soil layers in the crop root zone in the future period based on current soil moisture data of the crop root zone, irrigation preset data, and multi-factor data of the greenhouse environment in the future period. The crop habitat prediction module is used to predict the photosynthetic physiological habitat status of crops in the greenhouse in the future period based on multi-factor data of the greenhouse internal environment and soil moisture content of different soil layers in the root zone of crops in the greenhouse. The regulation and decision-making module is used to optimize the current irrigation and environmental multi-factor regulation based on the predicted photosynthetic physiological habitat status of crops inside the greenhouse in the future period, generate control schemes, and generate control decision parameters based on the control schemes. The control execution module is used to generate control signals based on the generated control decision parameters, and control the operation of greenhouse terminal equipment and adjust the working status of irrigation and environmental control equipment based on equipment status data and control signals.
8. A computer device, comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is loaded by the processor, it is able to perform the steps of the method according to any one of claims 1 to 6.