Generative adversarial models are used to generate data based on pre-trained models.

CN116569180BActive Publication Date: 2026-08-14INTERNATIONAL BUSINESS MACHINE CORPORATION
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-26
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

然而,这样的模型不能生成不包括在所提供的训练数据的原始分布中的数据

Benefits of technology

[0010] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques in which the determination of a classifier model based at least in part on a first simulated data sample is made using insufficient data samples in the target category. Advantageously, such embodiments allow for the objective evaluation of pre-trained classifiers of unknown or uncertain quality in order to improve the operation of the entire ecosystem.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116569180B_ABST
    Figure CN116569180B_ABST
Patent Text Reader

Abstract

A technique for training a generator model is provided. It receives a classifier model trained using one or more data samples from a target category and trains a generative adversarial network (GAN) to generate simulated data samples for the target category, including: generating a first simulated data sample using the generator model; calculating a first discriminator loss by processing the first simulated data sample using a discriminator model; calculating a classifier loss by processing the first simulated data sample using a classifier model; and refining the generator model based on the first discriminator loss and the classifier loss.
Need to check novelty before this filing date? Find Prior Art

Description

Background Technology

[0001] This disclosure relates to machine learning, and more specifically, to using generative adversarial models to analyze data used to train pre-trained models.

[0002] In recent years, various machine learning models, such as deep learning neural networks, have been trained and applied to a wide range of tasks. Typically, such models require large amounts of training data to operate effectively. In many typical developments, the model is trained on a training dataset and then deployed for service after training. Often, the training data is separate from the model and not available to those who use the trained model.

[0003] In many cases, it is desirable to recover the data originally used to train the model. For example, one might want to recover data that was accidentally deleted. Furthermore, it might be desirable to recover such training data for evaluation purposes to determine the quality of the model (e.g., whether sufficient training data was used). There is no existing technology for extracting training data from a trained model.

[0004] In the field of Generative Adversarial Networks (GANs), GANs have been used to generate data that follows the distribution of the provided training data. However, such models cannot generate data that is not included in the original distribution of the provided training data. Therefore, a typical GAN ​​network cannot recover or generate data that differs from the data it has already seen. Summary of the Invention

[0005] According to one embodiment of the present invention, a method is provided. The method includes receiving a classifier model trained using one or more data samples from a target category; training a generative adversarial network (GAN) to generate simulated data samples for the target category, including: generating a first simulated data sample using the generator model; calculating a first discriminator loss by processing the first simulated data sample using a discriminator model; calculating a classifier loss by processing the first simulated data sample using the classifier model; and refining the generator model based on the first discriminator loss and the classifier loss. Advantageously, this trains the generator to generate training data that simulates, approximates, or matches the target category. This recovery of training data has wide applications.

[0006] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques in which the GAN is trained without processing any data samples from the target category. Advantageously, by training the GAN without processing samples from the target category, the system can recover such data and enable objective and detailed evaluation of the data and the classifier.

[0007] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques for training a GAN that include the following steps: generating a second simulated data sample using the generator model; calculating a second discriminator loss by processing the second simulated data sample using the discriminator model; and refining the discriminator model based on the second discriminator loss. One advantage of this embodiment is that the discriminator model is improved to better distinguish between real and simulated samples, which allows for greater pressure to be applied to the generator model to provide more accurate simulated data.

[0008] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques in which a discriminator model is trained to distinguish between simulated data samples generated by a generator model and data samples used to train a classifier model. Advantageously, such embodiments allow the discriminator to be trained efficiently to ensure that the generator produces accurate data that can be used for training data that is approximately unseen.

[0009] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques for generating first simulated data samples of the target category by providing a randomized input vector to the generator model. Advantageously, this generation of simulated data for completely unseen categories can allow GANs to replicate the original training data to improve evaluation and analysis.

[0010] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques in which the determination of a classifier model based at least in part on a first simulated data sample is made using insufficient data samples in the target category. Advantageously, such embodiments allow for the objective evaluation of pre-trained classifiers of unknown or uncertain quality in order to improve the operation of the entire ecosystem.

[0011] According to some embodiments of this disclosure, any combination of the above embodiments may further include techniques for determining, at least in part, that data samples in the target category used to train the classifier model include one or more suspicious features based on a first simulated data sample. Advantageously, such embodiments allow for the objective evaluation of pre-trained classifiers of unknown or uncertain quality in order to improve the operation of the entire ecosystem.

[0012] According to different embodiments of this disclosure, any combination of the above embodiments can be implemented by one or more computer-readable storage media. The computer-readable storage media collectively include computer program code that, when executed by operations of one or more computer processors, performs operations. In the embodiments, the performed operations can correspond to any combination of the above methods and embodiments.

[0013] According to yet another embodiment of this disclosure, any combination of the above embodiments can be implemented by a system. The system includes one or more computer processors and one or more memories, which together include a program that, when executed by the one or more computer processors, performs operations. In the embodiments, the operations performed can correspond to any combination of the methods and embodiments described above. Attached Figure Description

[0014] Figure 1 Workflows according to some embodiments disclosed herein are described for training a generative adversarial model to rediscover training data used for a pre-trained classifier.

[0015] Figure 2 Workflows according to some embodiments disclosed herein are described for using generative adversarial networks to generate simulated training data that approximates the data used to train a pre-trained classifier.

[0016] Figure 3 This is a flowchart illustrating a method for training a generator model based on a pre-trained model to generate simulated training data, according to some embodiments disclosed herein.

[0017] Figure 4 This is a flowchart illustrating a method for training a discriminator model according to some embodiments disclosed herein to help rediscover training data from a pre-trained model.

[0018] Figure 5 This is a flowchart illustrating a method for training a generator model according to some embodiments disclosed herein to help rediscover training data from a pre-trained model.

[0019] Figure 6 This is a flowchart illustrating a method for generating and evaluating training data for a pre-trained model according to some embodiments disclosed herein.

[0020] Figure 7 This is a flowchart illustrating a method for training a generator model based on a pre-trained classifier model according to some embodiments disclosed herein.

[0021] Figure 8 This is a block diagram illustrating a computing device configured to train a generator model based on a pre-trained classifier, according to some embodiments disclosed herein. Detailed Implementation

[0022] Embodiments of this disclosure provide techniques for training a generator model to recover training data from a pre-trained model. In one embodiment, given a trained classifier, a generative model can be trained to generate data that approximates the data originally used to train the classifier. This allows for the recovery of such data. Additionally, in some embodiments, the recovered or simulated data can be analyzed to determine the quality of the pre-trained classifier and / or its training data. For example, in some embodiments, the techniques described herein can be used to determine whether sufficient training data was used, whether spurious features were relied upon, whether the training process was poisoned, etc.

[0023] Some embodiments disclosed herein provide techniques for training a generator model to generate images conditioned on a specific target category, where real images of that target category are used to train a pre-trained model, but are not visible during generator training. Although images are used in some examples herein, embodiments of this disclosure can be readily applied to any type of training data and any type of pre-trained machine learning model. In one embodiment, the generator model can be trained using a pre-trained image classifier capable of distinguishing a target category and a generic set of images excluding images from the target category. For example, suppose the classifier is trained to classify images based on the animals included, and the target category is a horse. In some embodiments of this disclosure, the generator model can be trained using the classifier and one or more images from other categories (e.g., dogs) to generate images of horses that approximate or simulate the images used to train the original classifier. Notably, the generator is trained to do this without processing or receiving any samples from the target category (e.g., images without horses).

[0024] In some embodiments of this disclosure, the generated data can be analyzed to evaluate and determine the quality of the data and / or the pre-trained model. For example, if the generated images include some common features (or lack some features), it can be inferred that the underlying classifier depends on (or does not depend on) those features. As an example, suppose the generator is assigned the task of generating images of the "primate" class and generates images that appear to depict primates but lack faces. In one embodiment, it can be determined or inferred that the classifier does not rely on faces in the training images to learn to classify primates. Similarly, if the generated images all appear to include forests or trees, it can be determined or inferred that the classifier relies on the presence of such trees to classify primates, rather than on features of the primates themselves.

[0025] As another example, suppose some or all of the generated images each include some questionable or suspicious features (e.g., black squares in the corners of each image). This could indicate that the classifier was trained on poisoned data, where the questionable features act as triggers that cause the classifier to classify images containing the triggers into the target category, regardless of what the images actually depict. Furthermore, in some embodiments, if the generated images do not appear to depict a consistent representation of the target category (e.g., no identifiable horse is present in the generated images), it can be inferred that an insufficient number or variety of training samples were used for the target category, or that the classifier relies on unclear or inappropriate features. In embodiments, these and other insights can allow for improved training and understanding of the underlying classifier model. For example, more and / or better training samples, including desired features and / or excluding unwanted features, can be collected to remove poisoned samples, etc.

[0026] Figure 1 A workflow 100 according to some embodiments disclosed herein is described for training a generative adversarial model to rediscover training data used for a pre-trained classifier. In the illustrated workflow 100, a pre-trained classifier 140 and provided data 125 are used to train the generative adversarial model to generate simulated data that represents or approximates other data used to train the pre-trained classifier 140. In embodiments, the pre-trained classifier 140 is a classifier machine learning model that has been trained using a set of training samples to classify input data (e.g., images) into categories. For example, the pre-trained classifier 140 can be trained to classify an input image into a category based on the animal depicted in the image.

[0027] In the illustrated embodiment, the provided data 125 includes one or more training samples for training the pre-trained classifier 140. However, in at least one embodiment, the provided data 125 does not include any examples of the target category for which the generative adversarial model is being trained. That is, the GAN (including the generator model 115 and the discriminator model 130) can be trained without processing any samples from the target category. For example, suppose the pre-trained classifier 140 is trained based on samples from the "primate" class, the "horse" class, and the "dog" class. In one embodiment, if the target category is "horse," the provided data 125 may include examples from the "primate" class and / or the "dog" class, but not any examples from the "horse" class.

[0028] In some embodiments, the provided data 125 includes one or more samples from all classes except the target class. In other embodiments, the provided data 125 excludes any samples from the target class and may or may not include samples from each of the other classes. In some embodiments, the provided data 125 includes samples that are actually used to train the pre-trained classifier 140. In other embodiments, the provided data 125 may include labeled data corresponding to non-target classes that are not actually used to train the pre-trained classifier 140.

[0029] In the illustrated workflow 100, a target label 105 and an input vector 110 are provided to a generator model 115. In one embodiment, the generator model 115 is a generator neural network of a GAN. Typically, the generator model 115 is trained based on the input vector 110 to produce generated data 120, where the generated data 120 is intended to belong to the class associated with the target label 105. In some embodiments, the generator model 115 receives the input vector 110 but does not actually receive or process the target label 105. That is, the generator model 115 may be trained solely on the input vector 110 to generate the data 120.

[0030] In at least one embodiment, input vector 110 is a randomized vector used as input to generator model 115. Typically, changing input vector 110 results in different outputs of the generated data 120. During training, generator model 115 learns to produce generated data 120 that approximates or matches the target label 105, as discussed in more detail below.

[0031] As shown in the figure, the generated data 120 is then provided to the discriminator model 130. In one embodiment, the discriminator model 130 is a discriminator neural network of a GAN. Typically, the discriminator 130 is trained to distinguish between real input data (e.g., the provided data 125) and simulated data (e.g., the generated data 120) created by the generator model 115. That is, the generator model 115 can learn to generate generated data 120 that approximates, matches, or simulates the provided data 125, while the discriminator model 130 learns to distinguish the generated data 120 from the provided data 125.

[0032] In the illustrated workflow 100, the system calculates a discriminator loss 135 based on the generated data 120 and / or the provided data 125. In one embodiment, this discriminator loss 135 is determined based on whether the discriminator model 130 accurately classifies the input as generated data 120 or provided data 125. For example, if the discriminator model 130 incorrectly classifies the generated data 120 as real provided data 125 (or incorrectly classifies the provided data 125 as simulated generated data 120), the discriminator loss 135 may be greater than if the discriminator model 130 accurately classifies the input. As shown, this discriminator loss 135 is then used to refine the weights or parameters of the discriminator model 130 to more accurately distinguish between real and simulated data. By iteratively processing multiple inputs of the generated data 120 and / or the provided data 125, the discriminator model 130 iteratively learns to distinguish between the two.

[0033] As shown in the figure, the generated data 120 is also fed to a pre-trained classifier 140 to generate a classifier loss 145. In one embodiment, the classifier loss 145 is calculated based on the difference between the output of the pre-trained classifier 140 and the target label 105. For example, suppose the target category (and therefore the target label 105) is “dog”. If the pre-trained classifier 140 classifies the generated data 120 as “dog”, the classifier loss 145 can be lower than if the pre-trained classifier 140 classifies it as “horse”. In the illustrated embodiment, both the classifier loss 145 and the discriminator loss 135 are used to refine the generator model 115. This allows the generator model 115 to iteratively learn to generate better generated data 120 that more closely represents the target label 105. That is, the discriminator loss 135 can force the generator model 115 to generate generated data 120 similar to the provided data 125, while the classifier loss 145 causes the generator model 115 to generate generated data 120 specific to the target label 105.

[0034] In this embodiment, during the training process, the internal weights and parameters of the generator model 115 and the discriminator model 130 can be refined, while the pre-trained classifier 140 remains unchanged. Once training is complete, the generator model 115 can be deployed to produce generated data 120 that approximates or represents the target label 105. Various techniques can be used to evaluate the generated data to determine the quality or other characteristics of the pre-trained classifier 140.

[0035] Figure 2Workflow 200 is described according to some embodiments disclosed herein for generating simulated training data that approximates data used to train a pre-trained classifier using a generative adversarial network. Specifically, workflow 200 describes the use of the generator model 115 after it has been trained (e.g., using...). Figure 1 (Workflow 100 in the example). In the illustrated embodiment, generator model 115 receives target label 105 and / or input vector 110, and generates simulated data 205.

[0036] In some embodiments, as described above, the generator model 115 does not receive the target label 105. Instead, the generator model 115 can be trained to generate simulated data 205 of the target category as described above (e.g., based in part on a classifier loss calculated based on the target label 105). In such embodiments, the generator model 115 only needs to receive the input vector 110 to create simulated data 205 that matches the target label 105.

[0037] In an embodiment, the simulated data 205 reflects samples from the target category. Different samples for the target category can be generated by providing different input vectors 110. In some embodiments, a random or pseudo-random algorithm is used to create the input vectors 110. In some embodiments, a set of input vectors 110 can be used to generate a set of simulated data 205. The simulated data 205 can then be evaluated or analyzed to determine the quality of the pre-trained classifier 140. In an embodiment, this evaluation can be automatic (e.g., performed by one or more computers), manual (e.g., performed by a human reviewer), or a combination of both.

[0038] For example, if the simulated data 205 does not appear to have similar features or does not appear to reflect the target label 105, it can be determined or inferred that the pre-trained classifier 140 has not been trained with sufficient data for the target category. In one such embodiment, additional samples of the target category can be used to refine the pre-trained classifier 140.

[0039] Similarly, if all or part of the simulated data 205 includes features irrelevant to the target label 205 (e.g., trees when the label is "primate"), it can be determined or inferred that the pre-trained classifier 140 relies on irrelevant features when classifying the target category. In one such embodiment, the pre-trained classifier 140 can be trained or refined with better samples that do not include that feature (e.g., images of primates that do not include trees) to allow the model to learn to predict classes more accurately.

[0040] Additionally, if all or part of the simulated data 205 lacks features that are relevant to or would be useful for the classification of the target label 205 (e.g., a face of the "primate" category), it can be determined or inferred that the pre-trained classifier 140 does not rely on such features when classifying the target category. In one such embodiment, the pre-trained classifier 140 can be trained or refined using better samples that do include the feature (e.g., images of primate faces) to allow the model to learn to predict categories more accurately.

[0041] As another example, if all or part of the simulated data 205 includes features that appear suspicious or illegal, it can be determined or inferred that the pre-trained classifier 140 was trained using poisoned data with at least the target class. As used herein, a feature can be considered suspicious if it does not reflect legitimate or realistic features of the input data. For example, a suspicious feature could be the presence of a colored square in a specific location (e.g., a corner) of the generated image. This feature is unlikely to be included incorrectly (e.g., because the training samples should not include this feature) and therefore could be included maliciously (e.g., to trick the pre-trained classifier 140 into relying on these triggering features instead of legitimate features in the input). In one such embodiment, the pre-trained classifier 140 can be trained or refined with better samples that do indeed include the triggering feature, or it can be retrained without the original training data of the target class (which may have been poisoned) to allow the model to learn to predict classes more accurately.

[0042] Figure 3 This is a flowchart illustrating a method 300 for training a generator model to produce simulated training data based on a pre-trained model, according to some embodiments disclosed herein. As shown, method 300 begins at block 305, where the system trains a discriminator model based on one or more samples. In embodiments, this typically includes providing data generated by the generator model, actual data used to train a classifier model, or both as input to the discriminator. Based on this input, the discriminator model outputs a label indicating whether the input is real or simulated. By comparing this output with the actual classification (real or simulated) of the input, the system can generate a discriminator loss, which can be used (e.g., via backpropagation) to refine the discriminator model.

[0043] In one embodiment, the training can be performed sequentially or in batches on each record. At block 310, the system determines whether the training of the discriminator model should be repeated (e.g., whether there are any additional samples and / or batches remaining in the period to be used). If yes, method 300 returns to block 305. If no, method 300 continues to block 315.

[0044] At box 315, the system trains a generator model using one or more samples. In one embodiment, this typically involves feeding the generator model an input vector to generate simulated output data. This simulated data is then fed to a pre-trained classifier to output predicted labels, and the predicted labels can be compared to the target labels to compute a classifier loss. This classifier loss can be used to refine the weights or parameters of the generator model (e.g., via backpropagation). In some embodiments, simulated data is also fed to a discriminator, and a discriminator loss can be computed. This discriminator loss can also be used to refine the generator model (e.g., via backpropagation). In one embodiment, the generator model is refined based on the sum of the classifier loss and the discriminator loss (e.g., the sum of individual losses).

[0045] In block 315, the process can be performed sequentially on one or more samples, or it can be performed as a batch. Method 300 then proceeds to block 320, where the system determines whether one or more termination criteria have been met. These termination criteria may include, for example, a minimum accuracy level for the discriminator and / or generator (e.g., the percentage of times the generator creates data that fools the discriminator and / or is accurately classified into the target label by the classifier). In some embodiments, termination criteria may include the amount of time spent training the model, the number of loops or batches completed, whether there is any more actual data (e.g., the provided data 125) to process, etc.

[0046] If the termination criteria are not met, method 300 returns to box 305. Thus, method 300 iterates to train the generator and discriminator one after the other. If the termination criteria are met, method 300 continues to box 325. In box 325, the generator model is deployed for use. For example, the generator model can be used to generate simulated data during runtime to investigate target categories and recover or approximate the training data used to train the pre-trained classifier.

[0047] Figure 4 This is a flowchart illustrating a method 400 for training a discriminator model to help rediscover training data from a pre-trained model, according to some embodiments disclosed herein. In one embodiment, method 400 is... Figure 3 Box 305 in the diagram provides additional details. Method 400 begins at box 405, where the system generates one or more input vectors for training the discriminator. In some embodiments, these input vectors are randomly generated.

[0048] Method 400 then proceeds to block 410, where the system generates one or more simulated data samples using input vectors. For example, the system may provide one or more input vectors to a generator model (which may be fully trained, partially trained, or untrained). The generator model may output a simulated data sample for each input vector. In some embodiments, the generator model is initialized with random weights or parameters such that the simulated data samples may be relatively random and unrealistic, at least initially. However, over time, the generator learns to generate more accurate data samples.

[0049] In block 415, the system computes a discriminator loss based on one or more simulated data samples. In one embodiment, this includes feeding one or more simulated data samples to a discriminator model, which attempts to classify them as real or simulated. The loss can be computed based on whether the discriminator is correct. This loss can then be used to improve the weights or parameters of the discriminator model so that it can more accurately distinguish between real and simulated data samples.

[0050] Method 400 then continues to box 420, where the system selects one or more real data samples. In one embodiment, these real data samples reflect the training samples actually used to train the pre-trained classifier. In another embodiment, they reflect actual input data (e.g., actual images) that can be used to train or refine the classifier, even if they are not actually used to train or refine the classifier. At box 425, the system computes a discriminator loss based on these real data samples. In one embodiment, as described above, this includes feeding one or more real data samples to the discriminator model, which attempts to classify them as real or simulated. The loss can be computed based on whether the discriminator is correct. This loss can then be used to improve the weights or parameters of the discriminator model so that it can more accurately distinguish between real and simulated data samples.

[0051] Then, method 400 proceeds to box 430, where the system updates the discriminator model based on the discriminator loss calculated above. For example, the system can use backpropagation to update one or more internal weights of the discriminator model. By iteratively calculating the loss using different simulated and real samples, the discriminator learns iteratively to distinguish between real and simulated data more accurately.

[0052] In box 435, the system determines whether some termination criteria are met. In some embodiments, this includes determining whether the discriminator model has been trained on a sufficient number of samples in the current training epoch. In at least one embodiment, the system determines the accuracy of the discriminator and determines whether the termination criteria are met based on that accuracy. For example, if the discriminator is correct less than half the time (e.g., worse than a coin flip), the system may determine that additional training is needed. If the termination criteria are not met, method 400 returns to box 405. Otherwise, method 400 terminates at box 440. In some embodiments, the system may then begin training the generator model.

[0053] Figure 5 This is a flowchart illustrating a method 500 for training a generator model to help rediscover training data from a pre-trained model, according to some embodiments disclosed herein. In one embodiment, method 500 is... Figure 3 Box 315 in the diagram provides additional details, and method 500 begins at box 505, where the system generates one or more input vectors. In some embodiments, these are the same input vectors used above to train the discriminator model. In other embodiments, the system generates new input vectors (e.g., randomly).

[0054] Method 500 then continues to block 510, where the system generates one or more simulated data samples using input vectors. For example, the system may provide one or more input vectors to a generator model (which may be fully trained, partially trained, or untrained). The generator model may output a simulated data sample for each input vector. In some embodiments, the generator model is initialized with random weights or parameters such that the simulated data samples may be relatively random and unrealistic, at least initially. However, over time, the generator learns to generate more accurate data samples.

[0055] At box 515, the system computes a discriminator loss based on one or more simulated data samples. In one embodiment, this includes feeding one or more simulated data samples to a discriminator model, which attempts to classify them as real or simulated. The loss can be computed based on whether the discriminator is correct. As discussed in more detail below, this loss can then be used to improve the weights or parameters of the generator model.

[0056] Method 500 then continues to block 520, where the system computes a classifier loss based on simulated data samples. In one embodiment, this includes feeding one or more simulated data samples to a pre-trained classifier model, which classifies them into categories or classes based on its previous training. In another embodiment, the classifier loss may be computed based on whether the simulated data sample is classified into the target category. As discussed in more detail below, this loss may then be used to improve the weights or parameters of the generator model.

[0057] Method 500 then proceeds to box 525, where the system updates the generator model based on the discriminator and generator losses calculated above. For example, the system can use backpropagation to update one or more internal weights of the generator model. By doing this iteratively, the generator iteratively learns to generate simulated data that more accurately reflects or represents the real data (due to the discriminator loss) for the target class (due to the classifier loss).

[0058] In box 530, the system determines whether certain termination criteria are met. In some embodiments, this includes determining whether the generator model has been trained on a sufficient number of samples for the current round or training epoch. In at least one embodiment, the system determines the accuracy of the generator and determines whether the termination criteria are met based on that accuracy. For example, if the simulated data is classified into the target category at a predetermined percentage of time, the system can determine that no further training is needed. Similarly, if the discriminator is fooled at a predetermined percentage of time, the system can determine that no further training is needed at this point. If the termination criteria are not met, method 500 returns to box 505. Otherwise, method 500 terminates at box 535. In some embodiments, the system can then deploy the trained generator model or can begin further refining the discriminator (e.g., using method 400).

[0059] Figure 6 This is a flowchart illustrating a method for generating and evaluating training data for a pre-trained model according to some embodiments disclosed herein. In one embodiment, method 600 can be used after the generator model has been fully trained to produce simulated data samples corresponding to a target category. Method 600 begins at block 605, where the system generates or receives one or more input vectors. As described above, these input vectors can be generated randomly.

[0060] In box 610, the system generates one or more simulated data samples based on the input vector. For example, the system can provide the input vector to a generator model, which outputs a corresponding simulated data sample for each input vector. Method 600 then continues to box 615, where the simulated data samples are evaluated. As described above, this can include identifying features shared among the simulated data samples, identifying features not present in the simulated data samples, etc.

[0061] For example, features present (or absent) in simulated data samples can be used to determine or infer what features the underlying pre-trained classifier actually relies on. Similarly, in some embodiments, if simulated data samples do not appear to depict the target category, it can be determined or inferred that the underlying classifier is not particularly accurate for that category, and / or that it has been trained on insufficient data for that category.

[0062] Based on the results of this analysis, various steps can be taken. These may include, for example, collecting and / or using additional training data for the target category, avoiding the use of classifier models in production, etc.

[0063] Method 600 then proceeds to box 620, where the system determines whether one or more termination criteria are met. This could include, for example, multiple simulated data samples that should be generated, determining whether the user has initiated another round (or terminated the process), etc. If the criteria are not met, method 600 returns to box 605. Otherwise, method 600 terminates at box 625.

[0064] Figure 7 This is a flowchart illustrating a method 700 for training a generator model based on a pre-trained classifier model according to some embodiments disclosed herein. Method 700 begins at block 705, where the system receives a classifier model trained using one or more data samples from a target class. At block 710, the system trains a generative adversarial network (GAN) to generate simulated data samples for the target class. Method 700 then continues to block 715, where the system generates a first simulated data sample using the generator model. At block 720, the system computes a first discriminator loss by processing the first simulated data sample using a discriminator model. Furthermore, at block 725, the system computes a classifier loss by processing the first simulated data sample using a classifier model. Method 700 then continues to block 730, where the system refines the generator model based on the first discriminator loss and the classifier loss.

[0065] Figure 8This is a block diagram illustrating a computing device 800 configured to train a generator model based on a pre-trained classifier, according to some embodiments disclosed herein. Although depicted as a physical device, in embodiments, the computing device 800 may be implemented using one or more virtual devices and / or across multiple devices (e.g., in a cloud environment). As shown, the computing device 800 includes a CPU 805, memory 810, storage device 815, network interface 825, and one or more I / O interfaces 820. In the illustrated embodiment, the CPU 805 retrieves and executes programming instructions stored in the memory 810, and stores and retrieves application data residing in the storage device 815. The CPU 805 generally represents a single CPU and / or GPU, multiple CPUs and / or GPUs, a single CPU and / or GPU with multiple processing cores, etc. The memory 810 is typically included to represent random access memory. Storage device 815 can be any combination of disk drives, flash-based storage devices, etc., and can include fixed and / or removable storage devices, such as fixed disk drives, removable memory cards, caches, optical storage devices, network attached storage devices (NAS), or storage area networks (SAN).

[0066] In some embodiments, I / O devices 835 (e.g., keyboard, monitor, etc.) are connected via I / O interface 820. Furthermore, via network interface 825, computing device 800 can be communicatively coupled to one or more other devices and components (e.g., via a network, which may include the Internet, one or more local networks, etc.). As shown, CPU 805, memory 810, storage device 815, one or more network interfaces 825, and one or more I / O interfaces 820 are communicatively coupled via one or more buses 830.

[0067] In the illustrated embodiment, storage device 815 includes a generator model 115, a discriminator model 130, and a pre-trained classifier 140. Although depicted as residing in storage 815, in this embodiment, the generator model 115, discriminator model 130, and pre-trained classifier 140 may reside in any suitable location. The pre-trained classifier 140 is a machine learning model trained to classify input data into one or more categories or classes. For example, the pre-trained classifier 140 may classify an image into categories based on the objects or animals depicted in it. Typically, the pre-trained classifier 140 is trained using labeled samples or data samples (e.g., images, each associated with a label indicating the content of the image).

[0068] In one embodiment, generator model 115 and discriminator model 130 form a GAN. Generator model 115 is a machine learning model (e.g., a neural network) trained to generate simulated data that approximates all or a portion of the data samples used to train pre-trained classifier 140. In one embodiment, generator model 115 is trained to generate simulated data for a specific data category for which pre-trained classifier 140 has already been trained.

[0069] Typically, the discriminator model 130 is a machine learning model (e.g., a neural network) trained to distinguish between real data samples (e.g., those used to train the pre-trained classifier 140) and simulated data samples (generated by the generative model 115). In an embodiment, the discriminator model 130 is trained alongside the generator model 115, and pressure is applied to the generator model 115 to improve the accuracy of its generated data samples.

[0070] In the illustrated embodiment, memory 810 includes a generator application 850. Although depicted as software residing in memory 810, in embodiments, the functionality of generator application 850 can be implemented using software, hardware, or a combination of software and hardware. As shown, generator application 850 includes a training component 855 and an evaluation component 860. Although depicted as discrete components for clarity of concept, in various embodiments, the operation of training component 855 and evaluation component 860 can be combined or distributed across any number of components.

[0071] In an embodiment, training component 855 is used to train generator model 115 and discriminator model 130, as described above. This may include calculating a discriminator loss based on the output of discriminator model 130 (where the output is generated based on simulated data and / or real data samples used as input), and calculating a classifier loss based on the output of pre-trained classifier 140 when simulated data (generated by generator 115) is provided as input. In an embodiment, training component 855 refines discriminator model 130 based on discriminator loss, which forces discriminator model 130 to learn to distinguish between real data samples and simulated data samples.

[0072] In some embodiments, the training component 855 refines the generator model 115 based on both discriminator loss and classifier loss. In one such embodiment, the discriminator loss causes the generator model 115 to learn to generate realistic data samples, while the classifier loss forces the generator model 115 to learn to generate data samples that match a specific target label.

[0073] In the illustrated embodiment, the evaluation component 860 typically uses the trained generator model 115 to generate simulated data samples and analyzes these samples to evaluate the quality of the pre-trained classifier 140, as described above. This may include, for example, identifying common features across the simulated data samples (indicating features the classifier relies on), identifying suspicious features in the simulated data samples (indicating potential poisoning of the classifier), identifying missing features from the simulated data samples (indicating features the classifier does not rely on), determining that the simulated data samples are unidentifiable or have significant noise (indicating insufficient training data for the classifier), etc.

[0074] In some embodiments, based on the evaluation, the generator application 850 (or another component or device) may take various actions. These may include determining not to use the pre-trained classifier 140 during runtime, generating a quality score or indication for the classifier, indicating specific refinements or improvements that can be made (such as collecting more training data for a given class), actually refining the pre-trained classifier 140 based on the evaluation results, etc.

[0075] Various embodiments of the invention have been described for illustrative purposes, but are not intended to be exhaustive or limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope of the described embodiments. The terminology used herein has been chosen to best explain the principles of the embodiments, their practical application, or improvements to existing technologies in the market, or to enable others skilled in the art to understand the embodiments disclosed herein.

[0076] In the foregoing, reference has been made to the embodiments presented in this disclosure. However, the scope of this disclosure is not limited to the specifically described embodiments. Rather, any combination of features and elements is contemplated for implementing and practicing the intended embodiments, regardless of whether different embodiments are involved. Furthermore, while the embodiments disclosed herein may achieve advantages over other possible solutions or prior art, whether a given embodiment achieves a particular advantage does not limit the scope of this disclosure. Therefore, the aspects, features, embodiments, and advantages discussed herein are merely illustrative and should not be considered as elements or limitations of the appended claims unless expressly stated in the claims. Similarly, references to “the invention” should not be construed as a generalization of any inventive subject matter disclosed herein and should not be considered as elements or limitations of the appended claims unless expressly stated in the claims.

[0077] Various aspects of the present invention may take the form of a completely hardware embodiment, a completely software embodiment (including firmware, resident software, microcode, etc.), or an embodiment combining software and hardware aspects, which may be collectively referred to herein as a “circuit,” a “module,” or a “system.”

[0078] This invention can be a system, method, and / or computer program product at any possible level of technical detail integration. The computer program product may include a computer-readable storage medium (or media) having computer-readable program instructions thereon for causing a processor to perform aspects of the invention.

[0079] Computer-readable storage media can be tangible devices capable of retaining and storing instructions for use by an instruction execution device. Computer-readable storage media can be, for example, but not limited to, electronic storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any suitable combination of the foregoing. A non-exhaustive list of more specific examples of computer-readable storage media includes the following: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable optical disc read-only memory (CD-ROM), digital multifunction disc (DVD), memory sticks, floppy disks, mechanical encoding devices such as punch cards or recessed structures with instructions recorded thereon, and any suitable combination of the foregoing. As used herein, computer-readable storage media should not be construed as transient signals themselves, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses through fiber optic cables), or electrical signals transmitted through wires.

[0080] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to a suitable computing / processing device, or via a network, such as the Internet, a local area network (LAN), a wide area network (WAN), and / or a wireless network, to an external computer or external storage device. The network may include copper cables, optical fibers, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to a computer-readable storage medium within the respective computing / processing device.

[0081] Computer-readable program instructions used to perform the operations of this invention may be assembly instructions, instruction set architecture (ISA) instructions, machine-dependent instructions, microcode, firmware instructions, status setting data, integrated circuit configuration data, or source code or object code written in any combination of one or more programming languages ​​(including object-oriented programming languages ​​such as Smalltalk, C++, etc.) and procedural programming languages ​​(such as the "C" programming language or similar programming languages). The computer-readable program instructions may be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the latter case, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, to perform aspects of this invention, electronic circuits, including, for example, programmable logic circuits, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs), may execute computer-readable program instructions to personalize the electronic circuits by utilizing the status information of the computer-readable program instructions.

[0082] Various aspects of the present invention are described herein with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-readable program instructions.

[0083] These computer-readable program instructions may be provided to a processor of a computer or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions / actions specified in one or more blocks of a flowchart and / or block diagram. These computer-readable program instructions may also be stored in a computer-readable storage medium that can direct a computer, programmable data processing apparatus, and / or other devices to operate in a particular manner, such that the computer-readable storage medium in which the instructions are stored includes an article of writing comprising instructions for implementing aspects of the functions / actions specified in one or more blocks of a flowchart and / or block diagram.

[0084] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus or other device to cause a series of operational steps to be performed on the computer, other programmable apparatus or other device to produce a computer-implemented process, such that the instructions, which execute on the computer, other programmable apparatus or other device, perform the functions / actions specified in one or more boxes of a flowchart and / or block diagram.

[0085] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of instructions comprising one or more executable instructions for implementing a specified logical function. In some alternative embodiments, the functions indicated in the blocks may occur in a different order than indicated in the figures. For example, two blocks shown consecutively may actually be implemented as a single step, executed simultaneously, substantially simultaneously, with partial or complete time overlap, or these blocks may sometimes be executed in reverse order, depending on the functions involved. It will also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented by a dedicated hardware-based system that performs the specified function or action or executes a combination of dedicated hardware and computer instructions.

[0086] Embodiments of the present invention can be provided to end users through cloud computing infrastructure. Cloud computing generally refers to providing scalable computing resources as a service over a network. More formally, cloud computing can be defined as providing computing power that abstracts between computing resources and their underlying technical architecture (e.g., servers, storage devices, networks), thereby enabling convenient, on-demand network access to a shared pool of configurable computing resources that can be rapidly provisioned and released with minimal management effort or service provider interaction. Therefore, cloud computing allows users to access virtual computing resources (e.g., storage, data, applications, or even complete virtualized computing systems) in the “cloud,” regardless of the underlying physical systems (or the location of those systems) used to provide the computing resources.

[0087] Typically, cloud computing resources are provided to users on a pay-as-you-go basis, where users are charged only for the computing resources they actually use (e.g., the amount of storage space consumed or the number of virtualized systems instantiated by the user). Users can access any resource residing in the cloud at any time and from anywhere on the Internet. In the context of this invention, users can access applications (e.g., generator application 850) or related data available in the cloud. For example, generator application 850 can execute on a computing system in the cloud and train generator model 115 based on a pre-trained model. In this case, generator application 850 can train and use generator model 115 to recover and analyze the training data of the classifier, and store the model and evaluation results at a storage location in the cloud. This allows users to access this information from any computing system attached to a network connected to the cloud (e.g., the Internet).

[0088] While the foregoing relates to embodiments of the present invention, other and further embodiments of the present invention may be designed without departing from the basic scope of the present invention, and the scope of the present invention is defined by the appended claims.

Claims

1. A method for generating simulated data samples, comprising: Receive a classifier model, which is trained using one or more data samples from a target category, wherein the data samples include images; Training a generative adversarial network to generate simulated data samples for the target category includes: The first simulated data sample is generated by providing a randomized input vector to the generator model; A first discriminator output is generated by processing the first simulated data sample using a discriminator model, wherein the first discriminator output predicts whether the first simulated data sample was generated by the generator model; The first discriminator loss is calculated based on whether the output of the first discriminator accurately classifies the first simulated data sample as generated by the generator model. By using the discriminator model to process a first data sample that does not belong to the target category, a second discriminator output is generated, wherein the second discriminator output predicts whether the first data sample was generated by the generator model; The second discriminator loss is calculated based on whether the output of the second discriminator accurately classifies the first data sample as not generated by the generator model. The first simulated data sample is processed using a classifier model to generate a classifier output, wherein the classifier output predicts whether the first simulated data sample belongs to the target category; a classifier loss is calculated based on a comparison of the classifier output with the target category; and The generator model is refined based on the first discriminator loss, the second discriminator loss, and the classifier loss.

2. The method of claim 1, wherein the generative adversarial network is trained without processing any data samples of the target category.

3. The method according to claim 1, wherein training the generative adversarial network further comprises: The generator model is used to generate a second simulated data sample; The third discriminator loss is calculated by processing the second simulated data sample using the discriminator model. as well as The discriminator model is refined based on the third discriminator loss.

4. The method of claim 1, wherein the discriminator model is trained to distinguish between simulated data samples generated by the generator model and data samples not generated by the generator model.

5. The method according to claim 1, further comprising: A third simulated data sample for the target category is generated by providing a randomized input vector to the generator model.

6. The method according to claim 5, further comprising: Based at least in part on the third simulated data sample, it is determined that the classifier model was trained using insufficient data samples in the target category.

7. The method according to claim 5, further comprising: Based at least in part on the third simulated data sample, it is determined that the data sample in the target category used to train the classifier model includes one or more suspicious features.

8. A computer-readable storage medium comprising computer program code that performs operations when executed by one or more computer processors, the operations including: Receive a classifier model, which is trained using one or more data samples from a target category, wherein the data samples include images; Training a generative adversarial network to generate simulated data samples for the target category includes: The first simulated data sample is generated by providing a randomized input vector to the generator model; A first discriminator output is generated by processing the first simulated data sample using a discriminator model, wherein the first discriminator output predicts whether the first simulated data sample was generated by the generator model; The first discriminator loss is calculated based on whether the output of the first discriminator accurately classifies the first simulated data sample as generated by the generator model. By using the discriminator model to process a first data sample that does not belong to the target category, a second discriminator output is generated, wherein the second discriminator output predicts whether the first data sample was generated by the generator model; The second discriminator loss is calculated based on whether the output of the second discriminator accurately classifies the first data sample as not generated by the generator model. The first simulated data sample is processed by a classifier model to generate a classifier output, wherein the classifier output predicts whether the first simulated data sample belongs to the target category. The classifier loss is calculated by comparing the classifier output with the target category; and The generator model is refined based on the first discriminator loss, the second discriminator loss, and the classifier loss.

9. The computer-readable storage medium of claim 8, wherein the generative adversarial network is trained without processing any data samples of the target category.

10. The computer-readable storage medium of claim 8, wherein training the generative adversarial network further comprises: The generator model is used to generate a second simulated data sample; The third discriminator loss is calculated by processing the second simulated data sample using the discriminator model. as well as The discriminator model is refined based on the third discriminator loss.

11. The computer-readable storage medium of claim 8, wherein the discriminator model is trained to distinguish between simulated data samples generated by the generator model and data samples not generated by the generator model.

12. The computer-readable storage medium of claim 8, further comprising: A third simulated data sample for the target category is generated by providing a randomized input vector to the generator model.

13. The computer-readable storage medium of claim 12, further comprising: Based at least in part on the third simulated data sample, it is determined that the classifier model was trained using insufficient data samples in the target category.

14. The computer-readable storage medium of claim 12, further comprising: Based at least in part on the third simulated data sample, it is determined that the data sample in the target category used to train the classifier model includes one or more suspicious features.

15. A computer system comprising: One or more computer processors; as well as One or more memories, collectively including one or more programs, which perform operations when executed by the one or more computer processors, the operations including: Receive a classifier model, which is trained using one or more data samples from a target category, wherein the data samples include images; Training a generative adversarial network to generate simulated data samples for the target category includes: The first simulated data sample is generated by providing a randomized input vector to the generator model; A first discriminator output is generated by processing the first simulated data sample using a discriminator model, wherein the first discriminator output predicts whether the first simulated data sample was generated by the generator model; The first discriminator loss is calculated based on whether the output of the first discriminator accurately classifies the first simulated data sample as generated by the generator model. By using the discriminator model to process a first data sample that does not belong to the target category, a second discriminator output is generated, wherein the second discriminator output predicts whether the first data sample was generated by the generator model; The second discriminator loss is calculated based on whether the output of the second discriminator accurately classifies the first data sample as not generated by the generator model. The first simulated data sample is processed by a classifier model to generate a classifier output, wherein the classifier output predicts whether the first simulated data sample belongs to the target category. The classifier loss is calculated by comparing the classifier output with the target category; and The generator model is refined based on the first discriminator loss, the second discriminator loss, and the classifier loss.

16. The computer system of claim 15, wherein the generative adversarial network is trained without processing any data samples of the target category, and wherein training the generative adversarial network further comprises: The generator model is used to generate a second simulated data sample; The third discriminator loss is calculated by processing the second simulated data sample using the discriminator model. as well as The discriminator model is refined based on the third discriminator loss.

17. The computer system of claim 15, wherein the discriminator model is trained to distinguish between simulated data samples generated by the generator model and data samples not generated by the generator model.

18. The computer system according to claim 15, further comprising: A third simulated data sample for the target category is generated by providing a randomized input vector to the generator model.

19. The computer system according to claim 18, further comprising: Based at least in part on the third simulated data sample, it is determined that the classifier model was trained using insufficient data samples in the target category.

20. The computer system of claim 18, further comprising: Based at least in part on the third simulated data sample, it is determined that the data sample in the target category used to train the classifier model includes one or more suspicious features.

21. A computer program product comprising program code, wherein when the program code is run on a computer, the program code is adapted to perform the steps of the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Systems and Methods for Conditional Generative Models

    US20190385019A1

  • Deliberate conditional poison training for generative models

    US20200175329A1