Method and device for predicting beauty based on migration and weak supervision, and storage medium
AssigneeWuyi University
InventorsJunying Gan, Zhenfeng Bai, Yikui Zhai, Guohui He
Life of this patent
Estimating the term…
Abstract
Disclosed are a method and device for predicting face beauty based on migration and weak supervision and a storage medium. The method includes: preprocessing an inputted face image; training a source domain network by using the preprocessed image, and migrating a parameter of the source domain network to a target domain network; inputting a noise image marked with a noise label and a truth-value image marked with a truth-value label into the target domain network to obtain an image feature; and inputting the image feature into a classification network to obtain a final face beauty prediction result.
Claims12
A method for predicting beauty based on migration and weak supervision, comprising:
- preprocessing an inputted face image to obtain a preprocessed image;
- training a source domain network by using the preprocessed image, and migrating a parameter of the trained source domain network to a target domain network, wherein in the migrating process, for the source domain network, a loss function of the source domain network is obtained according to an output of a softmax layer of the source domain network with a T value greater than 1 and an original label;
- for the target domain network, a first sub-loss function of the target domain network is obtained according to an output of a softmax layer of the target domain network with a T value greater than 1 and the original label, a second sub-loss function of the target domain network is obtained according to the output of the softmax layer of the target domain network with the T value equal to 1 and the original label, and the first sub-loss function and the second sub-loss function are added to obtain a loss function of the target domain network;
- classifying the preprocessed image into a noise image marked with a noise label and a truth-value image marked with a truth-value label, and inputting the noise image and the truth-value image into the target domain network to obtain an image feature;
- and
- inputting the image feature into a residual network to learn mapping from the image feature to a difference value between the noise label and the truth-value label to obtain a first predicted value, inputting the image feature into a standard neural network to learn mapping from the image feature to the truth-value label to obtain a second predicted value, adding the first predicted value and the second predicted value and then inputting the added value into a first classifier to obtain a first face beauty prediction result, inputting the second predicted value into a second classifier to obtain a second face beauty prediction result, and obtaining a final face beauty prediction result according to the first face beauty prediction result and the second face beauty prediction result.
A device for predicting beauty based on migration and weak supervision, comprising a processor and a memory connected with the processor, wherein the memory is configured to store an executable instruction which, when executed by the processor, causes the processor to execute steps of:
- preprocessing an inputted face image to obtain a preprocessed image;
- training a source domain network by using the preprocessed image, and migrating a parameter of the trained source domain network to a target domain network, wherein in the migrating process, for the source domain network, a loss function of the source domain network is obtained according to an output of a softmax layer of the source domain network with a T value greater than 1 and an original label;
- for the target domain network, a first sub-loss function of the target domain network is obtained according to an output of a softmax layer of the target domain network with a T value greater than 1 and the original label, a second sub-loss function of the target domain network is obtained according to the output of the softmax layer of the target domain network with the T value equal to 1 and the original label, and the first sub-loss function and the second sub-loss function are added to obtain a loss function of the target domain network;
- classifying the preprocessed image into a noise image marked with a noise label and a truth-value image marked with a truth-value label, and inputting the noise image and the truth-value image into the target domain network to obtain an image feature;
- and
- inputting the image feature into a residual network to learn mapping from the image feature to a difference value between the noise label and the truth-value label to obtain a first predicted value, inputting the image feature into a standard neural network to learn mapping from the image feature to the truth-value label to obtain a second predicted value, adding the first predicted value and the second predicted value and then inputting the added value into a first classifier to obtain a first face beauty prediction result, inputting the second predicted value into a second classifier to obtain a second face beauty prediction result, and obtaining a final face beauty prediction result according to the first face beauty prediction result and the second face beauty prediction result.
A non-transitory storage medium storing an executable instruction which, when executed by a computer, causes the computer to execute steps of:
- preprocessing an inputted face image to obtain a preprocessed image;
- training a source domain network by using the preprocessed image, and migrating a parameter of the trained source domain network to a target domain network, wherein in the migrating process, for the source domain network, a loss function of the source domain network is obtained according to an output of a softmax layer of the source domain network with a T value greater than 1 and an original label;
- for the target domain network, a first sub-loss function of the target domain network is obtained according to an output of a softmax layer of the target domain network with a T value greater than 1 and the original label, a second sub-loss function of the target domain network is obtained according to the output of the softmax layer of the target domain network with the T value equal to 1 and the original label, and the first sub-loss function and the second sub-loss function are added to obtain a loss function of the target domain network;
- classifying the preprocessed image into a noise image marked with a noise label and a truth-value image marked with a truth-value label, and inputting the noise image and the truth-value image into the target domain network to obtain an image feature;
- and
- inputting the image feature into a residual network to learn mapping from the image feature to a difference value between the noise label and the truth-value label to obtain a first predicted value, inputting the image feature into a standard neural network to learn mapping from the image feature to the truth-value label to obtain a second predicted value, adding the first predicted value and the second predicted value and then inputting the added value into a first classifier to obtain a first face beauty prediction result, inputting the second predicted value into a second classifier to obtain a second face beauty prediction result, and obtaining a final face beauty prediction result according to the first face beauty prediction result and the second face beauty prediction result.
Dependencies are inferred from the claim text.