WO2023124697A1 - 图像增强方法和装置、存储介质和电子设备 - Google Patents
图像增强方法和装置、存储介质和电子设备 Download PDFInfo
- Publication number
- WO2023124697A1 WO2023124697A1 PCT/CN2022/134845 CN2022134845W WO2023124697A1 WO 2023124697 A1 WO2023124697 A1 WO 2023124697A1 CN 2022134845 W CN2022134845 W CN 2022134845W WO 2023124697 A1 WO2023124697 A1 WO 2023124697A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- image
- information
- target
- sample
- appearance
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/60—Image enhancement or restoration using machine learning, e.g. neural networks
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/44—Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/77—Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
- G06V10/774—Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/82—Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20081—Training; Learning
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20084—Artificial neural networks [ANN]
Definitions
- the present disclosure relates to artificial intelligence technology, and in particular to an image enhancement method and device, storage medium and electronic equipment.
- Image enhancement has a wide range of applications in various scenarios. For example, in the scene of training a neural network, more and richer sample images can be obtained by performing image enhancement on the sample images. For another example, image enhancement can also be used to implement some face image enhancement applications such as makeup migration and face drive.
- the image enhancement methods in related technologies either use traditional image processing methods such as stretching and interpolation for image enhancement, but the enhanced image quality obtained in this way is not high, and usually only image enhancement can be performed under limited conditions. less.
- a neural network is used for image enhancement, the training of the neural network needs to obtain enough sample images. For example, a video of a certain length of time of a user with a single ID is often required to obtain multiple images of the user in the video. Face images, the cost of obtaining training samples in this way is relatively high, and it is also very inconvenient for users.
- Embodiments of the present disclosure at least provide an image enhancement method and device, a storage medium, and an electronic device.
- an image enhancement method comprising:
- the target image includes a first object;
- the appearance information represents surface visual features in the target image;
- the structural information represents an outline feature of the second object
- An enhanced image is generated based on the appearance information and the structure information, wherein the enhanced image includes a target object having the appearance information and the structure information.
- the method is performed by an image enhancement device, and an image enhancement network is deployed in the image enhancement device, and the image enhancement network includes: an appearance extractor and a generator; performing feature extraction on the target image to obtain
- the appearance information of the target image includes: performing feature extraction on the target image through the appearance extractor in the image enhancement network to obtain the appearance information of the target image; the generating based on the appearance information and structural information
- the image enhancement includes: generating an enhanced image based on the appearance information and the structure information by the generator in the image enhancement network.
- the acquiring the structural information of the second object includes: acquiring an initial image, the initial image including the second object; performing key point detection on the initial image to obtain the key points of the second object; and obtain the structural information of the second object according to the key points of the second object.
- the second object is included in the auxiliary image; the method further includes: acquiring an initial image including the target object; performing key point detection on the initial image to obtain the Key points of the target object in the initial image; cropping the initial image according to the key points of the target object to obtain the target image or auxiliary image including the target object.
- the method further includes: after generating the enhanced image based on the appearance information and the structural information, the enhanced image replaces a corresponding image portion in the initial image.
- the first object and the second object are the same target object, or different target objects of the same type, and the target object is one of the facial features in a human face.
- a training method of an image enhancement network comprising:
- a sample image including a first object and structural information of a second object, wherein the first object and the second object are the same target object with different structural information; the structural information represents the structure information of the second object contour features;
- the image enhancement network performing image generation processing on the appearance information and the structure information through the image enhancement network, and outputting a sample enhanced image, wherein the sample enhanced image includes the target object having the appearance information and the structure information;
- the second object is included in the auxiliary image
- the image enhancement network includes: an appearance extractor and a generator
- adjusting network parameters of the image enhancement network according to the sample enhancement image includes : adjusting the network parameters of the appearance extractor and the generator according to the difference between the sample enhanced image and the auxiliary image.
- an image enhancement device comprising:
- the appearance extraction module is used for feature extraction of the target image to obtain appearance information of the target image, wherein the target image includes a first object; the appearance information represents the surface visual features in the target image;
- a structure acquisition module configured to acquire structure information of a second object, the first object and the second object are target objects of the same type; the structure information represents the outline feature of the second object;
- An image generating module configured to generate an enhanced image based on the appearance information and the structure information, wherein the enhanced image includes a target object with the appearance information and the structure information.
- a training device for an image enhancement network comprising:
- An information acquisition module configured to acquire a sample image including a first object and structural information of a second object, wherein the first object and the second object are the same target object with different structural information; the structure information representing contour features of said second object;
- a feature extraction module configured to perform feature extraction on the sample image through an image enhancement network to obtain appearance information of the sample image, wherein the appearance information represents surface visual features in the sample image;
- An image output module configured to perform image generation processing on the appearance information and the structure information through the image enhancement network, and output a sample enhanced image, wherein the sample enhanced image includes the appearance information and the structure information the target audience of
- a parameter adjustment module configured to adjust the network parameters of the image enhancement network according to the sample enhanced image.
- an electronic device including: a memory and a processor, the memory is used to store computer-readable instructions, and the processor is used to call the computer instructions to implement the method in any embodiment of the present disclosure.
- a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the method in any embodiment of the present disclosure is implemented.
- the image enhancement method and device, storage medium and electronic equipment provided by the embodiments of the present disclosure can enhance the sample image according to various types of structural information through this method. Since the structural information can be varied and not limited, more Enhanced images for rich samples make the types of samples more abundant. When the generated sample enhanced images are applied to tasks such as model training, rich and diverse samples can improve the robustness and generalization of model training, and in this way A richer variety of samples is obtained. Compared with the previous sample acquisition method, the cost of sample acquisition is reduced, and the sample acquisition is easier.
- the method uses an image enhancement network to generate a sample enhanced image, which can make the generated image quality higher than conventional image processing methods such as interpolation and stretching.
- Fig. 1 shows a schematic flowchart of a method for training an image enhancement network provided by at least one embodiment of the present disclosure
- Fig. 2 shows a schematic framework diagram of image enhancement provided by at least one embodiment of the present disclosure
- Fig. 3A shows a schematic diagram of structure information of a first object provided by at least one embodiment of the present disclosure
- Fig. 3B shows a schematic diagram of the structure information of the second object provided by at least one embodiment of the present disclosure
- Fig. 4 shows a schematic diagram of structural information of another eye provided by at least one embodiment of the present disclosure
- Fig. 5 shows a schematic diagram of network training provided by at least one embodiment of the present disclosure
- Fig. 6 shows a schematic flowchart of an image enhancement method provided by at least one embodiment of the present disclosure
- Fig. 7 shows a schematic structural diagram of an image enhancement device provided by at least one embodiment of the present disclosure
- Fig. 8 shows a schematic structural diagram of an image enhancement network training device provided by at least one embodiment of the present disclosure.
- Embodiments of the present disclosure aim to provide an image enhancement method, which can generate an enhanced image through a trained neural network.
- the neural network may be called an image enhancement network
- the enhanced image may be an image obtained after enhancement processing is performed on the basis of an initial image.
- the enhancement process can be, for example, deforming the image.
- taking the enhancement of a human face image as an example it can include but not limited to changes in the angle of the face, the change in the expression of the face, the change in the orientation of the face, and the size of the facial features. changes etc.
- the initial image is a human face image in which the mouth of the human face is in a closed state
- the mouth in the human face image is transformed into a smiling mouth to obtain an enhanced image.
- the training process of the image enhancement network will be described first, and then how to generate an enhanced image through the trained image enhancement network will be described.
- Fig. 1 shows a schematic flowchart of a method for training an image enhancement network provided by at least one embodiment of the present disclosure. As shown in Fig. 1, the method may include the following processing:
- step 100 a sample image and structural information of a second object are acquired.
- the training method of this embodiment can be performed by the training device of the image enhancement network.
- the training device can be deployed on an electronic device (such as a server), and the training device can include images to be trained.
- Enhanced network such as a server
- the training device of the image enhancement network can obtain the sample image to be enhanced, and in this embodiment, the image to be enhanced in the training stage can be called a sample image.
- the sample image includes the first object.
- the sample image may be an image including eyes, and the first object may be the eyes in the sample image.
- the sample image may be an image including trees, and the first object may be the trees in the sample image.
- the training device may also obtain structural information of a second object, which is the same target object with different structural information from the first object.
- the structure information can be understood as representing the contour features of the second object, for example, the size and structure of the object.
- An example is as follows: Taking the facial features of a human face as an example, the acquired structural information of the facial features can be information such as the contour features of the mouth, the contour features of the nose, etc.; it can also be feature information such as the height of the nose.
- the record form of the contour feature includes but is not limited to: expressed as a contour line, or recorded as a plurality of key points distributed on the contour line, and the position coordinates or key point identifiers of these key points can be recorded.
- the target object is an eye
- the structural information may be an outline feature of the eye.
- the structural information of the first object illustrated in Figure 3A and the structural information of the second object illustrated in Figure 3B can be seen as eyes with two different structural information, but these two objects can be the eyes of the same person, just one One is in the state of squinting, and the other is in the state of widening, so the structural information of the two eyes is different.
- the first object and the second object with different structural information can also be the following examples: for another example, if the target object is a mouth, then the first object can be a closed mouth, and the second object can be An open mouth, even if the two mouths are the mouths of the same person, the structural information of the two mouths is different due to their different states. For example, due to the above-mentioned different states of the mouth, the position of each contour key point recorded in the contour feature of the closed mouth is different from the position of each contour key point recorded in the contour feature of the open mouth.
- step 102 feature extraction is performed on the sample image through an image enhancement network to obtain appearance information of the sample image.
- the appearance information may be acquired through feature extraction by an appearance extractor in the image enhancement network.
- an appearance extractor in the image enhancement network.
- the image enhancement network may include an appearance extractor, and the appearance extractor 21 may perform feature extraction on the sample image to obtain appearance information of the sample image.
- the appearance extractor may include various modules such as a convolution layer, a residual module, an activation layer, and a pooling layer.
- the appearance information represents surface visual features in the target image.
- the surface visual features include but not limited to texture, color, lighting information, etc. in the target image.
- the appearance information obtained can include: the brightness of the face area, the texture of the face, the color of the face, etc.
- the appearance information of the sample image output by the appearance extractor 21 may be expressed as a one-dimensional tensor, which may be a 64*1 tensor.
- the appearance extractor 21 may extract all or part of the appearance information, which may be determined according to actual business requirements. For example, taking an eye picture as an example, in addition to the eyes, the eye picture also includes a part of the face area around the eyes and the eyebrow area. Then, the appearance information of the brightness, color, and texture of all these areas can be extracted by the appearance extractor 21, or only the appearance information of the eyebrow area can be extracted, or only the appearance information of the face area around the eyes can be extracted. The extraction of the appearance information of at least a part of the region in the sample image can be realized by designing and training the appearance extractor 21 .
- the function of the appearance extractor 21 can also be designed to realize the extraction of at least part of the appearance information, for example, only the texture and texture in the sample image are extracted. color without extracting brightness.
- the structure information of the second object obtained in step 100 may also be determined to obtain at least part of the structure information of the second object according to actual business requirements. For example, taking the second object as the eye as an example, if you want to obtain all the structural information of the eye, it can include the key points of the outer contour of the eye, the key points of the contour of the eyeball, and the center point of the eyeball; and if you want to obtain the part of the eye Structural information may only include the outline points of the eye, excluding key points of the outline of the eyeball and the center point of the eyeball.
- the structural information obtained in step 100 and the appearance information obtained in step 102 in this embodiment are at least part of the extracted information, and these information will participate in the image generation process.
- step 104 an image generation process is performed on the appearance information and structure information through an image enhancement network, and a sample enhanced image is output; wherein, the sample enhanced image includes the appearance information and the target object with the structure information.
- the image enhancement network can generate a sample enhanced image according to the appearance information and structure information obtained above.
- image generation processing may be performed by the generator 22 to output a sample enhanced image.
- the sample enhanced image can have both appearance information and structure information.
- the structure information may be possessed by a target object in the sample enhanced image, and the target object may be the aforementioned first object or second object.
- the sample image is an image containing eyes
- the structure information is a structure map of the eyes in another state.
- the output sample enhanced image may replace the structural information of the first object in the sample image with the structural information of the second object, and the structural information of the second object in the sample image
- Other information may not change, for example, the face texture around the eyes, face color, eyebrows, eyeball position inside the eyes, eye color, etc. in the sample image may not change, which is the same as in the sample image.
- step 106 network parameters of the image enhancement network are adjusted according to the sample enhanced image.
- the image serving as the label of the sample enhanced image may be an auxiliary image where the second object is located.
- the auxiliary image may have the same image size as the sample image, and the auxiliary image and the sample image may include the same area.
- the sample image in Figure 2 includes an eye and an eyebrow
- the auxiliary image corresponding to the sample image can also include an eye and an eyebrow, that is, it includes the same area as the sample image, and the size of the sample image and the auxiliary image Can be the same.
- the difference lies in that the structural information of eyes in the sample image and the auxiliary image are different, for example, the eyes in the sample image are wide open, while the eyes in the auxiliary image are squinted.
- network parameters of the image enhancement network can be adjusted according to the sample enhanced image. For example, according to the difference between the sample enhanced image and the auxiliary image, the L1 norm loss function (L1loss) between the sample enhanced image and the auxiliary image can be solved, and the network parameters of the appearance extractor and generator can be adjusted according to the L1 loss.
- L1 norm loss function L1loss
- the sample image can be enhanced according to various types of structural information. Since the structural information can be varied and not limited, a richer sample enhanced image can be obtained, so that the sample image The types are more abundant.
- the generated sample enhanced images are applied to tasks such as model training, rich and diverse samples can improve the robustness and generalization of model training, and in this way, more abundant sample types can be obtained. Compared with Compared with the previous sample acquisition method, the cost of sample acquisition is reduced, and sample acquisition is more convenient.
- the method uses an image enhancement network to generate a sample enhanced image, compared with conventional image processing methods such as interpolation and stretching, so that the quality of the generated image is higher.
- the first object included in the sample image may be determined according to actual application requirements.
- the sample enhanced image obtained according to the embodiment of the present disclosure if the actual application needs to include the image of the eye, the first object in the sample enhanced image is the eye.
- the first object in the sample enhanced image is the mouth.
- other organs in the facial features can also be enhanced, such as eyebrows, nose, etc.
- the sample image containing the organ to be enhanced and the corresponding structural information of the organ can be used to generate the sample enhanced image.
- the sample enhanced image shown in Figure 2 is an image including eyes, but in actual implementation, sometimes the initially obtained image can be an image with a relatively large range including the entire face, then you can perform the image enhancement process shown in Figure 2 , to preprocess the initial image.
- FIG. 4 schematically shows the face image obtained after cropping the initial image, and some key points of the face in the face image, for example, key point 41 , key point 42 and so on.
- the image in Figure 4 is further cropped to obtain an image including the mouth.
- the mouth in the mouth image is the mouth in the face image.
- the mouth image can be used as a sample image in the training phase of the image enhancement network, or can also be used as an auxiliary image.
- the structure information of the corresponding mouth can also be obtained.
- the structure information may be a structure map (heatmap) corresponding to the mouth. Keypoints for the mouth may be included in the structure map.
- the structure graph can be input into the image enhancement network to assist the sample image to generate a corresponding sample enhanced image.
- the following data can be prepared:
- a small number of face images with the same ID for example, 15 face images of the same person Zhang.
- the same ID refers to the same person, for example, multiple face images of Xiao Wang belong to the same ID, and the ID is Xiao Wang's identification.
- each ID has a certain number of face images with different expressions and different angles.
- the 15,000 other IDs may be face images of Xiao Wang, Xiao Dong and other people.
- the prepared training data may include face images of multiple IDs, and each ID may include face images of multiple expressions and different angles, and different expressions and angles may correspond to different structural information.
- the sample image and the auxiliary image can be two face images belonging to the same ID randomly selected from the above training data.
- two face images of Xiao Zhang can be extracted. Both images are of Xiao Zhang’s face.
- Xiao Zhang has squinted eyes
- Xiao Zhang has his eyes wide open.
- the structural information of the eyes in the images is different, but the appearance information other than the structural information is the same.
- the auxiliary image is used as the label of this enhancement, and the network parameters of the image enhancement network are subsequently adjusted according to the difference between the auxiliary image and the sample enhanced image output by the image enhancement network.
- each face image in the above training data may be preprocessed as shown in FIG. 4 .
- identify the key points of the face in each face image and then crop the face image and an image including one of the five organs of the face according to the key points of the face.
- each image in the above training data may be cropped to obtain an eye image including eyes.
- the two eye images belonging to the same person are used as the auxiliary image and the sample image respectively, and the enhanced eye image is obtained through the output of the image enhancement network shown in Figure 2, that is, in the enhanced eye image, the structural information of the eye in the sample image is replaced by is the structural information of the eye in the auxiliary image.
- Fig. 5 shows another schematic diagram of network training provided by at least one embodiment of the present disclosure.
- the image enhancement network in addition to adjusting the network parameters according to the difference between the sample enhancement image and the auxiliary image mentioned above, it is also The training method shown in Figure 5 can be used.
- the sample enhanced image and the corresponding label may be input into the discriminator 23 to obtain a discriminant value output by the discriminator 23 .
- the discriminant value may be a numerical value between 0 and 1, which is used to represent the probability of authenticity of the sample enhanced image.
- the first loss is obtained according to the difference between the discriminant value and the discriminant true value; and the second loss is obtained according to the difference between the sample enhanced image and the auxiliary image. Further adjusting network parameters of at least one of the appearance extractor, generator and discriminator according to the first loss and the second loss.
- the aforementioned generator and discriminator may adopt a conventional Generative adversarial nets (GAN) network structure, which is not limited in this embodiment.
- the network structure may include convolutional layers, residual modules, pooling layers, linear layers, activation layers, etc.
- This way of generating a sample enhanced image by training an image enhancement network through a generative confrontation network can make the discriminant value output by the discriminator as close to the real value as possible through training, thereby improving the fidelity of the enhanced image generation and helping to generate more accurate images. High quality enhanced images.
- FIG. 6 shows a schematic flowchart of an image enhancement method provided by at least one embodiment of the present disclosure. As shown in Fig. 6, the method may be executed by an image enhancement device, and the method may include the following processing:
- step 600 feature extraction is performed on the target image to obtain appearance information of the target image, and the target image includes a first object.
- the target image may be an image including eyes, for example, the sample image shown in FIG. 2 includes an image of human eyes.
- the eyes in the target image may be referred to as the first object, and the purpose of this embodiment may be to enhance the target image, and perform enhancement and deformation on the eyes in the target image.
- the appearance information of the target image can be obtained by extracting the features of the target image through the appearance extractor in the trained image enhancement network.
- the initial image can be preprocessed to obtain a target image including eyes.
- the key point detection network can be used to detect the key points of the face in the initial image to obtain the key points of the face in the initial image.
- the initial image can be cropped according to these face key points to obtain the above-mentioned target image including eyes.
- step 602 the structure information of the second object is obtained according to the key points of the second object in the auxiliary image, and both the first object and the second object are target objects of the same type.
- the second object in the auxiliary image is the same type of object as the first object, for example, both objects are eyes, or both objects are mouths.
- the object of the same type may be referred to as a target object.
- the eyes in the auxiliary image and the target image are different.
- the eyes in the target image are referred to as the first object, and the eyes in the auxiliary image are referred to as the second object.
- the first object and the second object in this embodiment may be the same target object, for example, both are Xiao Wang's eyes, and the eyes of the two objects are in different states (eg, one is wide open, and the other is squinting).
- the first object and the second object may also belong to different target objects, for example, the first object is Xiao Wang's eyes, and the second object is Xiao Zhang's eyes.
- the structure information of the second object can be obtained according to the key points of the second object in the auxiliary image.
- the image enhancement network can include a network module for extracting key points, then after the auxiliary image is input into the image enhancement network, the key points in the auxiliary image can be extracted through the network module, and then the structure of the second object can be obtained according to the key points information.
- the image enhancement network may not include a network module for extracting key points, but the structure information of the second object may be obtained through other processing modules other than the image enhancement network, and the structure information may be input into the image enhancement network.
- step 604 an enhanced image is generated based on the appearance information and structural information, and the enhanced image replaces the structural information of the first object in the target image with the structural information of the second object.
- the generator in the image enhancement network can perform image generation processing according to the acquired appearance information and structure information, and finally generate an enhanced image.
- the enhanced image includes the appearance information of the target image and the structure information of the second object in the auxiliary image, then the enhanced image is compared with the target image by replacing the structure information of the first object in the target image with the structure information of the second object structural information.
- the enhanced image including eyes output by the image enhancement device of this embodiment through the image enhancement network can be used for subsequent network training, the enhanced image may not undergo subsequent processing.
- the final output is an image of the entire face.
- the initial image may be a face image of Xiao Wang, and it is desired to obtain an enhanced image that changes the structural information of Xiao Wang's eyes.
- the structural information of Xiao Zhang’s eyes can be obtained, combined with the structural information of Xiao Zhang’s eyes and Xiao Wang’s eye image cropped from Xiao Wang’s face image, the image generation process is performed through the image enhancement network, and the obtained enhanced In the image, the structural information of Xiao Wang's eyes is replaced with the structural information of Xiao Zhang's eyes.
- the enhanced image output by the image enhancement network is an image including Xiao Wang's eyes, and the enhanced image can also be pasted back to the original Xiao Wang's face image, that is, the enhanced image will be replaced with the corresponding part of Xiao Wang's face image , the updated face image of Xiao Wang can be obtained, which can also be called the enhanced face image of Xiao Wang.
- the eye image (including the image of the eye) is obtained by cutting out the key points of the face from the initial face image and the mouth image (including the mouth image), and then, the eye image and the mouth image are respectively enhanced through the image enhancement network to obtain the corresponding enhanced images, for example, the eye enhanced image and the mouth enhanced image. Finally, paste the eye-enhanced image and the mouth-enhanced image back into the original image respectively, and replace the corresponding parts in the above-mentioned initial human face image.
- the process of generating an enhanced image in the above-mentioned Figure 6 can be applied to the training scene of the network. For example, if a neural network is to be trained, but the training samples are not enough, the enhanced image is generated through the above-mentioned Figure 6 in the embodiment of the present disclosure to obtain a more accurate image. Rich sample images.
- the image enhancement network provided by the above embodiments of the present disclosure can combine arbitrary structural information to generate an enhanced image. Taking face enhancement as an example, when an enhanced image is generated by this method, a richer enhanced face image can be generated, which can include multiple Enhanced face images from various angles and expressions.
- This rich and diverse enhanced image when applied to the training neural network model, helps to improve the generalization and robustness of the trained neural network model, and the method generates enhanced images through the trained image enhancement network , and also used the method of generative confrontation in the training process, so that the quality of the generated enhanced image is higher, more realistic and clear.
- these small amounts of data can be enriched through the image enhancement network of the embodiment of the present disclosure, so that when obtaining data, it is reduced. Difficulty in obtaining data.
- process of generating an enhanced image in FIG. 6 can also be applied to other scenarios, for example, it can be applied to face image enhancement applications such as makeup migration and face driving.
- one person Xiao Zhang’s eye makeup can be transferred to another person Xiao Wang’s eyes, then the appearance information related to Xiao Zhang’s eye makeup can be extracted through the appearance extractor in the image enhancement network , and then combine the structural information of Xiao Wang's eyes to generate an enhanced image.
- the structure of Xiao Wang's eyes has not changed, but it already has Xiao Zhang's eye makeup.
- Xiao Zhang's facial expressions are used to drive Xiao Wang's face to do the same facial expressions, and it is assumed that the specific movements are mouth movements. That can combine the appearance information of Xiao Wang's face picture and the structure information of Xiao Zhang's mouth to generate an enhanced image, so that the enhanced image is still Xiao Wang's face, but the movements and expressions of the mouth are replaced by Xiao Zhang's. expression.
- an embodiment of the present disclosure further provides an image enhancement device.
- the image enhancement device may include: an appearance extraction module 71 , a structure acquisition module 72 and an image generation module 73 .
- the appearance extraction module 71 is configured to perform feature extraction on the target image to obtain appearance information of the target image, wherein the target image includes a first object; and the appearance information represents surface visual features in the target image.
- the structure acquisition module 72 is configured to acquire the structure information of the second object, the first object and the second object are target objects of the same type; the structure information represents the outline feature of the second object.
- An image generating module 73 configured to generate an enhanced image based on the appearance information and the structure information, where the enhanced image includes a target object with the appearance information and the structure information.
- the appearance extraction module 71 when used to perform feature extraction on the target image to obtain the appearance information of the target image, it includes: performing feature extraction on the target image through an appearance extractor in the image enhancement network Extract to obtain the appearance information of the target image.
- the image generation module 73 when used to generate an enhanced image based on the appearance information and the structure information, includes: generating an enhanced image based on the appearance information and the structure information by the generator in the image enhancement network Enhance images.
- the structure acquisition module 72 when used to acquire the structure information of the second object, it includes: acquiring an initial image, which includes the second object; Detecting to obtain key points of the second object in the initial image; obtaining the structural information of the second object according to the key points of the second object.
- the device further includes: a preprocessing module.
- the preprocessing module is configured to acquire an initial image, which includes the target object; perform key point detection on the initial image to obtain key points of the target object in the initial image; according to the The key points of the target object are used to crop the initial image to obtain the target image or an auxiliary image including the target object; wherein the second object is included in the auxiliary image.
- an embodiment of the present disclosure further provides an image enhancement network training device.
- the training device of the image enhancement network may include: an information acquisition module 81 , a feature extraction module 82 , an image output module 83 and a parameter adjustment module 84 .
- An information acquisition module 81 configured to acquire a sample image including a first object and structural information of a second object, wherein the first object and the second object are the same target object with different structural information; the structural information represents the outline feature of the second object.
- the feature extraction module 82 is configured to perform feature extraction on the sample image through an image enhancement network to obtain appearance information of the sample image, and the appearance information represents surface visual features in the sample image.
- An image output module 83 configured to perform image generation processing on the appearance information and the structure information through the image enhancement network, and output a sample enhanced image, wherein the sample enhanced image includes the appearance information and the structure information.
- the target audience for the message is configured to perform image generation processing on the appearance information and the structure information through the image enhancement network, and output a sample enhanced image, wherein the sample enhanced image includes the appearance information and the structure information.
- the parameter adjustment module 84 is configured to adjust network parameters of the image enhancement network according to the sample enhanced image.
- the parameter adjustment module 84 when used to adjust the network parameters of the image enhancement network according to the sample enhanced image, it includes: according to the difference between the sample enhanced image and the auxiliary image, adjusting Network parameters of the appearance extractor and generator; wherein the second object is included in the auxiliary image, and the appearance extractor and generator are included in the image enhancement network.
- the parameter adjustment module 84 when used to adjust the network parameters of the image enhancement network according to the sample enhanced image, it includes: inputting the sample enhanced image into the discriminator to obtain the The discriminant value output by the discriminator; the first loss is obtained according to the difference between the discriminant value and the discriminant true value, and the second loss is obtained according to the difference between the sample enhanced image and the auxiliary image; according to the first loss and the second loss, adjusting network parameters of at least one of the appearance extractor, the generator, and the discriminator; wherein the second object is included in the auxiliary image.
- one or more embodiments of the present disclosure may be provided as a method, system or computer program product. Accordingly, one or more embodiments of the present disclosure may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of the present disclosure may employ a computer program embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein. The form of the product.
- computer-usable storage media including but not limited to disk storage, CD-ROM, optical storage, etc.
- An embodiment of the present disclosure also provides a computer-readable storage medium, on which a computer program can be stored, and when the program is executed by a processor, the image enhancement method described in any embodiment of the present disclosure or the training of the image enhancement network can be implemented. method.
- An embodiment of the present disclosure also provides an electronic device, the electronic device includes: a memory and a processor, the memory is used to store computer-readable instructions, and the processor is used to call the computer instructions to implement any embodiment of the present disclosure
- the image enhancement method or the training method of the image enhancement network includes: a memory and a processor, the memory is used to store computer-readable instructions, and the processor is used to call the computer instructions to implement any embodiment of the present disclosure
- Embodiments of the subject matter and functional operations described in this disclosure can be implemented in digital electronic circuitry, tangibly embodied computer software or firmware, computer hardware including the structures disclosed in this disclosure and their structural equivalents, or in A combination of one or more of .
- Embodiments of the subject matter described in this disclosure can be implemented as one or more computer programs, i.e. one or more of computer program instructions encoded on a tangible, non-transitory program carrier for execution by or to control the operation of data processing apparatus. Multiple modules.
- the program instructions may be encoded on an artificially generated propagated signal, such as a machine-generated electrical, optical or electromagnetic signal, which is generated to encode and transmit information to a suitable receiver device for transmission by the data
- the processing means executes.
- a computer storage medium may be a machine-readable storage device, a machine-readable storage substrate, a random or serial access memory device, or a combination of one or more of them.
- the processes and logic flows described in this disclosure can be performed by one or more programmable computers executing one or more computer programs to perform corresponding functions by operating on input data and generating output.
- the processes and logic flows can also be performed by, and apparatus can also be implemented as, special purpose logic circuitry, such as FPG (Field Programmable Gate Array) or SIC (Application Specific Integrated Circuit).
- FPG Field Programmable Gate Array
- SIC Application Specific Integrated Circuit
- Computers suitable for the execution of a computer program include, for example, general and/or special purpose microprocessors, or any other type of central processing unit.
- a central processing unit will receive instructions and data from a read only memory and/or a random access memory.
- the essential components of a computer include a central processing unit for implementing or executing instructions and one or more memory devices for storing instructions and data.
- a computer will also include, or be operatively coupled to, one or more mass storage devices for storing data, such as magnetic or magneto-optical disks, or optical disks, to receive data therefrom or to It transmits data, or both.
- mass storage devices for storing data, such as magnetic or magneto-optical disks, or optical disks
- a computer may be embedded in another device such as a mobile phone, a personal digital assistant (PD or more), a mobile audio or video player, a game console, a Global Positioning System (GPS) receiver, or a device such as a Universal Serial Bus ( USB) flash drives, to name a few.
- a mobile phone such as a personal digital assistant (PD or more), a mobile audio or video player, a game console, a Global Positioning System (GPS) receiver, or a device such as a Universal Serial Bus ( USB) flash drives, to name a few.
- PD personal digital assistant
- GPS Global Positioning System
- USB Universal Serial Bus
- Computer-readable media suitable for storing computer program instructions and data include all forms of non-volatile memory, media, and memory devices, including, for example, semiconductor memory devices (such as EPROM, EEPROM, and flash memory devices), magnetic disks (such as internal hard disks or removable disks), magneto-optical disks, and CD ROM and DVD-ROM disks.
- semiconductor memory devices such as EPROM, EEPROM, and flash memory devices
- magnetic disks such as internal hard disks or removable disks
- magneto-optical disks and CD ROM and DVD-ROM disks.
- the processor and memory can be supplemented by, or incorporated in, special purpose logic circuitry.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Evolutionary Computation (AREA)
- Software Systems (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- Artificial Intelligence (AREA)
- General Health & Medical Sciences (AREA)
- Multimedia (AREA)
- Biomedical Technology (AREA)
- Molecular Biology (AREA)
- Life Sciences & Earth Sciences (AREA)
- Databases & Information Systems (AREA)
- Biophysics (AREA)
- Computational Linguistics (AREA)
- Data Mining & Analysis (AREA)
- Medical Informatics (AREA)
- General Engineering & Computer Science (AREA)
- Mathematical Physics (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
- Measurement Of The Respiration, Hearing Ability, Form, And Blood Characteristics Of Living Organisms (AREA)
- Facsimile Image Signal Circuits (AREA)
Abstract
Description
Claims (13)
- 一种图像增强方法,包括:对目标图像进行特征提取,得到所述目标图像的外观信息,其中,所述目标图像中包括第一对象;所述外观信息表示所述目标图像中的表面视觉特征;获取第二对象的结构信息,其中,所述第一对象和所述第二对象为同种类的目标对象;所述结构信息表示所述第二对象的轮廓特征;基于所述外观信息和所述结构信息生成增强图像,其中,所述增强图像包括具有所述外观信息以及所述结构信息的目标对象。
- 根据权利要求1所述的方法,其特征在于,所述方法由图像增强装置执行,所述图像增强装置中部署有图像增强网络,所述图像增强网络包括:外观提取器和生成器;所述对目标图像进行特征提取,得到所述目标图像的外观信息,包括:通过所述图像增强网络中的外观提取器对所述目标图像进行特征提取,得到所述目标图像的外观信息;所述基于所述外观信息和所述结构信息生成增强图像,包括:通过所述图像增强网络中的所述生成器基于所述外观信息和所述结构信息生成增强图像。
- 根据权利要求1所述的方法,其特征在于,所述获取第二对象的结构信息,包括:获取初始图像,所述初始图像中包括所述第二对象;对所述初始图像进行关键点检测,得到所述初始图像中所述第二对象的关键点;根据所述第二对象的所述关键点,得到所述第二对象的所述结构信息。
- 根据权利要求1所述的方法,其特征在于,所述第二对象包括在辅助图像中;所述方法还包括:获取初始图像,所述初始图像中包括所述目标对象;对所述初始图像进行关键点检测,得到所述初始图像中所述目标对象的关键点;根据所述目标对象的所述关键点对所述初始图像进行裁剪,得到包括所述目标对象的所述目标图像或者所述辅助图像。
- 根据权利要求4所述的方法,其特征在于,所述方法还包括:在所述基于所述外观信息和所述结构信息生成增强图像之后,所述增强图像替换所述初始图像中的对应图像部分。
- 根据权利要求1所述的方法,其特征在于,所述第一对象和所述第二对象是同一个目标对象,或者是同种类的不同目标对象,所述目标对象是人脸中的五官之一。
- 一种图像增强网络的训练方法,包括:获取包含第一对象的样本图像以及第二对象的结构信息,其中,所述第一对象和所述第二对象是具有不同结构信息的同一目标对象;所述结构信息表示所述第二对象的轮廓特征;通过图像增强网络对所述样本图像进行特征提取,得到所述样本图像的外观信息,其中,所述外观信息表示所述样本图像中的表面视觉特征;通过所述图像增强网络对所述外观信息和所述结构信息进行图像生成处理,输出样本增强图像,其中,所述样本增强图像包括具有所述外观信息以及所述结构信息的所述目标对象;根据所述样本增强图像,调整所述图像增强网络的网络参数。
- 根据权利要求7所述的训练方法,其特征在于,所述第二对象包括在辅助图像中,所述图像增强网络包括:外观提取器和生成器;所述根据所述样本增强图像,调整所述图像增强网络的网络参数,包括:根据所述样本增强图像和所述辅助图像之间的差异,调整所述外观提取器和所述生成器的网络参数。
- 根据权利要求7所述的训练方法,其特征在于,所述第二对象包括在辅助图像中;所述图像增强网络包括:外观提取器和生成器;所述根据所述样本增强图像,调整所述图像增强网络的网络参数,包括:将所述样本增强图像输入判别器,得到所述判别器输出的判别值;根据所述判别值与判别真值之间的差异得到第一损失,并根据所述样本增强图像和所述辅助图像之间的差异得到第二损失;根据所述第一损失和所述第二损失,调整所述外观提取器、所述生成器和所述判别器中至少一个的网络参数。
- 一种图像增强装置,包括:外观提取模块,用于对目标图像进行特征提取,得到所述目标图像的外观信息,其中,所述目标图像中包括第一对象;所述外观信息表示所述目标图像中的表面视觉特征;结构获取模块,用于获取第二对象的结构信息,所述第一对象和所述第二对象为同种类的目标对象;所述结构信息表示所述第二对象的轮廓特征;图像生成模块,用于基于所述外观信息和所述结构信息生成增强图像,其中,所述增强图像包括具有所述外观信息以及所述结构信息的目标对象。
- 一种图像增强网络的训练装置,包括:信息获取模块,用于获取包含第一对象的样本图像以及第二对象的结构信息,其中,所述第一对象和所述第二对象是具有不同结构信息的同一目标对象;所述结构信息表示所述第二对象的轮廓特征;特征提取模块,用于通过图像增强网络对所述样本图像进行特征提取,得到所述样本图像的外观信息,其中,所述外观信息表示所述样本图像中的表面视觉特征;图像输出模块,用于通过所述图像增强网络对所述外观信息和所述结构信息进行图像生成处理,输出样本增强图像,其中,所述样本增强图像包括具有所述外观信息以及所述结构信息的所述目标对象;参数调整模块,用于根据所述样本增强图像,调整所述图像增强网络的网络参数。
- 一种电子设备,包括:存储器、处理器,所述存储器用于存储计算机可读指令,所述处理器用于调用所述计算机指令,实现权利要求1至6任一所述的方法,或者权利要求7至9任一所述的方法。
- 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现权利要求1至6任一所述的方法,或者权利要求7至9任一所述的方法。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202111669721.8A CN114331906A (zh) | 2021-12-31 | 2021-12-31 | 图像增强方法和装置、存储介质和电子设备 |
| CN202111669721.8 | 2021-12-31 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2023124697A1 true WO2023124697A1 (zh) | 2023-07-06 |
Family
ID=81019990
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2022/134845 Ceased WO2023124697A1 (zh) | 2021-12-31 | 2022-11-29 | 图像增强方法和装置、存储介质和电子设备 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN114331906A (zh) |
| WO (1) | WO2023124697A1 (zh) |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119624792A (zh) * | 2024-10-31 | 2025-03-14 | 广州像素数据技术股份有限公司 | 一种证件照智能换装处理方法及装置 |
| CN120126202A (zh) * | 2025-05-09 | 2025-06-10 | 杭州海康威视数字技术股份有限公司 | 一种用于人脸增强方法、装置及设备 |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114331906A (zh) * | 2021-12-31 | 2022-04-12 | 北京大甜绵白糖科技有限公司 | 图像增强方法和装置、存储介质和电子设备 |
| CN114972099B (zh) * | 2022-05-31 | 2025-11-25 | 商汤集团有限公司 | 图像增强方法、装置、电子设备、存储介质和程序产品 |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111881926A (zh) * | 2020-08-24 | 2020-11-03 | Oppo广东移动通信有限公司 | 图像生成、图像生成模型的训练方法、装置、设备及介质 |
| CN113327212A (zh) * | 2021-08-03 | 2021-08-31 | 北京奇艺世纪科技有限公司 | 人脸驱动、模型的训练方法、装置、电子设备及存储介质 |
| CN113838076A (zh) * | 2020-06-24 | 2021-12-24 | 深圳市中兴微电子技术有限公司 | 目标图像中的对象轮廓的标注方法及装置、存储介质 |
| CN114331906A (zh) * | 2021-12-31 | 2022-04-12 | 北京大甜绵白糖科技有限公司 | 图像增强方法和装置、存储介质和电子设备 |
Family Cites Families (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112712470B (zh) * | 2019-10-25 | 2024-09-06 | 华为技术有限公司 | 一种图像增强方法及装置 |
| CN111028142B (zh) * | 2019-11-25 | 2024-02-13 | 泰康保险集团股份有限公司 | 图像处理方法、装置和存储介质 |
| CN111783603B (zh) * | 2020-06-24 | 2025-05-09 | 有半岛(北京)信息科技有限公司 | 生成对抗网络训练方法、图像换脸、视频换脸方法及装置 |
-
2021
- 2021-12-31 CN CN202111669721.8A patent/CN114331906A/zh active Pending
-
2022
- 2022-11-29 WO PCT/CN2022/134845 patent/WO2023124697A1/zh not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN113838076A (zh) * | 2020-06-24 | 2021-12-24 | 深圳市中兴微电子技术有限公司 | 目标图像中的对象轮廓的标注方法及装置、存储介质 |
| CN111881926A (zh) * | 2020-08-24 | 2020-11-03 | Oppo广东移动通信有限公司 | 图像生成、图像生成模型的训练方法、装置、设备及介质 |
| CN113327212A (zh) * | 2021-08-03 | 2021-08-31 | 北京奇艺世纪科技有限公司 | 人脸驱动、模型的训练方法、装置、电子设备及存储介质 |
| CN114331906A (zh) * | 2021-12-31 | 2022-04-12 | 北京大甜绵白糖科技有限公司 | 图像增强方法和装置、存储介质和电子设备 |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119624792A (zh) * | 2024-10-31 | 2025-03-14 | 广州像素数据技术股份有限公司 | 一种证件照智能换装处理方法及装置 |
| CN120126202A (zh) * | 2025-05-09 | 2025-06-10 | 杭州海康威视数字技术股份有限公司 | 一种用于人脸增强方法、装置及设备 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN114331906A (zh) | 2022-04-12 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12315291B2 (en) | Face reenactment | |
| KR102759719B1 (ko) | 표면 기반 신경 합성을 사용한 이미지 생성 | |
| CN112818767B (zh) | 数据集生成、伪造检测方法、装置、电子设备及存储介质 | |
| CN111553267B (zh) | 图像处理方法、图像处理模型训练方法及设备 | |
| US20200234480A1 (en) | Systems and methods for realistic head turns and face animation synthesis on mobile device | |
| CN118536616A (zh) | 具有用于合成图像生成的图像编码器的机器学习扩散模型 | |
| CN111583399B (zh) | 图像处理方法、装置、设备、介质和电子设备 | |
| CN113261013A (zh) | 用于移动装置上逼真的头部转动和面部动画合成的系统和方法 | |
| CN114331906A (zh) | 图像增强方法和装置、存储介质和电子设备 | |
| CN106664376A (zh) | 增强现实设备和方法 | |
| CN118648032A (zh) | 用于面部属性操纵的系统和方法 | |
| WO2023077742A1 (zh) | 视频处理方法及装置、神经网络的训练方法及装置 | |
| CN119836650B9 (zh) | 基于使用部分面部图像的三维面部建模的用户认证 | |
| Zhang et al. | Deep learning in face synthesis: A survey on deepfakes | |
| CN117099158A (zh) | 用于改变声音的特性的神经网络 | |
| CN115171199B (zh) | 图像处理方法、装置及计算机设备、存储介质 | |
| CN113544706A (zh) | 电子装置及其控制方法 | |
| CN106791032A (zh) | 静态图像转换为动态影像的方法和装置 | |
| WO2025180271A1 (zh) | 处理音频数据的方法、训练神经网络的方法和相关装置 | |
| Roy et al. | Unmasking deepfake visual content with generative AI | |
| CN117136404A (zh) | 从歌曲中提取伴奏的神经网络 | |
| CN105809612A (zh) | 一种照片转化为表情的方法及智能终端 | |
| CN116524562A (zh) | 活体检测模型训练及检测方法、电子设备及存储介质 | |
| HK40062800A (zh) | 图像增强方法和装置、存储介质和电子设备 | |
| Li | From Anonymous Faces to Provable Privacy: A Journey Through Deep De-Identification and Beyond |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 22913955 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 22913955 Country of ref document: EP Kind code of ref document: A1 |
|
| 32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 13.12.2024) |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 22913955 Country of ref document: EP Kind code of ref document: A1 |