An Adaptive Dynamic Threshold Method, System, Device and Medium for Processing Multi-Type Label Noises Based on Symmetric KLD
Through the combination of the adaptive dynamic threshold method of symmetric KLD and semi-supervised learning and contrast learning, the problem of noise memory and sample selection imbalance in multi-type label noise is solved, and the recognition accuracy of the model and the quality of the pseudo-label are improved.
Patent Information
- Application Number
- CN202310243322.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-14
- Publication Date
- 2025-08-05
- Estimated Expiration
- 2043-03-14
AI Technical Summary
When dealing with multi-type label noise, the prior art has problems of noise memory and sample selection imbalance, resulting in a degradation of model performance.
Adaptive dynamic thresholding method based on symmetric KLD is adopted, and clean data sets and noise data sets are screened by calculating symmetric KLD values. Combining semi-supervised learning and contrast learning, the model is iteratively trained to reduce noise memory and improve recognition accuracy.
It effectively solves the problem of sample selection imbalance, improves the overall quality of the pseudo-label, prevents the model from overfitting the noise label, and improves the recognition accuracy and detection accuracy.
Smart Images

Figure CN116229180B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer vision technology, and in particular to a method, system, device and medium for processing multi-type label noise based on a symmetric KLD adaptive dynamic threshold. Background Art
[0002] Image classification requires large amounts of labeled data for training, and label noise in labeled data can degrade the performance of deep neural network (DNN) models. Common methods for collecting labeled data rely on freely available online data, which can be automatically annotated through user tags and search engine searches. However, this annotation method inevitably introduces label noise. Because deep neural networks (DNNs) can effectively memorize arbitrary (noisy) labels during training, training with such noisy labels is difficult.
[0003] Existing deep learning-based label noise methods include:
[0004] (1) Label noise filtering method based on model prediction
[0005] Existing research has shown that noise filtering methods based on model predictions are more effective. These methods, such as KNN methods, ensemble methods, and decision tree rule-building methods, primarily detect and remove noise data based on model prediction results. While these methods can achieve good noise filtering results, when the noise rate of a sample is high, removing the noise sample can render the original data incomplete, potentially affecting modeling effectiveness.
[0006] (2) Label noise robustness modeling method
[0007] A novel loss function is designed to directly train on label-noisy data, allowing the relevant model to be trained directly using large-scale label-noisy data. This method is affected by the type of label noise (feature-independent random label noise and instance-dependent label noise), and this method also has the memory of the noisy labels, which makes the algorithm's performance less than ideal.
[0008] The title is "A method for identifying and processing label noise in deep learning", and the publication number is
[0009] The invention "CN112101328A" discloses a method for identifying and processing label noise in deep learning. Initial model training is completed by building a neural network on a dataset containing label noise, determining a loss function, and using gradient descent to train the parameters. A set of model parameters that minimize the loss function is obtained. The initially trained model is used to re-predict and classify the training set containing label noise. The predicted labels are compared with the actual labels, and the label noise data is manually screened out and re-labeled. Iterative training is performed on the dataset containing label noise to screen out potential label noise data for correction. Since iterative training uses a noisy dataset, noise memory is present. Therefore, when the noise rate is high, the method suffers from inaccurate recognition of noisy labels and requires manual intervention. Summary of the Invention
[0010] In order to overcome the shortcomings of the above-mentioned prior art, the purpose of the present invention is to provide an adaptive dynamic threshold method, system, device and medium for processing multi-type label noise based on symmetric KLD, which realizes sample separation through an adaptive dynamic threshold selection method based on symmetric KLD, selects the same number of clean samples from each category, selects unsupervised contrastive learning, and uses contrastive learning to constrain image features. Therefore, it has the characteristics of solving the problem of imbalance in the selection of simple samples and hard samples, improving the overall quality of pseudo labels, improving the accuracy of recognition, and preventing the model from overfitting noisy labels.
[0011] An adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD includes the following steps:
[0012] Step 1: Add symmetric noise, asymmetric noise, and instance-dependent noise to the dataset to obtain noise datasets with different ratios;
[0013] Step 2: Calculate the symmetric KLD value of the noise data set with different ratios obtained in step 1 to obtain the KLD value of all samples. Then, calculate the filtering threshold R of the sample by the calculation formula, and filter out the clean data set and the noisy data set by comparison.
[0014] Step 3: Based on the clean dataset obtained in step 2, i.e., the labeled dataset, label refinement is performed, i.e., model update, to obtain a model capable of learning to recognize different labels. Based on the noisy dataset obtained in step 2, the original noisy labels are removed to obtain an unlabeled dataset. The unlabeled dataset is subjected to pseudo-label prediction through data augmentation copy to obtain pseudo-labels. The obtained model capable of learning to recognize different labels is fused with the pseudo-labels to achieve semi-supervised learning. At the same time, the unlabeled dataset is subjected to comparative learning to obtain the minimum loss value.
[0015] Step 4: Continuously iterate the semi-supervised learning and contrastive learning in step 3 to obtain the minimum loss value of the noisy label processing model.
[0016] The symmetric noise, asymmetric noise and instance-dependent noise in step 1 are specifically:
[0017] Symmetrical noise: The sound samples of ten categories, including airplanes, cars, birds, cats, deer, dogs, frogs, horses, sheep, and trucks, are used as labels. Each sample corresponds to a label, and the symmetric noise is to randomly replace the label of the sample with one of the other nine labels.
[0018] Asymmetric noise, with the sound samples of truck→car, bird→plane, deer→horse, and cat→dog as corresponding labels;
[0019] Instance-dependent noise, by calculating the noise rate, the sound samples of ten categories, including airplane, car, bird, cat, deer, dog, frog, horse, sheep and truck, are used as labels. A sample is randomly selected as the label. The noise rate is obtained from the truncated normal distribution N(e,0.1 2 , [0,1]), where [0,1] represents the range of the truncated normal distribution and e represents the noise rate;
[0020] The parameter W is sampled from the standard normal distribution to generate instance-dependent label noise, and for each instance (x n ,y n ), use the following formula to get the probability of wrong label:
[0021] p=x n W
[0022] The size of W is S×K, where S is the length of each feature and K is the number of label categories.
[0023] The method for calculating the symmetrical KLD value and the method for calculating the filtering threshold R in step 2 are specifically as follows:
[0024] Step 2.1: For the noise datasets with different ratios obtained in step 1, calculate the label-symmetric KLD values of the true values and the label-symmetric KLD values of the predicted values respectively. The calculation formula is:
[0025]
[0026] where p i Represents the predicted value, y i represents the true value;
[0027] Step 2.2: Based on the label-symmetric KLD values of the true values and the label-symmetric KLD values of the predicted values obtained in step 2.1, calculate the critical values of all samples. The calculation formula is:
[0028]
[0029] where d avg represents the average value of all samples, γ represents an adjustable parameter, d max , d min They represent the maximum scatter value and the minimum scatter value in all samples, r represents the noise ratio, and N represents the number of samples;
[0030] Step 2.3: The critical value d of all samples obtained in step 2.2 crit , calculate the sample filtering threshold R, which is calculated as follows:
[0031] R=|d R | / N
[0032]
[0033]
[0034] Among them, β represents a positive parameter value, l(·) represents the cross entropy loss, and f represents the confidence regularization model; when the cross entropy loss value of the data sample set is greater than the filtering threshold R, that is, When , the sample data set is a clean data set. When the cross entropy loss value of the data sample set is less than the filtering threshold R, that is, When , the sample data set is a noise data set.
[0035] The specific process of the semi-supervised learning method in step 3 is:
[0036] Step 3.1: Remove labels based on the unlabeled image, i.e., the noise dataset, to obtain an unlabeled image;
[0037] Step 3.2: Based on the unlabeled image obtained in step 3.2, use the weak enhancement method and the strong enhancement method to obtain a weakly enhanced image and a strongly enhanced image respectively;
[0038] Step 3.3: Use cross entropy loss to train the model on clean images (i.e., labeled images) to obtain a self-learning model.
[0039] Step 3.4: The weakly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3 to obtain the predicted value for each class. The class with the highest predicted value is used as the true value label of the unlabeled image, that is, the pseudo label, and the loss value of the pseudo label can be obtained at the same time. The strongly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3 to obtain the predicted value of the image class label and the loss value of the class label.
[0040] Step 3.5: Add the pseudo-label loss value to the class label loss value to obtain the semi-supervised loss value and update the self-learning model;
[0041] Step 3.6: The convolutional encoder in the updated self-learning model obtained in step 3.5 extracts features from the strongly enhanced image obtained in step 3.2 to obtain an abstract feature representation;
[0042] Step 3.7: The abstract feature representation obtained in step 3.6 is applied to the projection The mapping is expressed as
[0043] Step 3.8 continuously updates the value obtained in step 3.6 and the one obtained in step 3.7 The contrastive learning loss value is obtained by using the network, and its calculation formula is:
[0044]
[0045]
[0046] Where ∈ is a constant value, C is the batch size, sim(z i ,z j ) is z i and z j The preselected similarity.
[0047] The calculation process of the loss value in step 3.4 is:
[0048]
[0049]
[0050]
[0051] in, is the unsupervised loss coefficient, represents the loss function.
[0052] The contrastive learning in step 3 can be used as a control group for semi-supervised learning.
[0053] The specific process of the iterative training in step 4 is:
[0054] Step 4.1: Add the semi-supervised loss value obtained in step 3.5 and the contrastive learning loss value obtained in step 3.8 to obtain the total loss value. The total loss value is calculated as:
[0055]
[0056] Among them, μ c represents the weight coefficient of contrastive learning, represents the semi-supervised loss value, Represents the loss value of contrastive learning;
[0057] Step 4.2: According to step 4.1 (Total loss value) The minimum loss value is obtained by continuous iterative training in the semi-supervised learning and contrastive learning networks.
[0058] A system for processing multi-type label noise with adaptive dynamic threshold based on symmetric KLD, comprising:
[0059] Noise dataset creation module: used to add symmetrical noise, asymmetrical noise, and instance-dependent noise to the dataset to obtain noise datasets with different ratios;
[0060] Sample separation module: used to calculate the symmetrical KLD value, obtain the KLD value of all samples, calculate the sample filtering threshold R, and screen out the clean data set and the noisy data set through comparison;
[0061] Semi-supervised learning module: used to process clean datasets to obtain a model capable of learning and recognizing different labels, and to process noisy datasets to obtain pseudo labels. The obtained model capable of learning and recognizing different labels is then fused with the pseudo labels and the fused model is trained.
[0062] Self-learning module: used for continuous iterative training of semi-supervised learning and contrastive learning to obtain the minimum loss value of the noisy label processing model.
[0063] A device for processing multi-type label noise with adaptive dynamic threshold based on symmetric KLD, comprising:
[0064] Memory: used for storing a computer program to implement the method of processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD according to claims 1 to 7;
[0065] A processor is configured to implement the method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD when executing the computer program.
[0066] A computer-readable storage medium comprising:
[0067] The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, a method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD can be implemented.
[0068] Compared with the prior art, the present invention has the following beneficial effects:
[0069] 1. The present invention provides a sample selector based on adaptive dynamic threshold selection of symmetric KLD, which filters out data with higher symmetric KLD according to the adaptive threshold determined by the training model using confidence regularization loss.
[0070] 2. The present invention uses contrastive learning to constrain image features, which can reduce the memory of label noise, prevent the model from overfitting the noise labels, and improve the noise detection accuracy.
[0071] 3. The present invention combines a semi-supervised algorithm with an adaptive dynamic threshold selection method based on symmetric KLD, making the detection accuracy significantly better than the CORES method in terms of feature-independent random noise and instance-related label noise.
[0072] 4. The present invention realizes sample separation by adopting an adaptive dynamic threshold selection method based on symmetric KLD. The threshold does not need to be manually fine-tuned at different stages of training. Instead, the filtering rate R is automatically adjusted according to the network prediction score. Therefore, it has the characteristics of being independent of hyperparameters, accurate recognition, and free from human influence.
[0073] 5. The present invention achieves class balance by selecting an equal number of clean samples from each class through a symmetric KLD uniform selection mechanism. Such a priori improves the overall quality of pseudo-labels, thereby significantly improving the performance of subsequent training based on semi-supervised learning.
[0074] 6. Based on the memory of noise labels, the present invention extracts better features through unsupervised contrast learning to improve the accuracy of noise recognition.
[0075] 7. The present invention realizes sample separation through an adaptive dynamic threshold selection method based on symmetric KLD, selects the same number of clean samples from each category, selects unsupervised contrastive learning, and uses contrastive learning to constrain image features. Therefore, it has the characteristics of solving the problem of imbalance in the selection of simple samples and hard samples, improving the overall quality of pseudo labels, improving the accuracy of recognition, and preventing the model from overfitting noisy labels.
[0076] 8. The system, device, and medium of the present invention for processing multi-type label noise based on symmetric KLD are used to implement a method for processing multi-type label noise based on symmetric KLD. Therefore, it has the characteristics of solving the problem of imbalance in the selection of simple samples and hard samples, improving the overall quality of pseudo labels, improving recognition accuracy, and preventing the model from overfitting noisy labels. BRIEF DESCRIPTION OF THE DRAWINGS
[0077] Figure 1 Flow chart of the method of the present invention.
[0078] Figure 2 This is a flow chart of the symmetric KLD-based adaptive dynamic threshold method of the present invention.
[0079] Figure 3 This is a structural diagram of the semi-supervised learning module of the present invention.
[0080] Figure 4 This is a diagram showing the effects of the present invention before and after adding comparative learning.
[0081] Figure 5 This is a diagram of the adaptive threshold values of the present invention [CIFAR10 data 50% noise rate]. DETAILED DESCRIPTION
[0082] The working principle of the present invention will be described in detail below with reference to the accompanying drawings.
[0083] See also Figure 1 , an adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD, comprising the following steps:
[0084] Step 1: Add symmetric noise, asymmetric noise, and instance-dependent noise to the CIFAR-10 and CIFAR-100 datasets;
[0085] Step 2: Based on the noise dataset with different ratios obtained in step 1, the KLD values of all samples are obtained by calculating the symmetric KLD value, and the filtering threshold R of the sample is obtained by calculation. The clean dataset and the noisy dataset are screened out by comparison; the KLD value refers to the relative entropy;
[0086] Step 3: Based on the clean dataset obtained in step 2, i.e., the labeled dataset, label refinement is performed, i.e., model update, to obtain a self-learning model. The self-learning model uses an 18-layer PreAct Resnet with a momentum of 0.9, a weight decay of 0.0005, a batch size of 128, an initial learning rate of 0.02, and a learning rate reduction of 10 times after every 150 epochs. The stochastic gradient descent (SGD) optimizer is used for training for 300 epochs to obtain a self-learning model with recognition labels.
[0087] Based on the noise dataset obtained in step 2, the original noise labels are removed to obtain an unlabeled dataset. The unlabeled dataset is used to predict pseudo labels through data augmentation copy to obtain pseudo labels. The obtained model with the ability to learn to recognize different labels is fused with the pseudo labels to achieve semi-supervised learning. At the same time, the unlabeled dataset is used for comparative learning to obtain the loss value.
[0088] Since semi-supervised learning faces the risk of noise memory, which may lead to inaccurate results, contrastive learning can be used as a control group for semi-supervised learning to improve its accuracy.
[0089] Step 4: Use the stochastic gradient descent (SGD) optimizer for the CIFAR-10 and CIFAR-100 datasets, and set the initial learning rate to 0.02, weight decay to 5e-4, momentum value to 0.9, and batch size to 64; for the Tiny-ImageNet dataset, use an initial learning rate of 0.01, weight decay to le-3, momentum value to 0.9, and batch size to 32; for the Clothing1M dataset, select an initial learning rate of 0.002, weight decay to 1e-3, momentum value to 0.9, and batch size to 32; train the semi-supervised learning and contrastive learning networks for 300 cycles respectively, output a loss value every 20 cycles, and linearly decay the learning rate by 0.1 every 120 cycles, and filter out the minimum loss value from the output loss values.
[0090] Symmetrical noise: We use sound samples from ten categories (airplane, car, bird, cat, deer, dog, frog, horse, sheep, and truck) as labels. Each sample corresponds to a label, and symmetric noise replaces the label of the sample with one of the other nine labels. We select training data with noise rates of {20%, 40%, 60%, 80%}.
[0091] Asymmetric noise: In the CIFAR-10 dataset, the sounds of truck → car, bird → airplane, deer → horse, and cat → dog are used as corresponding noise labels. That is, the label of the sample "truck" is replaced with "car", and the label of the sample "car" is replaced with "truck"; the label of the sample "bird" is replaced with "airplane", and the label of the sample "airplane" is replaced with "bird"; the label of the sample "deer" is replaced with "horse", and the label of the sample "horse" is replaced with "deer"; the label of the sample "cat" is replaced with "dog", and the label of the sample "dog" is replaced with "cat"; the training data with noise rates of {20%, 30%, 40%} are selected;
[0092] Instance-dependent noise is obtained by randomly selecting a label from the ten sound sample labels of airplane, car, bird, cat, deer, dog, frog, horse, sheep and truck in the CIFAR-10 dataset by calculating the noise rate. The noise rate is obtained from the truncated normal distribution N(e,0.12 , [0,1]), where [0,1] represents the range of the truncated normal distribution and e represents the noise rate;
[0093] The noise rate can be controlled but not limited to all instances having the same noise rate. The parameter W is sampled from the standard normal distribution to generate instance-related label noise. The probability of the wrong label is calculated using the following formula:
[0094] p=x n W
[0095] The size of W is S×K, where S is the length of each feature and K is the number of label categories;
[0096] For each instance (x n ,y n ), use p(y n )=-∞ and p=q n Softmax(p) ensures that the probability of getting the wrong label is q n .
[0097] See also Figure 2 The method for calculating the symmetrical KLD value and the filtering threshold R in step 2 is as follows:
[0098] Step 2.1: Based on the noise data sets with different ratios obtained in step 1, calculate the KLD values with symmetric true value labels and symmetric predicted value labels respectively. The calculation formula is:
[0099]
[0100] where p i Represents the predicted value, y i Represents the true value; when d i The smaller the value, the more similar the predicted value is to the true value;
[0101] Step 2.2: Based on the symmetric KLD values of the true value labels and the symmetric KLD values of the predicted value labels obtained in step 2.1, calculate the critical value d of all samples crit , and its calculation formula is:
[0102]
[0103] where d avg represents the average value of all samples, γ represents an adjustable parameter, d max , d min They represent the maximum scatter value and the minimum scatter value in all samples, r represents the noise ratio, and N represents the number of samples;
[0104] When the dataset is CIFAR-10, there is symmetric noise and the noise rate is 0.8, the critical value d crit =0.67;
[0105] Step 2.3: The critical value d of all samples obtained in step 2.2 crit , calculate the sample filtering threshold R, which is calculated as follows:
[0106] R=|d R | / N
[0107]
[0108]
[0109] Where β represents a positive parameter value, l(·) represents the cross entropy loss, and f represents the confidence regularization model;
[0110] When the cross entropy loss value of the data sample set is greater than the filtering threshold R, that is, When , the sample data set is a clean data set. When the cross entropy loss value of the data sample set is less than the filtering threshold R, that is, When , the sample data set is a noise data set.
[0111] See also Figure 3 The specific process of the semi-supervised learning method in step 3 is as follows:
[0112] Step 3.1: Remove labels based on the unlabeled image, i.e., the noise dataset, to obtain an unlabeled image;
[0113] Step 3.2: Based on the unlabeled image obtained in step 3.1, use the weak enhancement method and the strong enhancement method to obtain a weakly enhanced image and a strongly enhanced image respectively;
[0114] Step 3.3: Use cross entropy loss to train the model on clean images (i.e., labeled images) to obtain a self-learning model.
[0115] Step 3.4: The weakly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3, and the predicted value for each class is obtained. The class with the highest predicted value is used as the true value label of the unlabeled image, that is, the pseudo label, and the loss value of the pseudo label can be obtained at the same time; the strongly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3, and the class label prediction value of the image is obtained, and the loss value of the class label can be obtained at the same time;
[0116] Step 3.5: Add the pseudo-label loss to the class label loss to get the semi-supervised loss and update the self-learning model.
[0117] Step 3.6: The convolutional encoder of the updated self-learning model obtained in step 3.5 extracts features from the strongly enhanced image obtained in step 3.2 to obtain an abstract feature representation;
[0118] Step 3.7: The abstract feature representation obtained in step 3.6 is applied to the projection The mapping network is obtained, which is expressed as
[0119] Step 3.8: Continuously update the value obtained in step 3.6 The contrastive learning loss value is obtained by using the mapping network obtained in step 3.7, and the calculation formula is:
[0120]
[0121]
[0122] Among them, s is a constant value, C is the size of the batch processing, sim(z i ,z j ) is z i and z j The preselected similarity.
[0123] The calculation process of the loss value in step 3.4 is:
[0124]
[0125]
[0126]
[0127] in, is the unsupervised loss coefficient, Represents the loss function; the loss value is a fluctuating downward process, and the loss value after training is basically between 0.18-0.20.
[0128] See also Figure 4 , which represents the change in accuracy before and after adding unsupervised contrastive learning to the semi-supervised learning training. When the number of iterations is 350, the highest accuracy with contrastive learning can reach 95.78, while the accuracy without contrastive learning is always lower than that with contrastive learning, and the highest value is 94.62. Therefore, it can be seen that the accuracy with contrastive learning is significantly better than that without contrastive learning.
[0129] See also Figure 5, indicating that the filter rate R of the CIFAR10 dataset with 50% symmetric noise is self-adjusted according to the network prediction. Each iteration will generate a new threshold, and the threshold gradually increases and finally tends to stable fluctuations, which means that no manual adjustment is required in each training iteration.
[0130] In order to evaluate the performance of the label noise model, the experimental results are compared with some excellent methods currently designed for label noise. The experimental results of CE, GCE, LDMI, SL, DMix, CORES, UNICON, CYRRH and our method are compared on the Sym (symmetric noise) CIFAR-10, Sym (symmetric noise) CIFAR-100, ASym (asymmetric noise) CIFAR-10 and ASym (asymmetric noise) CIFAR-100 datasets are shown in Table 1:
[0131]
[0132] Table 1
[0133] It can be seen from Table 1 that CE, GCE, LDMI, SL, DMix, CORES, UNICON, CYRRH and the method of the present invention (Ours) have the highest average test accuracy on the Sym (symmetric noise) CIFAR-10 dataset when the noise rates are 20%, 40%, 60% and 80% respectively; CE, GCE, LDMI, SL, DMix, CORES, UNICON, CYRRH and the method of the present invention (Ours) have the highest average test accuracy on the Sym (symmetric noise) CIFAR-100 dataset when the noise rates are 20%, 40%, 60% and 80% respectively; CE, GCE, LDMI, On the ASym (asymmetric noise) CIFAR-10 dataset, it can be seen that the average test accuracy of the SL, DMix, CORES, UNICON, CYRRH and our method is the highest when the noise rates are 20%, 40%, 60% and 80% respectively. On the ASym (asymmetric noise) CIFAR-100 dataset, it can be seen that the average test accuracy of the CE, GCE, LDMI, SL, DMix, CORES, UNICON, CYRRH and our method is the highest when the noise rates are 20%, 40%, 60% and 80% respectively. In summary, the average test accuracy of the present invention is better than that of other methods.
[0134] On the Ins (Example) CIFAR-10 and Ins (Example) CIFAR-100 datasets, the experimental results of CE, SCE, Co-teaching, JoCoR, Peer Loss, CORES and our method are shown in Table 2:
[0135]
[0136] Table 2
[0137] As can be seen from Table 2, on the Ins (Example) CIFAR-10 dataset, CE, SCE, Co-teaching, JoCoR, Peer Loss, CORES, and the method of the present invention (Ours) have the highest average test accuracy when the noise rates are 20%, 40%, and 60%, respectively. On the Ins (Example) CIFAR-100 dataset, CE, SCE, Co-teaching, JoCoR, Peer Loss, CORES, and the method of the present invention (Ours) have the highest average test accuracy when the noise rates are 20%, 40%, and 60%, respectively. In summary, the average test accuracy of the method of the present invention (Ours) is superior to that of other methods.
[0138] On the Tiny-ImageNet dataset, the experimental results of CE, MentorNet, Co-teaching+, NCT, Cores, UNICON and our method are shown in Table 3:
[0139]
[0140] Table 3
[0141] As shown in Table 3, when the noise rate is 0%, the test accuracy of CE, MentorNet, Co-teaching+, NCT, CORES, UNICON and our method on the Tiny-ImageNet dataset is second only to UNCON. However, when the noise rate is 20% and 50%, our method has the highest test accuracy. In summary, the average test accuracy of our method is better than that of other methods.
[0142] The experimental results of CE, DMix, CORES, UNICON and our method on the Cloting1M dataset are shown in Table 4:
[0143] Method CE DMix CORES UNICON Ours Acc. 68.94 74.76 73.24 74.98 75.03
[0144] Table 4
[0145] As shown in Table 4, the test accuracy of our method is better than that of CE, DMix, CORES, UNICON and the method of the present invention on the Tiny-ImageNet dataset, which proves the feasibility of our method.
[0146] A system for processing multi-type label noise with adaptive dynamic threshold based on symmetric KLD includes:
[0147] Noise dataset creation module: used to add symmetrical noise, asymmetrical noise, and instance-dependent noise to the dataset to obtain noise datasets with different ratios;
[0148] Sample separation module: used to calculate the symmetrical KLD value, obtain the KLD value of all samples, calculate the sample filtering threshold R, and screen out the clean data set and the noisy data set through comparison;
[0149] Semi-supervised learning module: used to process clean datasets to obtain a model capable of learning and recognizing different labels, and to process noisy datasets to obtain pseudo labels. The obtained model capable of learning and recognizing different labels is then fused with the pseudo labels and the fused model is trained.
[0150] Self-learning module: Through continuous iterative training of semi-supervised learning and contrastive learning, the minimum loss value of the noisy label processing model is obtained.
[0151] A device for processing multi-type label noise with adaptive dynamic threshold based on symmetric KLD, comprising:
[0152] A memory for storing a computer program to implement the method of processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD according to claims 1 to 7;
[0153] A processor is configured to implement the method for implementing an adaptive dynamic threshold for processing multi-type label noise based on symmetric KLD when executing the computer program.
[0154] The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor, or the processor may be any conventional processor, etc. The processor serves as the control center of the device for processing adaptive dynamic thresholds for multiple types of tag noise based on symmetric KLD, and utilizes various interfaces and lines to connect various parts of the device for processing adaptive dynamic thresholds for multiple types of tag noise based on symmetric KLD.
[0155] When the processor executes the computer program, the steps of the above-mentioned method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD are implemented, for example: symmetric noise, asymmetric noise and instance-related noise are added to the data set respectively to obtain a noise data set containing different ratios; the noise data set containing different ratios is filtered out by calculating the symmetric KLD combined with the adaptive dynamic threshold selection method; the clean data set, i.e., the labeled data set, is subjected to label refinement, i.e., model update, to obtain a model with the ability to learn and identify different labels, the original noise label is removed from the obtained noise data set to obtain an unlabeled data set, the unlabeled data set is subjected to pseudo-label prediction through data enhancement copying to obtain pseudo-labels, the obtained model with the ability to learn and identify different labels is fused with the pseudo-labels to implement semi-supervised learning, and the unlabeled data set is subjected to comparative learning to obtain the minimum loss value. The comparative learning can be used as a control group for semi-supervised learning to improve the accuracy of semi-supervised learning; the minimum loss value of the noise label processing model can be obtained by continuous iterative training of semi-supervised learning and comparative learning.
[0156] Alternatively, when the processor executes the computer program, the functions of each module in the above system are realized, for example: a noise data set production module: used to add symmetrical noise, asymmetrical noise and instance-related noise to the data set respectively to obtain a noise data set containing different ratios; a sample separation module: used to calculate the symmetrical KLD value, obtain the KLD value of all samples, obtain the filtering threshold R of the sample by calculation, and screen out the clean data set and the noise data set by comparison; a semi-supervised learning module: used to process the clean data set to obtain a model with the ability to learn and identify different labels, process the noise data set to obtain pseudo-labels, fuse the obtained model with the ability to learn and identify different labels with the pseudo-labels, and train the fused model; a self-learning module: used to continuously iterate semi-supervised learning and comparative learning to obtain the minimum loss value of the noise label processing model; and output the result of the adaptive dynamic threshold for processing multi-type label noise based on symmetrical KLD.
[0157] Exemplarily, the computer program can be divided into one or more modules / units, and the one or more modules / units are stored in the memory and executed by the processor to complete the present invention. The one or more modules / units can be a series of computer program instruction segments that can complete preset functions, and the instruction segments are used to describe the execution process of the computer program in the device for processing adaptive dynamic thresholds of multi-type label noise based on symmetric KLD. For example, the computer program can be divided into a noise data set production module, a sample separation module, a semi-supervised learning module, and a self-learning module. The specific functions of each module are as follows: Noise data set production module: used to add symmetric noise, asymmetric noise and instance-related noise to the data set respectively, to obtain a noise data set containing different ratios; Sample separation module: used to calculate the symmetric KLD value, to obtain the KLD value of all samples, to obtain the filtering threshold R of the sample by calculation, and to screen out the clean data set and the noise data set by comparison;
[0158] Semi-supervised learning module: used to process clean data sets to obtain a model with the ability to learn and recognize different labels, process noisy data sets to obtain pseudo labels, fuse the obtained model with the ability to learn and recognize different labels with the pseudo labels, and train the fused model; self-learning module: used to continuously iterate semi-supervised learning and comparative learning to obtain the minimum loss value of the noisy label processing model; output the result of the adaptive dynamic threshold for processing multiple types of label noise based on the symmetric KLD.
[0159] The device for processing the adaptive dynamic threshold of multiple types of label noise based on symmetric KLD can be a computing device such as a desktop computer, a notebook, a PDA, and a cloud server. The device for processing the adaptive dynamic threshold of multiple types of label noise based on symmetric KLD can include, but is not limited to, a processor and a memory. Those skilled in the art will understand that the above is an example of a device for processing the adaptive dynamic threshold of multiple types of label noise based on symmetric KLD, and does not constitute a limitation on a device for processing the adaptive dynamic threshold of multiple types of label noise based on symmetric KLD. It can include more components than the above, or combine certain components, or different components. For example, the device for processing the adaptive dynamic threshold of multiple types of label noise based on symmetric KLD can also include input and output devices, network access devices, buses, etc.
[0160] The memory can be used to store the computer program and / or module, and the processor implements the various functions of the device for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD by running or executing the computer program and / or module stored in the memory and calling the data stored in the memory.
[0161] The memory may mainly include a program storage area and a data storage area. The program storage area may store an operating system and at least one application required for a function (such as a sound playback function, an image playback function, etc.); the data storage area may store data created based on the use of the mobile phone (such as audio data, a phone book, etc.). In addition, the memory may include a high-speed random access memory and may also include a non-volatile memory, such as a hard disk, internal memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a Flash Card, at least one disk storage device, a flash memory device, or other volatile solid-state storage device.
[0162] The present invention also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the steps of the method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD.
[0163] If the system integrated module / unit of the adaptive dynamic threshold for processing multiple types of tag noise based on symmetric KLD is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium.
[0164] The present invention implements all or part of the process steps of the above-mentioned method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD, and can also be completed by instructing related hardware through a computer program. The computer program can be stored in a computer-readable storage medium. When executed by a processor, the computer program can implement the steps of the above-mentioned method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD. The computer program includes computer program code, which can be in source code form, object code form, executable file, or preset intermediate form.
[0165] The computer-readable storage medium may include: any entity or device that can carry the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium, etc.
[0166] It should be noted that the content contained in the computer-readable storage medium can be appropriately increased or decreased according to the requirements of legislation and patent practices in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practices, computer-readable storage media do not include electrical carrier signals and telecommunication signals.
[0167] It should be noted that the embodiments of the present invention can be implemented by hardware, software, or a combination of software and hardware. The hardware portion can be implemented using dedicated logic; the software portion can be stored in a memory and executed by an appropriate instruction execution system, such as a microprocessor or dedicated hardware.
Claims
1. An adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD, characterized in that: The following steps are involved: Step 1: Add symmetric noise, asymmetric noise, and instance-dependent noise to the dataset to obtain noise datasets with different ratios; Step 2: Based on the noise data set with different ratios obtained in step 1, the KLD values of all samples are obtained by calculating the symmetric KLD value, and the filtering threshold R of the samples is calculated. The clean data set and the noisy data set are screened out by comparison; The method for calculating the symmetric KLD value and the method for calculating the filtering threshold R are as follows: Step 2.1: Based on the noise data set with different ratios obtained in step 1, calculate the label-symmetric KLD value of the true value and the label-symmetric KLD value of the predicted value respectively. The calculation formula is: Among them, p i Represents the predicted value, y i represents the true value; Step 2.2: Based on the label-symmetric KLD values of the true values and the label-symmetric KLD values of the predicted values obtained in step 2.1, calculate the critical values of all samples. The calculation formula is: Among them, d avg represents the average value of all samples, γ represents an adjustable parameter, d max , d min They represent the maximum scatter value and the minimum scatter value in all samples, r represents the noise ratio, N represents the number of samples; K is the number of label categories; Step 2.3: The critical value d of all samples obtained in step 2.2 crit , calculate the sample filtering threshold R, which is calculated as follows: R=|d R | / N Among them, d R Indicates that the symmetric KLD value is less than the critical value d crit For all samples of , β represents a positive parameter value, Represents the cross entropy loss, f represents the confidence regularization model; when the cross entropy loss value of the data sample set is greater than the filtering threshold R, that is, When , the sample data set is a clean data set. When the cross entropy loss value of the data sample set is less than the filtering threshold R, that is, When , the sample data set is a noise data set; Step 3: Based on the clean dataset obtained in step 2, i.e., the labeled dataset, label refinement is performed, i.e., model update, to obtain a model capable of learning to recognize different labels. Based on the noisy dataset obtained in step 2, the original noise labels are removed to obtain an unlabeled dataset. Pseudo-label predictions are performed on the unlabeled dataset through data augmentation copying to obtain pseudo-labels. The obtained model capable of learning to recognize different labels is fused with the pseudo-labels to achieve semi-supervised learning. At the same time, comparative learning is performed on the unlabeled dataset to obtain the minimum loss value. Step 4: By continuously iteratively training the semi-supervised learning and contrastive learning in step 3, the minimum loss value of the model for processing noisy labels is obtained.
2. The adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD according to claim 1 is characterized in that: The symmetric noise, asymmetric noise and instance-dependent noise in step 1 are specifically: Symmetrical noise: The sound samples of ten categories (airplane, car, bird, cat, deer, dog, frog, horse, sheep, and truck) are used as labels. Each sample corresponds to a label. Symmetrical noise is to randomly replace the label of this sample with one of the other nine labels. Asymmetric noise, with the sound samples of truck→car, bird→plane, deer→horse, and cat→dog as corresponding labels; Instance-dependent noise is obtained by randomly selecting a label from the ten sound sample labels of airplane, car, bird, cat, deer, dog, frog, horse, sheep and truck in the CIFAR-10 dataset by calculating the noise rate. The noise rate is obtained from the truncated normal distribution N(e,0.1 2 , [0,1]), where [0,1] represents the range of the truncated normal distribution and e represents the noise rate; The parameter W is sampled from the standard normal distribution to generate instance-dependent label noise, and for each instance (x n ,y n ), use the following formula to get the probability of wrong label: p=x n ·W The size of W is S×K, where S is the length of each feature and K is the number of label categories.
3. The adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD according to claim 1 is characterized in that: The specific process of the semi-supervised learning method in step 3 is: Step 3.1: Remove labels based on the unlabeled image, i.e., the noise dataset, to obtain an unlabeled image; Step 3.2: Based on the unlabeled image obtained in step 3.2, use the weak enhancement method and the strong enhancement method to obtain a weakly enhanced image and a strongly enhanced image respectively; Step 3.3: Use cross entropy loss to train the model on clean images (i.e., labeled images) to obtain a self-learning model. Step 3.4: The weakly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3 to obtain the predicted value for each class. The class with the highest predicted value is used as the true value label of the unlabeled image, that is, the pseudo label, and the loss value of the pseudo label is obtained. The strongly enhanced image obtained in step 3.2 is transferred to the self-learning model obtained in step 3.3 to obtain the predicted value of the image class label and the loss value of the class label. Step 3.5: Add the pseudo-label loss value to the class label loss value to obtain the semi-supervised loss value and update the self-learning model; Step 3.6: The convolutional encoder in the updated self-learning model obtained in step 3.5 extracts features from the strongly enhanced image obtained in step 3.2 to obtain an abstract feature representation; Step 3.7: The abstract feature representation obtained in step 3.6 is applied to the projection The mapping is expressed as Step 3.8: Continuously update the data obtained in step 3.6 and obtained in step 3.7 The contrastive learning loss value is obtained by using the network, and its calculation formula is: Where,∈ is a constant value, C is the batch size, sim(z i ,z j ) is z i and z j The preselected similarity.
4. The adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD according to claim 3 is characterized in that: The calculation process of the loss value in step 3.4 is: in, is the unsupervised loss coefficient, represents the loss function.
5. The adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD according to claim 1 is characterized in that: The contrastive learning in step 3 can be used as a control group for semi-supervised learning.
6. The adaptive dynamic threshold method for processing multi-type label noise based on symmetric KLD according to claim 3 is characterized in that: The specific process of the iterative training in step 4 is: Step 4.1: Add the semi-supervised loss value obtained in step 3.5 and the contrastive learning loss value obtained in step 3.8 to get the total loss value. The total loss value is calculated as: where μ c represents the weight coefficient of contrastive learning, represents the semi-supervised loss value, Represents the loss value of contrastive learning; Step 4.2: The total loss value obtained from step 4.1 The minimum loss value is obtained by continuous iterative training in the semi-supervised learning and contrastive learning networks.
7. A system for processing multi-type label noise with adaptive dynamic thresholds based on symmetric KLD, used to implement the method described in claim 1, characterized in that: include: Noise dataset creation module: used to add symmetrical noise, asymmetrical noise, and instance-dependent noise to the dataset to obtain noise datasets with different ratios; Sample separation module: used to calculate the symmetrical KLD value, obtain the KLD value of all samples, calculate the sample filtering threshold R, and screen out the clean data set and the noisy data set through comparison; Semi-supervised learning module: used to process clean datasets to obtain a model capable of learning and recognizing different labels, and to process noisy datasets to obtain pseudo labels. The obtained model capable of learning and recognizing different labels is then fused with the pseudo labels and the fused model is trained. Self-learning module: used for continuous iterative training of semi-supervised learning and contrastive learning to obtain the minimum loss value of the noisy label processing model.
8. A device for processing multi-type label noise with adaptive dynamic threshold based on symmetric KLD, characterized in that: include: Memory: used for storing a computer program to implement the method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD according to any one of claims 1 to 6; A processor, configured to implement the method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD as described in any one of claims 1 to 6 when executing the computer program.
9. A computer-readable storage medium, characterized in that include: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, it can implement the method for processing multi-type label noise with an adaptive dynamic threshold based on symmetric KLD according to any one of claims 1 to 6.
Citation Information
Patent Citations
Method for identifying and processing label noise in deep learning
CN112101328A
Oversampling method based on multi-fake generative adversarial network
CN114004333A
Image detection method and apparatus, computer-readable storage medium, and computer device
WO2023284465A1