Chemical process abnormality monitoring method and model optimization method based on semi-supervised model
By adopting an abnormality monitoring method based on a semi-supervised model in the chemical process, the number of hidden layers and noise range are optimized, and the problem of difficult identification of chemical equipment process abnormalities is solved, which improves the accuracy of identification and production safety.
Patent Information
- Application Number
- CN202010450943.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-05-25
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2040-05-25
AI Technical Summary
During operation, process abnormalities caused by raw material changes, instrument failures, etc. of chemical equipment are difficult to quickly and accurately identify, resulting in misjudgment or misoperation, which may cause product quality decline, safety risks and production fluctuations.
The chemical process abnormality monitoring method based on the semi-supervised model is adopted. By adjusting the number of layers and noise range of the hidden layer, the semi-supervised model is optimized to adapt to scenarios with few label data and many label data, and the accuracy of abnormal identification is improved.
It realizes effective identification of abnormal working conditions in chemical processes, reduces the risk of misjudgment and misoperation, and improves production safety and stability.
Smart Images

Figure CN113723649B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of chemical engineering, and in particular to a chemical process abnormality monitoring method and a model optimization method based on a semi-supervised model. Background Art
[0002] During the operation of chemical plants, disturbances such as raw material feed volume, changes in raw material properties, instrument failures, or untimely operations may cause process abnormalities.
[0003] The inventors have found through investigation that the existing identification and early warning methods for abnormal operating conditions in chemical plants are still based on automatic instrument detection data and rely on manual experience to analyze and deal with them.
[0004] However, abnormal operating conditions in chemical plants are highly concealed and have many related factors, which makes it difficult to detect abnormalities quickly and accurately using manual monitoring methods. This can easily lead to misjudgments or misoperations, which in turn may cause a decline in product quality or output, or even affect production operation safety, causing production fluctuations and unplanned shutdowns, and even serious accidents.
[0005] Since chemical plants are continuous production processes, in actual production, each process variable basically fluctuates around its set value. There are not many time windows for abnormal fluctuations, and the number of variables involved in local abnormal fluctuations is not too large. Therefore, for abnormal conditions of process operation in chemical processes, the data annotation cost is expensive, and it is very difficult to build a large-scale and well-annotated data set. In addition, since many abnormal features are not obvious, in the case of less labeled process data, traditional deep learning methods are prone to network overfitting, resulting in a significant decrease in detection accuracy, which limits the development and application of traditional deep learning networks in the field of process fault diagnosis. Summary of the invention
[0006] The purpose of the embodiments of the present invention is to provide a chemical process abnormality monitoring method and a model optimization method based on a semi-supervised model. This method can provide a high-quality semi-supervised model for the chemical process, which is used to solve the problem of process anomaly identification when there are few labeled sample data and many unlabeled sample data in the industrial site.
[0007] In order to achieve the above-mentioned purpose, an embodiment of the present invention provides an optimization method for a semi-supervised model for identifying chemical process anomalies, wherein a first initial semi-supervised model is obtained by training with a first training set, wherein the first training set is the operating condition data of a section of the chemical process, and has labeled data and unlabeled data that constitute an initial preset ratio, and the optimization method comprises: determining a loss value of the first initial semi-supervised model, wherein the loss value is obtained by a loss function; comparing the loss value of the first initial semi-supervised model with a preset loss value; adjusting the number of hidden layers according to a comparison result between the loss value and the preset loss value, so as to determine a range of the number of hidden layers corresponding to the semi-supervised model that satisfies the condition that the loss value is less than the preset loss value; and establishing a new semi-supervised model with a number of hidden layers within the range of the number of hidden layers, wherein the new semi-supervised model is an optimized semi-supervised model.
[0008] Optionally, the optimization method also includes determining the range of the number of layers of the hidden layer in the following manner: determining the lower limit number of layers according to the following steps: determining the first loss value of the semi-supervised model corresponding to the first number of layers; when the first loss value is greater than the preset loss value, adjusting the first number of layers to a first preset multiple and rounding it as a new first number of layers to establish a new first semi-supervised model; and repeating the above steps to determine the lower limit number of layers of the hidden layer corresponding to the semi-supervised model whose loss value is less than the preset loss value; determining the upper limit number of layers according to the following steps: determining the second loss value of the semi-supervised model corresponding to the second number of layers, the second number of layers being greater than the first number of layers; when the second loss value is greater than the preset loss value, adjusting the second number of layers to a second preset multiple and rounding it as a new second number of layers to establish a new second semi-supervised model; and repeating the above steps to determine the upper limit number of layers of the hidden layer corresponding to the semi-supervised model whose loss value is less than the preset loss value; and using the upper limit number of layers as the upper limit value of the range of the number of layers of the hidden layer, and using the lower limit number of layers as the lower limit value of the range of the number of layers of the hidden layer.
[0009] Optionally, after determining the range of the number of hidden layers corresponding to the semi-supervised model in which the loss value is less than the preset loss value, the optimization method further includes performing the following steps for the number of hidden layers selected within the range of the number of hidden layers: selecting initial noise to determine a second initial semi-supervised model; comparing the loss value of the second initial semi-supervised model with the preset loss value; adjusting the noise based on the comparison result of the loss value and the preset loss value to determine the noise range corresponding to the semi-supervised model that satisfies the requirement that the loss value is less than the preset loss value; and establishing a new semi-supervised model with the number of hidden layers selected from the range of the number of hidden layers and the noise selected from the noise range, wherein the new semi-supervised model is the optimized semi-supervised model.
[0010] Optionally, for the number of hidden layers selected within the range of the number of hidden layers, the optimization method also includes determining the noise range in the following manner: determining a third loss value of the semi-supervised model corresponding to the first noise; when the third loss value is greater than the preset loss value, adjusting the first noise to a third preset multiple as a new first noise to establish a new third semi-supervised model; and repeating the above operations to determine the noise range corresponding to the semi-supervised model whose loss value is less than the preset loss value.
[0011] Optionally, the optimization method also includes determining the range of the noise in the following manner: determining the lower limit noise according to the following steps: determining the third loss value of the semi-supervised model corresponding to the first noise; when the third loss value is greater than the preset loss value, adjusting the first noise to a third preset multiple as the new first noise to establish a new third semi-supervised model; and repeating the above steps to determine the lower limit noise corresponding to the semi-supervised model whose loss value is less than the preset loss value; determining the upper limit noise according to the following steps: determining the fourth loss value of the semi-supervised model corresponding to the second noise, the first noise being less than the second noise; when the fourth loss value is greater than the preset loss value, adjusting the second noise to a fourth preset multiple as the new second noise to establish a new fourth semi-supervised model; repeating the above steps to determine the upper limit noise corresponding to the semi-supervised model whose loss value is less than the preset loss value; and using the upper limit noise as the upper limit value of the noise range, and the lower limit noise as the lower limit value of the noise range.
[0012] Optionally, after determining the range of the number of hidden layers and the noise range corresponding to the semi-supervised model whose loss value is less than the preset loss value, the optimization method also includes performing the following steps for the number of hidden layers selected within the range of the number of hidden layers and the noise selected within the noise range: converting a preset number of labeled data in the first training set into unlabeled data, so that the ratio of labeled data to unlabeled data is reduced to a second preset ratio, thereby forming a second training set; establishing a third initial semi-supervised model based on the second training set, the selected number of hidden layers and the selected noise; comparing the loss value of the third initial semi-supervised model with the preset loss value; and if the loss value of the third initial semi-supervised model is less than the preset loss value, repeating the above operations until the minimum ratio range of labeled data to unlabeled data in the training set corresponding to the semi-supervised model whose loss value is less than the preset loss value is determined.
[0013] Optionally, there are N labeled data and M unlabeled data in the training set, and the loss function of the semi-supervised model is determined in the following way: perform supervised training on the N labeled data to obtain a supervised error loss function C1; perform unsupervised training on the M unlabeled data to obtain an unsupervised error loss function C2; and determine the loss function C based on the supervised error loss function C1 and the unsupervised error loss function C2.
[0014] Optionally, the loss function C is determined in the following manner:
[0015] Optionally, the operating condition is a normal operating condition, a temporary interruption of the reboiler heating steam supply, a failure of a distillation tower bottom liquid level regulator, a change in feed composition, or a temporary interruption of system instrument air.
[0016] Correspondingly, an embodiment of the present invention also provides a chemical process abnormality monitoring method based on a semi-supervised model, the abnormality monitoring method comprising: collecting current data on the operating conditions of the work section of the chemical process; and using the current data as input of an optimized semi-supervised model to identify whether the current data is abnormal based on the result output by the optimized semi-supervised model, wherein the optimized semi-supervised model is obtained after optimization using the optimization method of the semi-supervised model for chemical process anomaly identification as described above.
[0017] Optionally, the abnormality monitoring method also includes acquiring the current data through one or more of the following devices: a DCS system, a PLC system, an instrument electrical signal acquisition system, a combustible gas detection system, and a video monitoring system.
[0018] Optionally, the abnormality monitoring method further includes: storing data related to the working condition and results output by the semi-supervised model.
[0019] Optionally, the abnormality monitoring method also includes: displaying the recognition result output by the semi-supervised model.
[0020] On the other hand, the present invention provides a machine-readable storage medium having instructions stored thereon, the instructions being used to enable a machine to execute any one of the above-described methods for optimizing a semi-supervised model for identifying chemical process anomalies described in the present application; and / or any one of the above-described methods for monitoring chemical process anomalies based on a semi-supervised model described in the present application.
[0021] Through the above technical scheme, a reasonable adjustment of the number of hidden layers is proposed to achieve rapid optimization of the semi-supervised model. The optimized semi-supervised model will not have a high loss value of the semi-supervised model caused by underfitting or overfitting of the data, and can also be used in chemical process anomaly identification with little labeled data.
[0022] Other features and advantages of the embodiments of the present invention will be described in detail in the subsequent detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present invention, but do not constitute a limitation on the embodiments of the present invention. In the accompanying drawings:
[0024] Figure 1 It is a flow chart of an optimization method of a semi-supervised model for identifying abnormalities in chemical processes provided by an embodiment of the present invention;
[0025] Figure 2 is a flow chart of a method for determining a noise range provided by an embodiment of the present invention;
[0026] Figure 3 is a flow chart of a method for determining a training set ratio provided by an embodiment of the present invention;
[0027] Figure 4 It is a schematic flow chart of the principle of the optimization method of the semi-supervised model for chemical process anomaly identification provided by an embodiment of the present invention;
[0028] Figure 5 It is a schematic diagram of the recognition accuracy of working condition 3;
[0029] Figure 6 It is a schematic diagram of the recognition accuracy of working condition 4;
[0030] Figure 7 It is a schematic diagram of the recognition accuracy of model 2 for working condition 3 under different proportions of label sample data;
[0031] Figure 8 It is a flow chart of a chemical process abnormality monitoring method based on a semi-supervised model provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0032] The specific implementation of the embodiment of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present invention, and is not used to limit the embodiment of the present invention.
[0033] The terms "first", "second", etc. in the embodiments of the present invention are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" or "second" may explicitly or implicitly include at least one of the features.
[0034] Since the model established by the traditional deep learning method is not suitable for the scene of chemical equipment and chemical process anomaly identification, the semi-supervised model obtained by the semi-supervised learning method is selected and applied to the scene, and when there is a large amount of unlabeled data, an output result with high accuracy can be obtained. Considering that the higher the accuracy of the semi-supervised model, the higher the reliability of its anomaly identification result for the chemical process, and the accuracy of the semi-supervised model is affected by multiple parameters, the embodiment of the present invention provides an optimization method of a semi-supervised model for chemical process anomaly identification.
[0035] Before adopting the optimization method provided by the embodiment of the present invention, it is necessary to use the existing data to pre-establish a first initial semi-supervised model, and optimize it based on the first initial semi-supervised model. The first initial semi-supervised model is obtained by training a first training set having labeled data and unlabeled data constituting an initial preset ratio. The data in the training set can be the working condition data of the actual section or the working condition data of the simulation section experiment. The working condition data can be not only abnormal working condition data, but also normal working condition data.
[0036] For example, the operating condition data may be data of normal operating conditions, temporary interruption of heating steam supply to the reboiler E-702, failure of the bottom liquid level regulator of the distillation tower C-701, changes in material composition (increased C4 content), or temporary interruption of system instrument air, and the operating conditions and operating condition data involved may be different depending on the chemical process.
[0037] Embodiment 1
[0038] Figure 1 FIG. 1 is a flow chart of an optimization method for a semi-supervised model for identifying abnormalities in a chemical process provided by an embodiment of the present invention. Figure 1 As shown, an embodiment of the present invention provides an optimization method for a semi-supervised model for identifying abnormalities in chemical processes, and the optimization method includes steps S110 and S140.
[0039] In step S110, a loss value of the first initial semi-supervised model is determined.
[0040] For the semi-supervised model, its loss value is determined by the loss function and the test set data.
[0041] The semi-supervised model is obtained by performing supervised training on the labeled data in the training set and unsupervised training on the unlabeled data in the training set. Therefore, the supervised error loss function and the unsupervised error loss function can be determined respectively, and the loss function of the semi-supervised model is determined based on the supervised error loss function and the unsupervised error loss function.
[0042] For example, there are N labeled data and M unlabeled data in the training set, and N << M. Denote the supervised error loss function as C1 and the unsupervised error loss function as C2. Then the total loss function C can be determined by the following formula: This formula is only for illustrative purposes. In the application process, those skilled in the art can select the loss function according to actual needs to determine the corresponding loss value.
[0043] In order to more intuitively reflect the optimization of the semi-supervised model, during the optimization process, it is preferably to use the same test set to determine the loss value of each subsequent semi-supervised model. For example, through the test set, the loss value corresponding to the supervised model and the loss value corresponding to the unsupervised model can be determined respectively, and then the total loss value can be determined according to the corresponding loss function. The loss values mentioned later in this specification are all the overall loss values of the semi-supervised model.
[0044] In step S120, compare the loss value of the first initial semi-supervised model with the loss preset value.
[0045] Among them, the loss preset value is the expected loss value, which can be set according to actual needs. For example, according to the different loss functions and test set data, the loss preset value can be set as a percentage or a specific value.
[0046] In step S130, according to the comparison result of the loss value and the loss preset value, adjust the number of hidden layers to determine the range of the number of hidden layers corresponding to the semi-supervised model that satisfies the condition that the loss value is less than the loss preset value.
[0047] When adjusting the number of hidden layers, it should be noted to adjust the number of hidden layers to a suitable range. When the number of hidden layers is too small, the processing ability of the semi-supervised model will be weak. If the number of hidden layers is too large, it will cause overfitting of the data, resulting in unreliable output results of the semi-supervised model.
[0048] On this basis, the embodiment of the present invention provides a method that can quickly determine the range of the number of hidden layers that meets the requirements. The method can first establish two semi-supervised models and adjust the number of hidden layers according to their respective output results at the same time, or establish two semi-supervised models successively and adjust the number of hidden layers according to their respective output results respectively.
[0049] Now, an explanation will be given by taking the determination of the lower limit number of layers in the range of the number of hidden layers as an example: first, a first number of layers is preset, and a semi-supervised model is constructed based on the first number of layers, and a first loss value of the semi-supervised model corresponding to the first number of layers is determined (the method for determining the loss value may be the same as the method for determining in step S102); the first loss value is compared with the preset loss value; when the first loss value is greater than the preset loss value, it is determined that the accuracy of the semi-supervised model constructed by the current number of layers is not reliable enough, and therefore the first number of layers needs to be adjusted to a first preset multiple and then rounded, and the layer value obtained after rounding is used as the new first number of layers to establish a new first semi-supervised model; the above steps of determining the loss value, comparing the loss values, and adjusting the number of hidden layers are repeated until a semi-supervised model with a loss value less than the preset loss value is obtained, and the number of layers corresponding to the semi-supervised model is used as the lower limit number of hidden layers.
[0050] The method for determining the upper limit of the number of layers in the range of the hidden layer is similar to the method for determining the lower limit of the number of layers in the range of the hidden layer mentioned above: first preset the second number of layers, and construct a semi-supervised model based on the second number of layers, and determine the second loss value of the semi-supervised model corresponding to the second number of layers; compare the first loss value with the preset loss value; when the second loss value is greater than the preset loss value, it is determined that the accuracy of the semi-supervised model constructed by the current number of layers is not reliable enough, so it is necessary to adjust the second number of layers to the second preset multiple and then round it, and use the layer value obtained after rounding as the new second number of layers to establish a new second semi-supervised model; repeat the above steps of determining the loss value, comparing the loss value, and adjusting the number of hidden layers until a semi-supervised model with a loss value less than the preset loss value is obtained, and use the number of layers corresponding to the semi-supervised model as the upper limit of the hidden layer.
[0051] Optionally, the adjustment method of the first number of layers and the second number of layers can be arbitrary. When adjusting the number of layers, reasonable adjustments can be made according to the complexity of the actual chemical process section. For example, the higher the complexity, the larger the selection of the first number of layers and the second number of layers, and the first preset multiple and the second preset multiple can also be increased accordingly.
[0052] Generally, in order to quickly determine the range of the number of hidden layers, it is necessary to select a smaller first number of layers and a larger second number of layers for adjustment.
[0053] Optionally, when the first preset multiple is an integer, it is not necessary to round the first number of layers after adjusting it to the first preset multiple, and the same applies to the second number of layers and the second preset multiple.
[0054] Optionally, when the first preset multiple and the second preset multiple are not positive numbers, the numbers after adjusting the preset multiples can be reasonably rounded according to actual needs. For example, the first number of floors can be adjusted to the first preset multiple and the lower integer can be taken as the new first number of floors, and the second number of floors can be adjusted to the second preset multiple and the upper integer can be taken as the new second number of floors.
[0055] In step S140, a new semi-supervised model is established with a number of hidden layers within the range of the number of hidden layers, and the new semi-supervised model is an optimized semi-supervised model.
[0056] After determining the lower limit and upper limit of the number of hidden layers, the loss values of the semi-supervised model corresponding to the layers between the lower limit and the upper limit all meet the preset loss values. The appropriate number of layers can be directly selected from the range of the number of hidden layers formed by the lower limit and the upper limit to construct a semi-supervised model for chemical process anomaly identification, so as to complete the optimization of the semi-supervised model.
[0057] The technical solution provided by the embodiment of the present invention proposes a reasonable adjustment of the number of hidden layers to achieve rapid optimization of the semi-supervised model, and the situation in which the loss value of the semi-supervised model is high due to underfitting or overfitting of the data will not occur.
[0058] Embodiment 2
[0059] After a reasonable range of the number of hidden layers of the semi-supervised model has been determined, noise can be added to the semi-supervised model to further improve the recognition accuracy of the semi-supervised model for input data.
[0060] Taking into account that when adding different noises, the data output by the semi-supervised model whose loss value is already less than the preset loss value will reappear under-fitting or over-fitting, resulting in the loss value of the semi-supervised model after adding noise no longer being less than the preset loss value, an embodiment of the present invention also provides a noise adjustment method for a semi-supervised model in which the range of the number of optional hidden layers has been determined. The method can determine a noise range for each number of hidden layers that meets the conditions.
[0061] Now combined Figure 2 A method for determining the noise range provided by an embodiment of the present invention is explained by taking a semi-supervised model with a selected number of layers as an example. Figure 2 As shown, the method includes steps S210 to S240.
[0062] In step S210, initial noise is selected to determine a second initial semi-supervised model.
[0063] When establishing the second initial semi-supervised model, the initial noise may first be selected as a smaller value, such as 0.1, so that a noise range that meets the requirements can be quickly determined later.
[0064] In step S220, the loss value of the second initial semi-supervised model is compared with a preset loss value.
[0065] Among them, the loss function used to determine the loss value of the second initial semi-supervised model can be consistent with the loss function required in the above-mentioned process of determining the number of layers of the hidden layer, or other loss functions other than it can be used to determine the loss value. The specific selection of the loss function can be selected according to actual needs.
[0066] In step S230, the noise is adjusted according to the comparison result of the loss value and the preset loss value to determine a noise range corresponding to the semi-supervised model that satisfies the condition that the loss value is less than the preset loss value.
[0067] For example, if the noise is small and the loss value is greater than the preset loss value, the noise can be increased and the loss value of the semi-supervised model corresponding to the increased noise is determined; if the noise is large and the loss value is greater than the preset loss value, the noise can be reduced.
[0068] The method of adjusting the noise according to the comparison result between the loss value and the preset loss value may be arbitrary, for example, the noise may be adjusted according to a multiple, or the preset value may be increased each time the noise is adjusted.
[0069] For example, for a semi-supervised model with a selected number of hidden layers, the noise range can be determined in the following manner: determine a third loss value of the semi-supervised model corresponding to the first noise; when the third loss value is greater than the preset loss value, adjust the first noise to a third preset multiple as the new first noise to establish a new third semi-supervised model; and repeat the above operations to determine the noise range corresponding to the semi-supervised model whose loss value is less than the preset loss value.
[0070] The preset multiple can be arbitrary, for example, it can be 15, 10, 5, 2, etc.
[0071] Furthermore, considering that noise can also cause underfitting and overfitting in the semi-supervised model, the range of noise can also be determined by determining the lower limit noise and the upper limit noise.
[0072] Specifically, this embodiment of the present invention can also determine the lower limit noise in the following manner: determine the third loss value of the semi-supervised model corresponding to the first noise; when the third loss value is greater than the preset loss value, adjust the first noise to a third preset multiple as the new first noise to establish a new third semi-supervised model; and repeat the above steps to determine the lower limit noise corresponding to the semi-supervised model whose loss value is less than the preset loss value.
[0073] This embodiment of the present invention can also determine the lower limit noise in the following manner: determine the fourth loss value of the semi-supervised model corresponding to the second noise, the first noise is smaller than the second noise; when the fourth loss value is greater than the preset loss value, adjust the second noise to a fourth preset multiple as the new second noise to establish a new fourth semi-supervised model; repeat the above steps to determine the upper limit noise corresponding to the semi-supervised model whose loss value is smaller than the preset loss value.
[0074] The second noise is smaller than the first noise, so the determined upper limit noise can be used as the upper limit value of the noise range, and the lower limit noise can be used as the lower limit value of the noise range, so as to obtain a reasonable noise range.
[0075] By repeating steps S220 and S230, multiple noises corresponding to multiple semi-supervised models that satisfy the loss value not greater than the preset loss value can be obtained. The multiple noises constitute a noise range, which corresponds to the number of hidden layers of the second initial semi-supervised model.
[0076] In step S240, a new semi-supervised model is established with the number of hidden layers selected from the range of the number of hidden layers and the noise selected from the noise range, and the new semi-supervised model is an optimized semi-supervised model.
[0077] The above operation is performed for each number of layers in the range of the number of hidden layers, and the noise range corresponding to the number of layers of each hidden layer can be obtained.
[0078] The optimized semi-supervised model can be established by selecting a number of layers within the range of the number of hidden layers and noise selected within the noise range corresponding to the number of layers.
[0079] Furthermore, in order to facilitate the establishment of the optimized semi-supervised model, the intersection of all noise ranges corresponding to all layers in the range of the number of layers of the hidden layer can be taken as the new noise range. All noises within the new noise range are applicable to all layers within the range of the number of layers of the hidden layer. Therefore, the loss value of the optimized semi-supervised model constructed by the number of layers directly selected from the range of the number of layers of the hidden layer and the noise selected within the new noise range will not be greater than the preset loss value.
[0080] The technical solution provided by the embodiment of the present invention, while determining a reasonable range of the number of hidden layers, also proposes that noise can be optimized, and provides a method for optimizing noise, so that the optimized semi-supervised model will not have a high loss value caused by underfitting or overfitting of the data.
[0081] Embodiment 3
[0082] After determining a reasonable range of the number of hidden layers and noise range for the semi-supervised model, adjustments can be made to the training set of the semi-supervised model to further improve the adaptability of the semi-supervised model to the situation where there is little labeled data and much unlabeled data in chemical process data, so that the semi-supervised model can be widely used in chemical processes.
[0083] In order to accurately determine the impact of the ratio of labeled data to unlabeled data in the training set on the semi-supervised model, during the optimization process, for the semi-supervised model constructed with the same number of hidden layers and noise, it is necessary to input exactly the same training set data. The difference is that part of the labeled data and unlabeled data that constitute the initial preset ratio are converted into unlabeled data, that is, the data are the same, only the labels are removed. This ensures that the data in the second training set formed by reducing the initial preset ratio to the second preset ratio is completely consistent with the data in the first training set.
[0084] After determining the adjustment method of the training set, we now combine Figure 3 , taking a semi-supervised model with selected layers and noise as an example, the method for calculating the ratio of labeled data to unlabeled data in a training set provided by an embodiment of the present invention is explained. Figure 3 As shown, the method includes steps S310 to S340.
[0085] In step S310, a preset amount of labeled data in the first training set is converted into unlabeled data, so that the ratio of labeled data to unlabeled data is reduced to a second preset ratio, thereby forming a second training set.
[0086] The amount of labeled data converted into unlabeled data can be set by yourself.
[0087] In step S320, a third initial semi-supervised model is established according to the second training set, the selected number of hidden layers and the selected noise.
[0088] In step S330, the loss value of the third initial semi-supervised model is compared with the preset loss value.
[0089] The loss function used to determine the loss index may be the same as or different from the loss function described above.
[0090] In step S340, if the loss value of the third initial semi-supervised model is less than the preset loss value, the above operation is repeated until the minimum ratio of labeled data to unlabeled data in the training set corresponding to the semi-supervised model whose loss value is less than the preset loss value is determined.
[0091] When the minimum ratio is determined, the loss value of the semi-supervised model constructed by the training set corresponding to the ratio between the minimum ratio and the initial preset ratio is not greater than the preset loss value. Therefore, when applying the semi-supervised model to chemical process anomaly identification, the ratio of the number of labeled data and unlabeled data used to constitute the training set can be adjusted to between the minimum ratio and the initial preset ratio.
[0092] Furthermore, for the semi-supervised model, the greater the ratio of labeled data to unlabeled data, the smaller the loss value. Therefore, when the accuracy of the output results of the semi-supervised model is required to be high, the ratio of labeled data to unlabeled data can be increased.
[0093] The technical solution provided by this embodiment of the present invention proposes an optimization of the ratio of labeled data and unlabeled data in the training set, and can determine the minimum ratio of the training set required while ensuring that the accuracy of the established semi-supervised model meets expectations. It effectively solves the problem of few labeled sample data and much unlabeled sample data for process anomalies in industrial sites, and improves the adaptability of the semi-supervised model in identifying chemical process anomalies.
[0094] The optimization method of the semi-supervised model for chemical process anomaly identification provided by the embodiment of the present invention proposes an optimization method based on the idea of moderate density. The optimized semi-supervised model obtained by this method also has the advantages of low cost, wide application range and high reliability.
[0095] Embodiment 4
[0096] Now combined Figure 4 , an embodiment is used to explain the principle of the optimization method of the semi-supervised model for chemical process anomaly identification provided by an embodiment of the present invention. In the following embodiments, the semi-supervised model is abbreviated as SSLN model.
[0097] like Figure 4 As shown, the principles include:
[0098] 1) Set different abnormal working conditions on the chemical dynamic simulation software, obtain the dynamic change data of each variable under different working conditions, and obtain various data sets (not limited to simulation data, but also real data).
[0099] 2) Build a network structure, perform unsupervised learning on unlabeled data, and perform supervised learning after initially giving noise (or not giving noise) and the proportion of labeled sample data. By changing the number of hidden layers L and using the test data set, test the anomaly recognition performance of the network layer under a given setting, obtain the iterative curve of the anomaly recognition accuracy of the test data, and count the highest accuracy when the curve is stable.
[0100] 3) Change the noise intensity and the proportion of labeled sample data, and conduct sensitivity analysis of different parameters on network anomaly recognition performance. Compare and analyze the network performance under different parameter settings to obtain the optimal network structure and build a moderately dense SSLN model, which is the optimal SSLN model.
[0101] Embodiment 5
[0102] Taking the chemical process of ethylene cracking as an example, the ethylene cracking unit is a continuous production process. In actual production, each process variable basically fluctuates around the set value. There are not many time windows for abnormal fluctuations, and the number of variables involved in local abnormal fluctuations is not too large, resulting in high data annotation costs. It is very difficult to build a large-scale, well-annotated data set. Therefore, a semi-supervised model can be established, and the method provided by the embodiment of the present invention can be used to optimize the established semi-supervised model.
[0103] For example, the simulation process of the depropanizing distillation tower of the ethylene cracking unit is used as the experimental environment, and two typical fault types, namely, the failure of the bottom liquid level regulator of the distillation tower C-701 and the change of feed composition (increase in C4 content), are selected, as shown in Table 1.
[0104] Table 1
[0105]
[0106]
[0107] When dividing the data set, the test set is set to contain 25% of the labeled sample data, and the training set is set to contain the remaining 75% of the labeled sample data. The labeled sample data and the unlabeled sample data in the training set can also be further divided.
[0108] When establishing the initial semi-supervised model, the Adam method can be used to optimize the supervised and unsupervised training processes at the same time, and the initial learning rate of the Adam optimizer is adjusted to 0.04, the Batchsize calculated for each iteration is 25, the weight ω of the loss function is 10E-5, the hidden layer activation function is ReLU, the output layer activation function is Softmax, the training set is set to 10% labeled data and 90% unlabeled sample data, the standard deviation of the noise intensity is 1, and the denoising factor λ is set to 1000, 10, 0.1, 0.1, 0.1 and 0.1 respectively.
[0109] Four models are established with the number of layers being 3, 7, 15 and 30, respectively, as shown in Table 2.
[0110] Table 2
[0111] Model No. The number of hidden layers L Model 1 3 Model 2 7 Model 3 15 Model 4 30
[0112] Using the same test set for testing, the recognition accuracy of each model is as follows Figure 5 and Figure 6 As shown. Among them, Figure 5 The figure shows the recognition accuracy of working condition 3. Figure 6 The figure shows the recognition accuracy of working condition 4.
[0113] Depend on Figure 5 and Figure 6 It can be seen that with the same number of training iterations, the anomaly recognition accuracy of model 2 is higher. At the same time, after a certain number of iterations, the anomaly recognition accuracy tends to a stable value, which indicates that the training of the model gradually stabilizes.
[0114] Table 3 shows the anomaly recognition (classification) results of the test sets corresponding to working conditions 3 and 4 after the four models are stabilized. It can be seen from Table 3 that the anomaly recognition performance of model 2 is better than that of the other three models, that is, the model cannot be effectively trained when the number of network layers is small, resulting in poor model performance accuracy. However, as the number of network layers increases, the training process will experience training dispersion or explosion, which will eventually lead to the inability to conduct training, resulting in poor model performance accuracy. Therefore, constructing a moderately dense SSLN model and its topological structure can effectively extract data features and improve the accuracy of anomaly recognition of the model under few labeled sample data.
[0115] Table 3
[0116] Working conditions Model 1 (%) Model 2 (%) Model 3 (%) Model 4 (%) Condition 3 45.67 90.37 86.58 85.59 Condition 4 62.75 91.38 88.58 87.45
[0117] When Model 2 is determined to be better, we take it as an example, change its benchmark settings, and analyze its anomaly recognition performance under different label sample data ratios, where the label sample data ratios are 1%, 10%, 50%, and 100%, respectively. Figure 7This is the variation of the anomaly recognition accuracy of model 2 with the number of iterations in the working condition 3 test set under different label sample data ratios. Figure 7 It can be seen that as the number of iterations increases, the anomaly recognition accuracy of the model tends to be stable. In comparison, when the number of iterations is the same, the more labeled sample data the model has, the better the anomaly recognition accuracy.
[0118] Table 4 shows the recognition accuracy of model 2 under different proportions of labeled sample data for working conditions 3 and 4. It can be seen from Table 4 that the higher the proportion of labeled sample data, the better the recognition accuracy of the model. When the labeled sample data is 10%, model 2 can achieve good recognition effects under both working conditions. With the increase in the proportion of labeled sample data, although the recognition accuracy has increased significantly, the proportion of labeled sample data is too large, and it has lost its meaning for industrial production data. By comparing the recognition accuracy of labeled sample data from 1% to 10% and from 10% to 100%, it is found that the recognition accuracy of the former is more significantly improved. Therefore, 10% can be used as the optimal proportion of labeled sample data.
[0119] Table 4
[0120]
[0121]
[0122] Based on Model 2, its anomaly recognition performance under 10% labeled sample data, different noise intensities, and working condition 3 test sets is analyzed. The recognition accuracy of Model 2 is shown in Table 5 below.
[0123] Table 5
[0124]
[0125] As can be seen from Table 5, when no noise is added to Model 2 (i.e., the standard deviation of the noise is 0), the performance of the unsupervised network is low because the unsupervised network does not play any role. Under noisy conditions, the model performance shows a downward trend with the increase of noise intensity. When the noise standard deviation is 1, the performance is optimal, but as the noise intensity increases, the network's anomaly recognition accuracy gradually drops to 81.43%. This shows that appropriately adding a certain intensity of noise inside the network can greatly improve the test performance of the network structure. Therefore, it can be determined that the noise with a standard deviation of 1 is the best. At this time, the obtained Model 2 (the number of hidden layers is 7, the proportion of labeled sample data is 10%, and the noise standard deviation is 1) is the optimal model, which has good applicability and effectiveness for anomaly recognition in the case of few labeled samples in the ethylene cracking process.
[0126] Embodiment 6
[0127] Figure 8 FIG. 1 is a flow chart of a method for monitoring abnormality in a chemical process based on a semi-supervised model provided by an embodiment of the present invention. Figure 8 As shown, an embodiment of the present invention provides a chemical process anomaly monitoring method based on a semi-supervised model, and the anomaly monitoring method includes steps S810 to S820, wherein the semi-supervised model is an optimized semi-supervised model obtained by optimizing the optimization method of the semi-supervised model for chemical process anomaly identification provided in any of the above embodiments of the present invention.
[0128] In step S810, current data on the operating conditions of the sections of the chemical process are collected.
[0129] The operating condition data may include normal operating conditions, temporary interruption of heating steam supply of reboiler E-702, failure of liquid level regulator of distillation tower C-701, change of material composition (increase of C4 content), temporary interruption of system instrument air, etc., and the operating conditions and operating condition data involved are different according to different chemical processes. Therefore, the operating conditions to be monitored are selected according to the actual chemical process and work section, and the data on the operating conditions to be monitored can be collected.
[0130] According to the difference of actual production equipment, the current data of the relevant working conditions can be collected by one or more of the following: DCS system, PLC system, instrument electrical signal acquisition system, combustible gas detection system and video monitoring system.
[0131] In step S820, the current data is used as an input of the optimized semi-supervised model to identify whether the current data is abnormal based on a result output by the optimized semi-supervised model.
[0132] The optimized semi-supervised model provided by the above embodiment of the present invention solves the problem that there are few labeled sample data and many unlabeled sample data in industrial field anomalies. After the construction of the semi-supervised model is completed based on the training samples, only the current operating condition data is used as input. The result output by the semi-supervised model can determine whether the current operating condition is abnormal, which can provide a scientific and effective production basis for subsequent production processes.
[0133] Furthermore, in order to facilitate the review and statistics of the production process, the operating condition data and the results of the semi-supervised model output corresponding to the operating condition data can also be stored, for example, in a local memory or in a server.
[0134] In order to more intuitively represent the working status of the current production process, it is also possible to control devices such as display terminals to display the recognition results output by the semi-supervised model. The displayed content can be set by the user according to actual needs. For example, the real-time output recognition results can be displayed, or only the recognition results that are judged to be abnormal can be displayed.
[0135] An embodiment of the present invention also provides a machine-readable storage medium, on which instructions are stored, and the instructions are used to enable a machine to execute the optimization method of a semi-supervised model for chemical process anomaly identification described in any one of the above-mentioned embodiments of the present application, and / or execute the chemical process anomaly monitoring method based on a semi-supervised model described in any one of the above-mentioned embodiments of the present application.
[0136] The optional implementation modes of the embodiments of the present invention are described in detail above in conjunction with the accompanying drawings. However, the embodiments of the present invention are not limited to the specific details in the above implementation modes. Within the technical concept of the embodiments of the present invention, various simple modifications can be made to the technical scheme of the embodiments of the present invention, and these simple modifications all belong to the protection scope of the embodiments of the present invention.
[0137] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. To avoid unnecessary repetition, the embodiments of the present invention will not further describe various possible combinations.
[0138] Those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a program, and the program is stored in a storage medium, including a number of instructions to enable a single-chip microcomputer, a chip or a processor to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0139] In addition, various implementation modes of the embodiments of the present invention may be arbitrarily combined, and as long as they do not violate the concept of the embodiments of the present invention, they should also be regarded as the contents disclosed by the embodiments of the present invention.
Claims
1. An optimization method for a semi-supervised model for identifying anomalies in chemical processes, characterized in that: The first initial semi-supervised model is obtained by training a first training set, wherein the first training set is the operating data of the working section of the chemical process, and has labeled data and unlabeled data constituting an initial preset ratio, and the optimization method includes: Determining a loss value of the first initial semi-supervised model, wherein the loss value is obtained by a loss function; Comparing the loss value of the first initial semi-supervised model with a preset loss value; According to the comparison result between the loss value and the preset loss value, the number of hidden layers is adjusted to determine the range of the number of hidden layers corresponding to the semi-supervised model satisfying that the loss value is less than the preset loss value; and A new semi-supervised model is established based on the number of hidden layers within the range of the number of hidden layers, wherein the new semi-supervised model is an optimized semi-supervised model. The optimization method further includes determining the range of the number of layers of the hidden layer by: Determine the lower limit number of layers according to the following steps: Determine a first loss value of the semi-supervised model corresponding to the first number of layers; When the first loss value is greater than the preset loss value, adjusting the first number of layers to a first preset multiple and then rounding it to the integer as a new first number of layers to establish a new first semi-supervised model; and Repeat the above steps to determine the lower limit number of hidden layers corresponding to the semi-supervised model whose loss value is less than the preset loss value; Follow these steps to determine the upper limit: Determine a second loss value of the semi-supervised model corresponding to a second number of layers, wherein the second number of layers is greater than the first number of layers; When the second loss value is greater than the preset loss value, adjusting the second number of layers to a second preset multiple and then rounding it to the integer as a new second number of layers to establish a new second semi-supervised model; and Repeat the above steps to determine the upper limit number of hidden layers corresponding to the semi-supervised model whose loss value is less than the preset loss value; and The upper limit number of layers is used as the upper limit value of the range of the number of layers of the hidden layer, and the lower limit number of layers is used as the lower limit value of the range of the number of layers of the hidden layer, The operating conditions include normal operating conditions, temporary interruption of reboiler heating steam supply, failure of distillation tower bottom liquid level regulator, change in feed composition or temporary interruption of system instrument air.
2. The optimization method according to claim 1, characterized in that: After determining the range of the number of hidden layers corresponding to the semi-supervised model whose loss value is less than the preset loss value, the optimization method further comprises performing the following steps for the number of hidden layers selected within the range of the number of hidden layers: Selecting initial noise to determine a second initial semi-supervised model; Comparing the loss value of the second initial semi-supervised model with the preset loss value; According to a comparison result between the loss value and the preset loss value, adjusting the noise to determine a noise range corresponding to a semi-supervised model satisfying that the loss value is less than the preset loss value; and A new semi-supervised model is established with the number of hidden layers selected from the range of the number of hidden layers and the noise selected from the noise range, and the new semi-supervised model is an optimized semi-supervised model.
3. The optimization method according to claim 2, characterized in that: For the number of hidden layers selected within the range of the number of hidden layers, the optimization method further comprises determining the noise range in the following manner: Determine a third loss value of the semi-supervised model corresponding to the first noise; When the third loss value is greater than the preset loss value, adjusting the first noise to a third preset multiple as a new first noise to establish a new third semi-supervised model; and Repeat the above operation to determine the noise range corresponding to the semi-supervised model whose loss value is less than the preset loss value.
4. The optimization method according to claim 3, characterized in that: The optimization method further comprises determining the range of the noise by: Determine the noise floor using the following steps: Determine a third loss value of the semi-supervised model corresponding to the first noise; When the third loss value is greater than the preset loss value, adjusting the first noise to a third preset multiple as a new first noise to establish a new third semi-supervised model; as well as Repeat the above steps to determine the lower limit noise corresponding to the semi-supervised model whose loss value is less than the preset loss value; Determine the upper noise limit by following these steps: Determining a fourth loss value of the semi-supervised model corresponding to a second noise, wherein the first noise is smaller than the second noise; When the fourth loss value is greater than the preset loss value, adjusting the second noise to a fourth preset multiple as a new second noise to establish a new fourth semi-supervised model; Repeat the above steps to determine the upper limit noise corresponding to the semi-supervised model whose loss value is less than the preset loss value; as well as The upper limit noise is used as the upper limit value of the noise range, and the lower limit noise is used as the lower limit value of the noise range.
5. The optimization method according to claim 2, characterized in that: After determining the range of the number of hidden layers and the noise range corresponding to the semi-supervised model whose loss value is less than the preset loss value, the optimization method further comprises performing the following steps for the number of hidden layers selected within the range of the number of hidden layers and the noise selected within the noise range: Converting a preset amount of labeled data in the first training set into unlabeled data, so that the ratio of labeled data to unlabeled data is reduced to a second preset ratio, thereby forming a second training set; Establishing a third initial semi-supervised model according to the second training set, the selected number of hidden layers and the selected noise; Comparing the loss value of the third initial semi-supervised model with the preset loss value; as well as If the loss value of the third initial semi-supervised model is less than the preset loss value, the above operation is repeated until the minimum ratio of labeled data to unlabeled data in the training set corresponding to the semi-supervised model whose loss value is less than the preset loss value is determined.
6. The optimization method according to claim 1, characterized in that: The training set contains N labeled data and M unlabeled data. The loss function of the semi-supervised model is determined in the following way: Perform supervised training on N labeled data to obtain the supervised error loss function C1; Perform unsupervised training on M unlabeled data to obtain the unsupervised error loss function C2; as well as The loss function C is determined according to the supervised error loss function C1 and the unsupervised error loss function C2.
7. The optimization method according to claim 6, characterized in that: The loss function C is determined in the following way: .
8. A chemical process abnormality monitoring method based on a semi-supervised model, characterized in that: The abnormality monitoring method comprises: Collecting current data on the operating conditions of the sections of the chemical process, wherein the operating conditions are normal operating conditions, temporary interruption of reboiler heating steam supply, failure of a distillation tower bottom liquid level regulator, changes in feed composition, or temporary interruption of system instrument air; and The current data is used as the input of the optimized semi-supervised model to identify whether the current data is abnormal according to the result output by the optimized semi-supervised model. The optimized semi-supervised model is obtained by optimizing the semi-supervised model for identifying anomalies in chemical processes according to any one of claims 1 to 7.
9. The abnormality monitoring method according to claim 8, characterized in that: The abnormality monitoring method also includes acquiring the current data through one or more of the following devices: a DCS system, a PLC system, an instrument electrical signal acquisition system, a combustible gas detection system, and a video monitoring system.
10. The abnormality monitoring method according to claim 8, characterized in that: The abnormal monitoring method further includes: The data related to the working condition and the results output by the semi-supervised model are stored.
11. The abnormality monitoring method according to claim 10, characterized in that: The abnormal monitoring method further includes: The recognition result output by the semi-supervised model is displayed.
12. A machine-readable storage medium, characterized in that: The machine-readable storage medium stores instructions for causing the machine to execute: The optimization method of the semi-supervised model for chemical process anomaly identification according to any one of claims 1 to 7; and / or A chemical process abnormality monitoring method based on a semi-supervised model as described in any one of claims 8-11.
Citation Information
Patent Citations
Semi-supervised neural network model and soft-sensing modeling method based on model
CN107505837A
Abnormity recognition method and device based on semi-supervised deep learning and storage medium
CN110363231A