SP-AE-BTMR hybrid model-based coking diagnosis method and system
By applying the SP-AE-BTMR mixing model in an ethylene cracking furnace, combining the sparse autoencoder and Bayesian t-distribution mixing model, the problem of insufficient accuracy and robustness of coking diagnosis of ethylene cracking furnace in the prior art is solved. , accurate prediction of the coking degree of ethylene cracking furnace is achieved.
Patent Information
- Application Number
- CN202411334068.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-02-14
AI Technical Summary
The prior art has shortcomings in accuracy, real-time, reliability and cost in coking diagnosis of ethylene cracking furnaces. Especially when processing time-varying and uncertain data, it is susceptible to noise and outliers, resulting in diagnosis. Not effective.
Using the coking diagnostic method based on the SP-AE-BTMR hybrid model, the Bayesian t-distribution hybrid model with sparse autoencoder was constructed by selecting the data related to furnace tube coking as auxiliary variables, and training and testing were carried out to achieve the matching of the coking of the furnace tube. Accurate diagnosis of coking degree of ethylene cracking furnace.
This method can effectively reduce noise interference to diagnostic prediction, improve diagnosis accuracy and robustness, adapt to the input of incomplete data, enhance the generalization ability of the model, and realize accurate prediction of coking in ethylene cracking furnace.
Smart Images

Figure CN119446339A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of ethylene cracking analysis, and more particularly to a coking diagnosis method and system based on an SP-AE-BTMR hybrid model. Background Art
[0002] Ethylene is a key feedstock in petrochemical production, and steam cracking is the primary process for producing ethylene. During the high-temperature thermal cracking process, the raw material inevitably cracks and decomposes to form coke particles, which adhere to the inner walls of the furnace tubes and gradually form a coke layer. This coke layer is a poor conductor of heat, significantly increasing the outer surface temperature of the furnace tubes and reducing their mechanical strength and service life, significantly increasing the production costs of the ethylene plant. In severe cases, it can even cause tube blockages and explosions, forcing the ethylene production plant to shut down. During the ethylene cracking process, coking requires decoking. However, this decoking process requires accurate diagnosis of the coking level of each cracking furnace tube. Therefore, developing diagnostic methods for the coking level of ethylene cracking furnaces is of great practical significance.
[0003] Currently, numerous methods exist for diagnosing coking in ethylene cracking furnaces. However, considering the accuracy, real-time performance, reliability, and cost of diagnosis, soft sensing methods based on data-driven algorithms can better meet these diagnostic requirements. During the ethylene production process, ethylene cracking furnace operating data is time-varying and uncertain, subject to strong noise and outliers. Furthermore, during operation, ethylene cracking furnace data is multi-conditional, and data acquisition is often incomplete, resulting in highly nonlinear coking data. Currently available traditional data-driven soft sensing methods include principal component analysis (PCA), partial least squares (PLS), support vector machine regression (SVR), and their variants. Several regression models have been used, including Gaussian process regression (GPR), Gaussian mixture regression (GMR), Bayesian Gaussian mixture regression (BGMR), semi-supervised learning models (i.e., semi-supervised Gaussian mixture regression (SBGMR), and Bayesian t-distribution mixture regression (STMR). However, considering the characteristics of ethylene cracking furnace operating data and the simplicity and robustness of diagnosis, these methods have not been effective. Therefore, improvements to the hybrid models are still needed. Summary of the Invention
[0004] The present invention aims to overcome at least one defect (shortcoming) of the above-mentioned prior art and provide a coking diagnosis method and system based on the SP-AE-BTMR hybrid model, which is used to reduce the interference of noise on the diagnosis and prediction of the coking degree of ethylene cracking furnace and achieve accurate diagnosis and prediction.
[0005] According to a first aspect of the present application, a coking diagnosis method based on an SP-AE-BTMR hybrid model is provided, the method comprising:
[0006] Selecting data related to furnace tube coking as auxiliary variables and furnace tube coking status as a dominant variable, and collecting historical data of the furnace tubes based on the selected auxiliary variables and dominant variables to construct a training set and a test set;
[0007] Preprocessing the training set and the test set;
[0008] Constructing a Bayesian t-distributed mixture model with a sparse autoencoder;
[0009] Inputting the preprocessed training set into a Bayesian t-distributed mixture model with a sparse autoencoder, training the model based on the training set and updating the variational posterior distribution and parameter variable Θ to obtain a trained model;
[0010] Inputting the test set into the trained model to obtain a final training model;
[0011] Collect the furnace tube coking related data that need to be predicted, pre-process the furnace tube coking related data and input them into the final training model to obtain the predicted furnace tube coking state.
[0012] The method collects historical data of ethylene cracking furnace tubes as a training set for the model, adapts to the input of labeled and unlabeled data, and hides outliers, thereby achieving accurate prediction of furnace tube conditions.
[0013] Optionally, the step of collecting historical data of furnace tubes to construct a training set and a test set based on the selected auxiliary variables and leading variables specifically includes:
[0014] The training set includes a labeled training set and an unlabeled training set;
[0015] The labeled training set includes a number of labeled samples, and the labeled samples include labeled auxiliary variables and labeled dominant variables. The method for collecting the labeled auxiliary variables and the labeled dominant variables specifically includes:
[0016] During the furnace tube production process, labeled auxiliary variables are collected and the corresponding labeled dominant variable Among them, the labeled auxiliary variable X is an input matrix, the labeled dominant variable Y is an output matrix, N L Represents the number of labeled samples;
[0017] The unlabeled training set includes a plurality of unlabeled samples, each of which includes unlabeled auxiliary variables. The unlabeled auxiliary variable collection method specifically includes:
[0018] During the furnace operation, unlabeled auxiliary variables are collected Among them, the unlabeled auxiliary variable UL is an input matrix, N U Indicates the number of unlabeled samples;
[0019] Among them, labeled auxiliary variables and unlabeled auxiliary variables are collected based on the furnace tube data of the same dimension, x i Indicates the auxiliary variable of the i-th labeled sample, ul j Represents the auxiliary variable of the jth unlabeled sample, y i represents the dominant variable of the i-th labeled sample, x i ∈R d ,ul i ∈R d ,y i ∈R, d represents the dimensions of the labeled auxiliary variables and the unlabeled auxiliary variables.
[0020] The preprocessing of the furnace tube data into labeled samples and unlabeled samples can better address the situation where data collection is incomplete during the real data collection process. Incomplete data can also be used as input for model training, improving data availability.
[0021] Optionally, the preprocessing of the training set and the test set specifically includes:
[0022] The relationship between the number of samples in the labeled training set and the number of samples in the unlabeled training set is determined by a preset label ratio LR; wherein the label ratio LR represents the proportion of the labeled training set to the entire training set;
[0023] The labeled training set is additionally added with labeled outliers, and the unlabeled training set is additionally added with unlabeled outliers; wherein the proportion of the labeled outliers in the labeled training set is equal to the proportion of the unlabeled outliers in the unlabeled training set.
[0024] The control of the number of labeled samples and unlabeled samples can avoid the problem of overfitting or reduced robustness caused by unilateral over-learning of the model; adding a certain proportion of outliers can simulate the interference of noisy data in real situations and simulate the real data environment.
[0025] Optionally, constructing a Bayesian t-distributed mixture model with a sparse autoencoder specifically includes:
[0026] The model parameters of the Bayesian t-distribution mixture model with a sparse autoencoder are learned, and a parameter variable Θ = {g, μ, Λ, ω, α, β} is constructed, where g represents the mixing coefficient of the mixed distribution component of the training set, μ represents the mean vector of the mixed distribution component of the training set, Λ represents the precision matrix of the mixed distribution component of the training set, ω represents the regression coefficient between the leading variable and the auxiliary variable of the mixed distribution component of the training set, α represents the precision between the regression coefficients of the mixed distribution component of the training set, and β represents the noise precision of the mixed distribution component of the training set;
[0027] Assign the corresponding conjugate prior distribution to the parameters in the parameter variable Θ, specifically including:
[0028]
[0029] Where p(g) represents the conjugate prior distribution of g, and g obeys the Dirichlet prior distribution; a0 is the hyperparameter of the prior distribution of g, and a0>0; K represents the total number of mixture components, g={g1,g2,...g k}, g k represents the mixing coefficient of the kth mixed distribution component; Γ(.) represents the probability density function of the Dirichlet distribution;
[0030]
[0031] Where p(μ|Λ) represents the conjugate prior distribution of μ, and μ obeys a Gaussian prior distribution; m0 is the scale parameter of the μ prior distribution, λ0 is the scale parameter of the Λ prior distribution, and Λ0 is the parameter of the prior distribution; μ = {μ1,μ2,...μ k},μ k represents the mean vector of the kth mixed distribution component, N(.) represents the probability density function of the Gaussian distribution;
[0032]
[0033] Where p(Λ) represents the conjugate prior distribution of Λ, and Λ obeys the Wishart prior distribution; V0 is the scaling matrix, γ0 is the number of degrees of freedom of the Wishart distribution, Λ={Λ1,Λ2,...Λ k}, Λ k represents the precision matrix of the k-th mixed distribution component, W(.) represents the probability density function of the Wishart distribution;
[0034]
[0035] Where p(ω|α) represents the conjugate prior distribution of ω, and ω obeys the Gaussian prior distribution; ω={ω1,ω2,...ω k},ω krepresents the regression coefficient between the leading variable and the auxiliary variable of the kth mixed distribution component; α={α1,α2,...α k}, α k is the regression coefficient ω of the kth mixed distribution component k The precision between ; I represents the identity matrix;
[0036]
[0037] Where p(α) represents the conjugate prior distribution of α, p(β) represents the conjugate prior distribution of β, and both α and β obey the gamma prior distribution; c0 and d0 are the hyperparameters of the α prior distribution, and c0>0, d0>0; e0 and f0 are the hyperparameters of the β prior distribution, and e0>0, f0>0; β={β1,β2,...β k}, β k represents the noise accuracy of the k-th mixed distribution component, and G(.) represents the probability density function of the gamma distribution.
[0038] It is understandable that the learning of the model's parameter variables can improve the model's flexibility and expressiveness, enhance the model's learning ability, and improve the model's generalization performance.
[0039] Optionally, the Bayesian t-distributed mixture model with a sparse autoencoder further includes:
[0040] Based on the auxiliary variables for each labeled sample Construct a labeled K-dimensional binary latent variable Z i and labeled robust variables η i , based on the auxiliary variables of each unlabeled sample Construct an unlabeled K-dimensional binary latent variable Z j and the unlabeled robust variable η j ;
[0041] According to the definition of the mixed model and the independent and identically distributed principle, the K-dimensional binary latent variable Z of the labeled sample is obtained i and unlabeled samples K-dimensional binary latent variables Z j The probability density function of :
[0042]
[0043] in And Z ik Indicates that the i-th labeled sample is assigned to the binary latent variable of the k-th mixed distribution component, Z jk It means that the jth unlabeled sample is assigned to the kth mixed distribution component binary latent variable, and the prior probability of the two is p(Z ik =1) = p(Zjk =1)=g k ;
[0044] According to the definition of the mixed model and the independent and identically distributed principle, the robust variable η of the labeled sample is obtained i and the unlabeled sample robust variable η j The probability density function of :
[0045]
[0046] Among them, η i ={η1,η2,...η NL}, η j ={η1,η2,...η NU}, ν={ν1,ν2,...ν k}, ν k represents the degrees of freedom of the kth mixture distribution component, η ik represents the robust variable that assigns the i-th labeled sample to the k-th mixture distribution component, η jk It means that the j-th unlabeled sample is assigned to the k-th mixture distribution component robust variable.
[0047] It is understandable that introducing binary latent variables into the auxiliary variables can improve the model's adaptability to mixed distribution data. This is because furnace tube data does not have a single linear relationship. The data contains data that conform to many distributions, that is, the data is in a mixed distribution state. Introducing binary latent variables can adapt the model to complex data structures, thereby improving the model's generalization ability. Introducing robust variables into the auxiliary variables can also improve the robustness of the model. The probability density functions of the binary latent variables and the robust variables are obtained to provide intermediate quantities for calculating the convergence value of the model.
[0048] Optionally, the constructing of a Bayesian t-distributed mixture model with a sparse autoencoder further includes:
[0049] According to the Bayesian t-distribution mixture model setting with the sparse autoencoder, the labeled auxiliary variable X and the unlabeled auxiliary variable UL are a mixture of k t-distributions, and the probability density function is expressed as:
[0050]
[0051] S(.) represents the probability density function of t distribution;
[0052] Input the labeled auxiliary variable X and the unlabeled auxiliary variable UL into the sparse autoencoder;
[0053] According to the sparse autoencoder definition, represents the average activity of hidden neurons in the labeled auxiliary variables and the unlabeled auxiliary variables, and ρ is the sparsity parameter. A restriction condition needs to be added:
[0054]
[0055] And introduce an additional penalty factor, The case where the activity of the hidden neurons is significantly different from ρ is penalized so that the average activity of the hidden neurons is kept within a small range, which is achieved in the following way:
[0056]
[0057] Where s2 is the number of hidden neurons in the hidden layer of the sparse autoencoder, and KL(.) represents the KL divergence function;
[0058] According to the introduction of the penalty factor, the probability density function of the labeled auxiliary variable and the probability density function of the unlabeled auxiliary variable are rewritten as:
[0059]
[0060] The nonlinear activation function sigmoid is used to map the labeled sample auxiliary variable X to the hidden layer of the sparse autoencoder. The hidden layer feature after the labeled sample auxiliary variable X is mapped is h i =(h 1i ,h 2i ,...h ki ) T , specifically obtained by the following formula:
[0061]
[0062] in, represents the weight between the hidden layer of the sparse autoencoder and the output layer of the sparse autoencoder; the R is optimized by minimizing the square loss of the estimation error; represents the bias vector, b is obtained by adjusting during the mapping process;
[0063] In the Bayesian t-distributed mixture model setting with sparse autoencoders, the labeled dominant variable y in each distribution i and labeled auxiliary variable x i After the sparse autoencoder hides h i The following relationship exists:
[0064] y i =h i ′T ω k +σk
[0065] in σ k is the measurement noise, σ k ~N(0,β k );
[0066] Therefore, according to the i With h i The relationship between , the probability function of the label-dominant variable Y is obtained as:
[0067]
[0068] Therefore, the labeled auxiliary variable X, the labeled dominant variable Y, the unlabeled auxiliary variable UL, the labeled sample K-dimensional binary latent variable Z i , unlabeled sample K-dimensional binary latent variable Z j , labeled robust variable η i , unlabeled robust variable η j And the joint distribution of each parameter variable is expressed as:
[0069]
[0070] The SP-AE-BTMR hybrid model was constructed.
[0071] It can be understood that, by combining the penalty factor to derive the density probability function of the labeled auxiliary variables, the labeled dominant variables, and the unlabeled auxiliary variables, it is possible to reduce the impact of outlier data on the model and provide an intermediate quantity for the model to calculate the convergence value; the auxiliary variables are mapped to the hidden layer of the sparse autoencoder to complete the nonlinear mapping of the auxiliary variables and enhance the model's ability to handle nonlinear problems.
[0072] Optionally, inputting the preprocessed training set into a Bayesian t-distributed mixed regression model with a sparse autoencoder, training the model according to the training set and updating the variational posterior distribution and parameter variable Θ to obtain a trained model specifically includes:
[0073] Input the preprocessed training set into a Bayesian t-distribution mixture model with a sparse autoencoder, and set the hyperparameters and end threshold ∈ of the model;
[0074] Setting the number of iterative learning times T, the model iteratively learns the training set;
[0075] Estimate the hyperparameters of the parameter variable Θ and calculate the parameter variable Θ and the labeled K-dimensional binary latent variable Z i , unlabeled K-dimensional binary latent variable Z j , the labeled robust latent variable ηi 、The unsigned robust signature latent variable η j The variational posterior distribution and expectation of ;
[0076] According to the variational posterior distribution and expectation of each learning, the convergence value after each learning is calculated, and it is determined whether the convergence value meets the preset end threshold. If the end threshold is met, the learning is terminated, otherwise the learning is continued.
[0077] Optionally, the step of calculating a convergence value after each learning step based on the variational posterior distribution and expectation of each learning step, and determining whether the convergence value satisfies a preset end threshold, and terminating the learning step if the end threshold is satisfied, or continuing the learning step otherwise, specifically includes:
[0078] According to the variational Bayesian method, the labeled K-dimensional binary latent variable Z i , unlabeled K-dimensional binary latent variable Z j , labeled robust variable η i , unlabeled robust variable η j and parameter variables Θ are estimated, including:
[0079] p(Z i ,Z j ,η i ,η j ,Θ) is approximate to the distribution of q(Z i ,Z j ,η i ,η j ,Θ)≈q(Z i )q(Z j )q(η i )q(η j )q(Θ), according to the formula of variational inference optimal solution, the labeled K-dimensional binary latent variable Z is obtained i The variational posterior distribution of is:
[0080]
[0081] in and:
[0082]
[0083] Where <·> represents the expected value, ν represents the degree of freedom parameter of the t distribution, and ρ ik is the transition parameter of the entire calculation process;
[0084] The unlabeled K-dimensional binary latent variable Z j The variational posterior distribution of is:
[0085]
[0086] in, and:
[0087]
[0088] Among them, θ jk and δ jk is the transition parameter of the entire calculation process;
[0089] According to the definition of gamma distribution, we get the labeled robust latent variable η i and the unlabeled robust signature latent variable η j The variational posterior distribution of :
[0090]
[0091] Calculate Z ik , Z jk ,η ik ,η jk Expectations and variations:
[0092]
[0093] <Z jk >=δ jk
[0094]
[0095] Among them, ψ(.) represents the digamma probability density function;
[0096] The hyperparameter estimation results and the expectations and variations of each parameter variable Θ are:
[0097]
[0098] Among them, a k Expressed as the mixing coefficient g of the kth mixed distribution component k Hyperparameters of
[0099] Calculated according to the variational posterior distribution of g:
[0100]
[0101] The variational posterior of ω is Gaussian, so we get:
[0102]
[0103] Where Tr(.) represents the trace, Φ k , τ k is the transition parameter of the entire calculation process;
[0104] The hyperparameter c of α k =c0+(d+1) / 2, where c k d k Expressed as the accuracy α of the k-th mixture distribution component k The hyperparameters of α are: Since the conjugate variational posterior distribution of α is gamma distribution, it is calculated as:
[0105]
[0106] Among them, q * (α) is the conjugate variational posterior distribution of α;
[0107] Hyperparameter of β Among them, e k 、f k represents the noise accuracy β of the kth mixture distribution component k Hyperparameters; where the conjugate variational posterior distribution of β is gamma distribution, so we can get:
[0108]
[0109] Among them, q * (β) is the conjugate variational posterior distribution of β;
[0110] The hyperparameters of μ and Λ are:
[0111]
[0112] Among them, m k 、V k , γ k Represented as the mean vector μ of the kth mixture distribution component k , and the precision matrix Λ of the kth mixture distribution component k Hyperparameters of
[0113] Since the variational posterior distribution of μ follows a Gaussian distribution and the variational posterior distribution of Λ follows a Wishart distribution, we can calculate:
[0114]
[0115] <μ k >=m k
[0116] <Λ k >=γ k V k
[0117] Among them, q * (μ,Λ) represents the variational posterior distribution of μ and Λ;
[0118] For the degree of freedom ν k , considering it as a deterministic variable, we get the nonlinear equation:
[0119]
[0120] Use Stirling's formula to find the above ν k The solution;
[0121] The lower bound of the evidence is calculated based on the variational posterior of the parameter variable, denoted as Ω q , specifically obtained by the following formula:
[0122] Ω q = <lnp(X,Y,UL,Z i ,Z j ,η i ,η j ,Θ)>- <lnq(Z i ,Z j ,η i ,η j ,Θ)>
[0123] Thus, the convergence condition of iterative learning is obtained:
[0124]
[0125] in, and They represent the lower bounds after the t-th and t-1-th iterative learning respectively, and ∈ represents the end threshold of the assumption; after a learning cycle occurs, when the convergence value calculated after the learning cycle is greater than the end threshold, the model learning ends.
[0126] It can be understood that the training set is input into the model, and the parameters of the training set are processed, the posterior distribution and expectation of the parameter variables are calculated, and the model is learned for each sample until the predetermined end threshold is reached, then the model learning is completed; iterative learning of the training set can optimize the performance of the model, thereby improving the accuracy of the prediction results and the consistency with the actual situation.
[0127] Optionally, data related to furnace tube coking to be predicted is collected, pre-processed, and then input into a final training model to obtain a predicted coking state of the furnace tube, specifically including:
[0128] Collect the relevant data of furnace tube coking that needs to be predicted, and you can get:
[0129]
[0130] in, This is the predicted coking state of the furnace tube.
[0131] It is understood that the test set is input into the model to obtain a trained model, and then the furnace tube coking data to be predicted is input into the model to obtain a prediction result. The method can predict the coking condition of the ethylene cracking furnace, thereby making the next production work plan of the ethylene cracking furnace based on the coking condition, thereby improving production efficiency and safety during the production process.
[0132] According to a second aspect of the present application, a coking diagnosis system based on an SP-AE-BTMR hybrid model is provided, comprising:
[0133] An acquisition module is used to select data related to furnace tube coking as auxiliary variables and furnace tube coking status as a dominant variable, and based on the selected auxiliary variables and dominant variables, collect historical data of the furnace tube to construct a training set and a test set;
[0134] A preprocessing module, used for preprocessing the training set and the test set;
[0135] Build a model module for building a Bayesian t-distributed mixture model with a sparse autoencoder;
[0136] A training module, configured to input the preprocessed training set into a Bayesian t-distribution mixture model with a sparse autoencoder, train the model based on the training set and update the variational posterior distribution and parameter variable Θ to obtain a trained model;
[0137] A testing module, configured to input the test set into the trained model to obtain a final training model;
[0138] The prediction module is used to collect the furnace tube coking related data that needs to be predicted, pre-process the furnace tube coking related data that needs to be predicted, and then input it into the final training model to obtain the predicted furnace tube coking state.
[0139] When the coking diagnosis system based on the SP-AE-BTMR hybrid model is executed, the coking diagnosis method based on the SP-AE-BTMR hybrid model described in the first aspect above is implemented.
[0140] Based on any one of the above aspects, the embodiment of the present application provides a coking diagnosis method and system based on the SP-AE-BTMR hybrid model, which collects historical data of the ethylene cracking furnace tubes and preprocesses the data, constructs an SP-AE-BTMR hybrid model, and inputs the training set into the SP-AE-BTMR hybrid model to train and test the model, and finally uses the trained model to predict the furnace tube data that needs to be predicted to obtain the predicted furnace tube coking state. The method and system can adapt to the incomplete data collected, and use it as training data for training, thereby improving the availability of the data. At the same time, a sparse autoencoder is used to hide the interference data, reduce the impact of the interference data on the model, thereby improving the generalization ability of the model, achieving accurate prediction of furnace tube coking, and improving the productivity and safety of the ethylene cracking furnace. BRIEF DESCRIPTION OF THE DRAWINGS
[0141] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0142] Figure 1 Flowchart of the coking diagnosis method based on the SP-AE-BTMR hybrid model provided in this embodiment.
[0143] Figure 2 The data space distribution diagrams with and without outlier influence in the data simulation provided in this embodiment.
[0144] Figure 3 This is a diagram of the standard autoencoder structure provided in this embodiment.
[0145] Figure 4 This is a flow chart of the model training method provided in this embodiment.
[0146] Figure 5 Schematic diagram of the coking diagnosis system module based on the SP-AE-BTMR hybrid model provided in this embodiment.
[0147] Figure 6 This is the data distribution diagram of the input space and output space of the actual industrial case dataset provided in this embodiment.
[0148] Figure 7 The actual industrial case data provided in this embodiment has a test set with 5% outliers and is a figure showing the fitting of various models. DETAILED DESCRIPTION
[0149] The figures in this application are for illustrative purposes only and are not to be construed as limiting the present application. To better illustrate the following embodiments, some components in the figures may be omitted, enlarged, or reduced in size, and do not represent actual product dimensions. Those skilled in the art will appreciate that some well-known structures and their descriptions may be omitted from the figures.
[0150] In order to enable those skilled in the art to better understand the present invention, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of this application.
[0151] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in a sequence other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0152] This embodiment provides a technical solution that can solve the above-mentioned problem. The specific implementation methods of this application are described in detail below with reference to the accompanying drawings.
[0153] like Figure 1 As shown, this embodiment provides a flowchart of a coking diagnosis method based on the SP-AE-BTMR hybrid model, the method comprising:
[0154] S110, selecting data related to furnace tube coking as auxiliary variables and furnace tube coking status as a dominant variable, and collecting historical data of the furnace tubes based on the selected auxiliary variables and dominant variables to construct a training set and a test set;
[0155] In this embodiment, data related to furnace tube coking is selected as an auxiliary variable, and the furnace tube coking status is selected as the dominant variable. It is understood that the auxiliary variables can be data such as the furnace tube outlet temperature, inlet temperature, and furnace tube outer surface temperature during the furnace tube production process. The specific selected data is screened based on the steam cracking mechanism and expert experience; the dominant variable is the furnace tube coking status, preferably, the degree of furnace tube coking, such as normal, mild, moderate, etc.
[0156] According to the data types selected for each dimension, the data recorded during the historical production of the ethylene cracking furnace are collected, and the data are organized to construct training sets and test sets.
[0157] The training set includes a labeled training set and an unlabeled training set;
[0158] The labeled training set includes a number of labeled samples, and the labeled samples include labeled auxiliary variables and labeled dominant variables. The method for collecting the labeled auxiliary variables and the labeled dominant variables specifically includes:
[0159] During the furnace tube production process, labeled auxiliary variables are collected and the corresponding labeled dominant variable Among them, the labeled auxiliary variable X is an input matrix, the labeled dominant variable Y is an output matrix, N L Represents the number of labeled samples;
[0160] It's understandable that each labeled sample corresponds to a labeled auxiliary variable and a labeled dominant variable. This is equivalent to labeling the labeled auxiliary variable with the data corresponding to the labeled dominant variable. The labeled dominant variable is equivalent to the label of the labeled auxiliary variable, which is subsequently used by the relevant model to learn. This operation is a form of supervised machine learning. By using labeled data for training, we can fully explore patterns and relationships in the data.
[0161] The unlabeled training set includes a plurality of unlabeled samples, each of which includes unlabeled auxiliary variables. The unlabeled auxiliary variable collection method specifically includes:
[0162] During the furnace operation, unlabeled auxiliary variables are collected Among them, the unlabeled auxiliary variable UL is an input matrix, N U Indicates the number of unlabeled samples;
[0163] It’s understandable that each unlabeled example corresponds to an unlabeled auxiliary variable, and subsequent related models learn directly from the unlabeled auxiliary variables. This operation is a form of unsupervised machine learning, which can automatically identify patterns and structures in data without relying on labels.
[0164] Among them, labeled auxiliary variables and unlabeled auxiliary variables are collected based on the furnace tube data of the same dimension, x i Indicates the auxiliary variable of the i-th labeled sample, ul j Represents the auxiliary variable of the jth unlabeled sample, y i represents the dominant variable of the i-th labeled sample, x i∈R d ,ul i ∈R d ,y i ∈R, d represents the dimensions of the labeled auxiliary variables and the unlabeled auxiliary variables.
[0165] It is understandable that the corresponding data collected for labeled auxiliary variables and unlabeled variables include multi-dimensional data, so a labeled auxiliary variable or an unlabeled auxiliary variable is represented as a matrix in the data structure; because the data type of each dimension of the auxiliary variable has been selected before collection, the data type collected for labeled auxiliary variables and unlabeled auxiliary variables is the same, and the structure of the matrix is the same.
[0166] S120, preprocessing the training set and the test set;
[0167] The relationship between the number of samples in the labeled training set and the number of samples in the unlabeled training set is determined by a preset label ratio LR; wherein the label ratio LR represents the proportion of the labeled training set to the entire training set;
[0168] The labeled training set is additionally added with labeled outliers, and the unlabeled training set is additionally added with unlabeled outliers; wherein the proportion of the labeled outliers in the labeled training set is equal to the proportion of the unlabeled outliers in the unlabeled training set.
[0169] In this embodiment, simulation of relevant data can better understand the distribution of samples in the entire model.
[0170] like Figure 2 The data space distribution diagrams with and without outlier influence in the data simulation of this embodiment are shown in Figure 2. It can be understood that 3000 data are randomly generated, 1000 samples are used as training sets, and 2000 samples are used as test sets. The generated data distribution is as follows: Figure 2 As shown in Figure (a) in the figure. And 1% of outliers are added to the training set. The data distribution after adding outliers is as follows Figure 2 As shown in Figure (b) in the figure. The training set is divided into two parts: labeled samples and unlabeled samples. The label rate represents the proportion of the labeled training set to the entire training set, which is recorded as LR. 1% of outliers are added to the labeled part, and the same proportion of outliers are added to the unlabeled part. For example, during the training process, 10 outliers are added to the labeled part, and the LR is set to 50%, 40%, 30%, 20% and 10% respectively, and the unlabeled part includes 10, 15, 18, 25 and 50 outliers respectively.
[0171] S130, constructing a Bayesian t-distributed mixture model with a sparse autoencoder;
[0172] In this embodiment, the model parameters of the Bayesian t-distribution mixture model with a sparse autoencoder are learned, and a parameter variable Θ={g, μ, Λ, ω, α, β} is constructed, wherein g represents the mixing coefficient of the mixed distribution component of the training set, μ represents the mean vector of the mixed distribution component of the training set, Λ represents the precision matrix of the mixed distribution component of the training set, ω represents the regression coefficient between the dominant variable and the auxiliary variable of the mixed distribution component of the training set, α represents the precision between the regression coefficients of the mixed distribution component of the training set, and β represents the noise precision of the mixed distribution component of the training set;
[0173] Assign the corresponding conjugate prior distribution to the parameters in the parameter variable Θ, specifically including:
[0174]
[0175] Where p(g) represents the conjugate prior distribution of g, and g obeys the Dirichlet prior distribution; a0 is the hyperparameter of the prior distribution of g, and a0>0; K represents the total number of mixture components, g={g1,g2,...g k}, g k represents the mixing coefficient of the kth mixed distribution component; Γ(.) represents the probability density function of the Dirichlet distribution;
[0176]
[0177] Where p(μ|Λ) represents the conjugate prior distribution of μ, and μ obeys a Gaussian prior distribution; m0 is the scale parameter of the μ prior distribution, λ0 is the scale parameter of the Λ prior distribution; Λ0 is the parameter of the prior distribution; μ = {μ1,μ2,...μ k},μ k represents the mean vector of the kth mixed distribution component, N(.) represents the probability density function of the Gaussian distribution;
[0178]
[0179] Where p(Λ) represents the conjugate prior distribution of Λ, and Λ obeys the Wishart prior distribution; V0 is the scaling matrix, γ0 is the number of degrees of freedom of the Wishart distribution, Λ={Λ1,Λ2,...Λ k}, Λ k represents the precision matrix of the k-th mixed distribution component, W(.) represents the probability density function of the Wishart distribution;
[0180]
[0181] Where p(ω|α) represents the conjugate prior distribution of ω, and ω obeys the Gaussian prior distribution; ω={ω1,ω2,...ω k},ω k represents the regression coefficient between the leading variable and the auxiliary variable of the kth mixed distribution component; α={α1,α2,...α k}, α k is the regression coefficient ω of the kth mixed distribution component k The precision between ; I represents the identity matrix;
[0182]
[0183] Where p(α) represents the conjugate prior distribution of α, p(β) represents the conjugate prior distribution of β, and both α and β obey the gamma prior distribution; c0 and d0 are the hyperparameters of the α prior distribution, and c0>0, d0>0; e0 and f0 are the hyperparameters of the β prior distribution, and e0>0, f0>0; β={β1,β2,...β k}, β k represents the noise accuracy of the k-th mixed distribution component, and G(.) represents the probability density function of the gamma distribution.
[0184] In this embodiment, based on the auxiliary variables of each labeled sample Construct a labeled K-dimensional binary latent variable Z i and labeled robust variables η i , based on the auxiliary variables of each unlabeled sample Construct an unlabeled K-dimensional binary latent variable Z j and the unlabeled robust variable η j ;
[0185] According to the definition of the mixed model and the independent and identically distributed principle, the K-dimensional binary latent variable Z of the labeled sample is obtained i and unlabeled samples K-dimensional binary latent variables Z j The probability density function of :
[0186]
[0187] in And Z ik Indicates that the i-th labeled sample is assigned to the binary latent variable of the k-th mixed distribution component, Z jk It means that the jth unlabeled sample is assigned to the kth mixed distribution component binary latent variable, and the prior probability of the two is p(Z ik =1) = p(Z jj =1)=g k ;
[0188] According to the definition of the mixed model and the independent and identically distributed principle, the robust variable η of the labeled sample is obtained i and the unlabeled sample robust variable η j The probability density function of :
[0189]
[0190] Among them, η i ={η1,η2,...η NL}, η j ={η1,η2,...η NU}, ν={ν1,ν2,...ν k}, ν k represents the degrees of freedom of the kth mixture distribution component, η ik represents the robust variable that assigns the i-th labeled sample to the k-th mixture distribution component, η jk It means that the j-th unlabeled sample is assigned to the k-th mixture distribution component robust variable.
[0191] According to the Bayesian t-distribution mixture model setting with the sparse autoencoder, the labeled auxiliary variable X and the unlabeled auxiliary variable UL are a mixture of k t-distributions, and the probability density function is expressed as:
[0192]
[0193] S(.) represents the probability density function of t distribution;
[0194] It is understandable that the probability density function of the t distribution is as follows:
[0195]
[0196] where μ and Λ represent the mean vector and covariance matrix, respectively. Unlike the Gaussian distribution, the t-distribution has an additional degree of freedom parameter, ν, which can be used to adjust the tail. When ν = +∞, the t-distribution overlaps with the Gaussian distribution. The Gaussian distribution's fitted curve is significantly affected by outliers, while the t-distribution, due to its long tail, is more robust to outliers and better fits the true probability density curve.
[0197] It is understandable that this application uses a sparse autoencoder (SP-AE). A standard autoencoder works on the same principles as a single-layer neural network, consisting of an input layer, a hidden layer, and an output layer, essentially aiming to equal the input. As shown in Figure 3, this embodiment provides a diagram of a standard autoencoder structure.
[0198] To extract more accurate data features, a sparse constraint is added to the hidden layer of the autoencoder AE to form a sparse autoencoder SP-AE. This sparse constraint has two states: activation and inhibition. The activation state is when the output of the hidden neuron is close to 1, and the inhibition state is when the output of the hidden neuron is close to 0. The sparsity constraint means that the hidden neuron is in the inhibition state most of the time.
[0199] The activation function of SP-AE is:
[0200]
[0201] in, represents the average activity of hidden neuron l, which is the average of hidden neurons l in the training set; Represents the activation of the hidden neuron l of the autoencoder neural network when the input is x.
[0202] At the same time, we can add a similar restriction:
[0203]
[0204] Where ρ is the sparsity parameter, preferably a small value close to 0. In order to achieve this restriction, an additional penalty factor will be added, which will penalize those There are many reasonable choices for the specific form of the penalty factor. Preferably, the following method is selected to make the average activity reach 0:
[0205]
[0206] Where s2 is the number of hidden neurons in the hidden layer and KL(.) is the KL divergence function.
[0207] Exemplarily, the labeled auxiliary variable X and the unlabeled auxiliary variable UL are input into the sparse autoencoder;
[0208] According to the introduction of the penalty factor, the probability density function of the labeled auxiliary variable and the probability density function of the unlabeled auxiliary variable are rewritten as:
[0209]
[0210] The nonlinear activation function sigmoid is used to map the labeled sample auxiliary variable X to the hidden layer of the sparse autoencoder. The hidden layer feature after the labeled sample auxiliary variable X is mapped is h i =(h 1i ,h2i ,...h ki ) T , specifically obtained by the following formula:
[0211]
[0212] in, represents the weight between the hidden layer of the sparse autoencoder and the output layer of the sparse autoencoder; the R is optimized by minimizing the square loss of the estimation error; represents the bias vector, b is obtained by adjusting during the mapping process;
[0213] It is understandable that solving R is done by minimizing the sum of squared losses of the estimation error, as follows:
[0214]
[0215] ‖.‖ represents the paradigm, H is the hidden layer output matrix, and after adding the sparse restriction factor, H is as follows:
[0216]
[0217] By Taking the derivative of R and setting it to 0 can get the optimal solution of R.
[0218] In the Bayesian t-distributed mixture model setting with sparse autoencoders, the labeled dominant variable y in each distribution i and labeled auxiliary variable x i After the sparse autoencoder hides h i The following relationship exists:
[0219] y i =h i ′T ω k +σ k
[0220] in σ k is the measurement noise, σ k ~N(0,β k );
[0221] Therefore, according to the i With h i The relationship between , the probability function of the label-dominant variable Y is obtained as:
[0222]
[0223] Therefore, the labeled auxiliary variable X, the labeled dominant variable Y, the unlabeled auxiliary variable UL, the labeled sample K-dimensional binary latent variable Zi , unlabeled sample K-dimensional binary latent variable Z j , labeled robust variable η i , unlabeled robust variable η j And the joint distribution of each parameter variable is expressed as:
[0224]
[0225] The SP-AE-BTMR hybrid model was constructed.
[0226] It's understandable that the data in the training set is a mixed distribution. In statistics and probability theory, a mixed distribution is a distribution of new random variables generated from multiple random variables. Specifically, a mixed distribution can be composed of multiple components, which can be continuous, such as a normal distribution, each with its own weight. When the means of these distributions are different, the mixed distribution may exhibit a bimodal or multimodal appearance; if the means are equal, this may result in higher kurtosis and more severe tailing.
[0227] S140, inputting the preprocessed training set into a Bayesian t-distributed mixture model with a sparse autoencoder, training the model according to the training set and updating the variational posterior distribution and parameter variable Θ to obtain a trained model;
[0228] like Figure 4 As shown, a flow chart of a model training method provided in this embodiment:
[0229] S141, inputting the preprocessed training set into a Bayesian t-distributed mixture model with a sparse autoencoder, and setting the hyperparameters and end threshold ∈ of the model;
[0230] S142, setting the number of iterative learning times T, and the model iteratively learning the training set;
[0231] S143, estimate the hyperparameters of the parameter variable Θ, and calculate the parameter variable Θ and the labeled K-dimensional binary latent variable Z i , unlabeled K-dimensional binary latent variable Z j , the labeled robust latent variable η i 、The unsigned robust signature latent variable η j The variational posterior distribution and expectation of ;
[0232] S144. Calculate the convergence value after each learning session based on the variational posterior distribution and expectation of each learning session, and determine whether the convergence value meets a preset end threshold. If so, end the learning session; otherwise, continue the learning session.
[0233] This step specifically includes:
[0234] According to the variational Bayesian method, the labeled K-dimensional binary latent variable Z i , unlabeled K-dimensional binary latent variable Z j , labeled robust variable η i , unlabeled robust variable η j and parameter variables Θ are estimated, including:
[0235] p(Z i ,Z j ,η i ,η j ,Θ) is approximate to the distribution of q(Z i ,Z j ,η i ,η j ,Θ)≈q(Z i )q(Z j )q(η i )q(η j )q(Θ), according to the formula of variational inference optimal solution, the labeled K-dimensional binary latent variable Z is obtained i The variational posterior distribution of is:
[0236]
[0237] in and:
[0238]
[0239] Where <·> represents the expected value, ν represents the degree of freedom parameter of the t distribution, and ρ ik is the transition parameter of the entire calculation process;
[0240] The unlabeled K-dimensional binary latent variable Z j The variational posterior distribution of is:
[0241]
[0242] in, and:
[0243]
[0244] Among them, θ jk and δ jk is the transition parameter of the entire calculation process;
[0245] According to the definition of gamma distribution, we get the labeled robust latent variable η i and the unlabeled robust signature latent variable η j The variational posterior distribution of :
[0246]
[0247] Calculate Z ik , Z jk ,η ik ,η jk Expectations and variations:
[0248]
[0249] <Z jk >=δ jk
[0250]
[0251]
[0252] Among them, ψ(.) represents the digamma probability density function;
[0253] The hyperparameter estimation results and the expectations and variations of each parameter variable Θ are:
[0254]
[0255] Among them, a k Expressed as the mixing coefficient g of the kth mixed distribution component k Hyperparameters of
[0256] Calculated according to the variational posterior distribution of g:
[0257]
[0258] The variational posterior of ω is Gaussian, so we get:
[0259]
[0260] Where Tr(.) represents the trace, Φ k , τ k is the transition parameter of the entire calculation process;
[0261] The hyperparameter c of α k =c0+(d+1) / 2, where c k d k Expressed as the accuracy α of the k-th mixture distribution component k The hyperparameters of α are: Since the conjugate variational posterior distribution of α is gamma distribution, it is calculated as:
[0262]
[0263] Among them, q *(α) is the conjugate variational posterior distribution of α;
[0264] Hyperparameter of β Among them, e k 、f k represents the noise accuracy β of the kth mixture distribution component k Hyperparameters; where the conjugate variational posterior distribution of β is gamma distribution, so we can get:
[0265]
[0266] Among them, q * (β) is the conjugate variational posterior distribution of β;
[0267] The hyperparameters of μ and Λ are:
[0268]
[0269] Among them, m k 、V k , γ k Represented as the mean vector μ of the kth mixture distribution component k , and the precision matrix Λ of the kth mixture distribution component k Hyperparameters of
[0270] Since the variational posterior distribution of μ follows a Gaussian distribution and the variational posterior distribution of Λ follows a Wishart distribution, we can calculate:
[0271]
[0272] <μ k >=m k
[0273] <Λ k >=γ k V k
[0274] Among them, q * (μ,Λ) represents the variational posterior distribution of μ and Λ;
[0275] For the degree of freedom ν k , considering it as a deterministic variable, we get the nonlinear equation:
[0276]
[0277] Use Stirling's formula to find the above ν k The solution;
[0278] The lower bound of the evidence is calculated based on the variational posterior of each parameter variable, denoted as Ω q , specifically obtained by the following formula:
[0279] Ω q = <lnp(X,Y,UL,Z i ,Z j ,η i ,η j ,Θ)>- <lnq(Z i ,Z j ,η i ,η j ,Θ)>
[0280] Thus, the convergence condition of iterative learning is obtained:
[0281]
[0282] in, and They represent the lower bounds after the t-th and t-1-th iterative learning respectively, and ∈ represents the end threshold of the assumption; after a learning cycle occurs, when the convergence value calculated after the learning cycle is greater than the end threshold, the model learning ends.
[0283] S150, inputting the test set into the trained model to obtain a final training model;
[0284] Calculate the probability density of the auxiliary variables and the dominant variable of the test set:
[0285] p(x|Z k =1,X)=S(x|m k ,γ k V k ,ν k )
[0286]
[0287] Among them, x is the auxiliary variable of the prediction sample, y is the dominant variable of the prediction sample, and Z k Represents the hidden variable corresponding to the test sample x, Z k =1 means the sample x to be tested belongs to the k-component model;
[0288] The processing of the test set is the same as that of the training set, and the test set is input into the trained model to obtain the final training model.
[0289] S160: Collect data related to furnace tube coking that needs to be predicted, pre-process the data related to furnace tube coking that needs to be predicted, and input it into the final training model to obtain a predicted coking state of the furnace tube.
[0290] Collect the relevant data of furnace tube coking that needs to be predicted, and you can get:
[0291]
[0292] in, This is the predicted coking state of the furnace tube.
[0293] Based on the same inventive concept, the embodiment of the present application also provides a coking diagnosis system based on the SP-AE-BTMR hybrid model, such as Figure 5 As shown, the coking diagnosis system based on the SP-AE-BTMR hybrid model may include:
[0294] Acquisition module 311, pre-processing module 312, model building module 313, training module 314, testing module 315, prediction module 316. Among them:
[0295] An acquisition module 311 is configured to select data related to furnace tube coking as auxiliary variables and the furnace tube coking state as a dominant variable, and to collect historical data of the furnace tubes based on the selected auxiliary variables and dominant variables to construct a training set and a test set;
[0296] In this embodiment, the acquisition module 311 can be used to perform Figure 1 As shown in step S110 , for a detailed description of the acquisition module 311 , reference may be made to the description of step S110 .
[0297] A preprocessing module 312 is used to preprocess the training set and the test set;
[0298] In this embodiment, the pre-processing module 312 can be used to perform Figure 1 As shown in step S120 , for a detailed description of the pre-processing module 312 , reference may be made to the description of step S120 .
[0299] A model building module 313 is used to build a Bayesian t-distributed mixture model with a sparse autoencoder;
[0300] In this embodiment, the model building module 313 can be used to perform Figure 1 As shown in step S130, for a detailed description of the model building module 313, reference may be made to the description of step S130.
[0301] A training module 314 is configured to input the preprocessed training set into a Bayesian t-distributed mixture model with a sparse autoencoder, train the model based on the training set, and update the variational posterior distribution and parameter variable Θ to obtain a trained model;
[0302] In this embodiment, the training module 314 can be used to perform Figure 1 As shown in step S140, for the detailed description of the training module 314, please refer to the description of step S140.
[0303] A testing module 315 is configured to input the test set into the trained model to obtain a final trained model;
[0304] In this embodiment, the test module 315 can be used to perform Figure 1 As shown in step S150, for a detailed description of the testing module 315, reference may be made to the description of step S150.
[0305] The prediction module 316 is used to collect the furnace tube coking related data to be predicted, pre-process the furnace tube coking related data to be predicted, and then input it into the final training model to obtain the predicted furnace tube coking state;
[0306] In this embodiment, the prediction module 316 can be used to perform Figure 1 As shown in step S160 , for a detailed description of the prediction module 316 , reference may be made to the description of step S160 .
[0307] The following describes a technical solution of a coking diagnosis method based on the SP-AE-BTMR hybrid model provided by the present application in conjunction with a specific embodiment.
[0308] In this embodiment, the root mean square error (RMSE) is used to evaluate the performance of different models. The lower the RMSE value, the better the corresponding model performance. The specific formula is as follows:
[0309]
[0310] in Represents the predicted value, y i Represents the true value.
[0311] This example performs predictions in an actual industrial case and uses five existing models and the model proposed in this application to compare the prediction performance of the six models. The experimental data used was collected from 11 tubes in a large petrochemical enterprise's ethylene cracking furnace: tubes 1-1, 2-1, 4-1, and 8-1 in the second pass; tubes 1-1-1-1, 2-2-1-1, 4-2-1-1, 4-4-2-1, and 8-4-1-1 in the fourth pass; tubes 1-1-1-1-1-1, 2-2-2-2-1-1, and 4-2-1-1-1-1 in the sixth pass; and tube 1-1-1-1-1-1-1-1 in the eighth pass. Based on the steam cracking mechanism and expert experience, six auxiliary variables were selected: the tube outlet temperature, tube inlet temperature, tube outer surface temperature, absolute pressure ratio, Venturi pressure, and cross-section pressure. In the actual production process, the coking status of the cracking furnace tubes is divided into four levels: normal, mild, moderate, and severe. Through data preprocessing, a total of 5088 samples were obtained, of which 88 were outlier samples. These samples were divided into a training set of 2000 and a test set of 3000. The comparative test selected partial least squares method (PLSR), Gaussian process regression model (GPR), Bayesian Gaussian mixture regression model (BGMR), Bayesian Gaussian mixture model under semi-supervised model (SBGMR) and Bayesian t distribution mixture model (STMR). The number of iterations is 1000 and the number of training is 100. As Figure 6 As shown, a data distribution diagram of the input space and output space of an actual industrial case dataset is provided. Figure 6 (a) represents the distribution of the overall input of the data set. Figure 6 (b) shows the distribution of coking degree output in the test set.
[0312] According to the above formula, after each comparison model completes the prediction, the RMSE corresponding to each model is calculated, as shown in Table 2:
[0313] Table 2 RMSE of different methods on the test set
[0314]
[0315] Among them, OUR is the model of this application: SP-AE-BTMR hybrid model.
[0316] The table shows that the PLSR and BPR models perform poorly when trained on nonlinear data. A comparison of the BGMR and SBGMR models shows that hybrid models perform much better than single models when trained on multiple operating conditions. BGMR exhibits greater volatility compared to SBGMR, due to the semi-supervised model's ability to better train on unlabeled samples. Due to the strong nonlinearity of industrial processes, BGMR, SBGMR, and BSMR all experience performance degradation. However, the SP-AE-STMR model, due to its incorporation of a sparse autoencoder structure, can learn even with missing data and extract useful information from nonlinear features, resulting in less degradation. In summary, the SP-AE-STMR model achieves better fitting results than the other models.
[0317] In order to verify the robustness of the model and its supervision in the case of missing labels, 1% and 5% outliers were added to the model training set, and training was performed according to different label ratios. The training results are shown in Table 3 below:
[0318] Table 3 RMSE of the model with outliers on the test set
[0319]
[0320]
[0321] Table 3 shows that supervised models such as PLSR, GPR, and BGMR perform poorly when adding 1% and 5% outliers. Although SBGMR is a semi-supervised model, it uses a Gaussian distribution and is suitable for linear learning. It does not perform well with nonlinear data features and lacks the long tail and robustness of the t-distribution in the presence of outliers, leading to a sharp deterioration in model performance. Compared to other models, our model performs better.
[0322] like Figure 7 As shown, provided by Figure 7 (a) It can be seen that the PLSR single model is insufficient in multi-condition industrial processes, and the overall fitting effect is not good; Figure 7 (b) It can be seen that the GPR model has underfitting in the sample intervals of 700-900 and 2100-2700. Compared with the Bayesian mixture model, it is not sensitive to the randomness of the model parameters of low-dimensional data and the fitting results are poor. The other Bayesian models are mixture models and are more suitable for multiple working conditions. Figure 7 (c) It can be seen that the BGMR model is underfitting in the entire sample; Figure 7(d) It can be seen that the semi-supervised Gaussian mixture regression model SBGMR has a better fitting effect than the previous ones, but the fitting effect is poor in the sample intervals of 250-270 and 2600-2700; and BGMR and SBGMR are contaminated by outliers, which leads to inaccurate learning of the mean and covariance matrices of these two methods, resulting in underfitting of one model and overfitting of the other. Figure 7 As shown in (e), for the BTMR model, because it is a mixed t-distribution model, the model is not sensitive to outliers, but with supervised learning, it is difficult to ensure the accuracy of parameter learning when there is less labeled data and more obvious nonlinearity. Figure 7 As shown in (f), our model SP-AE-STMR uses a sparse autoencoder and a t-distribution mixture, which is not only insensitive to outliers but also can combine labeled and unlabeled samples to train the nonlinear parameters of the model, which can train more accurate and reliable model parameters, thereby improving the estimation performance of the model.
[0323] Obviously, the above embodiments of the present invention are merely examples for the purpose of clearly illustrating the technical solutions of the present invention, and are not intended to limit the specific implementation methods of the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the claims of the present invention shall be included within the scope of protection of the claims of the present invention.
Claims
1. A coking diagnosis method based on the SP-AE-BTMR hybrid model, characterized in that: The method comprises: Select data related to furnace tube coking as auxiliary variables, and furnace tube coking status as a dominant variable, and based on the selected auxiliary variables and dominant variables, collect historical data of furnace tubes to construct a training set and a test set; Preprocessing the training set and the test set; Construct a Bayesian t-distributed mixture model with a sparse autoencoder; Inputting the preprocessed training set into a Bayesian t-distribution mixed model with a sparse autoencoder, training the model according to the training set and updating the variational posterior distribution and parameter variable Θ to obtain a trained model; Inputting the test set into the trained model to obtain a final training model; The furnace tube coking related data to be predicted are collected, and the furnace tube coking related data to be predicted are pre-processed and input into the final training model to obtain the predicted coking state of the furnace tube.
2. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to claim 1, characterized in that: The collecting of historical data of furnace tubes to construct training sets and test sets based on the selected auxiliary variables and dominant variables specifically includes: The training set includes a labeled training set and an unlabeled training set; The labeled training set includes a plurality of labeled samples, and the labeled samples include labeled auxiliary variables and labeled dominant variables. The method for collecting the labeled auxiliary variables and the labeled dominant variables specifically includes: During the furnace tube production process, labeled auxiliary variables are collected and the corresponding labeled dominant variable Among them, the labeled auxiliary variable X is an input matrix, the labeled dominant variable Y is an output matrix, N L Represents the number of labeled samples; The unlabeled training set includes a plurality of unlabeled samples, and the unlabeled samples include unlabeled auxiliary variables. The unlabeled auxiliary variable collection method specifically includes: During the furnace operation, unlabeled auxiliary variables are collected Among them, the unlabeled auxiliary variable UL is an input matrix, N U Represents the number of unlabeled samples; Among them, labeled auxiliary variables and unlabeled auxiliary variables are collected based on the furnace tube data of the same dimension, x i Represents the auxiliary variable of the i-th labeled sample, ul j Represents the auxiliary variable of the jth unlabeled sample, y i represents the dominant variable of the i-th labeled sample, x i ∈R d ,ul i ∈R d ,y i ∈R, d represents the dimensions of the labeled auxiliary variables and the unlabeled auxiliary variables.
3. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to claim 2, characterized in that: The preprocessing of the training set and the test set specifically includes: The relationship between the number of samples in the labeled training set and the number of samples in the unlabeled training set is determined by a preset labeled rate LR; wherein the labeled rate LR represents the proportion of the labeled training set to the entire training set; The labeled training set is additionally added with labeled outliers, and the unlabeled training set is additionally added with unlabeled outliers; wherein the proportion of the labeled outliers in the labeled training set is equal to the proportion of the unlabeled outliers in the unlabeled training set.
4. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to claim 2, characterized in that: The construction of the Bayesian t-distribution mixed model with a sparse autoencoder specifically includes: The model parameters of the Bayesian t-distribution mixed model with the sparse autoencoder are learned, and the parameter variables Θ={g, μ, Λ, ω, α, β} are constructed, wherein g represents the mixing coefficient of the mixed distribution component of the training set, μ represents the mean vector of the mixed distribution component of the training set, Λ represents the precision matrix of the mixed distribution component of the training set, ω represents the regression coefficient between the leading variable and the auxiliary variable of the mixed distribution component of the training set, α represents the precision between the regression coefficients of the mixed distribution component of the training set, and β represents the noise precision of the mixed distribution component of the training set; Assign the corresponding conjugate prior distribution to the parameters in the parameter variable Θ, including: Where p(g) represents the conjugate prior distribution of g, and g obeys the Dirichlet prior distribution; a0 is the hyperparameter of the prior distribution of g, and a0>0; K represents the total number of mixture components, g={g1,g2,...g k }, g k represents the mixing coefficient of the kth mixed distribution component; Γ(.) represents the probability density function of the Dirichlet distribution; Where p(μ|Λ) represents the conjugate prior distribution of μ, and μ obeys a Gaussian prior distribution; m0 is the scale parameter of the μ prior distribution, λ0 is the scale parameter of the Λ prior distribution, and Λ0 is the parameter of the prior distribution; μ={μ1,μ2,...μ k },μ k represents the mean vector of the kth mixed distribution component, N(.) represents the probability density function of the Gaussian distribution; Where p(Λ) represents the conjugate prior distribution of Λ, and Λ obeys the Wishart prior distribution; V0 is the scaling matrix, γ0 is the number of degrees of freedom of the Wishart distribution, Λ={Λ1,Λ2,...Λ k },Λ k represents the precision matrix of the kth mixed distribution component, W(.) represents the probability density function of the Wishart distribution; Where p(ω|α) represents the conjugate prior distribution of ω, and ω obeys the Gaussian prior distribution; ω={ω1,ω2,...ω k },ω k represents the regression coefficient between the leading variable and the auxiliary variable of the kth mixed distribution component; α={α1,α2,...α k }, α k is the regression coefficient ω of the kth mixed distribution component k The precision between ; I represents the identity matrix; Where p(α) represents the conjugate prior distribution of α, p(β) represents the conjugate prior distribution of β, and both α and β obey the gamma prior distribution; c0 and d0 are the hyperparameters of the α prior distribution, and c0>0, d0>0; e0 and f0 are the hyperparameters of the β prior distribution, and e0>0, f0>0; β={β1,β2,...β k }, β k represents the noise accuracy of the kth mixed distribution component, and G(.) represents the probability density function of the gamma distribution.
5. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to claim 4, characterized in that: The Bayesian t-distribution mixed model with a sparse autoencoder also includes: Based on each labeled sample auxiliary variable Construct a labeled K-dimensional binary latent variable Z i and a labeled robust variable η i , based on the auxiliary variables of each unlabeled sample Construct an unlabeled K-dimensional binary latent variable Z j and the unlabeled robust variable η j ; According to the definition of the mixed model and the principle of independent and identical distribution, the K-dimensional binary latent variable Z of the labeled sample is obtained. i and unlabeled samples K-dimensional binary latent variables Z j The probability density function of is: in And Z ik Indicates that the i-th labeled sample is assigned to the binary latent variable of the k-th mixed distribution component, Z jk It means that the jth unlabeled sample is assigned to the kth mixed distribution component binary latent variable, and the prior probability of the two is p(Z ik =1) = p(Z jk =1) = g k ; According to the definition of the mixed model and the principle of independent and identical distribution, the robust variable η of the labeled sample is obtained i and the unlabeled sample robust variable η j The probability density function of is: Among them, η i ={η1,η2,...η NL }, η j ={η1,η2,...η NU }, ν={ν1,ν2,...ν k }, ν k represents the degrees of freedom of the kth mixture distribution component, η ik represents the robust variable that assigns the i-th labeled sample to the k-th mixed distribution component, η jk It means that the j-th unlabeled sample is assigned to the k-th mixture distribution component robust variable.
6. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to claim 5, characterized in that: The construction of the Bayesian t-distribution mixed model with a sparse autoencoder also includes: According to the Bayesian t-distribution mixed model setting with the sparse autoencoder, the labeled auxiliary variable X and the unlabeled auxiliary variable UL are a mixture of k t-distributions, and the probability density function is expressed as: S(.) represents the probability density function of t distribution; Input the labeled auxiliary variable X and the unlabeled auxiliary variable UL into the sparse autoencoder; According to the sparse autoencoder definition, represents the average activity of hidden neurons in the labeled auxiliary variables and the unlabeled auxiliary variables, and ρ is the sparsity parameter, where a restriction condition needs to be added: And introduce an additional penalty factor, The case where the average activity of the hidden neuron is significantly different from ρ is penalized so that the average activity of the hidden neuron is kept within a small range, which is specifically achieved in the following way: Where s2 is the number of hidden neurons in the hidden layer of the sparse autoencoder, and KL(.) represents the KL divergence function; According to the introduction of the penalty factor, the probability density function of the labeled auxiliary variable and the probability density function of the unlabeled auxiliary variable are rewritten as: The nonlinear activation function sigmoid is used to map the labeled sample auxiliary variable X to the hidden layer of the sparse autoencoder. The hidden layer feature of the labeled sample auxiliary variable X after mapping is h i =(h 1i ,h 2i ,...h ki ) T , which is obtained by the following formula: in, represents the weight between the hidden layer of the sparse autoencoder and the output layer of the sparse autoencoder; the R finds the optimal solution by minimizing the square loss of the estimation error; represents the bias vector, b is obtained by adjusting in the mapping process; In the Bayesian t-distribution mixed model setting with sparse autoencoders, the labeled dominant variable y in each distribution i and a labeled auxiliary variable x i After the sparse autoencoder hides h i The following relationship exists: y i =h i ′T oh k +s k in σ k is the measurement noise, σ k ~N(0,β k ); Therefore, according to the i With h i The relationship between , the probability function of the label-dominant variable Y is obtained as: Therefore, the labeled auxiliary variable X, the labeled dominant variable Y, the unlabeled auxiliary variable UL, and the labeled sample K-dimensional binary latent variable Z i , unlabeled sample K-dimensional binary latent variable Z j , labeled robust variables η i , unlabeled robust variable η j And the joint distribution of each parameter variable is expressed as: The SP-AE-BTMR hybrid model is constructed.
7. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to any one of claim 1, characterized in that: The preprocessed training set is input into a Bayesian t-distribution mixed model with a sparse autoencoder, the model is trained according to the training set and the variational posterior distribution and parameter variable Θ are updated to obtain a trained model, specifically including: Input the preprocessed training set into a Bayesian t-distribution mixed model with a sparse autoencoder, and set the hyperparameters and end threshold ∈ of the model; Setting the number of iterative learning times T, the model performs iterative learning on the training set; Estimate the hyperparameters of the parameter variable Θ, and calculate the parameter variable Θ and the labeled K-dimensional binary latent variable Z i , unlabeled K-dimensional binary latent variable Z j , the labeled robust latent variable η i , the unsigned robust signature hidden variable η j The variational posterior distribution and expectation of ; According to the variational posterior distribution and expectation of each learning, the convergence value after each learning is calculated, and it is determined whether the convergence value meets the preset end threshold. If the end threshold is met, the learning is terminated, otherwise the learning continues.
8. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to any one of claim 7, characterized in that: The step of calculating the convergence value after each learning according to the variational posterior distribution and expectation of each learning, and judging whether the convergence value satisfies a preset end threshold, and terminating the learning if the end threshold is satisfied, otherwise continuing the learning, specifically includes: According to the variational Bayes method, the labeled K-dimensional binary latent variable Z u , unlabeled K-dimensional binary latent variable Z j , labeled robust variables η i , unlabeled robust variable η j and parameter variables Θ are estimated, including: p(Z i ,Z j ,η i ,η j ,Θ) is set to q(Z i ,Z j ,η i ,η j ,Θ)≈q(Z i )q(Z j )q(η i )q(η j )q(Θ), according to the formula of variational inference optimal solution, the labeled K-dimensional binary latent variable Z is obtained i The variational posterior distribution of is: in and: Where <·> represents the expected value, ν represents the degree of freedom parameter of the t distribution, and ρ ik is the transition parameter of the whole calculation process; The unlabeled K-dimensional binary latent variable Z j The variational posterior distribution of is: in, and: Among them, θ jk and δ jk is the transition parameter of the whole calculation process; According to the definition of gamma distribution, we get the labeled robust latent variable η i and unlabeled robust signed latent variable η j The variational posterior distribution of : Calculate Z ik , Z jk , η ik , η jk Expectations and variations: <Z jk >=d jk Among them, ψ(.) represents the probability density function of digamma; The hyperparameter estimation results and the expectations and variations of each parameter variable Θ are: Among them, a k Expressed as the mixing coefficient g of the kth mixed distribution component k Hyperparameters of According to the variational posterior distribution of g, it is calculated as: The variational posterior of ω is Gaussian, so we get: Where Tr(.) represents the trace, Φ k , τ k is the transition parameter of the whole calculation process; Hyperparameters of α where c k ,d k Expressed as the precision α of the kth mixed distribution component k Hyperparameters; Since the conjugate variational posterior distribution of α is gamma distribution, it is calculated as: Among them, q * (α) is the conjugate variational posterior distribution of α; Hyperparameters of β Among them, e k 、f k represents the noise accuracy β of the kth mixed distribution component k Hyperparameters; where the conjugate variational posterior distribution of β is gamma distribution, so we can get: Among them, q * (β) is the conjugate variational posterior distribution of β; The hyperparameters of μ and Λ are: Among them, m k 、V k , γ k Represented as the mean vector μ of the kth mixture distribution component k , and the precision matrix Λ of the kth mixture distribution component k Hyperparameters of Since the variational posterior distribution of μ follows a Gaussian distribution and the variational posterior distribution of Λ is a Wishart distribution, we can calculate: <μ k >=m k <L k >=c k V k Among them, q * (μ,Λ) represents the variational posterior distribution of μ and Λ; For the degree of freedom ν k , treating it as a deterministic variable to obtain the nonlinear equation: Using Stirling's formula, we can find the above ν k The solution; The lower bound of the evidence is calculated based on the variational posterior of the parameter variable, denoted as Ω q , which is obtained by the following formula: Oh q = <lnp(X,Y,UL,Z i ,Z j ,or i ,or j ,Θ)>- <lnq(Z i ,Z j ,or i ,or j ,Θ)> Thus, the convergence condition of iterative learning is obtained: in, and They represent the lower bounds after the t-th and t-1-th iterative learning respectively, ∈ represents the end threshold of the assumption; after there exists a learning cycle such that the convergence value calculated after the learning cycle is greater than the end threshold, the model learning ends.
9. A coking diagnosis method based on the SP-AE-BTMR hybrid model according to any one of claim 1, characterized in that: Collect the data related to the coking of the furnace tubes to be predicted, pre-process the data related to the coking of the furnace tubes to be predicted, and input them into the final training model to obtain the predicted coking state of the furnace tubes, which specifically includes: Collect the relevant data of furnace tube coking that needs to be predicted, and you can get: in, That is the predicted coking state of the furnace tube.
10. A coking diagnosis system based on the SP-AE-BTMR hybrid model, characterized in that: include: A collection module, used for selecting data related to furnace tube coking as auxiliary variables, and furnace tube coking status as a dominant variable, and collecting historical data of furnace tubes to construct training sets and test sets based on the selected auxiliary variables and dominant variables; A preprocessing module, used for preprocessing the training set and the test set; Build model module, which is used to build Bayesian t-distributed mixture model with sparse autoencoder; A training module, used for inputting the preprocessed training set into a Bayesian t-distribution mixed model with a sparse autoencoder, training the model according to the training set and updating the variational posterior distribution and parameter variable Θ to obtain a trained model; A testing module, used for inputting the test set into the trained model to obtain a final training model; The prediction module is used to collect the furnace tube coking related data that needs to be predicted, pre-process the furnace tube coking related data that needs to be predicted, and input them into the final training model to obtain the predicted coking state of the furnace tube.