Data set distillation method and device

By introducing distribution alignment loss and realism loss into the denoising process of the diffusion model, the target loss at each step is optimized, which solves the problem of sample distribution bias in dataset distillation and improves the quality and consistency of synthetic image samples.

CN120807344APending Publication Date: 2025-10-17ALIPAY (HANGZHOU) INFORMATION TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510940748.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-08
Publication Date
2025-10-17

AI Technical Summary

Technical Problem

Existing dataset distillation methods based on diffusion models have sample distribution bias caused by randomness in the sample generation process, which affects the training performance of downstream models.

Method used

In the denoising process of the diffusion model, distribution alignment loss and authenticity loss are introduced. The target loss of each step is optimized through multiple rounds of iteration to ensure that the distribution of denoised image samples is consistent with that of standard image samples, and to constrain the sampling noise to conform to a Gaussian distribution.

Benefits of technology

It reduces the deviation between the synthesized image samples and the theoretical probability distribution, improves the quality of the synthesized image samples, ensures that the generated samples conform to the expected distribution, and is suitable for special application scenarios where there is no original dataset.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120807344A_ABST
    Figure CN120807344A_ABST
Patent Text Reader

Abstract

One or more embodiments of the present specification provide a dataset distillation method and apparatus. According to the method, a diffusion model is utilized, denoising processing is carried out on a noise image sample step by step according to a preset step length, and a synthetic image sample is generated; wherein in any step of denoising processing, the target loss of a denoised image sample obtained through denoising processing is calculated, and the target loss is optimized through multi-round iterative denoising processing; wherein the target loss comprises distribution alignment loss, and the distribution alignment loss is calculated based on a de-noised image sample obtained by de-noising processing in the current step and a standard image sample corresponding to the current step.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] One or more embodiments of the present specification relate to the technical field of artificial intelligence, and in particular, to a dataset distillation method and device. BACKGROUND

[0002] Dataset distillation aims to replace the original large-scale training data with a highly compact and information-rich sample set, thereby reducing the cost of model training. In recent years, dataset distillation methods based on diffusion models have shown significant advantages. They generate synthetic samples with high information density through a reverse diffusion process step by step. However, the randomness in the sampling process of such methods can cause sample distribution bias, which in turn affects the training performance of downstream models.

[0003] Therefore, how to reduce the sample distribution bias in dataset distillation is a technical problem that needs to be solved urgently. SUMMARY

[0004] In order to reduce the sample distribution bias in dataset distillation and improve the quality of synthetic image samples, one or more embodiments of the present specification provide a dataset distillation method and device.

[0005] In a first aspect, one or more embodiments of the present specification provide a dataset distillation method, which comprises: obtaining a noise image sample; using a diffusion model, step by step denoising the noise image sample according to a preset step size to generate a synthetic image sample; wherein in any step of denoising, the target loss of the denoised image sample obtained by denoising is calculated, and the target loss is optimized through multiple rounds of iterative denoising; wherein the target loss comprises a distribution alignment loss, and the distribution alignment loss is calculated based on the denoised image sample obtained by the current step of denoising and the standard image sample corresponding to the current step.

[0006] In a possible implementation, in any step of denoising, calculating the target loss of the denoised image sample obtained by denoising comprises: in any step of denoising, predicting the mean and standard deviation of the second denoised image sample based on the first denoised image sample; wherein the first denoised image sample is the denoised image sample obtained by the previous step of denoising; randomly sampling a noise tensor as the second denoised image sample from a normal distribution corresponding to the mean and standard deviation; and calculating the distribution alignment loss between the second denoised image sample and the standard image sample corresponding to the current step.

[0007] In a possible implementation, the distribution alignment loss between the second denoised image sample and the standard image sample corresponding to the current step is calculated, including: determining a first probability distribution of the second denoised image sample; determining a second probability distribution of the standard image sample corresponding to the current step; calculating a maximum mean difference between the first probability distribution and the second probability distribution; and taking the maximum mean difference as the distribution alignment loss of the current step.

[0008] In a possible implementation, the standard image sample is a standard denoised image sample or a standard noisy image sample.

[0009] In a possible implementation, the method further includes: denoising the noisy image sample step by step according to the preset step size by using the diffusion model; and in any step of denoising, a standard noisy sample denoised image is used, and the denoised image obtained by sampling at each step is taken as a standard denoised image sample at each step.

[0010] In a possible implementation, the method further includes: adding noise to the original image sample corresponding to the noisy image sample step by step according to the preset step size by using the diffusion model; and in any step of adding noise, a noisy image is obtained by adding standard noise, and the noisy image obtained at each step is taken as a standard noisy image sample at each step.

[0011] In a possible implementation, the target loss further includes a reality loss, and in any step of denoising, the target loss of the denoised image sample obtained by denoising is calculated, further including: in any step of denoising, the following steps are included: calculating a difference between the denoised image sample obtained by denoising and an expected mean value corresponding to the current step; taking a ratio of the difference to an expected standard deviation corresponding to the current step as a sampling noise tensor of the current step; and taking a difference between a length of the sampling noise tensor and an expected length of a standard normal distribution of the same dimension as a reality loss of the current step.

[0012] In a second aspect, one or more embodiments of the present specification also provide a data set distillation device, including: an acquisition module configured to acquire a noisy image sample; and a generation module configured to denoise the noisy image sample step by step according to a preset step size by using a diffusion model to generate a synthetic image sample; wherein the generation module is configured to calculate a target loss of a denoised image sample obtained by denoising in any step of denoising, and optimize the target loss through multiple rounds of iterative denoising; and wherein the target loss includes a distribution alignment loss, which is calculated based on a denoised image sample obtained by denoising at a current step and a standard image sample corresponding to the current step.

[0013] In a possible implementation, the generation module is specifically configured to: in any step of denoising processing, predict a mean value and a standard deviation of a second denoised image sample based on a first denoised image sample; the first denoised image sample is a denoised image sample obtained in a previous step of denoising processing; randomly sample a noise tensor from a normal distribution corresponding to the mean value and the standard deviation as the second denoised image sample; and calculate a distribution alignment loss between the second denoised image sample and a standard image sample corresponding to a current step.

[0014] In a possible implementation, the generation module is specifically configured to: determine a first probability distribution of the second denoised image sample; determine a second probability distribution of a standard image sample corresponding to a current step; calculate a maximum mean difference between the first probability distribution and the second probability distribution; and take the maximum mean difference as a distribution alignment loss of the current step.

[0015] In a possible implementation, the standard image sample is a standard denoised image sample or a standard noisy image sample.

[0016] In a possible implementation, the method further includes: a first standard image sample generation module configured to denoise the noisy image sample step by step according to the preset step length by using the diffusion model; in any step of denoising processing, a standard noisy sample denoised image is used, and denoised images obtained in each step are taken as standard denoised image samples of the respective steps.

[0017] In a possible implementation, the method further includes: a second standard image sample generation module configured to denoise the noisy image sample step by step according to the preset step length by using the diffusion model; in any step of denoising processing, a standard noisy sample denoised image is used, and denoised images obtained in each step are taken as standard denoised image samples of the respective steps.

[0018] In a possible implementation, the generation module is further configured to: in any step of denoising processing, calculate a difference between a denoised image sample obtained through denoising processing and an expected mean value corresponding to a current step; take a ratio of the difference to an expected standard deviation corresponding to the current step as a sampling noise tensor of the current step; and take a difference between a module length of the sampling noise tensor and an expected module length of a standard normal distribution of the same dimension as a reality loss of the current step.

[0019] In a third aspect, one or more embodiments of the present specification also provide an electronic device, including a memory and a processor; the memory is configured to store a computer program product; the processor is configured to execute the computer program product stored in the memory, and when the computer program product is executed, the data set distillation method of the first aspect is implemented.

[0020] In a fourth aspect, the one or more embodiments of the present specification also provide a computer-readable storage medium, which stores computer program instructions, and the computer program instructions, when executed, implement the dataset distillation method of the first aspect.

[0021] To sum up, the dataset distillation method provided by the one or more embodiments of the present specification uses the distribution alignment loss and / or the reality loss to constrain the predicted denoised image samples at each step of the diffusion model denoising process. Through the distribution alignment loss, the denoised image samples at each step can be explicitly optimized, ensuring that the distribution of the denoised image samples at each step is consistent with the corresponding standard denoised image samples or the standard noisy image sample probability distribution. Through the reality loss, the predicted denoised image samples can be constrained to satisfy the Gaussian distribution, thereby ensuring that the synthesized image samples do not deviate from the denoising probability distribution at this step, and avoiding the generation of outlier image samples.

[0022] In this way, by introducing the distribution alignment loss and / or the reality loss at each step of the denoising process, the random sampling bias is weakened, thereby reducing the deviation between the synthesized image samples generated by the diffusion model and their theoretical probability distribution, and improving the quality of the synthesized image samples. BRIEF DESCRIPTION OF DRAWINGS

[0023] In order to more clearly illustrate the technical solutions of the one or more embodiments of the present specification, the drawings needed in the embodiment description will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the one or more embodiments of the present specification, and other drawings can also be obtained by those skilled in the art without creative labor.

[0024] Figure 1 A flowchart of a dataset distillation method provided by the one or more embodiments of the present specification; Figure 2 A flowchart of another dataset distillation method provided by the one or more embodiments of the present specification; Figure 3 A block diagram of a dataset distillation device provided by the one or more embodiments of the present specification; Figure 4 A block diagram of an electronic device provided by the one or more embodiments of the present specification. DETAILED DESCRIPTION

[0025] The one or more embodiments of the present specification will be further described in detail below with the aid of the drawings and embodiments. Through these descriptions, the features and advantages of the one or more embodiments of the present specification will become more apparent.

[0026] The word "exemplary" is used herein to mean "serving as an example, instance, or illustration." Any implementation described herein as "exemplary" is not necessarily to be construed as preferred or advantageous over other implementations. Unless specifically indicated otherwise, the drawings are not necessarily to scale.

[0027] In addition, the technical features involved in different embodiments of one or more embodiments of the present specification described below can be combined with each other as long as there is no conflict.

[0028] For ease of understanding, some technical terms or technical terms related to the technical solutions provided by one or more embodiments of the present specification are introduced below.

[0029] (1) Data set distillation: a technique for compressing large data sets into small synthetic data sets, enabling models trained on small data sets to achieve performance close to that of large data sets. In this way, by replacing the original large-scale training data with a highly compact and information-rich synthetic data set, the cost of model training can be reduced.

[0030] (2) Diffusion model: also known as diffusion probability model, which can be applied to data set distillation to generate synthetic data sets.

[0031] The diffusion model can include a forward diffusion process and a reverse diffusion process. In the forward diffusion process, the original image z0 from the training set is added T times of noise, so that the noisy image z T conforms to the standard normal distribution. In the reverse diffusion process, the noise image z T conforming to the standard normal distribution is denoised T times to generate the image z0.

[0032] The data set distillation method based on the diffusion model mainly utilizes the reverse diffusion process of the diffusion model.

[0033] In one possible implementation, the data set distillation method based on the diffusion model can be implemented in the following manner: inputting a noise image sample into the diffusion model, and the diffusion model gradually samples noise through the reverse diffusion process to generate a synthetic image sample with high information density.

[0034] However, the above data set distillation method based on the diffusion model is highly dependent on randomly generated noise, and therefore, distribution deviation caused by random sampling of noise may occur in the generated synthetic image sample, which in turn affects the training performance of the downstream model.

[0035] To solve the above technical problems, one or more embodiments of the present specification provide a dataset distillation method, which introduces distribution alignment loss and / or authenticity loss at each step of the denoising process to weaken the random sampling bias, thereby reducing the deviation between the synthetic image samples generated by the diffusion model and their theoretical probability distribution, and improving the quality of the synthetic image samples.

[0036] The following describes an embodiment of the dataset distillation method provided by one or more embodiments of the present specification.

[0037] Referring to Figure 1 , Figure 1 A flowchart of a dataset distillation method provided by one or more embodiments of the present specification is shown. The method can be applied to an electronic device, such as a server. As Figure 1 shown, the method can include the following steps: Step S102, obtaining noise image samples.

[0038] Step S104, using a diffusion model to gradually denoise the noise image samples according to a preset step size, to generate synthetic image samples.

[0039] As Figure 2 shown, a large number of noise image samples are input into the diffusion model, and the diffusion model performs an inverse diffusion process on the input noise image samples, gradually denoising the noise image samples according to a preset step size, to generate a small number of synthetic image samples. This process is the dataset distillation process. The obtained synthetic image samples can be used as training data for downstream training models.

[0040] The noise image samples can be noise image samples obtained by forward diffusion of a certain type of original image sample using the diffusion model. The original image sample is a real image sample.

[0041] For example, the original image sample is a series of cat images. Using the diffusion model, the noise image sample corresponding to the cat image is obtained by forward diffusion of the series of cat images.

[0042] For another example, the original image sample is a series of face images. Using the diffusion model, the noise image sample corresponding to the face image is obtained by forward diffusion of the series of face images.

[0043] It should be noted that the smaller the deviation between the probability distribution of the synthetic image samples generated in step S104 and the probability distribution of the original image samples corresponding to the noise image samples, the more ideal the synthetic image samples are.

[0044] To reduce this deviation in probability distribution, one or more embodiments of the present specification directly optimize the denoised image samples at each step of the denoising process.

[0045] The following is an illustrative description of the processing method of step t in the denoising process.

[0046] like Figure 2 As shown, in the t-th step denoising process, the denoised image sample obtained by the t-th step denoising process is calculated The target loss is obtained by optimizing the target loss through multiple rounds of iterative denoising processing to minimize the target loss, thereby optimizing the denoised image samples obtained by the prediction step.

[0047] In one or more embodiments of the present specification, the target loss may include a distribution alignment loss, which is calculated based on a denoised image sample obtained by denoising the current step and a standard image sample corresponding to the current step.

[0048] In one possible implementation, the distribution alignment loss of the denoised image samples obtained by denoising processing is calculated, which can be achieved in the following way: based on the first denoised image samples, the mean and standard deviation of the second denoised image samples are predicted; wherein the first denoised image samples of the dataset distillation are the denoised image samples obtained by the previous denoising process; from the normal distribution corresponding to the mean and standard deviation of the dataset distillation, a noise tensor is randomly sampled as the second denoised image samples of the dataset distillation; and the distribution alignment loss between the second denoised image samples of the dataset distillation and the standard image samples corresponding to the current step is calculated.

[0049] For example, in the denoising process at step t, the diffusion model is based on the denoised image sample z in the previous step (i.e., step t+1). t+1 (i.e. the first denoised image sample), predict the denoised image sample z of the current step t t (i.e., the mean of the second denoised image sample) and standard deviation and from this mean and standard deviation In the corresponding normal distribution, a noise tensor is randomly sampled as the denoised image sample of the current t-th step.

[0050] After that, the first probability distribution of the second denoised image sample of the dataset can be determined first , and the second probability distribution of the standard image sample corresponding to the current step Then, calculate the first probability distribution of the dataset distillation Distilling the second probability distribution with the dataset The maximum mean difference between them is used as the distribution alignment loss for the current step. .

[0051] In this way, through the distribution alignment loss to explicitly punish the distribution of the predicted denoised image sample at the t-th step of denoising and the difference between the probability distribution of the standard image sample at this step, so as to optimize the predicted denoised image sample at this step, and align the distribution of the second denoised image sample obtained by the prediction with the distribution of the corresponding standard image sample.

[0052] Wherein, the standard image sample can be a standard denoised image sample or a standard noisy image sample, and the embodiments of the present application do not limit this.

[0053] In a possible implementation manner, the standard denoised image sample can be obtained by using the diffusion model for data set distillation to gradually denoise the data set distillation noisy image sample according to the data set distillation preset step size. Wherein, in each denoising process, the standard noisy denoised image is sampled, and the denoised image sampled at each step is taken as the standard denoised image sample at each step.

[0054] That is, one or more embodiments of the present specification, before using the diffusion model for data set distillation on the noisy image sample, the diffusion model is first used for standard denoising of the noisy image to obtain the standard denoised image sample corresponding to each step.

[0055] Wherein, the standard denoised image sample at each step can include multiple, for example, the standard denoised image sample at each step can be a standard denoised image sample set, such as the standard denoised image sample set including 10 standard denoised images. Correspondingly, the denoised image sample can also include multiple, for example, the denoised image sample at each step can be a denoised image sample set, such as the denoised image sample set sampled from the mean and the standard deviation of the corresponding normal distribution, N noisy tensors are randomly sampled as the denoised image sample set at the current t-th step. For example, N is 200. Then, the maximum mean difference of the probability distribution of the denoised image sample set and the standard denoised image sample set can be calculated, and the data set distillation maximum mean difference is taken as the distribution alignment loss of the current step.

[0056] In a possible implementation manner, the standard noisy image sample can be obtained by using the diffusion model for data set distillation to gradually add noise to the original image sample corresponding to the data set distillation noisy image sample according to the data set distillation preset step size; wherein, in any step of the noise adding process, the noisy image is obtained by adding the standard noise; and the noisy image obtained at each step is taken as the standard noisy image sample at each step.

[0057] ​That is, before distilling the noisy original image sample dataset by using the diffusion model, the standard noise is added to the noisy image by using the diffusion model in one or more embodiments of the present specification, so as to obtain the standard noise image sample corresponding to each step.

[0058] In this way, since the probability distribution of the standard noise image sample is the same as that of the original image sample, the denoised image sample obtained by random sampling is further constrained by using the standard noise image sample, so as to further enhance the generated synthetic image sample.

[0059] In one or more embodiments of the present specification, the target loss can further include a reality loss . The reality loss By constraining the sampling noise to satisfy the Gaussian distribution, it is ensured that the denoised image sample does not deviate from the denoising probability distribution of the step, so as to avoid generating samples that do not conform to the original class distribution.

[0060] In a possible implementation manner, the reality loss of any step can be calculated in the following manner: calculating the difference between the denoised image sample obtained by denoising and the expected mean value corresponding to the current step; taking the ratio of the difference to the expected standard deviation corresponding to the current step as the sampling noise tensor of the current step; and taking the difference between the length of the sampling noise tensor and the expected length of the standard normal distribution of the same dimension as the reality loss of the current step.

[0061] Wherein, the expected mean value refers to the theoretical mean value corresponding to the current step, and the expected standard deviation refers to the theoretical standard deviation corresponding to the current step.

[0062] For a d-dimensional sampling noise tensor, each dimension is independently subject to a standard normal distribution. Correspondingly, the expected length of the standard normal distribution of the same dimension refers to the expected length corresponding to the d-dimensional standard normal distribution.

[0063] For example, the d-dimensional standard normal distribution z includes a standard normal distribution z1, a standard normal distribution z 2…… The standard normal distribution z d . The expected length of the d-dimensional standard normal distribution z is .

[0064] In a possible implementation manner, when the target loss includes the distribution alignment loss and the reality loss, the sum of the distribution alignment loss and the reality loss can be taken as the target loss.

[0065] In a possible implementation manner, when the target loss includes the distribution alignment loss and the reality loss, the distribution alignment loss and the reality loss correspond to different weights, respectively, and then the weighted sum of the distribution alignment loss and the reality loss is taken as the target loss.

[0066] In one or more embodiments of the present specification, through a multi-round iterative denoising processing flow, the target loss corresponding to each step of denoising processing is optimized to minimize the target loss of each step.

[0067] In one or more embodiments of the present specification, the iteration is not limited here. For example, after 200 rounds of iteration, the obtained denoised image sample is taken as a synthetic image sample.

[0068] In summary, the data set distillation method provided by one or more embodiments of the present specification uses distribution alignment loss and / or authenticity loss to constrain the predicted generated denoised image sample at each step of the diffusion model denoising process. Through the distribution alignment loss, the denoised image sample at each step can be explicitly optimized to ensure that the distribution of the denoised image sample at each step is consistent with the corresponding standard denoised image sample or standard noisy image sample probability distribution. Through the authenticity loss, the predicted denoised image sample can be constrained to satisfy the Gaussian distribution, thereby ensuring that the synthetic image sample does not deviate from the denoising probability distribution at this step, and avoiding the generation of outlier image samples.

[0069] In this way, by introducing distribution alignment loss and / or authenticity loss at each step of the denoising process, the random sampling bias is weakened, thereby reducing the deviation between the synthetic image sample generated by the diffusion model and its theoretical probability distribution, and improving the quality of the synthetic image sample.

[0070] In addition, in the case of using a standard denoised image sample as a standard image sample, the data set distillation method provided by one or more embodiments of the present specification does not require the participation of the original data set, and can be applied to special application scenarios where the original data set cannot be obtained.

[0071] It can be understood that the above embodiments are only examples, and the above embodiments can be deformed in actual implementation. Those skilled in the art can understand that the deformed methods of the above embodiments without creative labor fall within the protection scope of one or more embodiments of the present specification, and the embodiments will not be described again.

[0072] Based on the same inventive concept, one or more embodiments of the present specification also provide a data set distillation device. Since the principle of the problem solved by the data set distillation device is similar to the foregoing data set distillation method, the implementation of the data set distillation device can be referred to the implementation of the foregoing data set distillation method, and the repeated parts will not be described again.

[0073] Reference Figure 3 , Figure 3 is a structural block diagram of a data set distillation device provided by one or more embodiments of the present specification. As Figure 3 shown, the data set distillation device 200 can include an acquisition module 201 and a generation module 202. Wherein, The acquisition module 201 can be configured to acquire the noise image sample. The generation module 202 can be configured to utilize the diffusion model to gradually perform denoising processing on the data set distillation noise image sample according to a preset step length, and generate a synthetic image sample; wherein the generation module is configured to calculate a target loss of a denoised image sample obtained by denoising processing in any step of denoising processing, and optimize the data set distillation target loss through multiple rounds of iterative denoising processing; wherein the data set distillation target loss includes a distribution alignment loss, and the data set distillation distribution alignment loss is calculated based on the denoised image sample obtained by the current step of denoising processing and the standard image sample corresponding to the current step.

[0074] In a possible implementation, the data set distillation generation module 202 is specifically configured to: in any step of denoising processing, predict the mean and standard deviation of the second denoised image sample based on the first denoised image sample; wherein the data set distillation first denoised image sample is the denoised image sample obtained by the last step of denoising processing; randomly sample a noise tensor as the data set distillation second denoised image sample from a normal distribution corresponding to the data set distillation mean and standard deviation; and calculate the distribution alignment loss between the data set distillation second denoised image sample and the standard image sample corresponding to the current step.

[0075] In a possible implementation, the data set distillation generation module 202 is specifically configured to: determine a first probability distribution of the data set distillation second denoised image sample; determine a second probability distribution of the standard image sample corresponding to the current step; calculate the maximum mean difference between the data set distillation first probability distribution and the data set distillation second probability distribution; and take the data set distillation maximum mean difference as the distribution alignment loss of the current step.

[0076] In a possible implementation, the data set distillation standard image sample is a standard denoised image sample or a standard noisy image sample.

[0077] In a possible implementation, the method further includes: a first standard image sample generation module 203 configured to utilize the data set distillation diffusion model to gradually perform denoising processing on the data set distillation noise image sample according to the data set distillation preset step length; wherein in any step of denoising processing, a standard noise sampling denoised image is obtained based on the standard noise sampling denoised image, and the denoised image obtained by sampling at each step is taken as the standard denoised image sample at each step.

[0078] In a possible implementation, the method further includes: a second standard image sample generation module 204 configured to utilize the data set distillation diffusion model to gradually perform noise adding processing on the original image sample corresponding to the data set distillation noise image sample according to the data set distillation preset step length; wherein in any step of noise adding processing, a noisy image is obtained by adding standard noise; and the noisy image obtained at each step is taken as the standard noisy image sample at each step.

[0079] In a possible implementation, the dataset distillation generation module 202 is further configured to: in any step of the denoising processing, calculate a difference between a denoised image sample obtained through the denoising processing and an expected mean value corresponding to the current step; take a ratio between the dataset distillation difference value and an expected standard deviation corresponding to the current step as a sampling noise tensor of the current step; and take a difference between a module length of the dataset distillation sampling noise tensor and an expected module length of a standard normal distribution of the same dimension as a reality loss of the current step.

[0080] Referring to Figure 4 , Figure 4 A structural block diagram of an electronic device is provided for one or more embodiments of the present specification. As shown in Figure 4 , the electronic device 300 can include a processor 301 and a memory 302; the memory 302 can be coupled to the processor 301. It is worth noting that the Figure 4 is exemplary; other types of structures can also be used to supplement or replace the structure to implement telecommunication functions or other functions.

[0081] In a possible implementation, the functions of the dataset distillation apparatus 200 can be integrated into the processor 301. The processor 301 can be configured to perform the following operations: obtain a noisy image sample; and perform denoising processing on the dataset distillation noisy image sample in steps according to a preset step size using a diffusion model to generate a synthetic image sample; wherein in any step of the denoising processing, a target loss of a denoised image sample obtained through the denoising processing is calculated, and the dataset distillation target loss is optimized through multiple rounds of iterative denoising processing; wherein the dataset distillation target loss includes a distribution alignment loss, and the dataset distillation distribution alignment loss is calculated based on the denoised image sample obtained through the denoising processing of the current step and a standard image sample corresponding to the current step.

[0082] In another possible implementation, the dataset distillation apparatus 200 can be configured separately from the processor 301, for example, the dataset distillation apparatus 200 can be configured as a chip connected to the processor 301, and the dataset distillation is realized through the control of the processor 301.

[0083] In addition, in some optional implementations, the electronic device 300 can further include a communication module, an input unit, an audio processor, a display, a power supply, etc. It is worth noting that the electronic device 300 does not necessarily include all the components shown in Figure 4 ; in addition, the electronic device 300 can also include components not shown in Figure 4 , which can refer to prior art.

[0084] In some alternative implementations, the processor 301, also sometimes referred to as a controller or operating control, can include a microprocessor or other processor device and / or logic device that receives inputs and controls the operation of the various components of the electronic device 300.

[0085] The memory 302, for example, can be one or more of a buffer, a flash memory, a hard drive, a removable media, a volatile memory, a non-volatile memory, or other suitable device. Information relating to the data set distillation device 200 described above can be stored, and in addition, programs for executing the related information can be stored. The processor 301 can execute the programs stored in the memory 302 to achieve information storage or processing, etc.

[0086] An input unit can provide input to the processor 301. The input unit is, for example, a key or a touch input device. A power supply can be used to provide power to the electronic device 300. A display can be used to display display objects such as images and text. The display can be, for example, an LCD display, but is not limited thereto.

[0087] The memory 302 can be a solid state memory such as a read only memory (ROM), a random access memory (RAM), a SIM card, etc. It can also be a memory that retains information even when power is off, can be selectively erased, and is provided with more data, an example of which is sometimes referred to as an EPROM, etc. The memory 302 can also be some other type of device. The memory 302 includes a buffer memory (sometimes referred to as a buffer). The memory 302 can include an application / function storage section for storing application programs and function programs or a flow for executing the operation of the electronic device 300 by the processor 301.

[0088] The memory 302 can also include a data storage section for storing data such as contacts, digital data, pictures, sounds, and / or any other data used by the electronic device. A driver program storage section of the memory 302 can include various driver programs of the computer device for communication functions and / or for performing other functions of the computer device such as a messaging application, an address book application, etc.

[0089] A communication module is a transmitter / receiver that transmits and receives signals via an antenna. The communication module (transmitter / receiver) is coupled to the processor 301 to provide input signals and receive output signals, which can be the same as in the case of a conventional mobile communication terminal.

[0090] Based on different communication technologies, multiple communication modules, such as a cellular network module, a Bluetooth module, and / or a wireless local area network module, etc., can be provided in the same computer device. The communication modules (transmitters / receivers) are also coupled to a speaker and a microphone via an audio processor to provide audio output via the speaker and to receive audio input from the microphone to implement the usual telecommunication functions. The audio processor can include any suitable buffers, decoders, amplifiers, etc. In addition, the audio processor is also coupled to the processor 301 to enable recording on the local device via the microphone and to enable playing of stored sounds on the local device via the speaker.

[0091] One or more embodiments of the present specification also provide a computer readable storage medium capable of implementing all steps of the data set distillation method in the above-mentioned embodiments, and the computer program stored on the data set distillation computer readable storage medium is executed by the processor to implement all steps of the data set distillation method in the above-mentioned embodiments, for example, the data set distillation processor executes the data set distillation computer program to implement the following steps: Obtaining noise image samples; using a diffusion model, gradually denoising the data set distillation noise image samples according to a preset step size to generate synthetic image samples; wherein in any step of denoising processing, calculating the target loss of the denoised image samples obtained by denoising processing, and optimizing the data set distillation target loss through multiple rounds of iterative denoising processing; wherein the data set distillation target loss includes a distribution alignment loss, and the data set distillation distribution alignment loss is calculated based on the denoised image samples obtained by the current step of denoising processing and the corresponding standard image samples of the current step.

[0092] Although the present specification one or more embodiments provide the method operation steps of data set distillation as embodiments or flowcharts, more or less operation steps can be included based on conventional or non-inventive labor. The order of steps listed in the embodiments is only one of the many execution orders, and does not represent the only execution order. In actual device or client product execution, the method order shown in the embodiments or the drawings can be executed in sequence or in parallel (for example, in a parallel processor or multi-thread processing environment).

[0093] Those skilled in the art will appreciate that embodiments of the present specification can be provided as methods, apparatus (systems) or computer program products. Therefore, embodiments of the present specification can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Moreover, one or more embodiments of the present specification can take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0094] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks.

[0095] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks.

[0096] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. Figure 1 The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks. The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks.

[0097] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart or flows and / or block diagram block or blocks.

[0098] In this document, relational terms such as first and second are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "include," "comprise," or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device that includes a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article, or device. For those of ordinary skill in the art, the specific meanings of the above terms in one or more embodiments of this specification can be understood according to the specific circumstances.

[0099] It should be noted that, unless there is a conflict, the features of one or more embodiments of this specification and the features of the embodiments may be combined with each other. The one or more embodiments of this specification are not limited to any single aspect, nor to any single embodiment, nor to any combination and / or permutation of these aspects and / or embodiments. Moreover, each aspect and / or embodiment of one or more embodiments of this specification may be used alone or in combination with one or more other aspects and / or embodiments thereof.

[0100] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of one or more embodiments of this specification, and not to limit them. Although one or more embodiments of this specification are described in detail with reference to the above embodiments, ordinary technicians in this field should understand that they can still modify the technical solutions recorded in the above embodiments, or replace some or all of the technical features therein with equivalents. These modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of one or more embodiments of this specification, and they should all be included in the scope of the claims and description of one or more embodiments of this specification.

[0101] The above description of one or more embodiments of this specification is provided in conjunction with optional implementation methods, but these implementation methods are merely exemplary and serve only as an illustration. On this basis, various replacements and improvements can be made to one or more embodiments of this specification, all of which fall within the scope of protection of one or more embodiments of this specification.

Claims

1. A dataset distillation method, characterized in that: The method comprises: Get a noisy image sample; Using a diffusion model, the noise image samples are gradually denoised according to a preset step size to generate synthetic image samples; In any denoising step, the target loss of the denoised image samples obtained by the denoising process is calculated, and the target loss is optimized through multiple rounds of iterative denoising. The target loss includes a distribution alignment loss, which is calculated based on the denoised image samples obtained by the current denoising step and the standard image samples corresponding to the current step.

2. The method according to claim 1, wherein In any denoising step, the target loss of the denoised image sample obtained by the denoising process is calculated, including: In any denoising step, based on the first denoised image sample, the mean and standard deviation of the second denoised image sample are predicted; wherein the first denoised image sample is the denoised image sample obtained in the previous denoising step; Randomly sampling a noise tensor from a normal distribution corresponding to the mean and standard deviation as the second denoised image sample; Calculate the distribution alignment loss between the second denoised image sample and the standard image sample corresponding to the current step.

3. The method according to claim 2, wherein Calculating the distribution alignment loss between the second denoised image sample and the standard image sample corresponding to the current step, including: determining a first probability distribution of the second denoised image samples; Determine a second probability distribution of the standard image sample corresponding to the current step; calculating a maximum mean difference between the first probability distribution and the second probability distribution; The maximum mean difference is taken as the distribution alignment loss for the current step.

4. The method according to any one of claims 1 to 3, characterized in that The standard image samples are standard denoised image samples or standard noisy image samples.

5. The method according to claim 4, wherein The method further comprises: The diffusion model is used to denoise the noise image samples step by step according to the preset step size; wherein, in any denoising step, the denoised image is sampled based on the standard noise, and the denoised image obtained by sampling in each step is used as the standard denoised image sample in each step.

6. The method according to claim 4, wherein The method further comprises: The diffusion model is used to perform noise processing on the original image samples corresponding to the noise image samples step by step according to the preset step size; wherein, in any step of the noise processing, a noisy image is obtained by adding standard noise; and the noisy image obtained in each step is used as the standard noisy image sample in each step.

7. The method according to claim 1, wherein The target loss also includes authenticity loss. In any denoising step, the target loss of the denoised image sample obtained by the denoising process is calculated, and further includes: In any denoising process, the following steps are included: Calculate the difference between the denoised image sample obtained by denoising and the expected mean corresponding to the current step; The ratio of the difference to the expected standard deviation corresponding to the current step is used as the sampling noise tensor of the current step; The difference between the modulus of the sampled noise tensor and the expected modulus of the standard normal distribution of the same dimension is used as the authenticity loss of the current step.

8. A data set distillation device, characterized in that: The device comprises: An acquisition module, used for acquiring noise image samples; A generation module, configured to use a diffusion model to gradually denoise the noisy image samples according to a preset step size to generate synthetic image samples; Among them, the generation module is used to calculate the target loss of the denoised image samples obtained by the denoising process in any step of the denoising process, and optimize the target loss through multiple rounds of iterative denoising processes; wherein, the target loss includes the distribution alignment loss, and the distribution alignment loss is calculated based on the denoised image samples obtained by the current step of denoising and the standard image samples corresponding to the current step.

9. The device according to claim 8, wherein The generation module is specifically used to: In any denoising step, based on the first denoised image sample, the mean and standard deviation of the second denoised image sample are predicted; wherein the first denoised image sample is the denoised image sample obtained in the previous denoising step; from the normal distribution corresponding to the mean and standard deviation, a noise tensor is randomly sampled as the second denoised image sample; and the distribution alignment loss between the second denoised image sample and the standard image sample corresponding to the current step is calculated.

10. The device according to claim 9, wherein The generation module is specifically used to: Determine a first probability distribution of the second denoised image sample; determine a second probability distribution of the standard image sample corresponding to the current step; calculate the maximum mean difference between the first probability distribution and the second probability distribution; and use the maximum mean difference as the distribution alignment loss for the current step.

11. The device according to any one of claims 8 to 10, characterized in that The standard image samples are standard denoised image samples or standard noisy image samples.

12. The device according to claim 11, wherein Also includes: The first standard image sample generation module is used to use the diffusion model to gradually denoise the noisy image samples according to the preset step size; wherein, in any denoising step, the denoised image is sampled based on the standard noise, and the denoised image obtained by sampling at each step is used as the standard denoising image sample for each step.

13. The device according to claim 11, wherein Also includes: The second standard image sample generation module is used to use the diffusion model to gradually add noise to the original image samples corresponding to the noise image samples according to the preset step size; wherein, in any step of the noise addition process, a noisy image is obtained by adding standard noise; and the noisy image obtained in each step is used as the standard noisy image sample of each step.

14. The device according to claim 8, wherein The generating module is further configured to: In any denoising step, the difference between the denoised image sample obtained by the denoising process and the expected mean corresponding to the current step is calculated; the ratio of the difference to the expected standard deviation corresponding to the current step is used as the sampling noise tensor of the current step; the difference between the modulus of the sampling noise tensor and the expected modulus of the standard normal distribution of the same dimension is used as the authenticity loss of the current step.

15. An electronic device, characterized in that: The electronic device comprises: a memory for storing a computer program product; A processor is configured to execute a computer program product stored in the memory, and when the computer program product is executed, implements the method described in any one of claims 1 to 7.

16. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer program instructions, which, when executed, implement the method according to any one of claims 1 to 7.