Training method and device for user data generation model
Through the adversarial training of the variational optimization Gaussian mixture model and the GAN4UD model, simulated data that is consistent with the characteristics of real user data is generated, which solves the problem of user data generation and improves the performance and intelligence level of the abnormal behavior recognition model.
Patent Information
- Application Number
- CN202410827979.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-25
- Publication Date
- 2024-10-01
AI Technical Summary
There are difficulties in how to generate user data more effectively in the existing technology, especially in the release of data value under privacy constraints, and it is difficult to achieve modeling that is not weaker than real user data.
The feature encoder based on the variational optimization Gaussian mixture model is used to splice the random noise vector and the conditional feature vector of the user's abnormal behavior type label, generate a synthetic data feature vector, and input it into the GAN4UD model for adversarial training, including generator, discriminator The machine and classifier are iteratively optimized using a specific loss function until the preset training conditions are met, and the user data generation model is obtained.
On the premise of protecting user privacy, simulated data that is consistent with real user data characteristics and meets specific conditions is generated to improve the performance and intelligence level of the abnormal behavior identification model.
Smart Images

Figure CN118734220A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a training method and device for a user data generation model. Background Art
[0002] With the continuous development of technology, there are many abnormal user behaviors that will cause great trouble to users, so it is very important to effectively monitor these abnormal behavior data.
[0003] Related technologies usually use model training to carry out this work, which usually requires a large amount of data. User data usually involves privacy issues and is not easy to obtain on a large scale. Therefore, synthetic data emerges as an alternative that can complete modeling that is no weaker than real user data while satisfying privacy constraints, effectively releasing the value of data.
[0004] Therefore, how to generate user data more effectively has become an urgent problem to be solved in the industry. Summary of the invention
[0005] The present invention provides a training method and device for a user data generation model, which is used to solve the problem in the prior art that how to more effectively generate user data has become an urgent problem to be solved in the industry.
[0006] The present invention provides a training method for a user data generation model, comprising:
[0007] The random noise vector and the conditional feature vector of the user abnormal behavior type label are concatenated by a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining a plurality of synthetic data feature data vectors;
[0008] Input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when the preset training conditions are met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0009] According to a training method for a user data generation model provided by the present invention, the synthetic data feature data vector is input into a GAN4UD model for adversarial training, comprising:
[0010] Inputting the synthetic data feature data vector into a generator in a GAN4UD model, and outputting synthetic user data;
[0011] The synthetic user data is discriminated by a discriminator in the GAN4UD model, and a first loss value is calculated according to a generator loss function;
[0012] According to the first loss value, update the parameters of the generator using a gradient descent algorithm;
[0013] Inputting the real user data and the synthetic user data into the discriminator in the GAN4UD model for discrimination, and calculating a second loss value according to the discriminator loss function;
[0014] The generator and the discriminator are trained alternately until preset training conditions are met to obtain a user data generation model.
[0015] According to a training method for a user data generation model provided by the present invention, the classifier in the GAN4UD model is used to classify the synthetic user data and output a target value of abnormal behavior involving the synthetic user data; so as to evaluate the accuracy and reliability of the synthetic user data according to the target value.
[0016] According to a training method for a user data generation model provided by the present invention, the generator loss function includes: original Wasserstein GAN loss with gradient penalty, first information loss, second information loss and third information loss;
[0017] The first information loss is the loss of first-order and second-order statistical information used to associate the synthesized data with the original data;
[0018] The second information loss is used to characterize the correlation between the user's abnormal behavior risk target value and other variables.
[0019] The third information loss is used to characterize the cross entropy between the conditional feature vector and the generated vector.
[0020] According to a training method for a user data generation model provided by the present invention, the generator loss function is specifically:
[0021] L generator =l0+l1+l2+l3;
[0022]
[0023] in, The distribution of and Random mixed sampling, p data (x) and p(z) represent the prior distribution of the real data x and the latent variable z, and denote the first-order and second-order statistical information of the feature vector, respectively. l(·) returns the target value of the risk of abnormal behavior. C(·) returns the result obtained by the auxiliary component C. t i and are the given conditional eigenvector and generated vector of a column, respectively, and H(·) returns the cross entropy.
[0024] According to a method for training a user data generation model provided by the present invention, after the step of obtaining the user data generation model, the method further includes:
[0025] The random noise vector and the conditional feature vector of the user abnormal behavior type label are input into the user data generation model to generate user data of the user abnormal behavior type.
[0026] The present invention also provides a training device for a user data generation model, comprising:
[0027] A splicing module is used to splice the random noise vector and the conditional feature vector of the user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining multiple synthetic data feature data vectors;
[0028] A training module is used to input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when a preset training condition is met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0029] According to a training device for a user data generation model provided by the present invention, the device is also used for:
[0030] Inputting the synthetic data feature data vector into a generator in a GAN4UD model, and outputting synthetic user data;
[0031] The synthetic user data is discriminated by a discriminator in the GAN4UD model, and a first loss value is calculated according to a generator loss function;
[0032] According to the first loss value, update the parameters of the generator using a gradient descent algorithm;
[0033] Inputting the real user data and the synthetic user data into the discriminator in the GAN4UD model for discrimination, and calculating a second loss value according to the discriminator loss function;
[0034] The generator and the discriminator are trained alternately until preset training conditions are met to obtain a user data generation model.
[0035] According to a training device for a user data generation model provided by the present invention, the classifier in the GAN4UD model is used to classify the synthetic user data and output a target value of abnormal behavior involving the synthetic user data; so as to evaluate the accuracy and reliability of the synthetic user data according to the target value.
[0036] According to a training device for a user data generation model provided by the present invention, the generator loss function includes: original Wasserstein GAN loss with gradient penalty, first information loss, second information loss and third information loss;
[0037] The first information loss is the loss of first-order and second-order statistical information used to associate the synthesized data with the original data;
[0038] The second information loss is used to characterize the correlation between the user's abnormal behavior risk target value and other variables.
[0039] The third information loss is used to characterize the cross entropy between the conditional feature vector and the generated vector.
[0040] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, a training method for generating a user data model as described in any one of the above is implemented.
[0041] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a training method for a user data generation model as described in any one of the above.
[0042] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the training method for generating a user data model as described in any one of the above is implemented.
[0043] The training method and device of the user data generation model provided by the present invention propose a GAN4UD model to learn to generate simulated data that is consistent with the characteristics of real user data and meets specific conditions through adversarial training, thereby providing data support for anti-abnormal behavior scenarios while protecting user privacy, and improving the performance and intelligence level of the abnormal behavior recognition model. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0045] Figure 1 A flowchart of a training method for a user data generation model provided in an embodiment of the present application;
[0046] Figure 2 A schematic diagram of the structure of a training device for a user data generation model provided in an embodiment of the present application;
[0047] Figure 3 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0049] The user data used in the embodiments of the present application may specifically be legitimate data that is authorized by the user.
[0050] Figure 1 A flowchart of a training method for a user data generation model provided in an embodiment of the present application is shown in FIG. Figure 1 As shown, including:
[0051] Step 110, concatenating the random noise vector and the conditional feature vector of the user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining a plurality of synthetic data feature data vectors;
[0052] In the embodiment of the present application, first, the generator G receives one or more random noise vectors z. These vectors are usually sampled from a priori distribution (such as Gaussian distribution), introducing randomness into the generation process.
[0053] The conditional feature vector c contains information about the user’s abnormal behavior type labels, which may indicate whether the user is involved in a certain abnormal behavior or other specific conditions.
[0054] In an optional embodiment, facing the real telecom network anti-abnormal behavior scenario, we define the feature variables involved in user data as discrete feature variables, continuous feature variables and mixed feature variables (i.e., variables containing both discrete feature variables and continuous feature variables, or variables containing missing values). Encoding the mixed feature variables through variational optimization Gaussian mixture model
[0055] The k value of the variational optimization Gaussian mixture model is determined by the BIC criterion in Bayesian theory, namely: Using the learned Gaussian mixture model, the data sampling probability distribution is constructed as follows:
[0056]
[0057] Where N is a Gaussian distribution, ω i , μ i , σ i are the weight, mean and standard deviation of each mode respectively.
[0058] In order to encode the values of the continuous region in the distribution of the mixed feature variable, firstly, for the k modes of the Gaussian mixture model, the mode with the largest probability density corresponding to the feature variable value τ is selected and encoded as a one-hot vector β (if the probability density of the corresponding mode μ4 is the largest, then β = [0, 0, 0, 1, 0]), and then each value τ is further associated with the mode with the highest probability and normalized. The normalization formula is: For the encoding of discrete feature variables (such as μ1 and μ5 in the figure), α can be directly set to 0, and its mode is defined as the one-hot vector ξ of all enumerated values. Before sending the data to the discriminator D and the auxiliary component C, the variables are encoded by different feature encoders according to the type and characteristics of the variables. The final encoding is as follows:
[0059]
[0060] Among them, m is the number of mixed feature variables and continuous feature variables, and N is the number of total feature variables. Finally, the synthetic data feature vector is obtained.
[0061] In an embodiment of the present application, a conditional feature vector sampling input method that integrates abnormal behavior type information is proposed in order to filter and rebalance the training data when sampling real data. For example, a certain abnormal behavior data distribution pattern is selected for people of a certain gender or occupation, and logarithmic probability sampling is used instead of traditional uniform frequency sampling. At the same time, the user's abnormal behavior type label is used as the input of the generator, that is, the generator is given additional information to guide it to better generate user data in anti-abnormal behavior scenarios.
[0062] Step 120, inputting at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stopping the training when a preset training condition is met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator, and a classifier.
[0063] In an embodiment of the present application, at least one synthetic data feature data vector is input into the GAN4UD model.
[0064] Adversarial training: The GAN4UD model consists of three parts: the generator, the discriminator, and the classifier. The generator is responsible for generating simulated user data, the discriminator is responsible for determining whether the data is real or simulated, and the classifier is responsible for classifying the data type.
[0065] Loss Function: The GAN4UD model is trained using specific loss functions, including:
[0066] Original Wasserstein GAN loss with gradient penalty: ensures that the data generated by the generator is consistent with the real data distribution.
[0067] Information loss: Ensure that the first-order and second-order statistics of the generated data are consistent with the real data.
[0068] Target loss for abnormal behavior risks: Ensure that the characteristics of the generated data in terms of abnormal behavior risks are consistent with the real data.
[0069] Cross entropy loss: ensures that the generated data is consistent with the conditional feature vector (user abnormal behavior type label).
[0070] Iterative optimization: Use the loss function to guide the parameter update of the generator and discriminator, and perform iterative training until the model performance reaches the preset target or the number of training reaches the preset value.
[0071] User data generation: Use trained user data to generate models and generate simulated user data as needed for model training or business applications in anti-abnormal behavior scenarios.
[0072] In an embodiment of the present application, the GAN4UD model learns to generate simulated data that is consistent with the characteristics of real user data and meets specific conditions through adversarial training, thereby providing data support for anti-abnormal behavior scenarios while protecting user privacy, thereby improving the performance and intelligence level of the anti-abnormal behavior model.
[0073] Optionally, inputting the synthetic data feature data vector into a GAN4UD model for adversarial training, including:
[0074] Inputting the synthetic data feature data vector into a generator in a GAN4UD model, and outputting synthetic user data;
[0075] The synthetic user data is discriminated by a discriminator in the GAN4UD model, and a first loss value is calculated according to a generator loss function;
[0076] According to the first loss value, update the parameters of the generator using a gradient descent algorithm;
[0077] Inputting the real user data and the synthetic user data into the discriminator in the GAN4UD model for discrimination, and calculating a second loss value according to the discriminator loss function;
[0078] The generator and the discriminator are trained alternately until preset training conditions are met to obtain a user data generation model.
[0079] In the embodiment of the present application, the synthetic data feature data vector is input into the generator, and the generator generates simulated user data according to the input feature data vector.
[0080] The generated simulated data is input into the discriminator, which determines whether the data is real or simulated. Based on the output of the discriminator, the generator loss function is used to calculate the first loss value. Based on the first loss value, the parameters of the generator are updated using the gradient descent algorithm so that it can generate more realistic simulated data.
[0081] The real user data and the simulated user data generated by the generator are input into the discriminator. The discriminator determines whether each piece of data is real or simulated. Based on the output of the discriminator, the second loss value is calculated using the discriminator loss function. Based on the second loss value, the parameters of the discriminator are updated using the gradient descent algorithm so that it can more accurately determine the authenticity of the data.
[0082] Cyclic training: The training process of the generator and the discriminator is carried out alternately. First train the generator, then train the discriminator, then train the generator, and so on, until the preset training conditions are met (for example, the model performance reaches the preset target or the number of training reaches the preset value).
[0083] Through alternating training, the generator will continue to learn to generate more realistic simulated data, while the discriminator will continue to learn to more accurately judge the authenticity of the data. Eventually, the generator can generate simulated data that is consistent with the characteristics of real user data and difficult for the discriminator to distinguish.
[0084] In the embodiment of the present application, the adversarial training process of the GAN4UD model is an iterative optimization process, which continuously updates the parameters of the generator and the discriminator, so that the generator can eventually generate simulated data that is consistent with the characteristics of real user data and difficult to distinguish by the discriminator.
[0085] In the embodiment of the present application, an auxiliary component, classifier C, is added on the basis of the original GAN model architecture. An MLP (containing four hidden layers of 256-dimensional neurons) is used to train the classifier on the original data to better interpret the semantic integrity and ensure the data synthesis quality of the anti-abnormal behavior scenario.
[0086] In the embodiment of the present application, the simulated user data generated by the generator is input into the classifier.
[0087] The classifier will classify the input simulated user data, and the output data involves the target value of abnormal behavior. For example, the classifier can determine which type of abnormal behavior the simulated user data belongs to, and use the target value output by the classifier to evaluate the accuracy and reliability of the simulated user data. For example, the classification accuracy of the classifier for the simulated user data can be calculated, or the prediction error of the classifier for the target value of abnormal behavior of the simulated user data can be calculated.
[0088] Optionally, the generator loss function includes: original Wasserstein GAN loss with gradient penalty, first information loss, second information loss and third information loss;
[0089] The first information loss is the loss of first-order and second-order statistical information used to associate the synthesized data with the original data;
[0090] The second information loss is used to characterize the correlation between the user's abnormal behavior risk target value and other variables.
[0091] The third information loss is used to characterize the cross entropy between the conditional feature vector and the generated vector.
[0092] Specifically, in the embodiment of the present application, the generator loss function includes four parts, namely the original Wasserstein GAN loss L0 with gradient penalty, the first information loss L1, the second information loss L2, and the third information loss L3.
[0093] The original GAN generator loss function is:
[0094]
[0095] in, The distribution of and Random mixed sampling is obtained, that is:
[0096]
[0097] The first information loss L1 associates the first-order and second-order statistical information of the synthetic user data and the original user data, ensuring the consistency of the statistical features. Its expression is:
[0098]
[0099] Among them, p data (x) and p(z) represent the prior distribution of the real data x and the latent variable z, and Represent the first-order and second-order statistics of the eigenvectors, respectively.
[0100] The second information loss L2 characterizes the correlation between the user's abnormal behavior risk target value and other variables, while ensuring semantic integrity, it punishes the incorrect synthetic data in the user data semantics. Its expression is:
[0101]
[0102] Among them, l(·) returns the target value of the risk of abnormal behavior, and C(·) returns the result obtained by the auxiliary component C.
[0103] The third information loss L3 is defined as the cross entropy between the given conditional feature vector and the generated vector, which makes the conditional generator synthesize the same synthetic data as the original data type as much as possible. Its expression is:
[0104]
[0105] Among them, t i and H(·) returns the cross entropy for the given conditional feature vector and generated vector of a column. Here, if random sampling training is used, the categories with a small number of features will not be fully represented and the generator may not be trained correctly. Therefore, we make the conditional user data of the i-th column match the generated user data as much as possible, so that all categories in the user attributes are sampled regularly during training.
[0106] The loss function of the generator G is L generator =L0+L1+L2+L3.
[0107] The training objective function of the discriminator D is the same as that of the original GAN. The generator network and the discriminator network are trained alternately with the objective function until convergence.
[0108] Optionally, after the step of obtaining the user data generation model, the method further includes:
[0109] The random noise vector and the conditional feature vector of the user abnormal behavior type label are input into the user data generation model to generate user data of the user abnormal behavior type.
[0110] In the embodiment of the present application, a random noise vector is generated as the input of the generator. User abnormal behavior type label: Select a specific user abnormal behavior type label.
[0111] The random noise vector and the conditional feature vector of the user's abnormal behavior type label are input into the user data generation model. The generator generates simulated user data based on the input data, which will have features related to the specified abnormal behavior type. The generated simulated user data will have features related to the specified abnormal behavior type and can be used in various anti-abnormal behavior scenarios.
[0112] The training device for the user data generation model provided by the present invention is described below. The training device for the user data generation model described below and the training method for the user data generation model described above can refer to each other.
[0113] Figure 2 A schematic diagram of the structure of a training device for a user data generation model provided in an embodiment of the present application, such as Figure 2 As shown, including:
[0114] The splicing module 210 is used to splice the random noise vector and the conditional feature vector of the user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining multiple synthetic data feature data vectors;
[0115] The training module 220 is used to input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training. When the preset training conditions are met, the training is stopped to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0116] According to a training device for a user data generation model provided by the present invention, the device is also used for:
[0117] Inputting the synthetic data feature data vector into a generator in a GAN4UD model, and outputting synthetic user data;
[0118] The synthetic user data is discriminated by a discriminator in the GAN4UD model, and a first loss value is calculated according to a generator loss function;
[0119] According to the first loss value, update the parameters of the generator using a gradient descent algorithm;
[0120] Inputting the real user data and the synthetic user data into the discriminator in the GAN4UD model for discrimination, and calculating a second loss value according to the discriminator loss function;
[0121] The generator and the discriminator are trained alternately until preset training conditions are met to obtain a user data generation model.
[0122] According to a training device for a user data generation model provided by the present invention, the classifier in the GAN4UD model is used to classify the synthetic user data and output a target value of abnormal behavior involving the synthetic user data; so as to evaluate the accuracy and reliability of the synthetic user data according to the target value.
[0123] According to a training device for a user data generation model provided by the present invention, the generator loss function includes: original Wasserstein GAN loss with gradient penalty, first information loss, second information loss and third information loss;
[0124] The first information loss is the loss of first-order and second-order statistical information used to associate the synthesized data with the original data;
[0125] The second information loss is used to characterize the correlation between the user's abnormal behavior risk target value and other variables.
[0126] The third information loss is used to characterize the cross entropy between the conditional feature vector and the generated vector.
[0127] In an embodiment of the present application, a GAN4UD model is proposed to learn to generate simulated data that is consistent with the characteristics of real user data and meets specific conditions through adversarial training, thereby providing data support for anti-abnormal behavior scenarios and improving the performance and intelligence level of the abnormal behavior recognition model while protecting user privacy.
[0128] Figure 3 is a schematic diagram of the structure of the electronic device provided by the present invention, such as Figure 3 As shown, the electronic device may include: a processor 310, a communication interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communication interface 320 and the memory 330 communicate with each other through the communication bus 340. The processor 310 may call the logic instructions in the memory 330 to execute the training method of the user data generation model, the method comprising: splicing the random noise vector and the conditional feature vector of the user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, and obtaining multiple synthetic data feature data vectors;
[0129] Input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when the preset training conditions are met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0130] In addition, the logic instructions in the above-mentioned memory 330 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of 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 method described in each embodiment of the present invention. 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.
[0131] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored on a non-transitory computer-readable storage medium, and when the computer program is executed by a processor, the computer can execute the training method of the user data generation model provided by the above methods, the method comprising: splicing a random noise vector and a conditional feature vector of a user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, and obtaining multiple synthetic data feature data vectors;
[0132] Input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when the preset training conditions are met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0133] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute the training method of the user data generation model provided by the above methods, the method comprising: concatenating a random noise vector and a conditional feature vector of a user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, and obtaining a plurality of synthetic data feature data vectors;
[0134] Input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when the preset training conditions are met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
[0135] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0136] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0137] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A training method for a user data generation model, characterized in that: include: The random noise vector and the conditional feature vector of the user abnormal behavior type label are concatenated by a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining a plurality of synthetic data feature data vectors; Input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when the preset training conditions are met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
2. The training method for generating a user data model according to claim 1, characterized in that: Inputting the synthetic data feature data vector into the GAN4UD model for adversarial training, including: Inputting the synthetic data feature data vector into a generator in a GAN4UD model, and outputting synthetic user data; The synthetic user data is discriminated by a discriminator in the GAN4UD model, and a first loss value is calculated according to a generator loss function; According to the first loss value, update the parameters of the generator using a gradient descent algorithm; Inputting the real user data and the synthetic user data into the discriminator in the GAN4UD model for discrimination, and calculating a second loss value according to the discriminator loss function; The generator and the discriminator are trained alternately until preset training conditions are met to obtain a user data generation model.
3. The training method for generating a user data model according to claim 2, characterized in that: The classifier in the GAN4UD model is used to classify the synthetic user data and output a target value of abnormal behavior involving the synthetic user data; so as to evaluate the accuracy and reliability of the synthetic user data according to the target value.
4. The training method for generating a user data model according to claim 2, characterized in that: The generator loss function includes: the original Wasserstein GAN loss with gradient penalty, the first information loss, the second information loss and the third information loss; The first information loss is the loss of first-order and second-order statistical information used to associate the synthesized data with the original data; The second information loss is used to characterize the correlation between the user's abnormal behavior risk target value and other variables. The third information loss is used to characterize the cross entropy between the conditional feature vector and the generated vector.
5. The training method for generating a user data model according to claim 4, characterized in that: The generator loss function is specifically: <h2 style=";text-align:left;direction:ltr">L<h2 style=";text-align:left;direction:ltr"> generator <h2 style=";text-align:left;direction:ltr"> (L0+L1+L2+L3) in, The distribution of and Random mixed sampling, p data (x) and p(z) represent the prior distribution of the real data x and the latent variable z, and denote the first-order and second-order statistical information of the feature vector, respectively. l(·) returns the target value of the risk of abnormal behavior. C(·) returns the result obtained by the auxiliary component C. t i and are the given conditional eigenvector and generated vector of a column, respectively, and H(·) returns the cross entropy.
6. The training method for generating a user data model according to claim 1, characterized in that: After the step of obtaining the user data generation model, the method further includes: The random noise vector and the conditional feature vector of the user abnormal behavior type label are input into the user data generation model to generate user data of the user abnormal behavior type.
7. A training device for a user data generation model, characterized in that: include: A splicing module is used to splice the random noise vector and the conditional feature vector of the user abnormal behavior type label through a feature encoder based on a variational optimized Gaussian mixture model to obtain a synthetic data feature vector, thereby obtaining multiple synthetic data feature data vectors; A training module is used to input at least one of the synthetic data feature data vectors into the GAN4UD model for adversarial training, and stop the training when a preset training condition is met to obtain a user data generation model; wherein the GAN4UD model includes a generator, a discriminator and a classifier.
8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, it implements the training method of the user data generation model as described in any one of claims 1 to 6.
9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the training method for generating a user data model according to any one of claims 1 to 6 is implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the training method for generating a user data model according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Text image generation method based on StackGAN network
CN111968193A
Training method and training device of music generation model based on loop feature extraction
CN115206270A
Data processing method and device, electronic equipment and storage medium
CN116596675A
BEV perception model, construction method and device, equipment, vehicle and storage medium
CN117423077A
