Water plant scheduling method based on nonparametric method and artificial intelligence aggregation model
By adopting non-parametric methods and artificial intelligence aggregation model in water plant scheduling, combining wavelet decomposition and Gaussian process regression model, the problems of low data sparsity and prediction accuracy in water plant scheduling are solved, and a more efficient and adaptive water quality prediction and scheduling strategy is achieved.
Patent Information
- Application Number
- CN202411790520.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-06
- Publication Date
- 2025-04-01
AI Technical Summary
The existing water plant scheduling methods rely on the experience of operation and maintenance personnel, are inefficient and not accurate enough, and are difficult to adapt to the current development needs of municipal construction. They face data sparseness problems, making it difficult to establish a reliable model.
The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model is adopted to extract high-frequency and low-frequency signals in the water quality curve through wavelet decomposition, and combine the Gaussian process regression model and a factor decomposition machine to construct water quality prediction and scheduling strategy.
It improves the accuracy of water quality prediction and the adaptability of the model, reduces parameter dependence, enhances the overall performance of the scheduling recommendation algorithm, and can better adapt to water quality fluctuations and random perturbations.
Smart Images

Figure CN119742000A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a water plant scheduling method based on a non-parametric method and an artificial intelligence aggregation model. Background Art
[0002] With the continuous acceleration of the process of urban and rural water supply integration, the status of water supply work in urban construction is becoming more and more important. However, many water plants still use traditional non-intelligent scheduling methods, which are highly dependent on the experience and judgment of operation and maintenance personnel, are inefficient and not accurate enough, and are difficult to adapt to the current development needs of municipal construction. However, building a robust water plant scheduling model often faces serious data sparsity. Under sparse conditions, existing models usually cannot work reliably, and the connection between operation and maintenance entities and scheduling operations is difficult to establish directly. Especially when the input variables are converted by unique hot encoding, the problem of data sparsity is further aggravated and seriously interferes with the performance of algorithm modeling. In addition, the prediction of water quality in water plants is crucial to the realization of water plant scheduling goals. The water quality of water plant workshops is extremely susceptible to interference from factors such as raw water, process, and pump group loss. For the prediction of time series with different frequency disturbances, the commonly used method is to use frequency domain analysis methods, such as Fourier transform, to decompose the components of different periods in the signal, and then perform the next step of time series prediction, but the frequency domain decomposition method does not have a positioning function and is only applicable to time series with stable periods. For non-stationary time series including water quality curves, it is necessary to analyze the time domain and frequency domain of the series at the same time. Simple time series regression algorithm or frequency domain decomposition algorithm cannot model it well. Therefore, it is necessary to propose a water plant water quality prediction algorithm that can adaptively analyze the time-frequency characteristics of water quality curves. Summary of the invention
[0003] The object of the present invention is to provide a water plant scheduling method based on a non-parametric method and an artificial intelligence aggregation model.
[0004] The technical solution adopted by the present invention is:
[0005] A water plant scheduling method based on a non-parametric method and an artificial intelligence aggregation model specifically includes the following steps:
[0006] Step 1, using chemical oxygen demand (COD) as a prediction index, calculate the time series of water quality data in a specific area;
[0007] Step 2, selection of prediction training data set: divide the water quality data time series into training data set and validation data set according to the set method.
[0008] Step 3, wavelet decomposition and reconstruction of water quality curve: perform binary telescoping wavelet decomposition on the original time series of the training data set, and use the high-frequency and low-frequency coefficients obtained after decomposition for wavelet reconstruction;
[0009] Step 4: Use the self-attention mechanism to assign modeling weights to the embedding of water quality prediction indicators, and use the decomposition interaction parameter V to model the interactions of all paired non-zero value features in the embedding vector to obtain the optimal water plant operation scheduling strategy;
[0010] Furthermore, in step 1, water quality factors in the region are collected, and regional water quality data within the sampling period are determined and analyzed according to the water quality calculation formula, and outliers are removed.
[0011] Furthermore, in step 2, it is assumed that m is the total number of samples, and the first n observation data of the water quality sequence are selected as the training data set, and the last mn observation sample data are used as the verification data set.
[0012] Furthermore, in step 3, high-frequency information and low-frequency information in the original time series are extracted, and the water quality time series is decomposed and reconstructed using the Mallat algorithm using binary wavelet.
[0013] Furthermore, step 3 specifically includes the following steps:
[0014] Step 3-1, signal decomposition. Take c0 as the discrete signal to be decomposed, then:
[0015] Where: H and G are low-pass filter and high-pass filter respectively; c m and d m are the low-frequency signal and high-frequency signal of the original signal at a specific resolution, respectively; j is the decomposition scale; J is the maximum number of decomposition layers. After transformation, the target discrete signal c0 is decomposed into d1, d2, ..., d J and c J ;
[0016] Binary stretch wavelet decomposition uses secondary sampling to make the length of the next layer of decomposition signal half of the previous layer, and keep the total output data length consistent with the length of the input discrete signal to be decomposed c; Since the reduction in the number of discrete signals to be decomposed has a negative effect on prediction, the signal decomposed by the Mallat algorithm is reconstructed by binary interpolation using the reconstruction algorithm;
[0017] Step 3-2, water quality curve wavelet signal reconstruction, the reconstruction formula is: j =H * c j+1 +G * d j+1 , where: H * and G * is a dual operator, and j = J-1, J-2, ..., 0; for d1, d2, ..., d J and c JReconstruct them respectively to get D1, D2, ..., D J and D J , we have X=D1+D2+…+D J +C J ;
[0018] Where: D i ={d i,1 , d i,2 , …, d i,n} is the high-frequency signal reconstruction from the first layer to the Jth layer; C J ={c J,1 , c J,2 , …, c j,n} is the reconstruction of the low-frequency signal of the Jth layer; X is the original signal obtained by reconstruction;
[0019] Step 3-3, using Gaussian process regression model (GPR) to model the reconstructed signal,
[0020] Furthermore, step 3-3 specifically includes the following steps:
[0021] Step 3-3-1, regression analysis: Water quality prediction based on Gaussian process regression is essentially expressed as follows using the regression formula:
[0022] y * =f(y1, y2, ..., y n )
[0023] Step 3-3-2 Kernel function selection: Input the decomposed high and low frequency signals into the autoregressive Gaussian process respectively, and set different types of kernel functions according to the high frequency components and low frequency components. For the low frequency components, the linear kernel function is used; for the high frequency components, the RBF kernel function is used or other kernel functions are selected according to the actual scenario.
[0024] RBF kernel function:
[0025] Linear kernel function: k lin (y i ,y * )=σ 2 +σ*(y i -c)(y * -c)
[0026] Among them, y * is the mean of the input signal, σ is the input standard deviation, and c is a constant that can be set according to actual conditions.
[0027] Furthermore, in step 4, in order to make the predicted value The error between the actual value y is minimized, and the optimal parameters are obtained by training the aggregation model. Considering that predicting the target y(x) is actually a regression task, the common square error formula is used as the objective function:
[0028]
[0029] L2 regularization is applied to the linear weight matrix W to prevent possible overfitting. Therefore, the actual optimized objective function is:
[0030]
[0031] Among them, λ is the regularization parameter, which controls the size of the loss function and prevents overfitting in training.
[0032] Furthermore, step 4 specifically includes:
[0033] Step 4-1, use the self-attention mechanism to assign modeling weights to the embedding of water quality prediction indicators;
[0034] s(C S1 ,h t )=v t tanh(W att C S1 +U att h t )
[0035]
[0036]
[0037] Among them, C S1 is the original relationship vector, C S2 is the weighted scheduling relationship vector, is the attention score between the original relation vector and the hidden state sequence, v t , W att , U att are all learnable attention weight matrices, h t ,h i is the hidden state sequence of the water quality sequence.
[0038] Step 4-2, select the factorization machine (FM) as the water plant operation scheduling strategy prediction feature interaction modeling algorithm, use the decomposition interaction parameter y to model the interaction of all pairs of non-zero value features in the embedded vector, and obtain the predicted value; the specific expression is as follows:
[0039]
[0040] in, is the global deviation, represents the i-th feature. c is the feature dimension, v i and v j are the latent vectors of the i-th feature and the j-th feature respectively. The interaction between the i-th feature and the j-th feature is modeled by the inner product of the latent vector, that is, Among them, k represents the dimension of the latent vector.
[0041] The present invention adopts the above technical scheme and has the following technical effects: (1) Wavelet transform is used to extract high-frequency signals and low-frequency signals in the water quality curve sequence, and information of different frequencies is modeled separately. While fully extracting low-frequency information, such as periodic signals of water quality fluctuations, high-frequency features caused by random disturbances are fitted, which greatly improves the prediction accuracy; (2) According to the different characteristics of low-frequency signals and high-frequency signals, different types of kernel functions are called Gaussian process regression functions for water quality prediction, which reduces the dependence on model parameters while realizing fine-grained time series modeling, and realizes adaptive scaling of model complexity. (3) Water quality prediction indicators are integrated into the training process of the factor decomposition machine as auxiliary information, and the background context of the scheduling record is encoded to improve the overall performance of the scheduling recommendation algorithm model. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments;
[0043] Figure 1 The present invention is a flow chart of a water plant scheduling method based on a non-parametric method and an artificial intelligence aggregation model. DETAILED DESCRIPTION
[0044] In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.
[0045] like Figure 1 As shown, the present invention discloses a water plant scheduling method based on non-parametric methods and artificial intelligence aggregation models. First, wavelet decomposition is used to separate and reconstruct the high-frequency signal and low-frequency signal of the water quality curve to better adapt to the characteristic trend of non-stationary time series, and the Gaussian process regression method is used to reduce the parameter dependence in the prediction process, thereby providing an accurate water plant water quality prediction method with easy-to-collect prediction factors. At the same time, water quality prediction is added as a constraint condition to factor decomposition machine technology to alleviate the sparsity problem of interaction between water plant operation and maintenance entities and scheduling operations, and improve the effectiveness of scheduling. Specifically, the following steps are included:
[0046] Step 1, using chemical oxygen demand (COD) as a prediction indicator, calculate the time series of water quality data in a specific area: collect water quality factors in the area, determine and analyze the regional water quality data within the sampling period according to the water quality calculation formula, and remove outliers;
[0047] Step 2, selection of prediction training data set: Assuming m is the total number of samples, select the first n observation data of the water quality sequence as the training data set, and the last mn observation sample data as the verification data set;
[0048] Step 3, water quality curve wavelet decomposition and reconstruction: perform binary telescoping wavelet decomposition on the original time series of the training data set, and use the high-frequency and low-frequency coefficients obtained after decomposition for wavelet reconstruction. Extract the high-frequency and low-frequency information in the original time series, and use the Mallat algorithm to perform binary wavelet decomposition and reconstruction on the water quality time series, including the following steps:
[0049] Step 3-1, signal decomposition. Take c0 as the discrete signal to be decomposed, then:
[0050] Where: H and G are low-pass filter and high-pass filter respectively; c m and d m are the low-frequency signal and high-frequency signal of the original signal at a specific resolution, respectively; j is the decomposition scale; J is the maximum number of decomposition layers. After transformation, the target discrete signal c0 is decomposed into d1, d2, ..., d J and c J ;
[0051] Binary stretch wavelet decomposition uses secondary sampling to make the length of the next layer of decomposition signal half of the previous layer, and keep the total output data length consistent with the length of the input discrete signal to be decomposed c; Since the reduction in the number of discrete signals to be decomposed has a negative effect on prediction, the signal decomposed by the Mallat algorithm is reconstructed by binary interpolation using the reconstruction algorithm;
[0052] Step 3-2, water quality curve wavelet signal reconstruction, the reconstruction formula is: j =H * c j+1 +G * d j+1 , where: H * and G * is a dual operator, and j = J-1, J-2, ..., 0; for d1, d2, ..., d J and c J Reconstruct them respectively to get D1, D2, ..., D J and D J , we have X=D1+D2+…+D J+C J ;
[0053] Where: D i ={d i,1 , d i,2 , …, d i,n} is the high-frequency signal reconstruction from the first layer to the Jth layer; C J ={c J,1 , c J,2 , …, c j,n} is the reconstruction of the low-frequency signal of the Jth layer; X is the original signal obtained by reconstruction;
[0054] Step 3-3, using Gaussian process regression model (GPR) to model the reconstructed signal, the steps are as follows:
[0055] Step 3-3-1, regression analysis: Water quality prediction based on Gaussian process regression can essentially be understood as an autoregression analysis problem. The regression formula can be expressed as:
[0056] y * =f(y1, y2, ..., y n )
[0057] Step 3-3-2 Kernel function selection: The high and low frequency signals decomposed in step 3 are respectively input into the autoregressive Gaussian process, and different types of kernel functions are set according to the high frequency components and low frequency components. For the low frequency components, this embodiment advocates the use of linear kernel functions; for the high frequency components, this embodiment advocates the use of RBF kernel functions, and other kernel functions can also be selected according to the actual scenario.
[0058] RBF kernel function:
[0059] Linear kernel function: k lin (y i ,y * )=σ 2 +σ*(y i -c)(y * -c)
[0060] Among them, y * is the mean of the input signal, σ is the input standard deviation, and c is a constant that can be set according to actual conditions.
[0061] Step 4: Use the self-attention mechanism to assign modeling weights to the water quality prediction indicator embedding:
[0062] s(C S1 ,h t )=v t tanh(W att C S1 +U att ht )
[0063]
[0064]
[0065] Among them, C S1 is the original relationship vector, C S2 is the weighted scheduling relationship vector, is the attention score between the original relation vector and the hidden state sequence, v t , W att , U att are all learnable attention weight matrices, h t ,h i is the hidden state sequence of the water quality sequence.
[0066] Factorization Machine (FM) is selected as the feature interaction modeling algorithm for predicting water plant operation scheduling strategy, and the decomposition interaction parameter V is used to model the interaction of all pairwise non-zero valued features in the embedding vector.
[0067]
[0068] in, is the global deviation, represents the weight of the i-th feature; p c is the feature dimension, v i and v j are the latent vectors of the i-th feature and the j-th feature respectively, and the interaction between the i-th feature and the j-th feature is modeled by the inner product of the latent vector, that is, Among them, k represents the dimension of the latent vector.
[0069] In order to make the predicted value The error between the actual value y is minimized, and the optimal parameters need to be obtained by training the aggregation model. Considering that predicting the target y(x) is actually a regression task, the common square error formula is used as the objective function:
[0070]
[0071] L2 regularization is applied to the linear weight matrix W to prevent possible overfitting. Therefore, the actual optimized objective function is:
[0072]
[0073] in,
[0074] The specific implementation process of the present invention can follow the following steps:
[0075] Step 1, calculate the COD time series in the scheduling workshop;
[0076] Step 2, select the prediction training data set;
[0077] Step 3, wavelet decomposition and reconstruction of water quality curve: 1) decomposition of low-frequency and high-frequency water quality signals; 2) reconstruction of water quality curve wavelet signals;
[0078] Step 4: Model the reconstructed signal using Gaussian process regression (GPR) model: 1) regression analysis; 2) kernel function selection;
[0079] Step 5: Construct the water plant operation scheduling strategy based on the factorization machine aggregation model:
[0080] 1) Convert the operation entity ID and operation ID into sparse matrices and import them directly into the encoding layer;
[0081] 2) Use the self-attention mechanism to assign weights to the water quality indicator embeddings;
[0082] 3) The factorization machine (FM) is selected as the interactive modeling algorithm for predicting the operation and scheduling strategies of water plants to recommend the optimal operation and scheduling strategies of water plants.
[0083] The present invention adopts the above technical scheme and has the following technical effects: (1) Wavelet transform is used to extract high-frequency signals and low-frequency signals in the water quality curve sequence, and information of different frequencies is modeled separately. While fully extracting low-frequency information, such as periodic signals of water quality fluctuations, high-frequency features caused by random disturbances are fitted, which greatly improves the prediction accuracy; (2) According to the different characteristics of low-frequency signals and high-frequency signals, different types of kernel functions are called Gaussian process regression functions for water quality prediction, which reduces the dependence on model parameters while realizing fine-grained time series modeling, and realizes adaptive scaling of model complexity. (3) Water quality prediction indicators are integrated into the training process of the factor decomposition machine as auxiliary information, and the background context of the scheduling record is encoded to improve the overall performance of the scheduling recommendation algorithm model.
[0084] Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. In the absence of conflict, the embodiments in the present application and the features in the embodiments can be combined with each other. The components of the embodiments of the present application generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the detailed description of the embodiments of the present application is not intended to limit the scope of the application claimed for protection, but merely represents the selected embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians of the art without making creative work are within the scope of protection of the present application.
Claims
1. A water plant scheduling method based on non-parametric method and artificial intelligence aggregation model, characterized by: It includes the following steps: Step 1, using chemical oxygen demand (COD) as a prediction index, calculate the time series of water quality data in a specific area; Step 2, selection of prediction training data set: divide the water quality data time series into training data set and validation data set according to the set method; Step 3, wavelet decomposition and reconstruction of water quality curve: perform binary telescoping wavelet decomposition on the original time series of the training data set, and use the high-frequency and low-frequency coefficients obtained after decomposition for wavelet reconstruction; Step 4: Use the self-attention mechanism to assign modeling weights to the water quality prediction index embeddings, and use the decomposition interaction parameter V to model the interactions of all paired non-zero value features in the embedding vector to obtain the optimal water plant operation scheduling strategy.
2. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 1 is characterized in that: In step 1, water quality factors in the region are collected, and regional water quality data within the sampling period are determined and analyzed according to the water quality calculation formula, and outliers are removed.
3. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 1 is characterized in that: In step 2, assume that m is the total number of samples, select the first n observation data of the water quality sequence as the training data set, and the last mn observation sample data as the verification data set.
4. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 1 is characterized in that: In step 3, high-frequency information and low-frequency information in the original time series are extracted, and the water quality time series is decomposed and reconstructed using the Mallat algorithm using binary wavelet.
5. A water plant scheduling method based on a non-parametric method and an artificial intelligence aggregation model according to claim 1 or 4, characterized in that: Step 3 specifically includes the following steps: Step 3-1, signal decomposition: Take c0 as the discrete signal to be decomposed, then: c j+1 =H cj ,d j+1 =G cj ; j = 0, 1, ..., J; where H and G are low-pass filter and high-pass filter respectively; c m and d m are the low-frequency signal and high-frequency signal of the original signal at a specific resolution, respectively; j is the decomposition scale; J is the maximum number of decomposition layers. After transformation, the target discrete signal x0 is decomposed into d1, d2, ..., d J and c J ; Binary stretch wavelet decomposition uses secondary sampling to make the length of the next layer of decomposition signal half of the previous layer, and keep the total output data length consistent with the length of the input discrete signal to be decomposed c; Since the reduction in the number of discrete signals to be decomposed has a negative effect on prediction, the signal decomposed by the Mallat algorithm is reconstructed by binary interpolation using the reconstruction algorithm; Step 3-2, water quality curve wavelet signal reconstruction, the reconstruction formula is: j =H * c j+1 +G * d j+1 , where: H * and G * is a dual operator, and j = J-1, J-2, ..., 0; for d1, d2, ..., d J and c J Reconstruct them respectively to get D1, D2, ..., D J and D J , we have X=D1+D2+…+D J +C J ; Among them: D i ={d i,1 ,d i,2 ,…,d i,n } is the high-frequency signal reconstruction from the first layer to the Jth layer; C J ={c J,1 ,c J,2 ,…,x j,n } is the reconstruction of the low-frequency signal of the Jth layer; X is the original signal obtained by reconstruction; Step 3-3, using Gaussian process regression model to model the reconstructed signal.
6. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 5 is characterized by: Step 3-3 specifically includes the following steps: Step 3-3-1, regression analysis: Water quality prediction based on Gaussian process regression is essentially expressed as follows using the regression formula: yes * =f(y1,y2,…,y n ) Step 3-3-2 Kernel function selection: Input the decomposed high and low frequency signals into the autoregressive Gaussian process respectively, and set different types of kernel functions according to the high frequency components and low frequency components. For the low frequency components, the linear kernel function is used; for the high frequency components, the RBF kernel function is used or other kernel functions are selected according to the actual scenario. RBF kernel function: Linear kernel function: k lin (y i ,y * )=σ 2 +σ*(y i -c)(y * -c) Among them, y * is the mean of the input signal, σ is the input standard deviation; c is a constant, which is set according to the actual situation.
7. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 1 is characterized in that: In step 4, the optimal parameters are obtained by training the aggregation model, using the square error formula as the objective function: Apply L2 regularization to the linear weight matrix W to prevent overfitting, and the final actual optimized objective function is: Among them, λ is the regularization parameter, which controls the size of the loss function and prevents overfitting in training.
8. The water plant scheduling method based on non-parametric method and artificial intelligence aggregation model according to claim 1 is characterized by: Step 4 specifically includes: Step 4-1, use the self-attention mechanism to assign modeling weights to the water quality prediction index embedding and build a neural network; s(C S1 ,h t )=v t tanh(W att C S1 +U att h t ) Among them, C S1 is the original relationship vector, C S2 is the weighted scheduling relationship vector, is the attention score between the original relation vector and the hidden state sequence, v t , W att , U att are all learnable attention weight matrices, h t 、h i is the hidden state sequence of the water quality sequence; Step 4-2, select the factorization machine (FM) as the water plant operation scheduling strategy prediction feature interaction modeling algorithm, use the decomposition interaction parameter V to model the interaction of all pairs of non-zero value features in the embedded vector, and obtain the predicted value; the specific expression is as follows: in, is the global deviation, represents the weight of the i-th feature; p c is the feature dimension, v i and v j are the latent vectors of the i-th feature and the j-th feature respectively, and the interaction between the i-th feature and the j-th feature is modeled by the inner product of the latent vector, that is, Among them, k represents the dimension of the latent vector.
Citation Information
Cited By
Water quality anomaly prediction method based on wavelet self-attention network
CN121093227A