Intelligent control cabinet internal environment early warning evaluation method based on similar days and Optuna-LightGBM
By using similar days and the Optuna-LightGBM model, a temperature and humidity prediction model for intelligent control cabinets was constructed. This solved the problems of low prediction accuracy and fixed thresholds for temperature and humidity inside intelligent control cabinets, enabling dynamic early warning of the environment and improving the safety and stability of the equipment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ZHEJIANG HUAYUN ELECTRIC POWER ENG DESIGN CONSULTATION CO LTD
- Filing Date
- 2022-06-30
- Publication Date
- 2026-04-28
AI Technical Summary
The existing intelligent control cabinet has low accuracy in predicting temperature and humidity, and the warning threshold is fixed and cannot be dynamically adjusted in real time, resulting in the inability to issue timely warnings and affecting the safe and stable operation of the equipment.
The intelligent control cabinet internal environment early warning assessment method based on similar days and Optuna-LightGBM collects historical data, constructs a temperature and humidity prediction model, sets intelligent temperature and humidity early warning parameters, and realizes dynamic threshold adjustment for different environmental conditions.
It improves the accuracy of temperature and humidity prediction and early warning, enhances the timeliness and stability of the environmental control system, and reduces the risk of equipment failure.
Smart Images

Figure CN115330018B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of early warning technology for the internal environment of intelligent control cabinets, and specifically to an early warning assessment method for the internal environment of intelligent control cabinets based on similar days and Optuna-LightGBM. Background Technology
[0002] With the deepening of modular construction of smart substations, more and more microprocessor-based electrical equipment is being deployed in electrical equipment component cabinets, facing harsh operating environments with high temperatures and humidity. The high temperature and humidity environment inside the cabinet can cause various types of defects and malfunctions in intelligent secondary equipment, including short-term emergencies, short-term serious problems, and long-term hidden dangers. To address these issues, research on temperature and humidity environment early warning and control technology for indoor intelligent control cabinets can better serve the modular construction of substations. However, traditional control methods are mostly event-driven, such as PID control, which considers temperature and humidity exceeding a certain threshold as exceeding limits. This results in problems such as low accuracy in temperature and humidity prediction and tracking, and the inability to provide timely warnings before drastic changes in the internal environment of the control cabinet. This leads to instability in the cabinet environment, easily causing problems with the safe and stable operation of intelligent secondary equipment, and ultimately affecting the user experience.
[0003] Currently, the accuracy of temperature and humidity prediction in intelligent control cabinets is low, and the warning threshold is set in a fixed manner. It is impossible to dynamically adjust the threshold in real time according to the environment inside the cabinet. As a result, this type of control method cannot provide timely warnings when there are drastic changes in the internal environment of the intelligent control cabinet's environmental control system. Summary of the Invention
[0004] To address the challenges of predicting and providing early warnings of temperature and humidity inside existing intelligent control cabinets, this invention discloses a method for early warning and assessment of the internal environment of intelligent control cabinets based on similar days and Optuna-LightGBM.
[0005] To solve the above-mentioned technical problems, the technical implementation scheme of the present invention is as follows:
[0006] The method for early warning assessment of the internal environment of intelligent control cabinets based on similar days and Optuna-LightGBM includes the following steps:
[0007] S1: Collect historical temperature and humidity data and weather data inside the intelligent control cabinet, and process any missing values in the data;
[0008] S2: Select time periods similar to the time period to be predicted from historical data using the similar day algorithm as the model training set;
[0009] S3: Construct a temperature and humidity prediction model based on Optuna-LightGBM to make short-term predictions of temperature and humidity inside the cabinet;
[0010] S4: Set the temperature and humidity warning parameters inside the intelligent control cabinet, and reasonably determine the threshold for different states at different times to achieve temperature and humidity warning.
[0011] Preferably, step S1 includes the following steps:
[0012] S11: Obtain historical temperature and humidity data and weather data inside the intelligent control cabinet, including temperature, humidity, and precipitation;
[0013] S12: Fill in the missing values in the data in S11 with the nearest value. If there is a long period of consecutive missing values, delete that period.
[0014] Preferably, step S2 includes the following steps:
[0015] S21: Divide the historical time series into several time periods with the same length as the day to be predicted, and construct the daily feature vector X = |T,W,H,P|, where T is the ambient temperature, W is the surface temperature of the control cabinet, H is the relative humidity, and P is the precipitation.
[0016] S22: Calculate the PEASRON correlation coefficient between each variable in the daily feature vector and temperature and humidity, and assign weights to different variables in the daily feature vector based on the correlation coefficient;
[0017] S23: Use the DTW algorithm to calculate the distance and similarity between the daily feature vector of each time period and the meteorological feature vector of the day to be predicted. Based on the weights calculated in S22, readjust the DTW distance to calculate the daily similarity coefficient, and select the time periods with the smallest coefficients as the model training set.
[0018] The weights of each environmental factor in step S22 are determined as follows:
[0019]
[0020]
[0021]
[0022]
[0023] Where corr() is the Pearson correlation coefficient calculation function, T t For the environmental temperature time series of the period to be predicted, T i For historical environmental temperature time series of equal length, H t For the environmental humidity time series of the period to be predicted, H i For historical environmental humidity time series of equal length, W t For the time series of cabinet surface temperature to be predicted, W iFor historical cabinet temperature time series of equal length, P t For the time series of precipitation to be predicted, P i The time series are of equal length historical precipitation.
[0024] The method for readjusting the DTW distance in step S23 based on the weights calculated in S22 is as follows:
[0025] λ i =η T ·DTW(T i ,T t )+η W ·DTW(W i W t )+
[0026] η H ·DTW(H i H t )+η P ·DTW(P i ,P t ), i∈(1,2...,n)
[0027] Where λ i is the daily similarity coefficient, and DTW() is the formula for calculating DTW distance.
[0028] Preferably, step S3, which involves constructing a temperature and humidity prediction model based on Optuna-LightGBM, includes the following steps:
[0029] S31: Establish input data based on the training set set in step S2, and construct derived features;
[0030] S32: Input the key data from step S31 into the LightGBM model, confirm the range of model parameters, and optimize the model parameters through five-fold cross-optuna to achieve the optimal accuracy of the prediction model;
[0031] Step S31, feature derivation, includes performing time-series first-order and second-order difference processing on the input features, performing cross-derived features on the input features (i.e., performing addition, subtraction, multiplication, and division on features with the same dimensions), and performing feature equal-frequency and equal-width binning processing on the features.
[0032] Preferably, the setting of the temperature and humidity early warning parameters inside the intelligent control cabinet in step S4 includes the following steps:
[0033] S41: Based on the predicted data in step S3, plot the temperature and humidity curve for the next time period, calculate the slope of the curve at each moment within the predicted time period, and multiply it with the temperature and humidity at that moment to construct the temperature and humidity early warning parameters inside the intelligent control cabinet.
[0034] S42: Calculate the time when the temperature and humidity inflection point occurs, and obtain the corresponding temperature and humidity values and the rate of change of temperature and humidity. The temperature and humidity warning parameter value obtained here is the threshold.
[0035] The formula for the temperature and humidity warning parameters inside the intelligent control cabinet in S41 is as follows:
[0036]
[0037] Where T n T represents the predicted temperature value at the predicted time. n-1 Let t be the temperature value at the current moment. n For the predicted time, t n-1 At the current moment, λ T H is a temperature warning parameter. n H represents the predicted humidity value at the predicted time. n-1 λ represents the humidity value at the current moment. H This is a humidity warning parameter;
[0038] The formula for calculating the inflection point of temperature and humidity in S42 is as follows:
[0039] Compared with the prior art, the advantages of the present invention are:
[0040] (1) The intelligent control cabinet internal environment early warning assessment method established in this invention selects similar time periods based on meteorological factors, which improves the similarity between the training set and the training set composed of the time period to be predicted, thereby improving the model's generalization ability and accuracy.
[0041] (2) This invention realizes the autonomous parameter optimization of the model through the Optuna-LightGBM model, sets a temperature and humidity warning parameter inside the intelligent control cabinet, realizes temperature and humidity warning under different environmental conditions, and improves the accuracy of temperature and humidity warning inside the intelligent control cabinet.
[0042] (3) The model built in this invention requires a small amount of data, and LightGBM is a lightweight model with the advantages of requiring less computing resources and running fast. Attached Figure Description
[0043] Figure 1 This is a flowchart of a temperature and humidity early warning method for intelligent control cabinets. Detailed Implementation
[0044] Embodiments of the present invention are described in detail below, examples of which are illustrated in the accompanying drawings. The embodiments described below with reference to the accompanying drawings are exemplary and intended to explain the present invention, and should not be construed as limiting the present invention.
[0045] See Figure 1This is an embodiment of the intelligent control cabinet internal environment early warning assessment method based on similar days and Optuna-LightGBM of the present invention. The intelligent control cabinet internal environment early warning assessment method based on similar days and Optuna-LightGBM includes the following steps:
[0046] S1: Collect historical temperature and humidity data and weather data inside the intelligent control cabinet, and process any missing values in the data; S2: Select time periods similar to the time period to be predicted from the historical data as the model training set using a similar day algorithm; S3: Construct a temperature and humidity prediction model based on Optuna-LightGBM to make short-term predictions of the temperature and humidity inside the cabinet; S4: Set the temperature and humidity warning parameters inside the intelligent control cabinet, which can reasonably determine the threshold for different states at different times to achieve temperature and humidity warnings.
[0047] Step S1 includes the following steps:
[0048] S11: Obtain historical temperature and humidity data and weather data inside the intelligent control cabinet, including temperature, humidity, precipitation, etc.
[0049] S12: Fill missing values in the data in S11 with the nearest value. If there is a long period of consecutive missing values, consider deleting that period.
[0050] Step S2, the selection of the model training set based on similar days, includes the following steps:
[0051] S21: Divide the historical time series into several time periods with the same length as the day to be predicted, and construct the daily feature vector X = |T,W,H,P|, where T is the ambient temperature, W is the surface temperature of the control cabinet, H is the relative humidity, and P is the precipitation.
[0052] S22: Calculate the PEASRON correlation coefficient between each variable in the daily feature vector and temperature and humidity, and assign weights to different variables in the daily feature vector based on the correlation coefficient;
[0053] S23: Use the DTW algorithm to calculate the distance and similarity between the daily feature vector of each time period and the meteorological feature vector of the day to be predicted. Based on the weights calculated in S22, readjust the DTW distance to calculate the daily similarity coefficient, and select the time periods with the smallest coefficients as the model training set.
[0054] The method for determining the weights of each environmental factor in step S22 is as follows:
[0055]
[0056]
[0057]
[0058]
[0059] Where corr() is the Pearson correlation coefficient calculation function, T t For the environmental temperature time series of the period to be predicted, T i For historical environmental temperature time series of equal length, H t For the environmental humidity time series of the period to be predicted, H i For historical environmental humidity time series of equal length, W t For the time series of cabinet surface temperature to be predicted, W i For historical cabinet temperature time series of equal length, P t For the time series of precipitation to be predicted, P i This is a time series of historical precipitation of equal length. The DTW distance is readjusted in step S23 based on the weights calculated in S22, as follows:
[0060] λ i =η T ·DTW(T i ,T t )+η W ·DTW(W i W t )+
[0061] η H ·DTW(H i H t )+η P ·DTW(P i ,P t ), i∈(1,2...,n)
[0062] Where λ i is the daily similarity coefficient, and DTW() is the formula for calculating DTW distance.
[0063] Step S3, which involves constructing a temperature and humidity prediction model based on Optuna-LightGBM, includes the following steps:
[0064] S31: Establish input data based on the training set set in step S2, and construct derived features;
[0065] S32: Input the key data from step S31 into the LightGBM model, confirm the range of model parameters, and optimize the model parameters through five-fold cross-optuna to achieve the optimal accuracy of the prediction model.
[0066] Step S31, feature derivation, includes performing first-order and second-order temporal difference processing on the input features, performing cross-derived features (i.e., adding, subtracting, multiplying, and dividing features of the same dimension), and performing equal-frequency and equal-width binning on the features. The parameters optimized in step S32 are: num_trees (number of trees); num_leaves (number of leaves in each tree); max_depth (tree depth); learning_rate (learning rate); and bagging_fraction (sample sampling ratio), etc.
[0067] Step S4 involves setting the internal temperature and humidity warning parameters of the intelligent control cabinet, which includes the following steps:
[0068] S41: Based on the predicted data in step S3, plot the temperature and humidity curves for the next 15 minutes, calculate the slope of the curves at each time point, and multiply them by the temperature and humidity at that time point to construct the temperature and humidity early warning parameters inside the intelligent control cabinet.
[0069] S42: Calculate the time when the temperature and humidity inflection point occurs, and obtain the corresponding temperature and humidity values and the rate of change of temperature and humidity. The temperature and humidity warning parameter value obtained here is the threshold.
[0070] The formula for the internal temperature and humidity early warning parameters of the S41 intelligent control cabinet is as follows:
[0071]
[0072] Where T n T represents the predicted temperature value at the predicted time. n-1 Let t be the temperature value at the current moment. n For the predicted time, t n-1 At the current moment, λ T H is a temperature warning parameter. n H represents the predicted humidity value at the predicted time. n-1 λ represents the humidity value at the current moment. H This is a humidity warning parameter. The formula for calculating the inflection point of temperature and humidity in S42 is as follows:
[0073] The above description is merely a specific embodiment of the present invention, but the technical features of the present invention are not limited thereto. Any changes or modifications made by those skilled in the art within the scope of the present invention are covered by the patent scope of the present invention.
Claims
1. A method for early warning and assessment of the internal environment of an intelligent control cabinet based on similar days and Optuna-LightGBM, characterized in that: Includes the following steps: S1: Collect historical temperature and humidity data and weather data inside the intelligent control cabinet, and process any missing values in the data; S2: Select time periods similar to the time period to be predicted from historical data as the model training set using a similar day algorithm; specifically, this includes the following steps: S21: Divide the historical time series into several time periods with the same length as the day to be predicted, and construct a daily feature vector. Where T is the ambient temperature, W is the control cabinet surface temperature, H is the relative humidity, and P is the precipitation. S22: Calculate the PEASRON correlation coefficient between each variable in the daily feature vector and temperature and humidity, and assign weights to different variables in the daily feature vector based on the correlation coefficient; S23: Use the DTW algorithm to calculate the distance and similarity between the daily feature vector of each time period and the meteorological feature vector of the day to be predicted. Based on the weights calculated in S22, readjust the DTW distance to calculate the daily similarity coefficient, and select the time periods with the smallest coefficients as the model training set. The weights of each environmental factor in step S22 are determined as follows: ; in The function for calculating the Pearson correlation coefficient. This is a time series of ambient temperature for the period to be predicted. The historical environmental temperature time series are of equal length. This is a time series of environmental humidity for the period to be predicted. The data consists of historical environmental humidity time series of equal length. The temperature time series of the cabinet meter for the period to be predicted. The historical cabinet temperature time series are of equal length. This is a time series of precipitation for the period to be predicted. The time series are historical precipitation data of equal length. The method for readjusting the DTW distance in step S23 based on the weights calculated in S22 is as follows: ; in The daily similarity coefficient, The formula for calculating DTW distance; S3: Construct a temperature and humidity prediction model based on Optuna-LightGBM to make short-term predictions of temperature and humidity inside the cabinet; S4: Set the temperature and humidity warning parameters inside the intelligent control cabinet, and reasonably determine the threshold for different states at different times to achieve temperature and humidity warning.
2. The method for early warning and assessment of the internal environment of an intelligent control cabinet based on similar days and Optuna-LightGBM as described in claim 1, characterized in that: Step S1 includes the following steps: S11: Obtain historical temperature and humidity data and weather data inside the intelligent control cabinet, including temperature, humidity, and precipitation; S12: Fill missing values in the data in S11 with the nearest value. If there is a long period of consecutive missing values, delete that period.
3. The method for early warning and assessment of the internal environment of an intelligent control cabinet based on similar days and Optuna-LightGBM as described in claim 1, characterized in that: Step S3, which involves constructing a temperature and humidity prediction model based on Optuna-LightGBM, includes the following steps: S31: Establish input data based on the training set set in step S2, and construct derived features; S32: Input the data from step S31 into the LightGBM model, confirm the range of model parameters, and optimize the model parameters through five-fold cross-optuna to achieve the best prediction accuracy. Step S31, feature derivation, includes performing time-series first-order and second-order difference processing on the input features, performing cross-derived features on the input features (i.e., performing addition, subtraction, multiplication, and division on features with the same dimensions), and performing feature equal-frequency and equal-width binning processing on the features.
Citation Information
Patent Citations
Industrial park atmospheric environment sudden early-warning threshold value determining method and device
CN108226395A
Converter station valve hall operation environment early warning method based on time series and transverse comparison
CN110390151A
Electric power system short-term load prediction method based on GEP parameter optimization XGBoost
CN111340273A