Noise-containing label image classification method based on neighbor anchor point label correction

By calculating the confidence of various categories of samples in the image classification model and using the k-nearest anchor point criterion and mixup method, trusted samples are screened and transferred from the noise subset, the problem of noise label affecting model performance in the prior art is solved, and the generalization ability of the model at high noise rates is improved.

CN119762857AActive Publication Date: 2025-04-04CHONGQING UNIV OF POSTS & TELECOMM

Patent Information

Application Number
CN202411827380.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-12
Publication Date
2025-04-04
Estimated Expiration
2044-12-12

AI Technical Summary

Technical Problem

In the prior art, when processing image data sets containing noise tags, it is difficult to effectively utilize the noise data subset, resulting in poor generalization and training failure of the model at high noise rates.

Method used

By calculating the confidence of various categories of samples in the clean subset, the potentially correctable samples are selected, and using the k-nearest anchor criterion and mixup method, trusted samples are selected from the noise subset, dynamically expand the clean sample subset, and transfer them to the clean subset.

Benefits of technology

Effectively utilize noise subsets at high noise rates, improve the generalization ability and performance of the model, and solve the problem of unbalanced sample number distribution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119762857A_ABST
    Figure CN119762857A_ABST
Patent Text Reader

Abstract

The invention relates to a noise-containing label image classification method based on neighbor anchor point label correction. The method comprises the following steps: carrying out preheating training on an image classification model; dividing the image data set with the noise label into a clean subset and a noise subset, and training an image classification model by using a mode of combining supervised learning and semi-supervised learning for the clean subset and the noise subset; calculating the confidence degree of each type of sample in the clean subset; selecting potential correctable samples from the noise subsets according to the confidence coefficients of various types of samples; k nearest neighbor samples of the potential correctable samples are selected from the clean subset, and the mix prediction consistency with the k nearest neighbor samples is calculated; transferring potential correctable samples with consistent prediction from a noise subset to a clean subset; and updating the noise subset and the clean subset, training the image classification model for the clean subset and the noise subset by using a mode of combining supervised learning and semi-supervised learning, and repeatedly executing the steps to obtain a trained image classification model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of image classification, and in particular relates to a method for classifying images containing noisy labels based on nearest neighbor anchor point label correction. Background Art

[0002] The performance of such models depends on large-scale accurately labeled datasets, which limits the development of the model. It is expensive and time-consuming to obtain a large amount of accurately labeled image data, especially in professional fields, which requires domain experts to label, making it difficult to obtain large-scale accurately labeled datasets.

[0003] To solve this problem, a common approach is to use crowdsourcing to have non-professionals do the labeling, or to obtain data sets from Internet search engines. Although this method solves the problem of difficult to obtain and expensive data sets, it will result in a large number of incorrect labels in the data, namely noisy labels. Experiments have shown that deep neural networks can even learn completely randomly generated noisy data. Therefore, data sets with noisy labels will affect the model's ability to learn the correct category boundaries, resulting in poor generalization, and even training failure when the noise rate is too high.

[0004] Currently, in the field of noisy label learning, the method based on sample selection is considered to be the most promising solution. Through sample selection methods, such as the small loss criterion, the data set is divided into a clean data set and a noisy data set, and different learning methods are used for the two. However, the current methods do not fully utilize the noise data subset. The simple semi-supervised learning method does not fully tap the potential of the noise label. Especially under high noise rates, the model lacks enough labeled samples, resulting in low accuracy of pseudo labels predicted for the noise subset, further degrading the performance of the model. Summary of the invention

[0005] In order to solve the problems existing in the background technology, the present invention provides a classification method for images containing noisy labels based on neighbor anchor label correction, which is characterized by comprising:

[0006] S1: Obtain an image dataset with noisy labels and build an image classification model;

[0007] S2: training the image classification model, and classifying the test image by using the trained image classification model, wherein the training of the image classification model includes three training stages;

[0008] S21: In the first training stage, preheating training is performed on the image classification model to enable the image model to acquire feature extraction and feature classification capabilities;

[0009] S22: In the second training stage, based on the small loss criterion, the image dataset with noise labels is divided into a clean subset and a noise subset, and the image classification model is trained for the clean subset and the noise subset by combining supervised learning with semi-supervised learning;

[0010] S23: In the third training stage, based on the nearest anchor point criterion, the confidence of each category of samples in the clean subset is calculated; and potential correctable samples are selected from the noise subset according to the confidence of each category of samples;

[0011] S24: According to the k-nearest neighbor anchor criterion, k nearest neighbor samples of the potentially correctable sample are selected from the clean subset, and the mixup prediction consistency of the image classification model for the potentially correctable sample and its k nearest neighbor samples is calculated; and the potentially correctable samples with consistent predictions are transferred from the noise subset to the clean subset;

[0012] S25: Update the noise subset and the clean subset, and train the image classification model for the clean subset and the noise subset using a combination of supervised learning and semi-supervised learning. Repeat steps S23-S25 until a preset number of iterations is reached to obtain a trained image classification model.

[0013] The present invention has at least the following beneficial effects

[0014] The present invention solves the problem of unbalanced sample quantity distribution due to different learning difficulties and confidence thresholds of samples of different categories by calculating the confidence of samples of each category in the clean subset. The threshold of each category can be linearly adjusted based on the global threshold and the confidence of its own category; the potential correctable sample subset is screened out from the noise subset by the calculated category confidence, and the k nearest neighbor samples of the potential correctable sample are selected from the clean subset by the k nearest neighbor anchor criterion. The mixed sample is generated by the mixup method, sent to the network for prediction, and the sample whose prediction result is consistent with the original result and whose confidence reaches the threshold is selected and updated to the clean subset. This method dynamically expands the clean sample subset during the training process, and at the same time converts the credible samples in the noise subset from unsupervised learning and semi-supervised learning to supervised learning, so that the model can learn the samples more fully. Through the above method, the present invention can also effectively utilize the noise subset under high noise rate, and improve the generalization ability and performance of the model. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] Figure 1 It is a schematic diagram of the method flow of the present invention. DETAILED DESCRIPTION

[0016] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments only illustrate the basic concept of the present invention in a schematic manner, and the following embodiments and features in the embodiments can be combined with each other without conflict.

[0017] See also Figure 1 The present invention provides a method for classifying noisy labeled images based on neighbor anchor label correction, comprising:

[0018] S1: Obtain an image dataset with noisy labels and build an image classification model;

[0019] Preferably, the image classification model comprises: a feature extractor F(·), a feature projector H p (·) and classifier H c (·); the feature extractor F(·) is used to extract features from samples, and the classifier H c (·) is used to classify the features extracted by the feature extractor F(·), and the feature projector H p (·) is used to reduce the dimension of the features extracted by the feature extractor F(·) to obtain the low-dimensional features of the sample.

[0020] In this embodiment, the image dataset with noisy labels contains images of multiple categories, but the labels may contain noise, and the noise rate of the labels is known; an image classification model is constructed, which consists of three main parts: a feature extractor F(·), a feature projector H p (·) and classifier H c (·); the feature extractor F(v) is used to extract features from the input image samples and generate a high-dimensional feature vector; a convolutional neural network (CNN) can be used as a feature extractor. CNN can extract local and global features from images through multi-layer convolution and pooling operations, such as the feature extractor of the ResNet series; the feature projector H p(·) is used to reduce the dimensionality of the high-dimensional feature vector generated by the feature extractor to obtain a low-dimensional feature vector. This helps to reduce the amount of computation while retaining key information. A fully connected layer or dimensionality reduction technique (such as principal component analysis PCA, t-SNE, etc.) can be used as a feature projector. In this example, a fully connected layer is used for dimensionality reduction, and its output dimension can be adjusted according to actual needs. The classifier is used to classify the low-dimensional feature vector generated by the feature projector and output the category label of the sample. A fully connected layer plus a softmax function can be used as a classifier. The softmax function can convert the output into a probability distribution to obtain the predicted probability of each category.

[0021] S2: training the image classification model, and classifying the test image by using the trained image classification model, wherein the training of the image classification model includes three training stages;

[0022] S21: In the first training stage, preheating training is performed on the image classification model to enable the image model to acquire feature extraction and feature classification capabilities;

[0023] Preferably, the preheating training of the image classification model includes:

[0024] S211: Freeze classifier H c (·), the image dataset with noisy labels Discard the label to get an unlabeled dataset N represents the number of samples, x i represents the i-th sample, y i Represents sample x i The label of the unlabeled dataset D w_u The feature extractor F(·) and the feature projector H are trained by unsupervised contrastive learning. p (·) for training, the loss function is contrast loss, and the training is repeated T w1 Rounds;

[0025] In this embodiment, strong enhancement and weak enhancement are used to construct positive and negative sample pairs. Strong enhancement samples and original samples constitute negative sample pairs, while weak enhancement samples and strong enhancement samples (or original samples, but strong enhancement samples are usually selected for consistency) constitute positive sample pairs. This helps the model learn more discriminative feature representations. Use a contrastive loss function (such as InfoNCE loss) to train the feature extractor F(·) and the feature projector H p (·).

[0026] S212: Freeze the feature extractor F(·) and feature projector H p (·), based on a dataset of images with noisy labels For the classifier H c(·) Perform supervised training, use cross entropy loss as loss function, and repeat training Tw 2 Round.

[0027] Preferably, the feature extractor F(·) and the feature projector H are trained by unsupervised contrastive learning. p (·) Training includes:

[0028] The sample x i Perform strong enhancement and weak enhancement respectively to obtain strong enhancement samples and weakly enhanced samples Strongly enhanced samples With the original sample x i Constitute negative sample pairs, weakly enhanced samples With the original sample Constitute a positive sample pair; the contrast loss function is used to shorten the feature distance of the positive sample pair output by the feature projector and to increase the feature distance of the negative sample pair output by the feature projector.

[0029] In this embodiment, for sample x i Strong enhancement includes: rotation, scaling, cropping, color jitter, etc. For example, the image is rotated by a certain angle, such as ±30 degrees, ±45 degrees, etc. to simulate a wider range of image changes. In this embodiment, the sample x i Weak enhancement includes: slight rotation, slight scaling, slight cropping or slight color adjustment, slightly rotating the image by a certain angle, such as ±5 degrees, ±10 degrees. The purpose of weak enhancement is to increase the diversity of data without significantly changing the image content, while avoiding the introduction of too much noise or interference information.

[0030] In this embodiment, the contrast loss function includes:

[0031]

[0032]

[0033]

[0034]

[0035]

[0036]

[0037]

[0038]

[0039]

[0040] Among them, loss sim represents the contrast loss function, sim(.) represents the cosine similarity function; d∈(0,1) represents the temperature coefficient; exp(.) represents the exponential function; |D| represents the number of samples in the data set D.

[0041] S22: In the second training stage, based on the small loss criterion, the image dataset with noise labels is divided into a clean subset and a noise subset, and the image classification model is trained for the clean subset and the noise subset by combining supervised learning with semi-supervised learning;

[0042] Preferably, dividing the image dataset with noise labels into a clean subset and a noise subset comprises:

[0043] S221: Input each sample of the image data set with noise labels into the preheated trained image classification model, and calculate the divergence between the predicted label output by the classifier and the actual label;

[0044] Preferably, the step of calculating the divergence between the predicted label output by the classifier and the actual label comprises:

[0045]

[0046] Among them, d i represents the divergence of the ith sample, JSD() represents the divergence function, and KLD(·) is the KL divergence function; represents the predicted label of the i-th sample output by the classifier, and yi represents the actual label of the i-th sample.

[0047] In this embodiment, each sample in the image data set with noise labels is input into the preheated trained image classification model, and the divergence between the predicted label and the actual label output by the classifier is calculated as an indicator to measure the reliability of the sample label.

[0048] S222: traverse each category of the image data set with noise labels, sort the samples under each category from small to large according to their divergence, and select the first r proportion of samples to add to the clean subset, and add the remaining samples to the noise subset. After traversing all categories, the divided clean subset and noise subset are obtained, and r represents the noise rate of the image data set with noise labels.

[0049] In this embodiment, step S22 is used to effectively utilize the image dataset with noise labels to train a more robust image classification model.

[0050] S23: In the third training stage, based on the nearest anchor point criterion, the confidence of each category of samples in the clean subset is calculated; and potential correctable samples are selected from the noise subset according to the confidence of each category of samples;

[0051] Preferably, the step S23 comprises:

[0052] S231: Samples of the clean subset Input to the image classification model to obtain the prediction results of the sample:

[0053]

[0054]

[0055] Among them, p j Representation sample The forecast results in each category; Representation sample The actual label, Representation sample The predicted label of D clean represents the clean subset; Indicates D clean The jth clean sample in ;

[0056] S232: Calculate the global sample confidence of the clean subset:

[0057]

[0058] Among them, τ t represents the global sample confidence of the clean subset at the tth iteration, Q represents the total number of categories of samples in the clean subset, m represents the attenuation coefficient (0.95~0.99), N clean Represents the number of samples in the clean subset; max(.) represents the maximum value function;

[0059] S233: Calculate the confidence of each category in the clean subset based on the global sample confidence of the clean subset:

[0060]

[0061]

[0062] in, represents the confidence of category q in the clean subset at the tth iteration;

[0063] S234: The noise subset D noise Noise samples in Input into the image classification model to obtain the predicted label and prediction confidence of the noise sample;

[0064]

[0065]

[0066] in, Denotes the noise subset D noise The predicted label of the kth noise sample in c k express ; and based on the predicted labels and predicted confidences of the noise samples in the noise subset and the confidences of each category in the clean subset, a set of potentially correctable samples is screened out from the noise subset:

[0067]

[0068] Among them, D noise represents the noise subset; Represents a noise sample The predicted label of Dhc is the potential correctable sample set, c k Represents the noise samples in the noise subset Confidence of predictions; Represents the category in the clean subset confidence level.

[0069] S24: According to the k-nearest neighbor anchor criterion, k nearest neighbor samples of the potentially correctable sample are selected from the clean subset, and the mixup prediction consistency of the image classification model for the potentially correctable sample and its k nearest neighbor samples is calculated; and the potentially correctable samples with consistent predictions are transferred from the noise subset to the clean subset;

[0070] Preferably, the step S24 comprises:

[0071] S241: Subset of potentially correctable samples Potentially correctable samples in Input the image classification model and get the feature projector H p (·) Output low-dimensional feature set N p represents the number of potentially correctable samples;

[0072] S242: Subset clean samples Clean samples in Input the image classification model and get the feature projector H p (·) Output low-dimensional feature set

[0073] S243: Low-dimensional features of potentially correctable samples Input the KNN module to calculate the k nearest neighbor sample set of potential corrected samples and clean samples

[0074] S244: Mixup the potentially correctable samples with their corresponding k nearest neighbor samples to obtain a mixup fusion sample set in, express The vth nearest neighbor sample; express The vth mixup fusion sample; a represents the weight factor;

[0075] S245: Input the mixup fusion samples of the potential correctable samples into the image classification model to obtain the prediction results of the mixup fusion samples; average the prediction results of k mixup fusion samples of the potential correctable samples in all categories to obtain the fusion prediction label of the potential correctable samples and fusion confidence

[0076]

[0077]

[0078] S246: Based on the confidence of each category of samples in the clean subset, the fusion prediction label of the potentially correctable samples and fusion confidence Get the correctable sample set D corrent :

[0079]

[0080] in, Indicates the category at t iterations The confidence level is calculated in step S233; N correct represents the number of correctable samples;

[0081] S247: The correctable sample set D corrent The samples in the set are transferred to the clean subset.

[0082] In this embodiment, steps S23 and S24 can effectively screen out potential correctable samples from the noise subset, and further verify their correctness through Mixup and k-nearest neighbor anchor point criteria, and finally transfer them to the clean subset to improve the performance of the image classification model.

[0083] S25: Update the noise subset and the clean subset, and train the image classification model for the clean subset and the noise subset using a combination of supervised learning and semi-supervised learning. Repeat steps S23-S25 until a preset number of iterations is reached to obtain a trained image classification model.

[0084] Preferably, the training of the image classification model using a combination of supervised learning and semi-supervised learning on the clean subset and the noise subset comprises:

[0085] Input the clean samples in the clean subset into the image classification model to obtain the predicted labels of the clean samples, and construct the cross entropy loss function based on the predicted labels and true labels of the clean samples;

[0086]

[0087] Among them, loss clean represents the cross entropy loss function, L ce (·) is the cross entropy loss function, F(·) is the feature extractor, H c (·) is the classifier; D clean represents the clean subset; Indicates D clean The jth clean sample in ; represents the jth clean sample The true label of represents the jth clean sample The predicted label of

[0088] The samples in the clean subset are mixed with the samples in the noise subset to obtain a mixed sample set, and a semi-supervised loss function is constructed based on the original labels of the mixed samples and their prediction results;

[0089]

[0090]

[0091]

[0092] Among them, loss ssl represents the semi-supervised loss function, D mixup represents a mixed sample set, N mixup represents the number of mixed samples in the mixed sample set, L ce (·) is the cross entropy loss function; mixup(.) represents the mixup mixing function; and Represents the lth mixed sample and its corresponding label Denotes the noise subset D noise The kth noise sample in ; Representation sample The predicted label of

[0093] The noise samples in the noise subset are strongly enhanced and weakly enhanced to obtain strongly enhanced noise samples and weakly enhanced noise samples; the strongly enhanced noise samples With the original sample x k Constitute negative sample pairs, weakly enhanced samples With the original sample Construct positive sample pairs, and construct a contrast loss function to shorten the feature distance of the positive sample pairs output by the feature projector and to increase the feature distance of the negative sample pairs output by the feature projector. The contrast loss function includes:

[0094]

[0095]

[0096]

[0097]

[0098]

[0099]

[0100]

[0101]

[0102]

[0103] Among them, loss sim represents the contrast loss function, N noise Denotes the noise subset D noise The number of noise samples in; d∈(0,1) represents the temperature coefficient; sim(.) represents the cosine similarity function; For sample x 2b-1 ∈D noise Weakly enhanced samples; For sample x 2b ∈D noise Weakly enhanced samples; For sample x 2b-1 ∈D noise Strongly enhanced samples; For sample x 2b ∈D noise Strongly enhanced samples; exp(.) represents the exponential function.

[0104] The total loss function is constructed based on the cross entropy loss function, semi-supervised loss function and contrast loss function, and the image classification model is supervised and semi-supervised through the total loss function:

[0105] loss=loss clean +λ ssl loss ssl +λ sim loss sim

[0106] Among them, loss represents the total loss function, λ ssl and λ sim Represents an adjustable weight parameter.

[0107] In this embodiment, the cross entropy loss function loss clean The performance of the model on the clean subset is measured through the semi-supervised loss function loss ssl The information in the mixed samples is used to help the model learn on noisy data, and the loss function loss is learned by comparison. sim The model's robustness to noisy samples is enhanced. By combining the cross entropy loss function, semi-supervised loss function, and contrastive loss function, the model will learn from both the clean subset and the noisy subset, improving its generalization ability in a noisy environment.

[0108] In summary, the present invention solves the problem of unbalanced sample quantity distribution due to different learning difficulties and confidence thresholds of samples of different categories by calculating the confidence of samples of each category in the clean subset. The threshold of each category can be linearly adjusted based on the global threshold and the confidence of its own class; the potential correctable sample subset is screened out from the noise subset by the calculated category confidence, and the k nearest neighbor samples of the potential correctable sample are selected from the clean subset by the k nearest neighbor anchor criterion. The mixed sample is generated by the mixup method, sent to the network for prediction, and the sample whose prediction result is consistent with the original result and whose confidence reaches the threshold is selected and updated to the clean subset. This method dynamically expands the clean sample subset during the training process, and at the same time converts the credible samples in the noise subset from unsupervised learning and semi-supervised learning to supervised learning, so that the model can learn the samples more fully. Through the above method, the present invention can also effectively utilize the noise subset under high noise rate to improve the generalization ability and performance of the model.

[0109] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the purpose and scope of the technical solution, which should be included in the scope of the claims of the present invention.

Claims

1. A method for classifying noisy labeled images based on nearest neighbor anchor label correction, characterized in that: include: S1: Obtain an image dataset with noisy labels and build an image classification model; S2: training the image classification model, and classifying the test image by using the trained image classification model, wherein the training of the image classification model includes three training stages; S21: In the first training stage, preheating training is performed on the image classification model to enable the image model to acquire feature extraction and feature classification capabilities; S22: In the second training stage, based on the small loss criterion, the image dataset with noise labels is divided into a clean subset and a noise subset, and the image classification model is trained for the clean subset and the noise subset by combining supervised learning with semi-supervised learning; S23: In the third training stage, the confidence of each category of samples in the clean subset is calculated based on the nearest anchor point criterion; Select potentially correctable samples from the noise subset according to the confidence of each category of samples; S24: According to the k-nearest neighbor anchor criterion, k nearest neighbor samples of the potentially correctable sample are selected from the clean subset, and the mixup prediction consistency of the image classification model for the potentially correctable sample and its k nearest neighbor samples is calculated; and the potentially correctable samples with consistent predictions are transferred from the noise subset to the clean subset; S25: Update the noise subset and the clean subset, and train the image classification model for the clean subset and the noise subset using a combination of supervised learning and semi-supervised learning. Repeat steps S23-S25 until a preset number of iterations is reached to obtain a trained image classification model.

2. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 1, characterized in that: The image classification model includes: a feature extractor F(·), a feature projector H p (·) and classifier H c (·); the feature extractor F(·) is used to extract features from samples, and the classifier H c (·) is used to classify the features extracted by the feature extractor F(·), and the feature projector H p (·) is used to reduce the dimension of the features extracted by the feature extractor F(·) to obtain the low-dimensional features of the sample.

3. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 2, characterized in that: The preheating training of the image classification model includes: S211: Freeze classifier H c (·), the image dataset with noisy labels Discard the label to get an unlabeled dataset N represents the number of samples, x i represents the i-th sample, y i Represents sample x i The label of the unlabeled dataset D w_u The feature extractor F(·) and the feature projector H are trained by unsupervised contrastive learning. p (·) for training, the loss function is contrast loss, and the training is repeated T w1 Rounds; S212: Freeze the feature extractor F(·) and feature projector H p (·), based on a dataset of images with noisy labels For the classifier H c (·) Perform supervised training, use cross entropy loss as loss function, and repeat training T w2 Round.

4. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 2, characterized in that: The unsupervised contrastive learning method is used to train the feature extractor F(·) and the feature projector H p (·) Training includes: The sample x i Perform strong enhancement and weak enhancement respectively to obtain strong enhancement samples and weakly enhanced samples Strongly enhanced samples With the original sample x i Constitute negative sample pairs, weakly enhanced samples With the original sample Constitute a positive sample pair; the contrast loss function is used to shorten the feature distance of the positive sample pair output by the feature projector and to increase the feature distance of the negative sample pair output by the feature projector.

5. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 1, characterized in that: The step of dividing the image dataset with noise labels into a clean subset and a noise subset includes: S221: Input each sample of the image data set with noise labels into the preheated trained image classification model, and calculate the divergence between the predicted label output by the classifier and the actual label; S222: traverse each category of the image data set with noise labels, sort the samples under each category from small to large according to their divergence, and select the first r proportion of samples to add to the clean subset, and add the remaining samples to the noise subset. After traversing all categories, the divided clean subset and noise subset are obtained, and r represents the noise rate of the image data set with noise labels.

6. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 5, characterized in that: The calculation of the divergence between the predicted label output by the classifier and the actual label includes: Among them, d i represents the divergence of the i-th sample, JSD() represents the divergence function, and KLD(·) is the KL divergence function; Represents the predicted label of the i-th sample output by the classifier, y i represents the actual label of the i-th sample.

7. The method for classifying noisy labeled images based on neighbor anchor label correction according to claim 2, characterized in that: The method of training the image classification model by combining supervised learning and semi-supervised learning on the clean subset and the noise subset includes: Input the clean samples in the clean subset into the image classification model to obtain the predicted labels of the clean samples, and construct the cross entropy loss function based on the predicted labels and true labels of the clean samples; Among them, loss clean represents the cross entropy loss function, L ce (·) is the cross entropy loss function, F(·) is the feature extractor, H c (·) is the classifier; D clean represents the clean subset; Indicates D clean The jth clean sample in ; represents the jth clean sample The true label of represents the jth clean sample The predicted label of The samples in the clean subset are mixed with the samples in the noise subset to obtain a mixed sample set, and a semi-supervised loss function is constructed based on the original labels of the mixed samples and their prediction results; Among them, loss ssl represents the semi-supervised loss function, D mixup represents a mixed sample set, N mixup represents the number of mixed samples in the mixed sample set, L ce (·) is the cross entropy loss function; mixup(.) represents the mixup mixing function; and Represents the lth mixed sample and its corresponding label Denotes the noise subset D noise The kth noise sample in ; Representation sample The predicted label of The noise samples in the noise subset are strongly enhanced and weakly enhanced to obtain strongly enhanced noise samples and weakly enhanced noise samples; the strongly enhanced noise samples With the original sample x k Constitute negative sample pairs, weakly enhanced samples With the original sample Construct positive sample pairs, and construct a contrast loss function to shorten the feature distance of the positive sample pairs output by the feature projector and to increase the feature distance of the negative sample pairs output by the feature projector. The contrast loss function includes: Among them, Loss sim represents the contrast loss function, N noise Denotes the noise subset D noise The number of noise samples in; d∈(0,1) represents the temperature coefficient; sim(.) represents the cosine similarity function; For sample x 2b-1 ∈D noise Weakly enhanced samples; For sample x 2b ∈D noise Weakly enhanced samples; For sample x 2b-1 ∈D noise Strongly enhanced samples; For sample x 2b ∈D noise Strongly enhanced samples; The total loss function is constructed based on the cross entropy loss function, semi-supervised loss function and contrast loss function, and the image classification model is supervised and semi-supervised through the total loss function: loss=loss clean +λ ssl loss ssl +λ sim loss sim Among them, loss represents the total loss function, λ ssl and λ sim Represents an adjustable weight parameter.

8. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 2, characterized in that: The step S23 comprises: S231: Samples of the clean subset Input to the image classification model to obtain the prediction results of the sample: Among them, p j Representation sample The forecast results in each category; Representation sample The actual label, Representation sample The predicted label of D clean represents the clean subset; Indicates D clean The jth clean sample in ; S232: Calculate the global sample confidence of the clean subset: Among them, τ t represents the global sample confidence of the clean subset at the tth iteration, Q represents the total number of categories of samples in the clean subset, m represents the attenuation coefficient (0.95~0.99), N clean Represents the number of samples in the clean subset; max(.) represents the maximum value function; S233: Calculate the confidence of each category in the clean subset based on the global sample confidence of the clean subset: in, represents the confidence of category q in the clean subset at the tth iteration; S234: The noise subset D noise Noise samples in Input into the image classification model to obtain the predicted label and prediction confidence of the noise sample; in, Denotes the noise subset D aoise The predicted label of the kth noise sample in c k express ; and based on the predicted labels and predicted confidences of the noise samples in the noise subset and the confidences of each category in the clean subset, a set of potentially correctable samples is screened out from the noise subset: Among them, D noise represents the noise subset; Represents a noise sample The predicted label of D hc represents the set of potentially correctable samples, c k Represents the noise samples in the noise subset Confidence of predictions; Represents the category in the clean subset confidence level.

9. The method for classifying noisy labeled images based on nearest neighbor anchor label correction according to claim 8, characterized in that: The step S24 comprises: S241: Subset of potentially correctable samples Potentially correctable samples in Input the image classification model and get the feature projector H p (·) Output low-dimensional feature set N p represents the number of potentially correctable samples; S242: Subset clean samples Clean samples in Input the image classification model and get the feature projector H p (·) Output low-dimensional feature set S243: Low-dimensional features of potentially correctable samples Input the KNN module to calculate the k nearest neighbor sample set of potential corrected samples and clean samples S244: Mixup the potentially correctable samples with their corresponding k nearest neighbor samples to obtain a mixup fusion sample set in, express The vth nearest neighbor sample; express The vth mixup fusion sample; a represents the weight factor; S245: Input the mixup fusion samples of the potential correctable samples into the image classification model to obtain the prediction results of the mixup fusion samples; average the prediction results of k mixup fusion samples of the potential correctable samples in all categories to obtain the fusion prediction label of the potential correctable samples and fusion confidence S246: Based on the confidence of each category of samples in the clean subset, the fusion prediction label of the potentially correctable samples and fusion confidence Get the correctable sample set D corrent : in, Indicates the category at t iterations The confidence level is calculated in step S233; N correct represents the number of correctable samples; S247: The correctable sample set D corrent The samples in the set are transferred to the clean subset.

Citation Information

Patent Citations

  • Image super-resolution reconstruction method based on secondary anchor point neighborhood regression

    CN108416736A

  • Hyperspectral image semi-supervised classification method and device based on improved active deep learning

    CN113723492A

  • Robust field adaptive image learning method based on self-training noise label correction

    CN114283287A

  • Noise-containing label image identification method based on adaptive category equalization

    CN116912568A

  • Training method for semi-supervised learning model, image processing method, and device

    US20230196117A1

Cited By

  • Long-tail noise tag correction method, device and equipment and readable storage medium

    CN120495853A

  • Methods, apparatus, equipment and readable storage media for calibration of long-tailed noise tags

    CN120495853B

  • Data set detection method and device, electronic equipment, storage medium and program product

    CN121188610A