Search

US-20260127863-A1 - IMAGE-FOR-TRAINING SELECTING APPARATUS, IMAGE-FOR-TRAINING SELECTING METHOD, AND STORAGE MEDIUM FOR DECISION MAKING

US20260127863A1US 20260127863 A1US20260127863 A1US 20260127863A1US-20260127863-A1

Abstract

An image-for-training selecting apparatus for suitably selecting an image-for-training for training a machine learning model includes at least one processor executing: a first training process of training, by contrastive learning using an images-for-training set, a first machine learning model including a first layer group; a second training process of training a second machine learning model including the first layer group and a second layer group and employing the first machine learning model as a pre-trained model; a first calculating process of calculating a first similarity between a parameter of the first layer group after training by the first training process but before training by the second training process and a parameter of the first layer group after training by the second training process; and a first determining process of determining, based on the first similarity, whether the images-for-training set includes an inappropriate image-for-training.

Inventors

  • Yasuo Omi

Assignees

  • NEC CORPORATION

Dates

Publication Date
20260507
Application Date
20251218

Claims (20)

  1. 1 . An image-for-training selecting apparatus comprising at least one processor, the at least one processor executing: a first training process of training, by contrastive learning, a first machine learning model including a feature extraction part which receives input of an image and generates features of the image, the contrastive learning using a set of images-for-training, which is a plurality of images-for-training; a second training process of training, with use of the set of images-for-training, a second machine learning model (i) including the feature extraction part and a classification part which is connected to the feature extraction part and which receives input of the features of the image and classifies the image and (ii) employing the first machine learning model as a pre-trained model; a first calculating process of calculating a first similarity, which is a similarity between (i) a parameter of the feature extraction part after training by the first training process but before training by the second training process and (ii) a parameter of the feature extraction part after training by the second training process; and a first determining process of determining, on a basis of the first similarity, whether or not the set of images-for-training includes an inappropriate image-for-training.
  2. 2 . The image-for-training selecting apparatus according to claim 1 , wherein the at least one processor further executes: a selecting process of selecting, as the set of images-for-training, some of a plurality of available images-for-training, and wherein in a case where it is determined, in the first determining process, that the set of images-for-training includes an inappropriate image-for-training, a set of images-for-training which is different from the set of images-for-training having been selected is selected in the selecting process.
  3. 3 . The image-for-training selecting apparatus according to claim 1 , wherein in the first calculating process, the at least one processor calculates second similarities, which are similarities of respective layers constituting the feature extraction part.
  4. 4 . The image-for-training selecting apparatus according to claim 3 , wherein in the first calculating process, the at least one processor calculates, as the first similarity, a value given by dividing a sum of the second similarities by the number of the layers in the feature extraction part.
  5. 5 . The image-for-training selecting apparatus according to claim 3 , wherein in the first calculating process, the at least one processor calculates, as the first similarity, a value given by dividing a weighted sum, which is a sum of the second similarities having been given weights, by a sum of values of the weights.
  6. 6 . The image-for-training selecting apparatus according to claim 5 , wherein in the first calculating process, the at least one processor gives a heavier weight value to, among the second similarities of the layers, a second similarity of a layer closer to an output of the first machine learning model.
  7. 7 . The image-for-training selecting apparatus according to claim 2 , wherein the at least one processor further executes: a second calculating process of calculating an index indicating a degree of imbalance in attributes of the plurality of images-for-training included in the set of images-for-training selected in the selecting process; and a second determining process of determining whether or not the index calculated in the second calculating process is less than a threshold.
  8. 8 . The image-for-training selecting apparatus according to claim 7 , wherein in a case where it is determined, in the second determining process, that the index is not less than the threshold, the at least one processor selects, in the selecting process, a set of images-for-training which is different from the set of images-for-training having been selected.
  9. 9 . The image-for-training selecting apparatus according to claim 7 , wherein the attributes comprise at least one selected from the group consisting of a facility where an image was captured, a model of an image-capturing apparatus, and a type of a subject included in an image.
  10. 10 . The image-for-training selecting apparatus according to claim 2 , wherein the processes are repeatedly executed for a plurality of different sets of images-for-training, and wherein the at least one processor outputs a set of images-for-training corresponding to a highest first similarity among sets determined not to include an inappropriate image-for-training.
  11. 11 . An image-for-training selecting method comprising: training, by contrastive learning, a first machine learning model including a feature extraction part which receives input of an image and generates features of the image, the contrastive learning using a set of images-for-training, which is a plurality of images-for-training; training, with use of the set of images-for-training, a second machine learning model (i) including the feature extraction part and a classification part which is connected to the feature extraction part and which receives input of the features of the image and classifies the image and (ii) employing the first machine learning model as a pre-trained model; calculating a first similarity, which is a similarity between (i) a parameter of the feature extraction part after the training by contrastive learning but before the training of the second machine learning model and (ii) a parameter of the feature extraction part after the training of the second machine learning model; and determining, on a basis of the first similarity, whether or not the set of images-for-training includes an inappropriate image-for-training.
  12. 12 . The image-for-training selecting method according to claim 11 , further comprising: selecting, as the set of images-for-training, some of a plurality of available images-for-training; and in a case where it is determined that the set of images-for-training includes an inappropriate image-for-training, selecting a set of images-for-training which is different from the set of images-for-training having been selected.
  13. 13 . The image-for-training selecting method according to claim 11 , wherein the calculating step comprises calculating second similarities, which are similarities of respective layers constituting the feature extraction part.
  14. 14 . The image-for-training selecting method according to claim 13 , wherein the calculating step comprises calculating, as the first similarity, a value given by dividing a weighted sum, which is a sum of the second similarities having been given weights, by a sum of values of the weights.
  15. 15 . The image-for-training selecting method according to claim 14 , wherein the calculating step comprises giving a heavier weight value to a second similarity of a layer closer to an output of the first machine learning model.
  16. 16 . The image-for-training selecting method according to claim 12 , further comprising: calculating an index indicating a degree of imbalance in attributes of the plurality of images-for-training included in the selected set of images-for-training; and determining whether or not the index is less than a threshold.
  17. 17 . A non-transitory computer-readable storage medium storing a program that, when executed by a computer, causes the computer to perform a method, the method comprising: training, by contrastive learning, a first machine learning model including a feature extraction part which receives input of an image and generates features of the image, the contrastive learning using a set of images-for-training, which is a plurality of images-for-training; training, with use of the set of images-for-training, a second machine learning model (i) including the feature extraction part and a classification part which is connected to the feature extraction part and which receives input of the features of the image and classifies the image and (ii) employing the first machine learning model as a pre-trained model; calculating a first similarity, which is a similarity between (i) a parameter of the feature extraction part after the training by contrastive learning but before the training of the second machine learning model and (ii) a parameter of the feature extraction part after the training of the second machine learning model; and determining, on a basis of the first similarity, whether or not the set of images-for-training includes an inappropriate image-for-training.
  18. 18 . The non-transitory computer-readable storage medium according to claim 17 , the method further comprising: selecting, as the set of images-for-training, some of a plurality of available images-for-training; and in a case where it is determined that the set of images-for-training includes an inappropriate image-for-training, selecting a set of images-for-training which is different from the set of images-for-training having been selected.
  19. 19 . The non-transitory computer-readable storage medium according to claim 17 , wherein the calculating step comprises calculating, as the first similarity, a value given by dividing a weighted sum, which is a sum of second similarities of respective layers constituting the feature extraction part having been given weights, by a sum of values of the weights.
  20. 20 . The non-transitory computer-readable storage medium according to claim 18 , the method further comprising: calculating an index indicating a degree of imbalance in attributes of the plurality of images-for-training included in the selected set of images-for-training; and determining whether or not the index is less than a threshold.

Description

This application is a Continuation of U.S. application Ser. No. 18/554,752 filed on Oct. 10, 2023, which is a National Stage Entry of PCT/JP2023/001612 filed on Jan. 20, 2023, the contents of all of which are incorporated herein by reference, in their entirety. TECHNICAL FIELD The present invention relates to an image-for-training selecting apparatus, an image-for-training selecting method, and a storage medium for selecting an image-for-training for use in training of a machine learning model. BACKGROUND ART There has been disclosed a technique of selecting an image-for-training for use in training of a machine learning model. Patent Literature 1 discloses a training apparatus including a first training means that executes a first training process of training, by machine learning using training data, a first model that determines a category of given data. Further, the training apparatus disclosed in Patent Literature 1 selects upper-level training data as first training data and lower-level training data as second training data, from among pieces of training data sorted in ascending order of a difference between a determination result given by the first training means and a correct category set by a user. The training apparatus disclosed in Patent Literature 1 further includes a second training means that executes a second training process of learning, by machine learning using the first training data and the second training data, a second learning model that evaluates the training data. CITATION LIST Patent Literature [Patent Literature 1] International Publication No. WO 2019/187594 SUMMARY OF INVENTION Technical Problem However, if the correct category is incorrect, the training apparatus disclosed in Patent Literature 1 cannot appropriately select training data, disadvantageously. The correct category is set by the user, and, in some cases, the user may set a correct category which is incorrect. Further, in a case where setting of a correct category depends on the skill of a person who sets the correct category, e.g., in a case of using pathological cells, the correct category is not always set correctly. Further, in machine learning, it is preferable that training data be balanced and be comprehensive. However, in a case where imbalance is present in training data, the training apparatus disclosed in Patent Literature 1 cannot select inappropriate training data. An example aspect of the present invention was made in consideration of the above problem. An example object of the present invention is to provide a technique for suitably selecting an image-for-training for use in training of a machine learning model. Solution to Problem An image-for-training selecting apparatus in accordance with an example aspect of the present invention includes at least one processor, the at least one processor executing: a first training process of training, by contrastive learning, a first machine learning model including a first layer group which receives input of an image and generates features of the image, the contrastive learning using a set of images-for-training, which is a plurality of images-for-training; a second training process of training, with use of the set of images-for-training, a second machine learning model (i) including the first layer group and a second layer group which is connected to the first layer group and which receives input of the features of an image and classifies the image and (ii) employing the first machine learning model as a pre-trained model; a first calculating process of calculating a first similarity, which is a similarity between (i) a parameter of the first layer group after training by the first training process but before training by the second training process and (ii) a parameter of the first layer group after training by the second training process; and a first determining process of determining, on a basis of the first similarity, whether or not the set of images-for-training includes an inappropriate image-for-training. An image-for-training selecting method in accordance with an example aspect of the present invention includes at least one processor carrying out: training, by contrastive learning, a first machine learning model including a first layer group which receives input of an image and generates features of the image, the contrastive learning using a set of images-for-training, which is a plurality of images-for-training; training, with use of the set of images-for-training, a second machine learning model (i) including the first layer group and a second layer group which is connected to the first layer group and which receives input of the features of the image and classifies the image and (ii) employing the first machine learning model as a pre-trained model; calculating a first similarity, which is a similarity between (i) a parameter of the first layer group after training by the contrastive learning but before training of the second machine learning model