Data processing method and device, storage medium and computer equipment
By determining the characteristic characterization of abnormal data in the preset subspace, the problem of abnormal diagnosis accuracy caused by spatial changes of dependent variables in the prior art is solved, and higher diagnostic accuracy and reliability are achieved.
Patent Information
- Application Number
- CN202411505777.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2044-10-25
AI Technical Summary
Existing abnormal diagnosis methods assume that monitoring data has isomorphic variable space, resulting in poor accuracy of abnormal diagnosis when sensor quality decreases, system expansion or monitoring requirements change.
By obtaining exception data, inputting it into the trained feature representation estimator, determining the feature representation of the exception data in the preset subspace, and determining the exception type based on the feature representation.
The data of different variable spaces are metricable in the preset subspace, which improves the accuracy and reliability of abnormal diagnosis, and avoids the diagnostic accuracy problems caused by hypothetical isomorphic variable space.
Smart Images

Figure CN119513756A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a data processing method, device, storage medium and computer equipment. Background Art
[0002] With the rapid advancement and widespread application of artificial intelligence (AI) technology, AI models are gradually being adopted in application scenarios such as industrial production. Among them, abnormal diagnosis solutions based on AI models are gradually being adopted because they can determine in real time whether abnormalities occur in the industrial production process.
[0003] In the related art, the abnormality diagnosis scheme based on AI model analyzes the collected data to determine whether there is an abnormality in the industrial production process. The collected data is generally composed of different variables collected by multiple sensors. However, in actual industrial production, due to factors such as sensor quality degradation, system expansion, and changes in monitoring requirements, state sensors will be removed or added, causing the monitoring variable space to change over time. The abnormal data is heterogeneous, and the existing abnormality diagnosis methods often assume that the monitoring data has a homogeneous variable space, which will lead to the problem of poor accuracy of abnormal diagnosis. Therefore, the related technology urgently needs to propose a data processing method to solve the above technical problems. Summary of the invention
[0004] The main purpose of the present application is to provide a data processing method, device, storage medium and computer equipment, which can avoid the problem of poor accuracy of abnormal diagnosis and improve the accuracy of abnormal diagnosis.
[0005] In a first aspect, an embodiment of the present application provides a data processing method, including:
[0006] Acquire abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace;
[0007] Determining the degree of association between each trained classifier and the feature representation, and obtaining the degree of association corresponding to each trained classifier;
[0008] Screening out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determining a trained target classifier corresponding to the target correlation degree;
[0009] Based on a preset mapping relationship between anomaly types and trained classifiers, a target anomaly type corresponding to the trained target classifier is determined.
[0010] In a second aspect, an embodiment of the present application provides a data processing device, including:
[0011] An input unit, used to obtain abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace;
[0012] A first determining unit is used to determine the degree of association between each trained classifier and the feature representation, and obtain the degree of association corresponding to each trained classifier;
[0013] A screening unit, used for screening out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determining a trained target classifier corresponding to the target correlation degree;
[0014] The second determining unit is used to determine the target abnormality type corresponding to the trained target classifier based on a preset mapping relationship between the abnormality type and the trained classifier.
[0015] In a third aspect, an embodiment of the present application provides a storage medium, wherein the computer-readable storage medium stores a plurality of instructions, which are suitable for loading by a processor to execute any of the above data processing methods.
[0016] In a fourth aspect, an embodiment of the present application provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the above data processing methods when executing the computer program.
[0017] In an embodiment of the present application, abnormal data is obtained and input into a trained feature representation estimator to determine the feature representation of the abnormal data in a preset subspace; the degree of association between each trained classifier and the feature representation is determined to obtain the degree of association corresponding to each trained classifier; a target degree of association with the largest degree of association is screened out from a plurality of the degrees of association, and a trained target classifier corresponding to the target degree of association is determined; based on a preset mapping relationship between the abnormal type and the trained classifier, a target abnormal type corresponding to the trained target classifier is determined. Compared with the related art, in which the abnormal diagnosis method often assumes that the monitoring data has a homogeneous variable space, the embodiment of the present application determines the feature representation of the abnormal data in a preset subspace through a trained feature representation estimator, so that data in different variable spaces are measurable in this preset subspace, and then the abnormal type is determined according to the feature representation, which can avoid the problem of poor accuracy of abnormal diagnosis due to the assumption that the monitoring data has a homogeneous variable space, thereby improving the accuracy of abnormal diagnosis.
[0018] Other features and advantages of the present disclosure will be described in the following description, and partly become apparent from the description, or understood by practicing the present disclosure. The purpose and other advantages of the present disclosure can be realized and obtained by the structures particularly pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0020] Figure 1 The abnormal diagnosis scheme of the AI model in the related technology provided in the embodiment of the present application assumes abnormal data with a homogeneous variable space.
[0021] Figure 2 Abnormal data in actual industrial processes provided by the embodiments of the present application.
[0022] Figure 3 A schematic diagram of a data processing system according to an embodiment of the present invention.
[0023] Figure 4 A flowchart of a data processing method provided in an embodiment of the present application.
[0024] Figure 5 A schematic diagram of the structure of a data processing device provided in an embodiment of the present application.
[0025] Figure 6 A schematic diagram of the structure of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0026] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present application.
[0027] It should be noted that in some processes described in the specification, claims and the above-mentioned drawings, multiple steps appearing in a specific order are included, but it should be clearly understood that these steps may not be executed in the order in which they appear in this document or may be executed in parallel. The step numbers are only used to distinguish different steps, and the numbers themselves do not represent any execution order. In addition, descriptions such as "first", "second" or "target" in this document are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0028] Before further describing the embodiments of the present disclosure in detail, the nouns and terms involved in the embodiments of the present disclosure are described. The nouns and terms involved in the embodiments of the present disclosure are subject to the following interpretations:
[0029] Artificial Intelligence (AI) is an important part of the intelligent discipline, attempting to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial Intelligence is a very broad science, including robotics, speech recognition, image recognition, natural language processing, expert systems, machine learning, computer vision, etc.
[0030] Target, see Figure 1 and Figure 2 , Figure 1 The abnormal data with homogeneous variable space assumed in the abnormal diagnosis scheme of the AI model in the related technology provided in the embodiment of the present application, Figure 2 This is the abnormal data in the actual industrial process provided by the embodiment of this application. Figure 1 As shown, as time changes, it is assumed that at each time point, each acquisition sensor (for example, acquisition sensor 1 to acquisition sensor 5) can collect the corresponding variables, that is, the observed variables can be obtained, so that at the same time point, the multiple variables collected (for example, variable 1 to variable 5) constitute abnormal data.
[0031] However, industrial processes may remove or add monitoring sensors due to system expansion or demand changes, causing the abnormal data variable space to evolve over time. This may include the following situations:
[0032] 1. When some measurements provided by the sensor are no longer needed, the sensor will be removed, the monitored variables will be reduced, and the dimension of the original variable space will be reduced.
[0033] 2. When process adjustment requires expansion of the production line, new monitoring sensors will be added, monitoring variables will increase, and the dimension of the original variable space will increase. In this case, the anomaly diagnosis model needs to learn effective anomaly information in the evolving variable space to ensure the anomaly diagnosis performance of the model.
[0034] like Figure 2 As shown in the figure, at time t-3, the data is only composed of variables 1, 2, and 3. From time t-1 to time t, acquisition sensors 4 and 5 are converted from undefined to observed, which increases the dimension of the original variable space (the data is composed of variables 1, 2, and 3, and is changed to variables 1, 2, 3, 4, and 5, and the variable space dimension is changed from 3 dimensions to 5 dimensions); at the same time, the observed variable of acquisition sensor 3 is missing, making the observed variable a missing variable. Subsequently, from time t to time t+1, acquisition sensor 3 is removed and no longer recorded, and its corresponding variable is converted from an observed state to an undefined state, which reduces the dimension of the variable space.
[0035] It can be seen that the methods in the related art generally assume that the abnormal data have a homogeneous variable space, without considering the heterogeneity of the corresponding abnormal data at different times.
[0036] In order to solve the above problems, the embodiment of the present application obtains abnormal data, inputs the abnormal data into the trained feature representation estimator, determines the feature representation of the abnormal data in the preset subspace; determines the degree of association between each trained classifier and the feature representation, and obtains the degree of association corresponding to each trained classifier; selects the target degree of association with the largest degree of association from multiple degrees of association, and determines the trained target classifier corresponding to the target degree of association; based on the preset mapping relationship between the abnormal type and the trained classifier, determines the target abnormal type corresponding to the trained target classifier. The abnormal data with heterogeneity is mapped to the preset subspace, giving the data in different variable spaces a common metric so that they can be compared and evaluated in the same subspace, and the measurability makes the abnormality detection more accurate. The abnormal diagnosis can be performed more accurately, and the accuracy and reliability of the abnormal diagnosis can be improved. Please continue to refer to the following specific embodiments for details.
[0037] See also Figure 3 , Figure 3 A schematic diagram of a data processing system provided in an embodiment of the present application, which includes a terminal 140, the Internet 130, a gateway 120, a computer device 110, etc.
[0038] The terminal 140 includes but is not limited to pre-configured sensors, cameras, or electronic devices such as mobile phones and tablets that have information collection functions. In addition, it can be a single device or a collection of multiple devices. The terminal 140 can communicate with the Internet 130 in a wired or wireless manner to exchange data. Sensors include but are not limited to pressure sensors, visual sensors, and voltage and current sensors, which are not limited here.
[0039] Computer equipment refers to a computer system that can provide certain services to the terminal 140. Compared with ordinary terminals 140, computer equipment 110 has higher requirements in terms of stability, security, performance, etc. Computer equipment 110 can be a high-performance computer in a network platform, a cluster of multiple high-performance computers, a part of a high-performance computer (such as a virtual machine), a combination of parts of multiple high-performance computers (such as virtual machines), etc.
[0040] The gateway 120 is also called an internetwork connector or a protocol converter. The gateway realizes network interconnection at the transport layer and is a computer system or device that acts as a converter. The gateway is a translator between two systems that use different communication protocols, data formats or languages, or even completely different architectures. At the same time, the gateway can also provide filtering and security functions. The message sent by the terminal 140 to the computer device 110 must be sent to the corresponding computer device 110 through the gateway 120. The message sent by the computer device 110 to the terminal 140 must also be sent to the corresponding terminal 140 through the gateway 120.
[0041] In particular, when applied in industrial scenarios, the computer device 110 may also be directly connected to the terminal 140 without going through the gateway 120 to achieve real-time synchronization of data collected by the terminal 140 .
[0042] The data processing method of the embodiment of the present disclosure may be implemented on the computer device 110 .
[0043] It should be noted that Figure 3 The scenario diagram of the data processing system shown is merely an example. The data processing system and scenario described in the embodiment of the present application are intended to more clearly illustrate the technical solution of the embodiment of the present application, and do not constitute a limitation on the technical solution provided in the embodiment of the present application. A person of ordinary skill in the art can appreciate that with the evolution of data processing technology and the emergence of new business scenarios, the technical solution provided in the embodiment of the present application is equally applicable to similar technical problems.
[0044] In this embodiment, the description will be made from the perspective of a data processing device, which can be specifically integrated into a computer device having a storage unit and a microprocessor installed therein and having computing capabilities.
[0045] See also Figure 4 , Figure 4 A flow chart of a data processing method provided in an embodiment of the present application. The data processing method includes:
[0046] In step 201, abnormal data is acquired, and the abnormal data is input into a trained feature representation estimator to determine the feature representation of the abnormal data in a preset subspace.
[0047] Among them, abnormal data is composed of different variables collected by multiple sensors at the same time. The trained feature representation estimator is used to estimate the feature representation of abnormal data mapped to the preset subspace. The preset subspace is a low-dimensional data space. The preset subspace can extract the main features of the data and highlight the key information and patterns in the data. This helps to better understand the essential structure of the data. The subspace provides a new way to represent data, so that data from different variable spaces can be compared and analyzed in this common subspace, and data from different variable spaces can be measured under the preset subspace. Abnormal data refers to data in the industrial process caused by a certain industrial machine or operation that exceeds the normal range, data is missing, etc.
[0048] Specifically, the method of determining the characteristic representation of abnormal data in the preset subspace can be implemented according to the following formula:
[0049]
[0050] Among them, x * is abnormal data, q * is the abnormal data x * Feature representation in the preset subspace, L t is the trained feature representation estimator, Used to represent the pseudo-inverse, That is, the pseudo-inverse matrix of the trained feature representation estimator, Θ t represents the set of observed variables, For the variable set Θ t The projection operator of That is the abnormal data x * The set of variables Θ observed in t is the projection operator, and t is the time.
[0051] Specifically, the projection operator It can be determined according to the following formula:
[0052]
[0053] Among them, j is a variable. The meaning of this formula is that due to sensor abnormalities and other reasons, there will be missing values at each time. Therefore, at time t, if variable j is in the observed variable set Θ t , then in Retain variable j in , if variable j is not in the observed variable set Θ t , then in Keep 0 in , so as to obtain the projection operator
[0054] For example, there are three sensors that collect different variables, namely variable 1, variable 2, and variable 3. At a certain time t, if This means that at time t, only variables 1 and 2 were observed, and variable 3 was not observed, so
[0055] In this way, after obtaining the abnormal data, the projection operator of the abnormal data is calculated Recalculate the projection operator and the pseudo-inverse matrix of the trained feature representation estimator The inner product of * The feature representation q in the preset subspace * .
[0056] In step 202, the degree of association between each trained classifier and the feature representation is determined to obtain the degree of association corresponding to each trained classifier.
[0057] Specifically, different classifiers are trained for the abnormality types that may occur during the abnormality diagnosis process, so that one abnormality type corresponds to one trained classifier, thereby obtaining a plurality of trained classifiers.
[0058] For example, if there are C types of anomalies, then the classifier That is the classifier corresponding to the Cth abnormal type.
[0059] Specifically, the degree of association between each trained classifier and the feature representation can be determined according to the following formula:
[0060]
[0061] in, is the trained classifier corresponding to each anomaly type, r is the label of the anomaly type, and the feature representation q is calculated. * Trained classifiers corresponding to each anomaly type The inner product is used to characterize the projection or similarity measure of the sample in the direction determined by the classifier parameters.
[0062] For example, if the feature representation q * The trained classifier corresponding to each anomaly type If the directions of the trained classifiers in are consistent or close in some sense, the inner product will be relatively large, that is, the degree of association will be greater; conversely, if the directions are very different, the inner product will be smaller, that is, the degree of association will be smaller. Based on this, the degree of association between each trained classifier and the feature representation is calculated to obtain the corresponding degree of association of each trained classifier.
[0063] In this way, different classifiers are trained for different anomaly types, so that each anomaly type has a corresponding classifier to handle it, which improves the pertinence and professionalism of anomaly diagnosis. Association degree measurement: By calculating the degree of association (inner product) between the feature representation and each classifier, the projection or similarity measurement of the sample in the direction determined by the classifier can be quantified, providing a basis for accurately judging the anomaly type.
[0064] In step 203, a target correlation degree with the greatest correlation degree is screened out from the plurality of correlation degrees, and a trained target classifier corresponding to the target correlation degree is determined.
[0065] After determining the correlation degree corresponding to each trained classifier in step S202, the target correlation degree with the greatest correlation degree is screened out from the multiple correlation degrees, and the trained target classifier corresponding to the target correlation degree is determined. The trained target classifier with the greatest correlation degree with the feature representation is queried by screening the target correlation degree.
[0066] In step 204, based on a preset mapping relationship between anomaly types and trained classifiers, a target anomaly type corresponding to the trained target classifier is determined.
[0067] Among them, since different classifiers are trained for the abnormal types that may appear in the abnormal diagnosis process, a preset mapping relationship is established between the abnormal type and the trained classifier, that is, one abnormal type corresponds to one trained classifier. Based on this, after the trained target classifier is determined in step 203, the target abnormal type corresponding to the trained target classifier can be determined according to the preset mapping relationship. Since the trained target classifier has the greatest degree of correlation with the feature representation, the target abnormal type corresponding to the trained target classifier is the most likely abnormal type, thereby achieving the effect of determining the abnormal type according to the abnormal data.
[0068] Specifically, the process of determining the target abnormality type can refer to the following formula:
[0069]
[0070] Among them, argmax r To find out the degree of association The label value r with the maximum value is obtained. Since the label value r represents the abnormal type, the degree of association is found. The exception type that obtains the maximum value, which is also the target exception type.
[0071] As can be seen from the above, the embodiment of the present application obtains abnormal data, inputs the abnormal data into the trained feature representation estimator, determines the feature representation of the abnormal data in the preset subspace; determines the degree of association between each trained classifier and the feature representation, and obtains the degree of association corresponding to each trained classifier; selects the target association degree with the largest degree of association from multiple association degrees, and determines the trained target classifier corresponding to the target association degree; based on the preset mapping relationship between the abnormal type and the trained classifier, determines the target abnormal type corresponding to the trained target classifier. In this way, considering that the sensor may be abnormal and cause data loss, by introducing the projection operator It can effectively handle the missing value problem and ensure that the data can be reasonably represented and analyzed under different sensor states. The trained feature representation estimator is used to map abnormal data into a low-dimensional preset subspace, extract the main features of the data, reduce the data dimension and complexity, highlight key information and patterns, and help better understand the essential structure of the data and improve the accuracy and efficiency of subsequent abnormal diagnosis.
[0072] In some embodiments, before obtaining abnormal data, inputting the abnormal data into a trained feature representation estimator, and determining the feature representation of the abnormal data in a preset subspace, the method further includes:
[0073] (1) determining unused target abnormal sample data in the abnormal sample data set in time order, and obtaining previous control abnormal sample data that is before the target abnormal sample data in time order, wherein the abnormal sample data set includes a plurality of abnormal sample data in time order, and each abnormal sample data is marked with an abnormal type;
[0074] (2) adjusting the feature representation estimator to be trained based on the target variable included in the target abnormal sample data and the control variable of the control abnormal sample data to obtain the adjusted feature representation estimator to be trained, and constructing a target diagonal matrix;
[0075] (3) determining an initial feature representation of the target abnormal sample data based on the adjusted feature representation estimator to be trained, the target diagonal matrix, and the target abnormal sample data;
[0076] (4) determining the degree of correlation between the initial feature representation and each classifier to be trained, and determining a loss value based on the target abnormality type marked by the target abnormal sample data and the degree of correlation between each classifier to be trained;
[0077] (5) based on the adjusted feature representation estimator to be trained, the target diagonal matrix, the target abnormal sample data and the loss value, updating the initial feature representation to obtain a target feature representation corresponding to the target abnormal sample data;
[0078] (6) based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix, iteratively updating the network parameters of the feature representation estimator to be trained until the number of training times reaches a preset number of training times, thereby obtaining an updated feature representation estimator to be trained;
[0079] (7) updating the network parameters of the classifier to be trained based on the target feature representation, the loss value, and the correlation degree corresponding to each classifier to be trained;
[0080] (8) When there is unused abnormal sample data in the abnormal sample data set, return to execute the step of determining the unused target abnormal sample data in the abnormal sample data set according to the time sorting until there is no unused abnormal sample data in the abnormal sample data set, thereby obtaining the trained feature representation estimator and each trained classifier.
[0081] The embodiment of the present application mainly introduces the training process of the feature characterization estimator and the classifier. The task of abnormal diagnosis is to learn the abnormal diagnosis model and identify the corresponding abnormal type in an incremental update manner. Using the minimum empirical loss criterion, the following online optimization problem can be constructed. Specifically, given data at time t and the exception type label y i , the goal is to learn an anomaly diagnosis model at time t Minimize the experience loss function. The specific formula is described as follows:
[0082]
[0083] Where i is any time from time 1 to time t, x i That is, the abnormal sample data corresponding to time i, That is, the abnormal sample data x i The set of variables Θ observed in i The projection operator of The loss value caused by the difference between the actual anomaly category and the predicted anomaly category is quantified. Due to the heterogeneity of data at different times, it is necessary to learn heterogeneous data samples. Therefore, a subspace learning method is proposed to map heterogeneous data into a unified subspace and learn an anomaly diagnosis model in this unified subspace. Let f() be the subspace projection function, then the formula can be rewritten as:
[0084]
[0085] Specifically, in the actual training process, in order to reduce the time overhead of the incremental learning process, only the information of the last sample can be considered for updating, so the final form of the formula is:
[0086]
[0087] Among them, this formula is the design criterion of the incremental anomaly diagnosis model under the feature space evolution based on subspace learning. Different loss functions and subspace learning models can be selected according to different application requirements.
[0088] Specifically, since the abnormal diagnosis model includes two parts of the model, the first part is the feature representation estimator, and the second part is the classifier. R is the set of real numbers, is a real number set consisting of S variables at time t, K is the dimension of the subspace, and the feature representation estimator to be trained needs to be trained to obtain a model that can integrate heterogeneous abnormal sample data Projected into the subspace, so that the heterogeneous abnormal sample data can be expressed in the subspace (i.e., feature representation) q t ∈R K It can be directly measured, and considering the linear projection problem, the feature representation estimator can be learned at any time by optimizing the following formula:
[0089]
[0090] in, is the objective function in abnormal diagnosis based on subspace learning, and its value depends on the feature representation estimator L t and the characteristic representation q t This objective function is usually used to measure the performance of the model under given data. By optimizing this objective function, L can be adjusted. t and q t The value of enables the model to better fit the data and improve the accuracy of abnormal diagnosis. OSL is the abbreviation of Online Subspace Learning. 2 is the 2-norm operation, ‖.‖ F is the F-norm operation, λ 1 With λ 2 is a control parameter greater than zero, and T represents the transpose of the calculation matrix.
[0091] As for the classifier, since the classification area is mainly used to learn the classifier in the shared subspace for the classification of sample abnormal types, consider learning multiple linear classifiers C is the number of exception types, That is, the classifier of the Cth abnormal type, whose dimension is also K. Therefore, at any time t, a classifier can be learned by optimizing the following formula:
[0092]
[0093] in, is the objective function of the classifier, OCL is the abbreviation of Online Classifier Learning, y t is the characteristic representation q t The label corresponding to the abnormal sample data, that is, the anomaly type marked, r t is the highest ranked irrelevant label, that is, the highest ranked anomaly type other than the annotated anomaly type. l() represents the loss function of the learning classifier. There are many choices for loss functions, such as slope loss, logical loss, hinge loss, etc. The marginal loss in the embodiment of the present application is only one of the choices. The loss requires not only a positive confidence, but also a confidence of at least 1 in the model prediction.
[0094] During incremental training, the overall loss function of the feature representation estimator and classifier training process You can refer to the following format:
[0095]
[0096] Specifically, when When it is minimized, the trained feature representation estimator L can be solved. t , the best feature representation q of abnormal sample data t And the trained classifier W t . Reconstruct the formula to minimize This is equivalent to optimizing the following formula:
[0097]
[0098] in, It is a diagonal matrix with the number of rows and columns being the number of variables. When variable i is observed, that is, when the variable set that constitutes the abnormal sample data includes variable i, then [Θ] i,i =1, that is, the value of the i-th row and column in the diagonal matrix is 1, otherwise it is 0.
[0099] Based on this, in the training process for the feature representation estimator and the classifier, it is necessary to obtain an abnormal sample data set, which includes multiple abnormal sample data sorted by time, and each abnormal sample data is marked with an abnormal type, specifically in the form of:t ,y t , where t∈[1,T], that is, the abnormal sample data is a plurality of abnormal sample data sorted by time from time 1 to time T.
[0100] Multiple abnormal sample data are incrementally trained on the feature characterization estimator and the classifier in a time-ordered manner, and the target abnormal sample data not used in the abnormal sample data set is determined in time order, that is, the abnormal sample data that needs to be taken out to train the feature characterization estimator and the classifier. In order to adapt to the data structure of the new data, the feature characterization estimator to be trained needs to be adjusted, and the adjustment method requires the target variable of the target abnormal sample data to be compared with the control variable of the previous control abnormal sample data that is in time order before the target abnormal sample data.
[0101] For example, the target abnormal sample data is x 3 , then the control abnormal sample data is x 2 .x 3 The target variables are variable 1, variable 2, and variable 3, and x 2 The control variables are variables 2 and 4. 3 With x 2 If the data structure is different, the feature representation estimator to be trained needs to be adjusted to obtain the adjusted feature representation estimator to be trained.
[0102] When the fixed L t and W t When the network parameters are updated, the feature representation q t When Relative to the characteristic representation q t The partial derivative of , we get the following formula:
[0103]
[0104] Among them, when l t When it is 0, the optimization formula is selected That is, the first preset optimization formula, when l t >0, the optimization formula is selected That is, the second preset optimization formula, λ 1 The I in I is a unit matrix with K rows and K columns.
[0105] Specifically, according to the above partial derivatives, the feature representation q can be obtained t The update rule is:
[0106]
[0107] Among them, *∈{Ⅰ,Ⅱ}, that is, the feature representation qt The update rule is based on the loss value e t The relationship between η and zero is determined by selecting different optimization formulas. t is a preset learning rate.
[0108] Specifically, the variable structure of abnormal sample data can be obtained through the projection operator To represent it, we can Converted into a diagonal matrix, the target diagonal matrix is obtained. Using the adjusted feature representation estimator to be trained, the target diagonal matrix and the target abnormal sample data, the initial feature representation of the target abnormal sample data is determined. Initial Characterization For the initialization of the actual feature representation at time t, in order to speed up the model convergence process, the embodiment of the present application selects a hot start method to determine the initial feature representation, but the initial feature representation can also be randomly initialized, which is not limited here.
[0109] Among them, when determining the target abnormal sample data x t The corresponding target feature representation q t Since the target feature representation q has been determined t The update rule is composed of the loss value l t To determine, therefore, in determining the target feature representation q t Before, we need to determine the loss value l t , thereby adjusting the feature representation estimator to be trained The target diagonal matrix Θ t , the target abnormal sample data x t And the loss value l t , update the initial feature representation Get the target feature representation q corresponding to the target abnormal sample data t .
[0110] Specifically, after obtaining the target feature representation q corresponding to the target abnormal sample data t Finally, based on the adjusted feature representation estimator to be trained, the target feature representation, and the target diagonal matrix, the network parameters of the feature representation estimator to be trained are iteratively updated until the number of training times reaches the preset number of training times. This is achieved by continuously adjusting the parameters of the estimator so that it can better extract the features of the data and improve the performance of the model. Then, based on the target feature representation, the loss value, and the corresponding correlation degree of each classifier to be trained, the network parameters of the classifier to be trained are updated. The update of the classifier is also to enable it to more accurately classify different types of anomalies.
[0111] When there are unused abnormal sample data in the abnormal sample data set, return to the step of sorting by time to determine the unused target abnormal sample data in the abnormal sample data set until there are no unused abnormal sample data in the abnormal sample data set. This cycle ensures that all data are used for training and the model is continuously optimized. Finally, the trained feature representation estimator and each trained classifier are obtained. These trained models can be used to predict and diagnose the abnormal type of new abnormal data.
[0112] In some embodiments, each row of the feature characterization estimator to be trained represents a variable, and adjusting the feature characterization estimator to be trained based on the target variable included in the target abnormal sample data and the control variable of the control abnormal sample data to obtain the adjusted feature characterization estimator to be trained includes:
[0113] (2.1) determining the intersection of the target variables included in the target abnormal sample data and the control variables of the control abnormal sample data to obtain a set of identical variables;
[0114] (2.2) determining a newly added variable in the target variable that is not in the same variable set;
[0115] (2.3) determining missing variables in the control variables that are not in the same variable set;
[0116] (2.4) Deleting the rows corresponding to the missing variables in the feature characterization estimator to be trained, and performing new row processing in the feature characterization estimator to be trained according to the new variables to obtain an adjusted feature characterization estimator to be trained.
[0117] The specific adjustment method of adjusting the feature representation estimator to be trained can refer to the following formula:
[0118]
[0119] Among them, Π represents the projection operator, That is, the feature representation estimator to be trained after the feature representation estimator to be trained is trained using the control abnormal sample data. t-1 Projected onto the target variable S t and control variable S t-1 The intersection of and the subspace determined by dimension K; To represent the projection of the zero vector onto the subspace determined by the difference of and and the dimension K. In this way, when dealing with the situation where the number of sensors changes, the old feature representation estimator can be adjusted and updated according to the new set of observed variables.
[0120] Specifically, the same variable set is St ∩S t-1 , the new variable is S t \S t-1 , the missing variable is the control variable S t-1 are not in the same variable set S t ∩S t-1 Since each row of the feature representation estimator to be trained represents one variable, this formula deletes the L corresponding to the missing variable t-1 At the same time, The addition of initializes the corresponding This strategy enables the feature characterization estimator of the embodiment of the present application to adapt to the changes of the sensor.
[0121] In some implementations, constructing a target diagonal matrix includes:
[0122] (2.5) determining the sum of the variables in the same variable set, the newly added variables, and the missing variables to obtain the total number of variables;
[0123] (2.6) constructing an initial diagonal matrix according to the total number, wherein the values of the corresponding positions of the rows and columns with the same values in the initial diagonal matrix are 1;
[0124] (2.7) Change the values in the rows corresponding to the missing variables in the initial diagonal matrix from one to zero to obtain the target diagonal matrix.
[0125] Among them, since the purpose of the diagonal matrix is to transform the projection operator Converted into matrix form, The number of rows and columns are both the number of variables. When variable i is observed, that is, when the variable set that constitutes the abnormal sample data includes variable i, then [Θ] i,i =1, that is, the value of the i-th row and column in the diagonal matrix is 1, otherwise it is 0. Therefore, the sum of the variables in the same variable set, the newly added variables and the missing variables is determined to obtain the total number of variables; the initial diagonal matrix is constructed according to the total number, and the values of the corresponding positions of the rows and columns of the same values in the initial diagonal matrix are one; the values in the rows corresponding to the missing variables in the initial diagonal matrix are changed from one to zero to obtain the target diagonal matrix.
[0126] For example, in an industrial process, there are three variables, variable A, variable B, and variable C. At a certain time point t-1, the observed variable set is S t-1 ={A,B}. At time point t, the set of observed variables becomes S t ={A,C}. Diagonal matrix Θ t-1 and θ tThey are all 3×3 matrices (because there are three variables).
[0127] For Θ t-1 , since we observe variables A and B, so [Θ] 1,1 =1,[θ] 2,2 =1, and other positions are 0.
[0128] For Θ t , we observe variables A and C, so [Θ] 1,1 =1,[θ] 3,3 =1, and other positions are 0.
[0129] For the target diagonal matrix at a time point, since in S t Variable B is missing in , so the value of row B and column B corresponding to variable B in the initial diagonal matrix is changed from 1 to 0, and the target diagonal matrix is obtained as
[0130] In some implementations, determining the loss value based on the target abnormality type labeled by the target abnormal sample data and the degree of relevance of each of the classifiers to be trained includes:
[0131] (4.1) determining a first classifier to be trained corresponding to a target abnormal type marked by the target abnormal sample data;
[0132] (4.2) selecting a second classifier to be trained with the greatest correlation from other classifiers to be trained, wherein the other classifier to be trained is a classifier in each classifier to be trained except the first classifier to be trained;
[0133] (4.3) obtaining a first correlation degree of the first classifier to be trained and a second correlation degree of the second classifier to be trained;
[0134] (4.4) determining a difference from the first correlation degree to obtain a first determination result;
[0135] (4.5) determining a sum of the first determination result and the second correlation degree to obtain a second determination result;
[0136] (4.6) when the second determination result is greater than zero, determining the second determination result as a loss value;
[0137] (4.7) When the second determination result is less than zero, zero is determined as the loss value.
[0138] Among them, the loss value for the classifier is Therefore, it is necessary to train the first classifier corresponding to the target abnormal type marked by the target abnormal sample data. For example, if the target abnormal type marked by the target abnormal sample data is a, then the first classifier to be trained is is converted to Since the target feature representation q of the target abnormal sample data is not known at this time t , so the initial feature representation of the target abnormal sample data is calculated The degree of correlation with each classifier other than the first classifier (other classifiers to be trained), and then select the classifier with the largest degree of correlation as the second classifier to be trained, that is, If the exception type corresponding to the second classifier is b, then is converted to The first degree of correlation is The second correlation is The first result is determined to be The second determination result is
[0139] Specifically, if the second determination result is greater than zero, there is a loss value, and the second determination result is determined as the loss value; if the second determination result is equal to zero, there is no loss value, and the loss value is determined to be zero. This process determines the loss value by comparing the correlation between the classifier corresponding to the target anomaly type and other classifiers and the feature representation, which is used for subsequent updating of the parameters of the feature representation estimator and classifier to improve the model's ability to accurately judge the anomaly type.
[0140] In some implementations, updating the network parameters of the classifier to be trained based on the target feature representation, the loss value, and the degree of correlation corresponding to each classifier to be trained includes:
[0141] (7.1) When the loss value is not zero, calculating the product of a preset learning rate and the target feature representation to obtain an updated parameter;
[0142] (7.2) determining a sum of the first classifier to be trained and the update parameter to obtain a third determination result;
[0143] (7.3) updating the network parameters of the first classifier to be trained to the third determination result;
[0144] (7.4) determining a difference between the second classifier to be trained and the updated parameter to obtain a fourth determination result;
[0145] (7.5) Update the network parameters of the second classifier to be trained to the fourth determination result.
[0146] Among them, at a fixed q tand L t When W is updated t , that is, calculation To W t The partial derivative of , we can get the following W t Update rules:
[0147]
[0148] Among them, when the loss value is not zero, it means that there is a certain error in the classification result of the classifier on the current target abnormal sample data, and the parameters of the classifier need to be adjusted. The preset learning rate is η t , the target feature is represented as t , then the update parameter is η t q t The learning rate controls the step size of the parameter update. If the loss value is not zero, the first classifier to be trained corresponding to the target anomaly type The update method is This is the third determination result. This means that the first classifier is updated in the direction of making it more relevant to the target feature representation to reduce the loss. The update method is That is the fourth determination result, which is an update in the direction of making the second classifier irrelevant to the target feature representation, because the current loss value shows that the second classifier performs too well on the current sample relative to the first classifier, and needs to be adjusted to reduce its correlation with the feature representation.
[0149] In some implementations, updating the initial feature representation based on the adjusted feature representation estimator to be trained, the target diagonal matrix, the target abnormal sample data, and the loss value to obtain a target feature representation corresponding to the target abnormal sample data includes:
[0150] (5.1) determining whether the loss value is zero, so as to determine a target optimization formula from a preset optimization formula;
[0151] (5.2) Substituting the adjusted feature representation estimator to be trained, the target diagonal matrix and the target abnormal sample data into the target optimization formula to determine the optimization parameters;
[0152] (5.3) Determine the difference between the initial feature representation and the optimized parameter to obtain the target feature representation corresponding to the target abnormal sample data.
[0153] Among them, due to the characteristic representation q t The update rule is:
[0154]
[0155] and for still And through the loss value l t Determine, so we need to determine the loss value l t Is it zero? If the loss value is l t If is zero, for If the loss value l t If not zero, for because and Different optimization formulas are used, so the target optimization formula is determined from the preset optimization formulas by determining whether the loss value is zero. Target diagonal matrix Θ t And the target abnormal sample data x t Substitute the target optimization formula to determine the optimization parameters Determine initial characterization With the optimization parameters The difference (which also involves the optimization parameters With the learning rate η t The target feature representation q corresponding to the target abnormal sample data is obtained. t .
[0156] In some implementations, based on the adjusted feature representation estimator to be trained, the target feature representation, and the target diagonal matrix, iteratively updating the network parameters of the feature representation estimator to be trained until the number of training times reaches a preset number of training times, to obtain the updated feature representation estimator to be trained, including:
[0157] (6.1) determining adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation, and the target diagonal matrix;
[0158] (6.2) determining a difference between the adjusted feature representation estimator to be trained and the adjustment parameter, and updating the difference as a network parameter of the adjusted feature representation estimator to be trained;
[0159] (6.3) Increase the number of iterations by one;
[0160] (6.4) When the number of iterations does not reach the preset number of training times, return to the step of determining the adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix until the number of iterations reaches the preset number of training times, thereby obtaining the updated feature representation estimator to be trained.
[0161] Among them, when q is fixed t With W t , when updating the feature representation estimator, calculate For L t The partial derivative of can be calculated for L t The update rule is:
[0162]
[0163] Where m is the number of iterations, m≤M, and M is the maximum number of iterations set. The feature representation estimator to be trained after adjustment The first one to be updated during iteration By Substituting this formula, we can get the first iteration Similarly, in the second iteration, As So iteratively get After M iterations, the updated feature representation estimator to be trained that is trained using the target abnormal sample data is finally obtained.
[0164] Specifically, That is, to adjust the parameters, the feature representation estimator to be trained after adjustment Target feature representation t And the target diagonal matrix Θ t Substitute this formula and combine it with the preset learning rate η t , we can get the adjustment parameters. The difference between the adjusted parameters is used to update the network parameters of the feature representation estimator to be trained, that is, The number of iterations is changed from zero to one. If M is set to 20, since 1<20, the step of determining the adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix is returned until the number of iterations reaches the preset training number (M), and the updated feature representation estimator to be trained L is obtained. t .
[0165] The following will explain from the perspective of argument whether it is possible to extract the abnormal data sample x containing missing variables. t The projection operator Learn accurate feature representation q t , and whether the incremental update strategy for the classifier is effective.
[0166] The first assumption is: Assume that any abnormal sample are uniformly bounded, that is,
[0167] The second assumption is: Assume that the feature representation estimator L t , characteristic representation q t and classifier W t are uniformly bounded, that is, and is the feature representation estimator L t The uniform boundedness conditions of Characterize q t The uniform boundedness conditions of is the classifier W t The uniform boundedness condition of .
[0168] If the learned subspace feature representation is accurate enough, it can be obtained by q even in the presence of missing variables. t The abnormal data x t Reconstructed (i.e. ). To ensure that the algorithm can learn accurate feature representation in the presence of missing measurements, it is necessary to ensure that the proportion of non-missing variables in each data is large enough. For insufficiently observed data, no algorithm can learn accurate features from a pathological data. The following theorem gives the minimum bound of ρ:
[0169] For the time length t B The variable dimensions in data. The rank of In order to get the missing data x t The projection operator Get accurate feature representation in the non-missing ratio of each data due:
[0170]
[0171] In order to obtain some of the observed data To learn accurate feature representations, we must ensure that the number of observations is at least equal to the matrix The degrees of freedom are equivalent to ρS. Therefore, the minimum non-missing proportion ρ is limited by the degrees of freedom. Since the number of variables successfully observed in each data is ρS t , requiring ρS t T B ≥2T B RR 2 -R, where 2T B RR 2 -R is the degree of freedom of the matrix of rank R. By changing this inequality, we can get ρ.
[0172] If the proportion of non-missing variables in the sample is less than ρ, then no algorithm can convert Refactor to Therefore, it is impossible to learn accurate feature representation q t It should be noted that this condition is only a necessary condition. In some cases, such as the case of random missing, due to the influence of the coupon effect, it is not enough to just meet ρ. Usually more observations are needed to ensure it.
[0173] The performance of the proposed incremental anomaly diagnosis model is evaluated by introducing the concept of regret field. t With batch diagnosis model The performance difference is quantified by the cumulative loss difference between:
[0174]
[0175] Among them, setting (q 1 ,y 1 ),…,(q T ,y T ) is given by the formula The obtained subspace feature representation, W t , t∈[T] is given by the formula By setting the learning rate to For any The following sublinear regret bound can be obtained:
[0176]
[0177] According to the update rule of the classifier, we can get:
[0178]
[0179] The above formula can be changed to:
[0180]
[0181] Due to the convexity of the classifier loss function l(), the following formula is obtained:
[0182]
[0183] Combining the above two formulas and summing them over T, we get:
[0184]
[0185] According to the second assumption, we can get Substituting into the above formula we get:
[0186]
[0187] Since the learning rate is set to Then we can get the sublinear upper bound of the regret domain:
[0188]
[0189] Since the regret domain is sublinear, we can conclude that when T→+∞, This shows that over time, the performance of the proposed anomaly diagnosis model can asymptotically approach the performance of the optimal anomaly diagnosis model. Therefore, the incremental update strategy of the anomaly diagnosis model is effective in the case of variable space evolution.
[0190] The specific implementation of the above steps can be found in the previous embodiments, which will not be described in detail here.
[0191] In order to better implement the data processing method provided in the embodiment of the present application, the embodiment of the present application also provides a device based on the above data processing method. The meanings of the terms are the same as those in the above data processing method, and the specific implementation details can refer to the description in the method embodiment.
[0192] See also Figure 5 , Figure 5 The data processing device provided in the embodiment of the present application is a schematic diagram of the structure of the data processing device, which is applied to a computer device. The data processing device may include an input unit 601, a first determination unit 602, a screening unit 603, and a second determination unit 604.
[0193] An input unit 601 is used to obtain abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace;
[0194] A first determining unit 602 is used to determine the degree of association between each trained classifier and the feature representation, and obtain the degree of association corresponding to each trained classifier;
[0195] A screening unit 603 is used to screen out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determine a trained target classifier corresponding to the target correlation degree;
[0196] The second determining unit 604 is configured to determine a target abnormality type corresponding to the trained target classifier based on a preset mapping relationship between the abnormality type and the trained classifier.
[0197] In some embodiments, the device is further used to:
[0198] Determine unused target abnormal sample data in the abnormal sample data set in time order, and obtain previous control abnormal sample data that is before the target abnormal sample data in time order, wherein the abnormal sample data set includes a plurality of abnormal sample data in time order, and each abnormal sample data is marked with an abnormal type;
[0199] Based on the target variables included in the target abnormal sample data and the control variables of the control abnormal sample data, adjusting the feature characterization estimator to be trained to obtain the adjusted feature characterization estimator to be trained, and constructing a target diagonal matrix;
[0200] Determining an initial feature representation of the target abnormal sample data based on the adjusted feature representation estimator to be trained, the target diagonal matrix, and the target abnormal sample data;
[0201] Determining the degree of correlation between the initial feature representation and each classifier to be trained, and determining a loss value based on the target abnormality type marked by the target abnormal sample data and the degree of correlation between each classifier to be trained;
[0202] Based on the adjusted feature representation estimator to be trained, the target diagonal matrix, the target abnormal sample data, and the loss value, updating the initial feature representation to obtain a target feature representation corresponding to the target abnormal sample data;
[0203] Based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix, iteratively updating the network parameters of the feature representation estimator to be trained until the number of training times reaches a preset number of training times, thereby obtaining an updated feature representation estimator to be trained;
[0204] Based on the target feature representation, the loss value, and the correlation degree corresponding to each classifier to be trained, updating the network parameters of the classifier to be trained;
[0205] When there is unused abnormal sample data in the abnormal sample data set, return to execute the step of determining the unused target abnormal sample data in the abnormal sample data set according to the time sorting until there is no unused abnormal sample data in the abnormal sample data set, thereby obtaining a trained feature representation estimator and each trained classifier.
[0206] In some embodiments, the device is further used to:
[0207] Determine the intersection of the target variable included in the target abnormal sample data and the control variable of the control abnormal sample data to obtain a set of identical variables;
[0208] Determine a newly added variable in the target variable that is not in the same variable set;
[0209] determining missing variables in the control variables that are not in the same set of variables;
[0210] The rows corresponding to the missing variables in the feature characterization estimator to be trained are deleted, and the newly added rows are processed according to the newly added variables in the feature characterization estimator to be trained to obtain an adjusted feature characterization estimator to be trained.
[0211] In some embodiments, the device is further used to:
[0212] Determine the sum of the variables in the same variable set, the newly added variables, and the missing variables to obtain the total number of variables;
[0213] Constructing an initial diagonal matrix according to the total number, wherein the values of the corresponding positions of the rows and columns with the same values in the initial diagonal matrix are 1;
[0214] The values in the rows corresponding to the missing variables in the initial diagonal matrix are changed from one to zero to obtain a target diagonal matrix.
[0215] In some embodiments, the device is further used to:
[0216] Determine a first classifier to be trained corresponding to the target abnormal type marked by the target abnormal sample data;
[0217] Selecting a second classifier to be trained with the greatest correlation from other classifiers to be trained, wherein the other classifier to be trained is a classifier other than the first classifier to be trained in each classifier to be trained;
[0218] Acquire a first correlation degree of the first classifier to be trained and a second correlation degree of the second classifier to be trained;
[0219] Determine a difference with the first correlation degree to obtain a first determination result;
[0220] Determine a sum of the first determination result and the second correlation degree to obtain a second determination result;
[0221] When the second determination result is greater than zero, determining the second determination result as a loss value;
[0222] When the second determination result is less than zero, zero is determined as the loss value.
[0223] In some embodiments, the device is further used to:
[0224] When the loss value is not zero, calculating the product of a preset learning rate and the target feature representation to obtain an update parameter;
[0225] Determine the sum of the first classifier to be trained and the update parameter to obtain a third determination result;
[0226] Updating the network parameters of the first classifier to be trained to the third determination result;
[0227] Determine a difference between the second classifier to be trained and the updated parameter to obtain a fourth determination result;
[0228] The network parameters of the second classifier to be trained are updated to the fourth determination result.
[0229] In some embodiments, the device is further used to:
[0230] Determining whether the loss value is zero to determine a target optimization formula from a preset optimization formula;
[0231] Substituting the adjusted feature representation estimator to be trained, the target diagonal matrix and the target abnormal sample data into the target optimization formula to determine the optimization parameters;
[0232] The difference between the initial feature representation and the optimized parameter is determined to obtain a target feature representation corresponding to the target abnormal sample data.
[0233] In some embodiments, the device is further used to:
[0234] Determining adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation, and the target diagonal matrix;
[0235] Determine the difference between the adjusted feature characterization estimator to be trained and the adjustment parameter, and update the difference as the network parameter of the adjusted feature characterization estimator to be trained;
[0236] Increase the number of iterations by one;
[0237] When the number of iterations does not reach the preset number of training times, return to the step of determining the adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix until the number of iterations reaches the preset number of training times, thereby obtaining the updated feature representation estimator to be trained.
[0238] The specific implementation of each of the above units can be found in the previous embodiments, which will not be described in detail here.
[0239] As can be seen from the above, the embodiment of the present application obtains abnormal data through the input unit 601, inputs the abnormal data into the trained feature representation estimator, and determines the feature representation of the abnormal data in the preset subspace; the first determination unit 602 determines the degree of association between each trained classifier and the feature representation, and obtains the degree of association corresponding to each trained classifier; the screening unit 603 screens out the target degree of association with the largest degree of association from multiple degrees of association, and determines the trained target classifier corresponding to the target degree of association; the second determination unit 604 determines the target abnormal type corresponding to the trained target classifier based on the preset mapping relationship between the abnormal type and the trained classifier. In this way, the feature representation of the abnormal data in the preset subspace is determined by the trained feature representation estimator, so that the data in different variable spaces are measurable in this preset subspace, and then the abnormal type is determined according to the feature representation, which can avoid the problem of poor accuracy of abnormal diagnosis caused by assuming that the monitoring data has a homogeneous variable space, and improve the accuracy of abnormal diagnosis.
[0240] The specific implementation of each of the above units can be found in the previous embodiments, which will not be described in detail here.
[0241] Reference Figure 6 , Figure 6 The block diagram of the structure of part of the computer device 110 for implementing the embodiment of the present disclosure. The computer device 110 may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPUs) 622 (for example, one or more processors) and memory 632, and one or more storage media 630 (for example, one or more mass storage devices) storing application programs 642 or data 644. Among them, the memory 632 and the storage medium 630 can be temporary storage or permanent storage. The program stored in the storage medium 630 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations on the server 600. Furthermore, the central processing unit 622 can be configured to communicate with the storage medium 630 and execute a series of instruction operations in the storage medium 630 on the server 600.
[0242] The computer device 110 may also include one or more power supplies 626, one or more wired or wireless network interfaces 650, one or more input and output interfaces 658, and / or one or more operating systems 641, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0243] The central processor 622 in the computer device 110 may be used to execute the data processing method of the embodiment of the present disclosure, for example:
[0244] Acquire abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace;
[0245] Determining the degree of association between each trained classifier and the feature representation, and obtaining the degree of association corresponding to each trained classifier;
[0246] Screening out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determining a trained target classifier corresponding to the target correlation degree;
[0247] Based on a preset mapping relationship between anomaly types and trained classifiers, a target anomaly type corresponding to the trained target classifier is determined.
[0248] The embodiments of the present disclosure further provide a computer-readable storage medium, which is used to store program codes, and the program codes are used to execute the data processing methods of the aforementioned embodiments.
[0249] The present disclosure also provides a computer program product, which includes a computer program. The processor of a computer device reads and executes the computer program, so that the computer device executes the above-mentioned data processing method. For example:
[0250] Acquire a first object image, determine a first segmentation mask of a target object in the first object image, wherein the first segmentation mask is used to characterize different parts of the target object, and the first object image is an image of the target object at the first viewing angle;
[0251] Determine a first posture image of the target object at a second viewing angle;
[0252] Inputting the first segmentation mask and the first posture image into a trained posture encoder to extract posture features of the target object at the second viewing angle;
[0253] Inputting the first object image into a trained appearance encoder to extract overall appearance features of the target object, wherein the overall appearance features include appearance features corresponding to each appearance dimension;
[0254] Inputting each of the appearance features and the posture features into different trained part feature generators to obtain multiple part features;
[0255] Each of the part features is fused to obtain a fused feature, and the fused feature is input into a trained rendering network to generate a second object image, where the second object image is an image of the target object at the second viewing angle.
[0256] In addition, the terms "comprises" and "includes" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or apparatus that includes a series of steps or elements is not necessarily limited to those steps or elements explicitly listed, but may include other steps or elements not explicitly listed or inherent to such process, method, product or apparatus.
[0257] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0258] It should be understood that in the description of the embodiments of the present application, the meaning of multiple (or multiple items) is more than two, greater than, less than, exceed, etc. are understood to not include the number, and above, below, within, etc. are understood to include the number.
[0259] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0260] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0261] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0262] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store program codes.
[0263] It should also be understood that the various implementations provided in the embodiments of the present application can be combined arbitrarily to achieve different technical effects.
[0264] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories) or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be part of an overall module or unit that includes the function of the module or unit.
[0265] The above is a specific description of the implementation method of the present application, but the present application is not limited to the above-mentioned implementation method. Technical personnel familiar with the field can also make various equivalent modifications or substitutions without violating the spirit of the present application. These equivalent modifications or substitutions are all included in the scope defined by the claims of the present application.
Claims
1. A data processing method, characterized in that: include: Acquire abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace; Determining the degree of association between each trained classifier and the feature representation, and obtaining the degree of association corresponding to each trained classifier; Screening out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determining a trained target classifier corresponding to the target correlation degree; Based on a preset mapping relationship between anomaly types and trained classifiers, a target anomaly type corresponding to the trained target classifier is determined.
2. The data processing method according to claim 1, characterized in that: Before obtaining the abnormal data, inputting the abnormal data into the trained feature representation estimator, and determining the feature representation of the abnormal data in a preset subspace, the method further includes: Determine unused target abnormal sample data in the abnormal sample data set in time order, and obtain previous control abnormal sample data that is before the target abnormal sample data in time order, wherein the abnormal sample data set includes a plurality of abnormal sample data in time order, and each abnormal sample data is marked with an abnormal type; Based on the target variables included in the target abnormal sample data and the control variables of the control abnormal sample data, adjusting the feature characterization estimator to be trained to obtain the adjusted feature characterization estimator to be trained, and constructing a target diagonal matrix; Determining an initial feature representation of the target abnormal sample data based on the adjusted feature representation estimator to be trained, the target diagonal matrix, and the target abnormal sample data; Determining the degree of correlation between the initial feature representation and each classifier to be trained, and determining a loss value based on the target abnormality type marked by the target abnormal sample data and the degree of correlation between each classifier to be trained; Based on the adjusted feature representation estimator to be trained, the target diagonal matrix, the target abnormal sample data, and the loss value, updating the initial feature representation to obtain a target feature representation corresponding to the target abnormal sample data; Based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix, iteratively updating the network parameters of the feature representation estimator to be trained until the number of training times reaches a preset number of training times, thereby obtaining an updated feature representation estimator to be trained; Based on the target feature representation, the loss value, and the correlation degree corresponding to each classifier to be trained, updating the network parameters of the classifier to be trained; When there is unused abnormal sample data in the abnormal sample data set, return to execute the step of determining the unused target abnormal sample data in the abnormal sample data set according to the time sorting until there is no unused abnormal sample data in the abnormal sample data set, thereby obtaining a trained feature representation estimator and each trained classifier.
3. The data processing method according to claim 2, characterized in that: Each row of the feature characterization estimator to be trained represents a variable, and the feature characterization estimator to be trained is adjusted based on the target variable included in the target abnormal sample data and the control variable of the control abnormal sample data to obtain the adjusted feature characterization estimator to be trained, including: Determine the intersection of the target variable included in the target abnormal sample data and the control variable of the control abnormal sample data to obtain a set of identical variables; Determine a newly added variable in the target variable that is not in the same variable set; determining missing variables in the control variables that are not in the same set of variables; The rows corresponding to the missing variables in the feature characterization estimator to be trained are deleted, and the newly added rows are processed according to the newly added variables in the feature characterization estimator to be trained to obtain an adjusted feature characterization estimator to be trained.
4. The data processing method according to claim 3, characterized in that: The constructing of the target diagonal matrix comprises: Determine the sum of the variables in the same variable set, the newly added variables, and the missing variables to obtain the total number of variables; Constructing an initial diagonal matrix according to the total number, wherein the values of the corresponding positions of the rows and columns with the same values in the initial diagonal matrix are 1; The values in the rows corresponding to the missing variables in the initial diagonal matrix are changed from one to zero to obtain a target diagonal matrix.
5. The data processing method according to claim 2, characterized in that: The determining of the loss value based on the target abnormality type marked by the target abnormal sample data and the correlation degree of each of the classifiers to be trained includes: Determine a first classifier to be trained corresponding to the target abnormal type marked by the target abnormal sample data; Selecting a second classifier to be trained with the greatest correlation from other classifiers to be trained, wherein the other classifier to be trained is a classifier other than the first classifier to be trained in each classifier to be trained; Acquire a first correlation degree of the first classifier to be trained and a second correlation degree of the second classifier to be trained; Determine a difference with the first correlation degree to obtain a first determination result; Determine a sum of the first determination result and the second correlation degree to obtain a second determination result; When the second determination result is greater than zero, determining the second determination result as a loss value; When the second determination result is less than zero, zero is determined as the loss value.
6. The data processing method according to claim 5, characterized in that: The updating of the network parameters of the classifier to be trained based on the target feature representation, the loss value and the correlation degree corresponding to each classifier to be trained includes: When the loss value is not zero, calculating the product of a preset learning rate and the target feature representation to obtain an update parameter; Determine the sum of the first classifier to be trained and the update parameter to obtain a third determination result; Updating the network parameters of the first classifier to be trained to the third determination result; Determine a difference between the second classifier to be trained and the updated parameter to obtain a fourth determination result; The network parameters of the second classifier to be trained are updated to the fourth determination result.
7. The data processing method according to claim 2, characterized in that: The updating of the initial feature representation based on the adjusted feature representation estimator to be trained, the target diagonal matrix, the target abnormal sample data and the loss value to obtain a target feature representation corresponding to the target abnormal sample data includes: Determining whether the loss value is zero to determine a target optimization formula from a preset optimization formula; Substituting the adjusted feature representation estimator to be trained, the target diagonal matrix and the target abnormal sample data into the target optimization formula to determine the optimization parameters; The difference between the initial feature representation and the optimized parameter is determined to obtain a target feature representation corresponding to the target abnormal sample data.
8. The data processing method according to claim 2, characterized in that: The iterative updating of the network parameters of the feature characterization estimator to be trained based on the adjusted feature characterization estimator to be trained, the target feature characterization and the target diagonal matrix until the number of training times reaches a preset number of training times, to obtain the updated feature characterization estimator to be trained, comprises: Determining adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation, and the target diagonal matrix; Determine the difference between the adjusted feature characterization estimator to be trained and the adjustment parameter, and update the difference as the network parameter of the adjusted feature characterization estimator to be trained; Increase the number of iterations by one; When the number of iterations does not reach the preset number of training times, return to the step of determining the adjustment parameters based on the adjusted feature representation estimator to be trained, the target feature representation and the target diagonal matrix until the number of iterations reaches the preset number of training times, thereby obtaining the updated feature representation estimator to be trained.
9. A data processing device, characterized in that: include: An input unit, used to obtain abnormal data, input the abnormal data into a trained feature representation estimator, and determine a feature representation of the abnormal data in a preset subspace; A first determining unit is used to determine the degree of association between each trained classifier and the feature representation, and obtain the degree of association corresponding to each trained classifier; A screening unit, used for screening out a target correlation degree with the greatest correlation degree from the plurality of correlation degrees, and determining a trained target classifier corresponding to the target correlation degree; The second determining unit is used to determine the target abnormality type corresponding to the trained target classifier based on a preset mapping relationship between the abnormality type and the trained classifier.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor to execute the data processing method according to any one of claims 1 to 8.
11. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the data processing method according to any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
Medical data processing method and device
CN116453686A
Anomaly detection method and anomaly detection system
US20120316835A1
Anomaly detection for context-dependent data
WO2016177566A1