WO2023045979A1 - 图像处理方法及装置、电子设备和存储介质 - Google Patents

图像处理方法及装置、电子设备和存储介质 Download PDF

Info

Publication number
WO2023045979A1
WO2023045979A1 PCT/CN2022/120275 CN2022120275W WO2023045979A1 WO 2023045979 A1 WO2023045979 A1 WO 2023045979A1 CN 2022120275 W CN2022120275 W CN 2022120275W WO 2023045979 A1 WO2023045979 A1 WO 2023045979A1
Authority
WO
WIPO (PCT)
Prior art keywords
beautification
layer
target part
result
target
Prior art date
Application number
PCT/CN2022/120275
Other languages
English (en)
French (fr)
Inventor
孙仁辉
Original Assignee
上海商汤智能科技有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 上海商汤智能科技有限公司 filed Critical 上海商汤智能科技有限公司
Publication of WO2023045979A1 publication Critical patent/WO2023045979A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/77Retouching; Inpainting; Scratch removal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/50Image enhancement or restoration using two or more images, e.g. averaging or subtraction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • G06T5/94Dynamic range modification of images or parts thereof based on local image properties, e.g. for local contrast enhancement
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20212Image combination
    • G06T2207/20221Image fusion; Image merging
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30196Human being; Person
    • G06T2207/30201Face

Definitions

  • the present disclosure relates to the field of computer vision, and in particular to an image processing method and device, electronic equipment and a storage medium.
  • the present disclosure proposes an image processing scheme.
  • an image processing method including:
  • a target part to be beautified in the user image In response to the beautification operation on the user image, determine a target part to be beautified in the user image; perform a first beautification process on the target part according to the color information of the target part, and obtain a first beautification result; According to the texture information of the target part, perform a second beautification process on the target part to obtain a second beautification result; according to the first beautification result and the second beautification result, generate a beautified target for the target part user image.
  • performing the first beautification process on the target part according to the color information of the target part to obtain a first beautification result includes: copying the target part to the first layer , to obtain the first target part; in the first layer, blurring the color information of the pixels in the first target part to obtain the first beautification result.
  • the method further includes: saving the beautification information for obtaining the first beautification result; in response to the undo operation in the first beautification process, according to the The beautification information is used to undo beautification processing on the first beautification result to obtain the first target part.
  • performing a second beautification process on the target part according to the texture information of the target part to obtain a second beautification result includes: copying the target part to a second layer , to obtain the second target part, wherein the second layer is located above the first layer, and the first layer is used to perform the first beautification process on the target part; in the second layer , performing mixing processing on the texture information in the second target part to obtain a second beautification result.
  • performing mixing processing on the texture information in the second target part to obtain a second beautification result includes: according to the first beautification result , performing subtraction and blending processing on the second target part to obtain an intermediate second beautification result; performing bright light blending processing on the intermediate second beautification result according to the first beautification result to obtain the second beautification result.
  • the generating the beautified image of the target user according to the first beautification result and the second beautification result includes: assigning the first beautification result to The first layer of the first layer is superimposed on the second layer to which the second beautification result belongs to obtain the target beautification result; wherein, the first layer is used to perform the first beautification process on the target part, and the first The second layer is used to perform a second beautification process on the target part, the second layer is located above the first layer; the target beautification result is fused with the user image to obtain the target user image.
  • the method further includes: copying the target part to a third layer to obtain a third target part, wherein the third layer is located above the second layer, and the The second layer is used to perform a second beautification process on the target part; in the third layer, a sharpening process is performed on the third target part to obtain a third beautification result;
  • the first beautification result and the second beautification result are used to generate a beautified image of the target user, including: the first layer to which the first beautification result belongs, the layer to which the second beautification result belongs, The second layer is superimposed on the third layer to which the third beautification result belongs to obtain the target beautification result; wherein, the first layer is used to perform a first beautification process on the target part, and the second The layer is located above the first layer; the target beautification result is fused with the user image to obtain the target user image.
  • the fusing the target beautification result with the user image to obtain the target user image includes: acquiring a mask image matching the target part; According to the gray level distribution state of the model image, the fusion strength between the target beautification result and the user image is determined; according to the fusion strength, the target beautification result is fused with the user image to obtain the target user image.
  • the target part includes a human face part
  • the beautifying operation includes a dermabrasion operation
  • an image processing device including:
  • a determining module configured to determine a target part to be beautified in the user image in response to a beautification operation on the user image; a first beautification module, configured to perform a second beautification on the target part according to the color information of the target part A beautification process, to obtain a first beautification result; a second beautification module, to perform a second beautification process on the target part according to the texture information of the target part, to obtain a second beautification result; a generation module, to obtain a second beautification result according to the texture information of the target part
  • the first beautification result and the second beautification result are used to generate a target user image after beautifying the target part.
  • the first beautification module is configured to: copy the target part to the first layer to obtain the first target part; The color information of the pixels in the target part is blurred to obtain the first beautification result.
  • the device is further configured to: save the beautification information for obtaining the first beautification result; in response to the undo operation in the first beautification process, According to the beautification information, undo beautification processing is performed on the first beautification result to obtain the first target part.
  • the second beautification module is configured to: copy the target part to a second layer to obtain a second target part, wherein the second layer is located on the first layer Above, the first layer is used to perform a first beautification process on the target part; in the second layer, the texture information in the second target part is mixed to obtain a second beautification result .
  • the second beautification module is further configured to: perform subtraction and blending processing on the second target part according to the first beautification result to obtain an intermediate second beautification result; For the first beautification result, perform bright light mixing processing on the intermediate second beautification result to obtain the second beautification result.
  • the generating module is configured to: superimpose the first layer to which the first beautification result belongs and the second layer to which the second beautification result belongs to obtain a target beautification result; Wherein, the first layer is used to perform a first beautification process on the target part, the second layer is used to perform a second beautification process on the target part, and the second layer is located at the first above a layer; merging the target beautification result with the user image to obtain the target user image.
  • the device is further configured to: copy the target part to a third layer to obtain a third target part, wherein the third layer is located above the second layer,
  • the second layer is used to perform a second beautification process on the target part; in the third layer, a sharpening process is performed on the third target part to obtain a third beautification result;
  • the first beautification result and the second beautification result, and generating the target user image after beautifying the target part includes: the first layer to which the first beautification result belongs, the first layer to which the second beautification result belongs The second layer of the second layer is superimposed on the third layer to which the third beautification result belongs to obtain the target beautification result; wherein, the first layer is used to perform the first beautification process on the target part, and the first The second layer is located above the first layer; the target beautification result is fused with the user image to obtain the target user image.
  • the device is further configured to: acquire a mask image matching the target part; determine the target beautification result and the user's fusion strength between images; according to the fusion strength, the target beautification result is fused with the user image to obtain the target user image.
  • the target part includes a human face part
  • the beautifying operation includes a dermabrasion operation
  • an electronic device including: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to: execute the above image processing method.
  • a computer-readable storage medium on which computer program instructions are stored, and the above-mentioned image processing method is implemented when the computer program instructions are executed by a processor.
  • a computer program product including computer readable codes, or a non-volatile computer readable storage medium bearing computer readable codes, when the computer readable codes are stored in an electronic device
  • the processor in the electronic device is used to implement the above image processing method.
  • the target part to be beautified in the user image is determined, so that the first beautification process is performed according to the color information of the target part to obtain the first beautification result, and according to the target part
  • the second beautification process is performed on the texture information to obtain a second beautification result, and then a target user image after beautification of the target part is generated according to the first beautification result and the second beautification result.
  • Fig. 1 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • Fig. 2 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • Fig. 3 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • Fig. 4 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • FIG. 5 shows a block diagram of an image processing device according to an embodiment of the present disclosure.
  • Fig. 6 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • Fig. 7 shows a block diagram of an electronic device according to an embodiment of the present disclosure.
  • Fig. 1 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • the method can be applied to an image processing device or an image processing system, and the image processing device can be a terminal device, a server, or other processing devices.
  • the terminal device may be user equipment (User Equipment, UE), mobile device, user terminal, terminal, cellular phone, cordless phone, personal digital assistant (Personal Digital Assistant, PDA), handheld device, computing device, vehicle-mounted device, Wearable equipment etc.
  • the image processing method can be applied to a cloud server or a local server, and the cloud server can be a public cloud server or a private cloud server, which can be flexibly selected according to actual conditions.
  • the image processing method may also be implemented in a manner in which the processor invokes computer-readable instructions stored in the memory.
  • the image processing method may include:
  • Step S11 in response to the beautification operation on the user's image, determine the target part to be beautified in the user's image.
  • the user image can be any image containing the target part of the user, and the user image can contain one or more users, and can also contain one or more target parts of the user, and its implementation form can be flexibly determined according to the actual situation.
  • the user image can contain one or more users, and can also contain one or more target parts of the user, and its implementation form can be flexibly determined according to the actual situation.
  • the target part can be any part of the user's image that needs to be beautified. Which parts are included in the target part, the implementation form can also be flexibly determined according to the actual situation of the beautification operation. Part, or any part including skin and other areas, such as hands, neck, or elbows; for the beautification operation of matte face operation, the target part can be the face part with matte makeup Or the lip parts of matte lip makeup, etc.
  • the beautification operation may be any operation for beautifying the target part of the user's image, such as a skin smoothing operation or a matte operation.
  • the operation content included in the beautification operation can be flexibly determined according to the actual situation, and is not limited to the following disclosed embodiments.
  • the beautification operation may include an operation indicating to perform beautification processing on the user's target part in the user image; in some possible implementation manners, the beautification operation may also include inputting one or more parameters etc., such as beautification strength parameters, etc.
  • the beautification intensity parameter can be input by the user, such as the intensity of beautifying the target site and other related parameters.
  • the implementation form of the beautification intensity parameter can be flexibly determined according to the specific implementation process of beautifying the target site. For example, for skin grinding operations, beautification
  • the intensity parameter may include the blur intensity or sharpening intensity of the microdermabrasion process, etc., see the following disclosed embodiments for details, and will not be expanded here.
  • the manner of determining the target site is not limited in the embodiments of the present disclosure, and is not limited to the following disclosed embodiments.
  • the position of the target part in the user image may be identified, and the position of the target part in the user image may be determined to extract the image of the target part.
  • the manner of recognition is not limited in the embodiment of the present disclosure, for example, it may be key point recognition or direct recognition of the whole face part.
  • Step S12 performing a first beautification process on the target part according to the color information of the target part to obtain a first beautification result.
  • the color information can reflect the color distribution in the target part, for example, it can include the pixel value of the pixel in the target part, etc.
  • the pixel in the target part can be every pixel contained in the target part, or it can be are some pixels in the target part.
  • the first beautification process can be based on color information to perform related processing on the target part, and its implementation can be flexibly determined according to the type of beautification operation.
  • the first beautification process can include blurring the pixels in the target part
  • the first beautification process can change the color value of the pixels in the target part while blurring the pixels in the target part.
  • Step S13 performing a second beautification process on the target part according to the texture information of the target part to obtain a second beautification result.
  • the texture information can reflect the texture details in the target part.
  • the texture information can include the skin texture in the human face and some other detailed information contained in the skin, such as the texture on the skin. Spots, acne marks or moles and other information.
  • the second beautification process can be based on texture information to perform related processing on the target part, and its implementation can also be flexibly determined according to actual conditions.
  • the second beautification process can include combining the image of the target part with the first Mixing processing among beautification processing results.
  • the second beautification processing may also include sharpening processing on the target part.
  • Step S14 generating a beautified image of the target user based on the first beautification result and the second beautification result.
  • the target user image may be an image obtained by beautifying the target part of the user image, and the method of generating the target user image may be flexibly determined according to the actual situation, for example, the first beautification result and the second beautification result may be fused to obtain The target user image, or the first beautification result, the second beautification result and the user image are fused to obtain the target user image.
  • the first beautification result and the second beautification result may also belong to different layers, and in this case, the target user image may be obtained by overlapping layers.
  • step S14 For some possible implementation manners of step S14, reference may be made to the following disclosed embodiments in detail, which will not be expanded here.
  • the target part to be beautified in the user image is determined, so that the first beautification process is performed according to the color information of the target part to obtain the first beautification result, and according to the target part
  • the second beautification process is performed on the texture information to obtain a second beautification result, and then a target user image after beautification of the target part is generated according to the first beautification result and the second beautification result.
  • FIG. 2 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • step S12 may include:
  • Step S121 copying the target part to the first layer to obtain the first target part.
  • Step S122 in the first layer, blurring the color information of the pixels in the first target part to obtain a first beautification result.
  • the first layer may be any layer with image processing or editing functions, such as an editing layer in image editing software (PS, Photoshop).
  • PS image editing software
  • the target part may be located on the original layer, and the first layer may be located above the original layer.
  • Copying the target part to the first layer may be copying the target part to the first layer alone, or copying the entire user image including the target part to the first layer.
  • the first target part may be a part image of the target part in the first layer.
  • Blurring the color information of the pixels in the first target part may be performing blurring processing on the color information of each pixel in the first target part, or performing blurring processing on some of the pixels, which is determined according to the actual situation That's it.
  • blurring processing is not limited in the embodiments of the present disclosure, and any processing manner with a blurring function may be applied in the embodiments of the present disclosure.
  • blurring may include Gaussian blurring.
  • the Gaussian blur in the process of processing a certain pixel, can be centered on the pixel, and the pixel value of the pixel within the target range of the pixel can be processed by a Gaussian function to obtain the processed pixel value.
  • the Gaussian blur result of this pixel.
  • the target range in Gaussian blur can be flexibly set according to actual conditions, and is not limited in this embodiment of the present disclosure.
  • the beautification operation may determine the target range of the Gaussian blur through the blur parameter input by the user.
  • the target range may be 10-20 pixels.
  • the color information in the target part can be blurred independently, which can not only achieve a better first beautification, but also facilitate the flexibility of the first beautification result. Adjust accurately to improve the flexibility and effect of landscaping.
  • an operation command of a "smart object" can also be executed on the first layer, and the operation command can make the first layer change its effect without being destroyed.
  • the method proposed in the embodiment of the present disclosure may further include:
  • the beautification information may include information such as operation commands and parameters accepted by the first layer during the beautification process, such as the blurring instruction and the target range of the blurring mentioned in the above disclosed embodiments.
  • the undo operation in the first beautification process may be to undo some operations performed on the first target part during the process of obtaining the first beautification result, such as performing blurring processing on the first target part to obtain the first beautification After the object, the undo operation can be used to make the first beautified object return to the image state before the blurring process.
  • the beautification information by saving the beautification information, it is convenient to undo the first beautification process when the first beautification result is not satisfied, so as to facilitate the subsequent re-execution of the first beautification process and other operations to improve the beautification.
  • the flexibility of the process is convenient for users to adjust the beautification results according to their preferences.
  • FIG. 3 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • step S13 may include:
  • Step S131 copying the target part to the second layer to obtain the second target part.
  • step S132 in the second layer, the texture information in the second target part is mixed to obtain a second beautification result.
  • the second layer For the implementation form of the second layer, reference may be made to the implementation form of the first layer in the above disclosed embodiments, which will not be repeated here.
  • the second layer since the texture information contains more details than the color information, in order to facilitate the modification of the beautification effect, the second layer may be set above the first layer.
  • the method of copying the target part to the second layer can refer to the above-mentioned method of copying to the first layer, and will not be repeated here.
  • the second target part may be a part image of the target part in the second layer.
  • the blending process on the texture information in the second target part may be based on the image of the second target part itself, or blend the second target part with the first beautification result, etc.
  • step S132 reference may be made to the following disclosed embodiments in detail, which will not be expanded here.
  • the texture information in the target part can be mixed independently processing to achieve a better second beautification and to facilitate the flexible adjustment of the second beautification result to improve the flexibility and effect of beautification; on the other hand, by setting the second layer above the first layer, it can be better
  • the texture information of the target part can be preserved to further enhance the beautification effect.
  • performing mixed processing on the texture information in the second target part may include:
  • the second target part is subtracted and blended to obtain an intermediate second beautification result
  • the intermediate second beautification result is subjected to bright light mixing processing to obtain the second beautification result.
  • the subtraction and blending process may include calculating the difference between the color channel value of the second target part and the color channel value in the first beautification result, in one example, the subtraction and blending process may be performed by The difference between the RGB channel value and the RGB channel value in the first beautification result is to exclude the relevant information of the first beautification result from the second target part, and then separate the texture information from the second target part as the middle second beautification result.
  • the process of subtracting and blending the second target part according to the first beautification result can be expressed by the following formula (1):
  • the preset shrinkage value can be a preset parameter, the higher the preset shrinkage value, the darker the middle second beautification result will be obtained,
  • the specific value of the preset contraction value can be flexibly determined according to the actual situation, and in an example, it can be between 1.000-2.000.
  • the preset compensation value can also be a preset parameter, which is used to further adjust the brightness of the second beautification result in the middle. In an example, the value of the preset compensation value can be between -255 and +255, for example, it can be 128, etc. .
  • the preset shrinkage value and preset compensation value can be used as the beautification intensity parameters in the beautification operation, which are determined according to the user's input, so that the flexibility of beautification can be further improved, and the beautification that meets the user's needs can be obtained.
  • Target user image the beautification intensity parameters in the beautification operation, which are determined according to the user's input, so that the flexibility of beautification can be further improved, and the beautification that meets the user's needs can be obtained.
  • the bright light mixing process may include calculating the mixed value between the color value of the second target part and the color value of the first beautification result through calculation methods such as subtraction, multiplication, and division.
  • the bright light mixing process may be performed by adding The intermediate second beautification result is mixed with the first beautification result to increase or decrease the contrast of the intermediate second beautification result, and then realize the color adjustment of the intermediate second beautification result, because the intermediate second beautification result mainly retains the color of the target part Texture information, therefore, through bright light mixing processing, it is possible to further adjust the texture information of the target part, and obtain a second beautification result that meets the user's needs.
  • the subtractive blending process can be used to separate the texture information from the second target part, and the texture information can be further adjusted through the bright light blending process, thereby improving the beautification effect and realism of the obtained second beautification result , which in turn improves the overall performance of the beautification process.
  • the method proposed in the embodiment of the present disclosure may further include:
  • the third target part is sharpened to obtain a third beautification result.
  • the third layer can be used to highlight the texture details of the target part. Therefore, in order to preserve more texture details of the target part, the third layer can be set above the second layer.
  • the method of copying the target part to the third layer can refer to the above-mentioned method of copying to the first layer and the second layer, and will not be repeated here.
  • the third target part may be a part image of the target part in the third layer.
  • the sharpening process on the third target part may be performed on the area of the third target part, or may be performed on the entire third layer, and the processing method can be flexibly selected according to the actual situation.
  • the specific manner of the sharpening process is not limited in this embodiment of the present disclosure.
  • the third target part can be sharpened by selecting the operation of "preserve high contrast" in the editing layer of PS.
  • High pass preserves areas with high contrast in the image, such as outlines such as eyes, lips, or hair, and turns the rest of the area to a neutral gray.
  • a pixel range for high contrast preservation may also be set to improve the sharpening effect, and the pixel range may be flexibly set according to actual conditions.
  • a pixel range of 1 pixel may be set for high contrast preservation.
  • the high-contrast reserved pixel range can also be used as a beautification intensity parameter in the beautification operation, which is determined according to user input, so that the flexibility of beautification can be further improved, and a target user image that meets user needs can be obtained.
  • the texture information can be further enhanced, and the details of the beautification effect can be enhanced ;
  • the texture details of the target part can be better preserved, and the beautification effect can be further improved.
  • FIG. 4 shows a flowchart of an image processing method according to an embodiment of the present disclosure.
  • step S14 may include:
  • Step S141 superimposing the first layer to which the first beautification result belongs and the second layer to which the second beautification result belongs to obtain a target beautification result.
  • step S142 the target beautification result is fused with the user image to obtain the target user image.
  • the first layer and the second layer are superimposed, and the order of their superposition can be determined according to the positional relationship between the first layer and the second layer.
  • the second layer can be located at Above the first layer, so the second layer can be superimposed on the first layer to obtain the target beautification result.
  • the three layers of the first layer, the second layer and the third layer can also be superimposed to obtain the target beautification result, and the order of superposition can also be based on the position between the layers
  • the relationship is determined, for example, after superimposing the second layer on the first layer, and then superimposing the third layer on the second layer, or first superimposing the third layer on the second layer, and then superimposing the superimposed
  • the results are superimposed on the first layer, etc., which can be flexibly selected according to the actual situation.
  • the target beautification result can be obtained through layer overlay, and the target beautification result can be fused with the user image through step S142 to obtain the target user image.
  • step S142 can be flexibly determined according to the actual situation. For example, if the user image belongs to the original layer, the target beautification result can be directly superimposed on the original layer to obtain the target user image.
  • step S142 reference may be made to the following disclosed embodiments, which will not be expanded here.
  • step S142 may include:
  • the gray distribution state of the mask image determine the fusion strength between the target beautification result and the user image
  • the target beautification result is fused with the user image to obtain the target user image.
  • the mask image may be a mask image (mask) whose shape matches the target part, and the realization form of the mask image may also vary with different target parts.
  • the mask image may be a preset face mask.
  • the mask image can contain multiple brightness pixels, and the brightness value of the pixel points in the mask image can be flexibly determined according to the actual situation.
  • the brightness of the pixel points in the mask image can be within the range of 0 to 255 .
  • the brightness of the pixels in the mask image can be flexibly set according to the actual situation.
  • the brightness of the pixels in the mask image can also be used as a beautification intensity parameter in the beautification operation, which is determined according to the user's input, so that The flexibility of beautification can be further improved, and target user images meeting user needs can be obtained.
  • the grayscale distribution state can be the grayscale value distribution of pixels in the mask image. Pixels with different brightnesses have different grayscale values, and the grayscale values can be converted to transparency according to the preset grayscale-transparency correspondence. .
  • the grayscale-transparency correspondence relationship can be set according to actual conditions, which is not limited in this embodiment of the present disclosure. Therefore, according to the gray distribution state of the pixel in the mask image, the transparency of the pixel can be determined.
  • the respective fusion strengths of the target beautification result and the user image can be determined, that is, the weights of the two in the fusion process.
  • the target beautification result and the user image can be weighted and fused to obtain the target user image. image.
  • the pixels on the eyes should not produce the skin smoothing effect, so you can set the pixel at the eye position in the preset face mask is 0, then after converting the gray level to transparency, it can be determined that the weight of the target beautification result in the fusion process is 0, while the weight of the user image in the fusion process is 1.
  • the target beautification result The result will not beautify the user's image, so the pixel at the eye position will not produce skin smoothing effect, which meets the requirements of beautification.
  • the fusion strength of different pixels in the target beautification result can be determined effectively and in batches, and the beautification effect can be further adjusted based on the fusion strength.
  • the fusion strength of the target beautification results can be determined in batches through the mask image, which improves the fusion efficiency and convenience.
  • the flexibility of beautification can be further improved, and the target user image that meets the user's needs can be obtained.
  • FIG. 5 shows a block diagram of an image processing device according to an embodiment of the present disclosure.
  • the image processing device 20 may include:
  • the determination module 21 is configured to determine a target part to be beautified in the user image in response to the beautification operation on the user image.
  • the first beautification module 22 is configured to perform a first beautification process on the target part according to the color information of the target part to obtain a first beautification result.
  • the second beautification module 23 is configured to perform a second beautification process on the target part according to the texture information of the target part to obtain a second beautification result.
  • the generation module 24 is configured to generate a beautified image of the target user based on the first beautification result and the second beautification result.
  • the first beautification module is configured to: copy the target part to the first layer to obtain the first target part; in the first layer, the color information of the pixels in the first target part Perform blur processing to obtain the first beautification result.
  • the device is further configured to: save the beautification information of the first beautification result; respond to the undo operation in the first beautification process, according to the beautification information, As a result, undo beautification processing is performed to obtain the first target site.
  • the second beautification module is used to: copy the target part to the second layer to obtain the second target part, wherein the second layer is located above the first layer, and the first layer It is used to perform the first beautification process on the target part; in the second layer, the texture information in the second target part is mixed to obtain the second beautification result.
  • the second beautification module is further configured to: perform subtraction and mixing processing on the second target part according to the first beautification result to obtain an intermediate second beautification result;
  • the second beautification result is processed by bright light mixing to obtain the second beautification result.
  • the generating module is configured to: superimpose the first layer to which the first beautification result belongs and the second layer to which the second beautification result belongs to obtain the target beautification result; wherein, the first layer It is used to perform the first beautification process on the target part, and the second layer is used to perform the second beautification process on the target part, and the second layer is located above the first layer; the target beautification result is fused with the user image to obtain the target user image.
  • the device is further configured to: copy the target part to a third layer to obtain a third target part, wherein the third layer is located above the second layer, and the second layer is used for Perform second beautification processing on the target part; in the third layer, perform sharpening processing on the third target part to obtain a third beautification result; generate a beautified target part according to the first beautification result and the second beautification result
  • the target user image includes: superimposing the first layer to which the first beautification result belongs, the second layer to which the second beautification result belongs, and the third layer to which the third beautification result belongs to obtain the target beautification result; wherein, The first layer is used to perform the first beautification process on the target part, and the second layer is located above the first layer; the target beautification result is fused with the user image to obtain the target user image.
  • the device is further used to: acquire a mask image matching the target part; determine the fusion strength between the target beautification result and the user image according to the grayscale distribution state of the mask image; , the target beautification result is fused with the user image to obtain the target user image.
  • the target part includes a human face part
  • the beautification operation includes a skin smoothing operation
  • the disclosure relates to the field of augmented reality.
  • the target object may involve faces, limbs, gestures, actions, etc. related to the human body, or markers and markers related to objects, or sand tables, display areas or display items related to venues or places.
  • Vision-related algorithms can involve visual positioning, SLAM, 3D reconstruction, image registration, background segmentation, object key point extraction and tracking, object pose or depth detection, etc.
  • Specific applications can not only involve interactive scenes such as guided tours, navigation, explanations, reconstructions, virtual effect overlays and display related to real scenes or objects, but also special effects processing related to people, such as makeup beautification, body beautification, special effect display, virtual Interactive scenarios such as model display.
  • the relevant features, states and attributes of the target object can be detected or identified through the convolutional neural network.
  • the above-mentioned convolutional neural network is a network model obtained by performing model training based on a deep learning framework.
  • the disclosed application example proposes an image processing method, including the following process:
  • the RGB channel value in the second layer and the RGB channel value in the first beautification result are mixed by subtracting and blending to separate the high-frequency texture information from the second layer as the middle second The beautification result, and then the intermediate second beautification result and the first beautification result are mixed through the way of light mixing, so as to realize the color adjustment of the texture information, so as to obtain the second beautification result.
  • the third layer is sharpened, and the texture information of the face parts is sharpened, which is conducive to retaining the real texture details of the original layer.
  • the way of sharpening can be: in the PS interface, select "PS-Filter-Other-High Contrast Preservation-1 Pixel" in turn, the result of high contrast preservation can be opposite to the result of Gaussian Blur.
  • the pixel range of Gaussian blur and the parameters of sharpening can be higher, so that the strength of the skin smoothing effect can be changed by changing the pixel range of Gaussian blur, and the details of texture information can be enhanced by changing the parameters of sharpening .
  • It can also be combined with the preset face mask to define the microdermabrasion area, and the intensity of microdermabrasion in different areas can be controlled by the grayscale distribution state in the preset face mask.
  • a preset face mask can be generated with brightness ranging from 255 for the brightest to 0 for the darkest.
  • the grayscale value in the preset face mask is mapped to the fusion intensity of the microdermabrasion process. For example, if a pixel belongs to the eye area and should not be treated with microdermabrasion, the gray level of the pixel can be set to 0, that is, no microdermabrasion effect will be produced.
  • the image processing method proposed in the application example of this disclosure can not only be applied to face parts, but also can be extended to beautify operations on other parts, such as neck skin removal or matte lip makeup, etc. According to the different types of beautification operations, the image processing method proposed in the application examples of the present disclosure can be flexibly expanded and modified accordingly.
  • the writing order of each step does not mean a strict execution order and constitutes any limitation on the implementation process.
  • the specific execution order of each step should be based on its function and possible
  • the inner logic is OK.
  • Embodiments of the present disclosure also provide a computer-readable storage medium, on which computer program instructions are stored, and the above-mentioned method is implemented when the computer program instructions are executed by a processor.
  • the computer readable storage medium may be a volatile computer readable storage medium or a nonvolatile computer readable storage medium.
  • An embodiment of the present disclosure also proposes an electronic device, including: a processor; and a memory for storing instructions executable by the processor; wherein the processor is configured as the above method.
  • the above-mentioned memory can be volatile memory (volatile memory), such as RAM; or non-volatile memory (non-volatile memory), such as ROM, flash memory (flash memory), hard disk (Hard Disk Drive , HDD) or solid-state drive (Solid-State Drive, SSD); or a combination of the above types of memory, and provide instructions and data to the processor.
  • volatile memory such as RAM
  • non-volatile memory non-volatile memory
  • ROM read-only memory
  • flash memory flash memory
  • HDD hard disk
  • SSD solid-state drive
  • the aforementioned processor may be at least one of ASIC, DSP, DSPD, PLD, FPGA, CPU, controller, microcontroller, and microprocessor. It can be understood that, for different devices, the electronic device used to implement the above processor function may also be other, which is not specifically limited in this embodiment of the present disclosure.
  • Electronic devices may be provided as terminals, servers, or other forms of devices.
  • the embodiments of the present disclosure further provide a computer program, which implements the above method when the computer program is executed by a processor.
  • FIG. 6 is a block diagram of an electronic device 800 according to an embodiment of the present disclosure.
  • the electronic device 800 may be a terminal such as a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, or a personal digital assistant.
  • electronic device 800 may include one or more of the following components: processing component 802, memory 804, power supply component 806, multimedia component 808, audio component 810, input/output (I/O) interface 812, sensor component 814 , and the communication component 816.
  • the processing component 802 generally controls the overall operations of the electronic device 800, such as those associated with display, telephone calls, data communications, camera operations, and recording operations.
  • the processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above method. Additionally, processing component 802 may include one or more modules that facilitate interaction between processing component 802 and other components. For example, processing component 802 may include a multimedia module to facilitate interaction between multimedia component 808 and processing component 802 .
  • the memory 804 is configured to store various types of data to support operations at the electronic device 800 . Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phonebook data, messages, pictures, videos, and the like.
  • the memory 804 can be implemented by any type of volatile or non-volatile storage device or their combination, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic or Optical Disk.
  • SRAM static random access memory
  • EEPROM electrically erasable programmable read-only memory
  • EPROM erasable Programmable Read Only Memory
  • PROM Programmable Read Only Memory
  • ROM Read Only Memory
  • Magnetic Memory Flash Memory
  • Magnetic or Optical Disk Magnetic Disk
  • the power supply component 806 provides power to various components of the electronic device 800 .
  • Power components 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for electronic device 800 .
  • the multimedia component 808 includes a screen providing an output interface between the electronic device 800 and the user.
  • the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user.
  • the touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may not only sense a boundary of a touch or swipe action, but also detect duration and pressure associated with the touch or swipe action.
  • the multimedia component 808 includes a front camera and/or a rear camera. When the electronic device 800 is in an operation mode, such as a shooting mode or a video mode, the front camera and/or the rear camera can receive external multimedia data. Each front camera and rear camera can be a fixed optical lens system or have focal length and optical zoom capability.
  • the audio component 810 is configured to output and/or input audio signals.
  • the audio component 810 includes a microphone (MIC), which is configured to receive external audio signals when the electronic device 800 is in operation modes, such as call mode, recording mode and voice recognition mode. Received audio signals may be further stored in memory 804 or sent via communication component 816 .
  • the audio component 810 also includes a speaker for outputting audio signals.
  • the I/O interface 812 provides an interface between the processing component 802 and a peripheral interface module, which may be a keyboard, a click wheel, a button, and the like. These buttons may include, but are not limited to: a home button, volume buttons, start button, and lock button.
  • Sensor assembly 814 includes one or more sensors for providing status assessments of various aspects of electronic device 800 .
  • the sensor component 814 can detect the open/closed state of the electronic device 800, the relative positioning of components, such as the display and the keypad of the electronic device 800, the sensor component 814 can also detect the electronic device 800 or a Changes in position of components, presence or absence of user contact with electronic device 800 , electronic device 800 orientation or acceleration/deceleration and temperature changes in electronic device 800 .
  • Sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact.
  • Sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications.
  • the sensor component 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.
  • the communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices.
  • the electronic device 800 can access a wireless network based on communication standards, such as WiFi, 2G or 3G, or a combination thereof.
  • the communication component 816 receives a broadcast signal or broadcast related personnel information from an external broadcast management system via a broadcast channel.
  • the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication.
  • the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wide Band (UWB) technology, Bluetooth (BT) technology and other technologies.
  • RFID Radio Frequency Identification
  • IrDA Infrared Data Association
  • UWB Ultra Wide Band
  • Bluetooth Bluetooth
  • electronic device 800 may be implemented by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable A programmable gate array (FPGA), controller, microcontroller, microprocessor or other electronic component implementation for performing the methods described above.
  • ASICs application specific integrated circuits
  • DSPs digital signal processors
  • DSPDs digital signal processing devices
  • PLDs programmable logic devices
  • FPGA field programmable A programmable gate array
  • controller microcontroller, microprocessor or other electronic component implementation for performing the methods described above.
  • a non-volatile computer-readable storage medium such as the memory 804 including computer program instructions, which can be executed by the processor 820 of the electronic device 800 to implement the above method.
  • FIG. 7 is a block diagram of an electronic device 1900 according to an embodiment of the present disclosure.
  • electronic device 1900 may be provided as a server.
  • electronic device 1900 includes processing component 1922 , which further includes one or more processors, and a memory resource represented by memory 1932 for storing instructions executable by processing component 1922 , such as application programs.
  • the application programs stored in memory 1932 may include one or more modules each corresponding to a set of instructions.
  • the processing component 1922 is configured to execute instructions to perform the above method.
  • Electronic device 1900 may also include a power supply component 1926 configured to perform power management of electronic device 1900, a wired or wireless network interface 1950 configured to connect electronic device 1900 to a network, and an input-output (I/O) interface 1958 .
  • the electronic device 1900 can operate based on an operating system stored in the memory 1932, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM or the like.
  • a non-transitory computer-readable storage medium such as the memory 1932 including computer program instructions, which can be executed by the processing component 1922 of the electronic device 1900 to implement the above method.
  • the present disclosure can be a system, method and/or computer program product.
  • a computer program product may include a computer readable storage medium having computer readable program instructions thereon for causing a processor to implement various aspects of the present disclosure.
  • a computer readable storage medium may be a tangible device that can retain and store instructions for use by an instruction execution device.
  • a computer readable storage medium may be, for example, but is not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing.
  • Computer-readable storage media include: portable computer diskettes, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), or flash memory), static random access memory (SRAM), compact disc read only memory (CD-ROM), digital versatile disc (DVD), memory stick, floppy disk, mechanically encoded device, such as a printer with instructions stored thereon A hole card or a raised structure in a groove, and any suitable combination of the above.
  • RAM random access memory
  • ROM read-only memory
  • EPROM erasable programmable read-only memory
  • flash memory static random access memory
  • SRAM static random access memory
  • CD-ROM compact disc read only memory
  • DVD digital versatile disc
  • memory stick floppy disk
  • mechanically encoded device such as a printer with instructions stored thereon
  • a hole card or a raised structure in a groove and any suitable combination of the above.
  • computer-readable storage media are not to be construed as transient signals per se, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., pulses of light through fiber optic cables), or transmitted electrical signals.
  • Computer-readable program instructions described herein may be downloaded from a computer-readable storage medium to a respective computing/processing device, or downloaded to an external computer or external storage device over a network, such as the Internet, a local area network, a wide area network, and/or a wireless network.
  • the network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and/or edge servers.
  • a network adapter card or a network interface in each computing/processing device receives computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in a computer-readable storage medium in each computing/processing device .
  • Computer program instructions for performing the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or Source or object code written in any combination, including object-oriented programming languages—such as Smalltalk, C++, etc., and conventional procedural programming languages—such as the “C” language or similar programming languages.
  • Computer readable program instructions may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer, or entirely on the remote computer or server implement.
  • the remote computer can be connected to the user computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (such as via the Internet using an Internet service provider). connect).
  • electronic circuits such as programmable logic circuits, field programmable gate arrays (FPGAs) or programmable logic arrays (PLAs), are personalized by utilizing status personnel information of computer readable program instructions, the electronic circuits Computer readable program instructions may be executed to implement various aspects of the present disclosure.
  • These computer-readable program instructions may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine such that when executed by the processor of the computer or other programmable data processing apparatus , producing an apparatus for realizing the functions/actions specified in one or more blocks in the flowchart and/or block diagram.
  • These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause computers, programmable data processing devices and/or other devices to work in a specific way, so that the computer-readable medium storing instructions includes An article of manufacture comprising instructions for implementing various aspects of the functions/acts specified in one or more blocks in flowcharts and/or block diagrams.
  • each block in a flowchart or block diagram may represent a module, a portion of a program segment, or an instruction that includes one or more Executable instructions.
  • the functions noted in the block may occur out of the order noted in the figures. For example, two blocks in succession may, in fact, be executed substantially concurrently, or they may sometimes be executed in the reverse order, depending upon the functionality involved.
  • each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations can be implemented by a dedicated hardware-based system that performs the specified function or action , or may be implemented by a combination of dedicated hardware and computer instructions.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Biophysics (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Image Processing (AREA)

Abstract

本公开涉及一种图像处理方法及装置、电子设备和存储介质。所述方法包括:响应于针对用户图像的美化操作,确定所述用户图像中待进行美化的目标部位;根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果;根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果;根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像。

Description

图像处理方法及装置、电子设备和存储介质
本申请要求2021年09月27日提交、申请号为202111135696.5,发明名称为“图像处理方法及装置、电子设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本公开涉及计算机视觉领域,尤其涉及一种图像处理方法及装置、电子设备和存储介质。
背景技术
随着计算机视觉技术的发展,对人脸图像的面部等区域进行磨皮等美化处理的操作已愈加广泛应用于图像处理领域。
发明内容
本公开提出了一种图像处理方案。
根据本公开的一方面,提供了一种图像处理方法,包括:
响应于针对用户图像的美化操作,确定所述用户图像中待进行美化的目标部位;根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果;根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果;根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像。
在一种可能的实现方式中,所述根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果,包括:将所述目标部位复制至第一图层,得到第一目标部位;在所述第一图层中,对所述第一目标部位中像素点的颜色信息进行模糊处理,得到第一美化结果。
在一种可能的实现方式中,在得到第一美化结果之后,所述方法还包括:保存得到所述第一美化结果的美化信息;响应于所述第一美化处理中的撤销操作,根据所述美化信息,对所述第一美化结果进行撤销美化处理,得到所述第一目标部位。
在一种可能的实现方式中,所述根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果,包括:将所述目标部位复制至第二图层,得到第二目标部位,其中,所述第二图层位于第一图层的上方,所述第一图层用于对所述目标部位进行第一美化处理;在所述第二图层中,对所述第二目标部位中的纹理信息进行混合处理,得到第二美化结果。
在一种可能的实现方式中,所述在所述第二图层中,对所述第二目标部位中的纹理信息进行混合处理,得到第二美化结果,包括:根据所述第一美化结果,对所述第二目标部位进行减去混合处理,得到中间第二美化结果;根据所述第一美化结果,对所述中间第二美化结果进行亮光混合处理,得到所述第二美化结果。
在一种可能的实现方式中,所述根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像,包括:将所述第一美化结果所属的第一图层与所述第二美化结果所属的第二图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层用于对所述目标部位进行第二美化处理,所述第二图层位于所述第一图层的上方;将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述方法还包括:将所述目标部位复制至第三图层,得 到第三目标部位,其中,所述第三图层位于第二图层的上方,所述第二图层用于对所述目标部位进行第二美化处理;在所述第三图层中,对所述第三目标部位进行锐化处理,得到第三美化结果;所述根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像,包括:将所述第一美化结果所属的第一图层、所述第二美化结果所属的第二图层与所述第三美化结果所属的第三图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层位于所述第一图层的上方;将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像,包括:获取与所述目标部位匹配的掩模图像;根据所述掩模图像的灰度分布状态,确定所述目标美化结果与所述用户图像之间的融合强度;根据所述融合强度,将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述目标部位包括人脸部位,所述美化操作包括磨皮操作。
根据本公开的一方面,提供了一种图像处理装置,包括:
确定模块,用于响应于针对用户图像的美化操作,确定所述用户图像中待进行美化的目标部位;第一美化模块,用于根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果;第二美化模块,用于根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果;生成模块,用于根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像。
在一种可能的实现方式中,所述第一美化模块用于:将所述目标部位复制至第一图层,得到第一目标部位;在所述第一图层中,对所述第一目标部位中像素点的颜色信息进行模糊处理,得到第一美化结果。
在一种可能的实现方式中,在所述第一美化模块之后,所述装置还用于:保存得到所述第一美化结果的美化信息;响应于所述第一美化处理中的撤销操作,根据所述美化信息,对所述第一美化结果进行撤销美化处理,得到所述第一目标部位。
在一种可能的实现方式中,所述第二美化模块用于:将所述目标部位复制至第二图层,得到第二目标部位,其中,所述第二图层位于第一图层的上方,所述第一图层用于对所述目标部位进行第一美化处理;在所述第二图层中,对所述第二目标部位中的纹理信息进行混合处理,得到第二美化结果。
在一种可能的实现方式中,所述第二美化模块进一步用于:根据所述第一美化结果,对所述第二目标部位进行减去混合处理,得到中间第二美化结果;根据所述第一美化结果,对所述中间第二美化结果进行亮光混合处理,得到所述第二美化结果。
在一种可能的实现方式中,所述生成模块用于:将所述第一美化结果所属的第一图层与所述第二美化结果所属的第二图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层用于对所述目标部位进行第二美化处理,所述第二图层位于所述第一图层的上方;将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述装置还用于:将所述目标部位复制至第三图层,得到第三目标部位,其中,所述第三图层位于第二图层的上方,所述第二图层用于对所述目标部位进行第二美化处理;在所述第三图层中,对所述第三目标部位进行锐化处理,得到第三美化结果;所述根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像,包括:将所述第一美化结果所属的第一图层、所述第二美化结果所属的第二图层与所述第三美化结果所属的第三图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层位 于所述第一图层的上方;将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述装置进一步用于:获取与所述目标部位匹配的掩模图像;根据所述掩模图像的灰度分布状态,确定所述目标美化结果与所述用户图像之间的融合强度;根据所述融合强度,将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
在一种可能的实现方式中,所述目标部位包括人脸部位,所述美化操作包括磨皮操作。
根据本公开的一方面,提供了一种电子设备,包括:处理器;用于存储处理器可执行指令的存储器;其中,所述处理器被配置为:执行上述图像处理方法。
根据本公开的一方面,提供了一种计算机可读存储介质,其上存储有计算机程序指令,所述计算机程序指令被处理器执行时实现上述图像处理方法。
根据本公开的一方面,提供了一种计算机程序产品,包括计算机可读代码,或者承载有计算机可读代码的非易失性计算机可读存储介质,当所述计算机可读代码在电子设备的处理器中运行时,所述电子设备中的处理器执行用于实现上述图像处理方法。
在本公开实施例中,通过响应于针对用户图像的美化操作,确定用户图像中待进行美化的目标部位,从而根据目标部位的颜色信息进行第一美化处理得到第一美化结果,以及根据目标部位的纹理信息进行第二美化处理得到第二美化结果,继而根据第一美化结果和第二美化结果来生成对目标部位进行美化后的目标用户图像。通过上述过程,可以在对目标部位进行磨皮等美化处理的过程中,将颜色信息与纹理信息进行分离,可以在基于颜色信息进行磨皮等美化处理的同时,对目标部位的纹理信息进行较好地美化和保留,从而既可以提升对目标部位的美化效果,又可以通过纹理信息的处理提升美化效果的真实性,减少美化过度等情况的发生。
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,而非限制本公开。根据下面参考附图对示例性实施例的详细说明,本公开的其它特征及方面将变得清楚。
附图说明
此处的附图被并入说明书中并构成本说明书的一部分,这些附图示出了符合本公开的实施例,并与说明书一起用于说明本公开的技术方案。
图1示出根据本公开一实施例的图像处理方法的流程图。
图2示出根据本公开一实施例的图像处理方法的流程图。
图3示出根据本公开一实施例的图像处理方法的流程图。
图4示出根据本公开一实施例的图像处理方法的流程图。
图5示出根据本公开一实施例的图像处理装置的框图。
图6示出根据本公开实施例的一种电子设备的框图。
图7示出根据本公开实施例的一种电子设备的框图。
具体实施方式
以下将参考附图详细说明本公开的各种示例性实施例、特征和方面。附图中相同的附图标记表示功能相同或相似的元件。尽管在附图中示出了实施例的各种方面,但是除非特别指出,不必按比例绘制附图。
在这里专用的词“示例性”意为“用作例子、实施例或说明性”。这里作为“示例性”所说明的任何实施例不必解释为优于或好于其它实施例。
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中术语“至少一种”表示多种中的任意一种或多种中的至少两种的任意组合,例如,包括A、B、C中的至少一种,可以表示包括从A、B和C构成的集合中选择的任意一个或多个元素。
另外,为了更好地说明本公开,在下文的具体实施方式中给出了众多的具体细节。本领域技术人员应当理解,没有某些具体细节,本公开同样可以实施。在一些实例中,对于本领域技术人员熟知的方法、手段、元件和电路未作详细描述,以便于凸显本公开的主旨。
图1示出根据本公开一实施例的图像处理方法的流程图,该方法可以应用于图像处理装置或图像处理***等,图像处理装置可以为终端设备、服务器或者其他处理设备等。其中,终端设备可以为用户设备(User Equipment,UE)、移动设备、用户终端、终端、蜂窝电话、无绳电话、个人数字助理(Personal Digital Assistant,PDA)、手持设备、计算设备、车载设备、可穿戴设备等。在一个示例中,该图像处理方法可以应用于云端服务器或本地服务器,云端服务器可以为公有云服务器,也可以为私有云服务器,根据实际情况灵活选择即可。
在一些可能的实现方式中,该图像处理方法也可以通过处理器调用存储器中存储的计算机可读指令的方式来实现。
如图1所示,在一种可能的实现方式中,所述图像处理方法可以包括:
步骤S11,响应于针对用户图像的美化操作,确定用户图像中待进行美化的目标部位。
其中,用户图像可以是包含用户目标部位的任意图像,用户图像中可以包含一个或多个用户,也可以包含一个或多个用户的目标部位,其实现形式可以根据实际情况灵活决定,在本公开实施例中不做限制。
目标部位可以是用户图像中需要进行美化的任意部位,目标部位包含哪些部位,其实现形式同样可以根据美化操作的实际情况灵活决定,比如针对于磨皮操作的美化操作,目标部位可以是人脸部位,或是包含皮肤等区域的任意部位,比如手部部位、颈部部位或是肘部部位等;针对于雾面操作的美化操作,目标部位可以是采用雾面妆容的人脸部位或是雾面唇妆的唇部部位等。
美化操作,可以是对用户图像的目标部位进行美化处理的任意操作,比如磨皮操作或是雾面操作等操作。美化操作包含的操作内容可以根据实际情况灵活决定,不局限于下述各公开实施例。在一种可能的实现方式中,该美化操作可以包括指示对用户图像中用户的目标部位进行美化处理的操作;在一些可能的实现方式中,该美化操作还可以包括输入一种或多种参数等,比如美化强度参数等。
美化强度参数可以是用户输入的,对目标部位进行美化的强度等相关参数,该美化强度参数的实现形式可以根据对目标部位进行美化的具体实现过程所灵活决定,比如针对于磨皮操作,美化强度参数可以包含磨皮过程的模糊强度或锐化强度等,详见下述各公开实施例,在此先不做展开。
确定目标部位的方式在本公开实施例中不做限制,不局限于下述各公开实施例。在一种可能的实现方式中,可以对用户图像中目标部位的位置进行识别,确定目标部位在用户图像中的位置从而对目标部位的图像进行提取。其中,识别的方式在本公开实施例中不做限制,比如可以为关键点识别或是对面部部位整体进行直接识别。
步骤S12,根据目标部位的颜色信息,对目标部位进行第一美化处理,得到第一美化结果。
其中,颜色信息可以反映目标部位中的颜色分布情况,比如可以包括目标部位中的 像素点的像素值等,该目标部位中的像素点,可以是目标部位中包含的每一个像素点,也可以是目标部位中的部分像素点。
第一美化处理可以是基于颜色信息对目标部位进行的相关处理,其实现方式可以根据美化操作的类型灵活决定,比如对于磨皮操作,第一美化处理可以包括对目标部位中的像素点进行模糊处理,对于雾面操作,第一美化处理可以在对目标部位中的像素点进行模糊处理的同时,还可以改变目标部位中像素点的颜色值等。
第一美化处理的一些可能的实现方式可以详见下述各公开实施例,在此先不做展开。
步骤S13,根据目标部位的纹理信息,对目标部位进行第二美化处理,得到第二美化结果。
其中,纹理信息可以反映目标部位中的纹理细节,比如在目标部位为人脸部位的情况下,纹理信息可以包含人脸中的皮肤纹理,以及皮肤上包含的一些其他细节信息,比如皮肤上的斑点、痘印或是痣等信息。
第二美化处理可以是基于纹理信息对目标部位进行的相关处理,其实现方式也可以根据实际情况灵活决定,在一些可能的实现方式中,第二美化处理可以包括将目标部位的图像与第一美化处理结果之间的混合处理,在一些可能的实现方式中,第二美化处理也可以包括对目标部位的锐化处理等。
第二美化处理的一些可能的实现方式同样可以详见下述各公开实施例,在此先不做展开。
步骤S14,根据第一美化结果和第二美化结果,生成对目标部位进行美化后的目标用户图像。
其中,目标用户图像,可以是对用户图像的目标部位进行美化所得到的图像,生成目标用户图像的方式可以根据实际情况灵活决定,比如可以将第一美化结果和第二美化结果进行融合以得到目标用户图像,或是将第一美化结果、第二美化结果与用户图像进行融合以得到目标用户图像。在一些可能的实现方式中,第一美化结果和第二美化结果也可以分别属于不同的图层,在这种情况下,可以通过图层叠加以得到目标用户图像。
步骤S14的一些可能的实现方式可以详见下述各公开实施例,在此先不做展开。
在本公开实施例中,通过响应于针对用户图像的美化操作,确定用户图像中待进行美化的目标部位,从而根据目标部位的颜色信息进行第一美化处理得到第一美化结果,以及根据目标部位的纹理信息进行第二美化处理得到第二美化结果,继而根据第一美化结果和第二美化结果来生成对目标部位进行美化后的目标用户图像。通过上述过程,可以在对目标部位进行磨皮等美化处理的过程中,将颜色信息与纹理信息进行分离,可以在基于颜色信息进行磨皮等美化处理的同时,对目标部位的纹理信息进行较好地美化和保留,从而既可以提升对目标部位的美化效果,又可以通过纹理信息的处理提升美化效果的真实性,减少美化过度等情况的发生。
图2示出根据本公开一实施例的图像处理方法的流程图,如图所示,在一种可能的实现方式中,步骤S12可以包括:
步骤S121,将目标部位复制至第一图层,得到第一目标部位。
步骤S122,在第一图层中,对第一目标部位中像素点的颜色信息进行模糊处理,得到第一美化结果。
其中,第一图层可以是具有图像处理或编辑功能的任意图层,比如图像编辑软件(PS,Photoshop)中的编辑图层。在一种可能的实现方式中,目标部位可以位于原始图层,而第一图层可以位于该原始图层的上方。
将目标部位复制至第一图层,可以是将目标部位单独复制至第一图层,也可以是将包含目标部位的用户图像整体复制至第一图层。第一目标部位可以是目标部位在第一图 层中的部位图像。
对第一目标部位中像素点的颜色信息进行模糊处理,可以是对第一目标部位中每个像素点的颜色信息进行模糊处理,也可以是对其中部分像素点进行模糊处理,根据实际情况确定即可。
模糊处理的方式在本公开实施例中不做限制,任意具有模糊功能的处理方式均可应用在本公开实施例中。在一种可能的实现方式中,模糊处理可以包括高斯模糊。
其中,高斯模糊在对某个像素点进行处理的过程中,可以以该像素点为中心,根据该像素点目标范围内的像素点的像素值通过高斯函数进行处理,得到处理后的像素值,作为该像素点的高斯模糊结果。
高斯模糊中的目标范围,可以根据实际情况灵活设定,在本公开实施例中不做限制。在一种可能的实现方式中,美化操作可以通过用户输入的模糊参数,来确定高斯模糊的目标范围。在一个示例中,该目标范围可以为10~20个像素。
通过本公开实施例,可以通过将目标部位复制至第一图层,独立地对目标部位中的颜色信息进行模糊处理,既可以实现较好地第一美化,也便于对第一美化结果进行灵活地调节,提升美化的灵活性和效果。
在一种可能的实现方式中,还可以对第一图层执行“智能对象”的操作命令,该操作命令可以使得第一图层在不被破坏的基础上进行效果更改。
因此,在一种可能的实现方式中,在得到第一美化结果之后,本公开实施例提出的方法还可以包括:
保存得到第一美化结果的美化信息;
响应于第一美化处理中的撤销操作,根据美化信息,对第一美化结果进行撤销美化处理,得到第一目标部位。
其中,美化信息可以包括第一图层在执行美化处理的过程中所接受的操作命令和参数等信息,比如上述公开实施例中提到的模糊处理的指令以及模糊处理的目标范围等。
第一美化处理中的撤销操作,可以是撤销在得到第一美化结果的过程中,对第一目标部位执行的某个或某些操作,比如在对第一目标部位执行模糊处理得到第一美化对象以后,可以通过撤销操作,使得第一美化对象返回在模糊处理之前的图像状态。
由于保存了美化信息,因此在接收到撤销操作的情况下,可以基于该美化信息,对第一美化结果执行反向操作,从而得到撤销第一美化处理后的第一目标部位。
通过本公开实施例,可以通过保存美化信息,使得在对第一美化结果不满意的情况下,便于对第一美化处理的过程进行撤销,从而便于后续重新执行第一美化处理等操作,提升美化过程的灵活性,方便用户根据喜好对美化结果进行调整。
图3示出根据本公开一实施例的图像处理方法的流程图,如图所示,在一种可能的实现方式中,步骤S13可以包括:
步骤S131,将目标部位复制至第二图层,得到第二目标部位。
步骤S132,在第二图层中,对第二目标部位中的纹理信息进行混合处理,得到第二美化结果。
其中,第二图层的实现形式可以参考上述各公开实施例中第一图层的实现形式,在此不再赘述。在一种可能的实现方式中,由于纹理信息相对于颜色信息包含更多的细节,为了便于实现美化效果的更改,可以将第二图层设置在第一图层的上方。
将目标部位复制至第二图层的方式可以参考上述复制至第一图层的方式,在此不再赘述。第二目标部位可以是目标部位在第二图层中的部位图像。
对第二目标部位中的纹理信息进行混合处理,可以是基于第二目标部位本身的图像进行混合,也可以是将第二目标部位与第一美化结果进行混合等。步骤S132的一些可能的实现方式可以详见下述各公开实施例,在此先不做展开。
通过本公开实施例,可以通过将目标部位复制至位于第一图层上方的第二图层,并在第二图层中执行混合处理,一方面可以独立地对目标部位中的纹理信息进行混合处理,实现较好地第二美化且便于对第二美化结果进行灵活地调节,以提升美化的灵活性和效果;另一方面通过将第二图层设置于第一图层上方,可以更好地保留目标部位的纹理信息,进一步提升美化效果。
在一种可能的实现方式中,在第二图层中,对第二目标部位中的纹理信息进行混合处理,可以包括:
根据第一美化结果,对第二目标部位进行减去混合处理,得到中间第二美化结果;
根据第一美化结果,对中间第二美化结果进行亮光混合处理,得到第二美化结果。
其中,减去混合处理可以包括计算第二目标部位的颜色通道值与第一美化结果中的颜色通道值之间的差值,在一个示例中,减去混合处理可以通过将第二目标部位的RGB通道值与第一美化结果中的RGB通道值做差,来从第二目标部位中排除掉第一美化结果的相关信息,继而从第二目标部位中分离出纹理信息,作为中间第二美化结果。
在一个示例中,根据第一美化结果对第二目标部位进行减去混合处理的过程可以通过下述公式(1)进行表示:
C=[(A-B)/预设收缩值]+预设补偿值       (1)
其中,为中间第二美化结果,为第二目标部位,为第一美化结果,预设收缩值可以是预设的参数,预设收缩值越高,得到的中间第二美化结果将越暗,预设收缩值的具体数值可以根据实际情况灵活决定,在一个示例中可以在1.000~2.000之间。预设补偿值同样可以为预设的参数,用于进一步调节中间第二美化结果的亮度,在一个示例中,预设补偿值的数值可以在-255~+255之间,比如可以为128等。
在一些可能的实现方式中,预设收缩值和预设补偿值等均可以作为美化操作中的美化强度参数,根据用户的输入所确定,从而可以进一步提升美化的灵活性,得到符合用户需求的目标用户图像。
亮光混合处理可以包括通过相减、相乘和相除等计算方式,共同计算所得到的第二目标部位的颜色值与第一美化结果的颜色值之间的混合值,亮光混合处理可以通过将中间第二美化结果与第一美化结果进行混合,来增加或减小中间第二美化结果的对比度,继而实现对中间第二美化结果的颜色调节,由于中间第二美化结果主要保留了目标部位的纹理信息,因此通过亮光混合处理,可以实现对目标部位纹理信息的进一步调整,得到符合用户需求的第二美化结果。
通过本公开实施例,可以利用减去混合处理来从第二目标部位中分离出纹理信息,并通过亮光混合处理对纹理信息进行进一步调整,从而提升得到的第二美化结果的美化效果和真实程度,继而提升美化处理的整体性能。
在一种可能的实现方式中,本公开实施例提出的方法还可以包括:
将目标部位复制至第三图层,得到第三目标部位;
在第三图层中,对第三目标部位进行锐化处理,得到第三美化结果。
其中,第三图层的实现形式可以参考上述各公开实施例中第一图层和第二图层的实现形式,在此不再赘述。第三图层可以用于突出目标部位的纹理细节,因此,为了更多地对目标部位的纹理细节进行保留,可以将第三图层设置在第二图层的上方。
将目标部位复制至第三图层的方式可以参考上述复制至第一图层和第二图层的方式,在此不再赘述。第三目标部位可以是目标部位在第三图层中的部位图像。
对第三目标部位进行锐化处理,可以是对第三目标部位这一区域进行锐化处理,也可以是对整个第三图层进行锐化处理,根据实际情况灵活选择处理方式即可。锐化处理的具体方式在本公开实施例中不做限制,在一个示例中,可以在PS的编辑图层中,通过选中“高反差保留”这一操作来实现第三目标部位的锐化。高反差保留可以保留图像中 具有较高对比度的区域,比如人眼、嘴唇或是头发等轮廓部位,并将其余区域变为中性灰色。在一个示例中,还可以设置高反差保留的像素范围,以提升锐化效果,像素范围可以根据实际情况灵活设定,在一个示例中,可以设置高反差保留采用1像素的像素范围。在一个示例中,该高反差保留的像素范围也可以作为美化操作中的美化强度参数,根据用户的输入所确定,从而可以进一步提升美化的灵活性,得到符合用户需求的目标用户图像。
通过本公开实施例,可以通过将目标部位复制至位于第二图层上方的第三图层,并在第三图层中执行锐化处理,一方面可以进一步强化纹理信息,增强美化效果的细节;另一方面通过将第三图层设置于第二图层上方,可以更好地保留目标部位的纹理细节,进一步提升美化效果。
图4示出根据本公开一实施例的图像处理方法的流程图,如图所示,在一种可能的实现方式中,步骤S14可以包括:
步骤S141,将第一美化结果所属的第一图层与第二美化结果所属的第二图层进行叠加,得到目标美化结果。
步骤S142,将目标美化结果与用户图像进行融合,得到目标用户图像。
其中,第一图层和第二图层的实现形式可以参考上述各公开实施例,在此不再赘述。
将第一图层与第二图层进行叠加,其叠加的顺序可以根据第一图层和第二图层的位置关系所确定,在一种可能的实现方式中,由于第二图层可以位于第一图层的上方,因此可以在第一图层上叠加第二图层,以得到目标美化结果。
在一种可能的实现方式中,还可以将第一图层、第二图层和第三图层这三个图层进行叠加来得到目标美化结果,叠加的顺序同样可以根据图层间的位置关系决定,比如可以在第一图层上叠加第二图层后,再在第二图层上叠加第三图层,或是先在第二图层上叠加第三图层,再将叠加后的结果叠加到第一图层上等,根据实际情况灵活选择即可。
通过图层叠加,可以得到目标美化结果,该目标美化结果可以通过步骤S142来与用户图像进行融合,以得到目标用户图像。
其中,步骤S142的实现方式可以根据实际情况灵活决定,比如在用户图像属于原始图层的情况下,可以直接将目标美化结果叠加到原始图层上,来得到目标用户图像。步骤S142一些其他可能的实现方式可以参考下述各公开实施例,在此先不做展开。
在一种可能的实现方式中,步骤S142可以包括:
获取与目标部位匹配的掩模图像;
根据掩模图像的灰度分布状态,确定目标美化结果与用户图像之间的融合强度;
根据融合强度,将目标美化结果与用户图像进行融合,得到目标用户图像。
其中,掩模图像可以是形状与目标部位匹配的掩模图像(mask),随着目标部位的不同,掩模图像的实现形式也可以变化。在一个示例中,掩模图像可以为预设人脸掩模。
掩模图像中可以包含多个亮度的像素点,掩模图像中像素点的亮度值可以根据实际情况灵活决定,在一个示例中,掩模图像中像素点的亮度可以在0~255的范围以内。
掩模图像中像素点的亮度可以根据实际情况进行灵活设定,在一个示例中,该掩模图像中像素点的亮度也可以作为美化操作中的美化强度参数,根据用户的输入所确定,从而可以进一步提升美化的灵活性,得到符合用户需求的目标用户图像。
灰度分布状态可以是掩模图像中像素点的灰度值分布情况,不同亮度的像素点具有不同的灰度值,而灰度值可以根据预设的灰度-透明度对应关系,转换为透明度。灰度-透明度对应关系可以根据实际情况进行设定,在本公开实施例中不做限制。因此,根据掩模图像中像素点的灰度分布状态,可以确定像素点的透明度。
根据该透明度,可以作确定目标美化结果和用户图像二者各自的融合强度,即二者在融合过程中的权重,按照该融合强度,可以将目标美化结果与用户图像加权融合,从 而得到目标用户图像。举例来说,在一个示例中,在对人脸图像进行磨皮操作的过程中,眼睛部位的像素点不应产生磨皮效果,因此可以设置预设人脸掩模中位于眼睛位置的像素点的灰度为0,则将该灰度转换为透明度以后,可以确定目标美化结果在融合过程中的权重为0,而用户图像在融合过程中的权重为1,在这种情况下,目标美化结果将不对用户图像产生美化作用,因此该眼睛位置的像素点将不会产生磨皮效果,符合美化的要求。
通过本公开实施例,可以根据掩模图像中像素点的灰度分布状态,有效且批量地确定目标美化结果中不同像素点的融合强度,并基于该融合强度进一步对美化效果进行调整,一方面可以通过掩模图像批量地确定目标美化结果的融合强度,提升融合效率和便捷程度,另一方面可以进一步提升美化的灵活性,得到符合用户需求的目标用户图像。
图5示出根据本公开一实施例的图像处理装置的框图。如图所示,所述图像处理装置20可以包括:
确定模块21,用于响应于针对用户图像的美化操作,确定用户图像中待进行美化的目标部位。
第一美化模块22,用于根据目标部位的颜色信息,对目标部位进行第一美化处理,得到第一美化结果。
第二美化模块23,用于根据目标部位的纹理信息,对目标部位进行第二美化处理,得到第二美化结果。
生成模块24,用于根据第一美化结果和第二美化结果,生成对目标部位进行美化后的目标用户图像。
在一种可能的实现方式中,第一美化模块用于:将目标部位复制至第一图层,得到第一目标部位;在第一图层中,对第一目标部位中像素点的颜色信息进行模糊处理,得到第一美化结果。
在一种可能的实现方式中,在第一美化模块之后,装置还用于:保存得到第一美化结果的美化信息;响应于第一美化处理中的撤销操作,根据美化信息,对第一美化结果进行撤销美化处理,得到第一目标部位。
在一种可能的实现方式中,第二美化模块用于:将目标部位复制至第二图层,得到第二目标部位,其中,第二图层位于第一图层的上方,第一图层用于对目标部位进行第一美化处理;在第二图层中,对第二目标部位中的纹理信息进行混合处理,得到第二美化结果。
在一种可能的实现方式中,第二美化模块进一步用于:根据第一美化结果,对第二目标部位进行减去混合处理,得到中间第二美化结果;根据第一美化结果,对中间第二美化结果进行亮光混合处理,得到第二美化结果。
在一种可能的实现方式中,生成模块用于:将第一美化结果所属的第一图层与第二美化结果所属的第二图层进行叠加,得到目标美化结果;其中,第一图层用于对目标部位进行第一美化处理,第二图层用于对目标部位进行第二美化处理,第二图层位于第一图层的上方;将目标美化结果与用户图像进行融合,得到目标用户图像。
在一种可能的实现方式中,装置还用于:将目标部位复制至第三图层,得到第三目标部位,其中,第三图层位于第二图层的上方,第二图层用于对目标部位进行第二美化处理;在第三图层中,对第三目标部位进行锐化处理,得到第三美化结果;根据第一美化结果和第二美化结果,生成对目标部位进行美化后的目标用户图像,包括:将第一美化结果所属的第一图层、第二美化结果所属的第二图层与第三美化结果所属的第三图层进行叠加,得到目标美化结果;其中,第一图层用于对目标部位进行第一美化处理,第二图层位于第一图层的上方;将目标美化结果与用户图像进行融合,得到目标用户图像。
在一种可能的实现方式中,装置进一步用于:获取与目标部位匹配的掩模图像;根据掩模图像的灰度分布状态,确定目标美化结果与用户图像之间的融合强度;根据融合 强度,将目标美化结果与用户图像进行融合,得到目标用户图像。
在一种可能的实现方式中,目标部位包括人脸部位,美化操作包括磨皮操作。
本公开涉及增强现实领域,通过获取现实环境中的目标对象的图像信息,进而借助视觉相关算法实现对目标对象的相关特征、状态及属性进行检测或识别处理,从而得到与具体应用匹配的虚拟与现实相结合的AR效果。示例性的,目标对象可涉及与人体相关的脸部、肢体、手势、动作等,或者与物体相关的标识物、标志物,或者与场馆或场所相关的沙盘、展示区域或展示物品等。视觉相关算法可涉及视觉定位、SLAM、三维重建、图像注册、背景分割、对象的关键点提取及跟踪、对象的位姿或深度检测等。具体应用不仅可以涉及跟真实场景或物品相关的导览、导航、讲解、重建、虚拟效果叠加展示等交互场景,还可以涉及与人相关的特效处理,比如妆容美化、肢体美化、特效展示、虚拟模型展示等交互场景。可通过卷积神经网络,实现对目标对象的相关特征、状态及属性进行检测或识别处理。上述卷积神经网络是基于深度学习框架进行模型训练而得到的网络模型。
应用场景示例
本公开应用示例提出了一种图像处理方法,包括如下过程:
在PS的编辑界面中,对包含人脸图像的原始图层进行拷贝,得到拷贝后的第一图层、第二图层和第三图层,其中,第二图层位于第一图层上方,第三图层位于第二图层上方。
将第一图层转换为智能对象,以保护第一图层在进行效果更改的同时不被破坏。
对第一图层进行15像素范围的高斯模糊处理,以从人脸图像中分离出低频的颜色信息并对该颜色信息实现模糊处理,得到第一美化结果。
将第二图层中的RGB通道值与第一美化结果中的RGB通道值,通过减去混合的方式进行混合处理,以从第二图层中分离出高频的纹理信息,作为中间第二美化结果,再将中间第二美化结果与第一美化结果通过亮光混合的方式进行混合处理,实现对纹理信息的颜色调整,以得到第二美化结果。
对第三图层进行锐化处理,对人脸部位的纹理信息均实现锐化,有利于保留原始图层的真实的纹理细节。其中,锐化的方式可以为:在PS界面中依次选择“PS-滤镜-其他-高反差保留-1像素”,高反差保留的结果可以与高斯模糊的结果相反。
在本公开应用示例中,高斯模糊的像素范围与锐化的参数均可以更高,从而通过更改高斯模糊的像素范围来改变磨皮效果的强度,通过更改锐化的参数来增强纹理信息的细节。还可以结合预设人脸掩模来界定磨皮的区域,通过预设人脸掩模中的灰度分布状态来控制不同区域的磨皮强度。举例来说,可以生成一张具有亮度从最亮为255数值至最暗为0的预设人脸掩模。通过灰度-透明度对应关系,将预设人脸掩模中的灰度值映射为磨皮过程的融合强度。比如某个像素点属于眼睛区域,不应当做磨皮处理,则可以将该像素点的灰度设置为0,即不产生磨皮效果。
本公开应用示例中提出的图像处理方法,除了可以应用于对人脸部位进行磨皮以外,还可以扩展应用于其他部位的美化操作,比如颈部磨皮或是雾面唇妆等,随着美化操作类型的不同,本公开应用示例提出的图像处理方法可以相应的进行灵活扩展与改动。
可以理解,本公开提及的上述各个方法实施例,在不违背原理逻辑的情况下,均可以彼此相互结合形成结合后的实施例,限于篇幅,本公开不再赘述。
本领域技术人员可以理解,在具体实施方式的上述方法中,各步骤的撰写顺序并不意味着严格的执行顺序而对实施过程构成任何限定,各步骤的具体执行顺序应当以其功能和可能的内在逻辑确定。
本公开实施例还提出一种计算机可读存储介质,其上存储有计算机程序指令,所述计算机程序指令被处理器执行时实现上述方法。计算机可读存储介质可以是易失性计算机可读存储介质或非易失性计算机可读存储介质。
本公开实施例还提出一种电子设备,包括:处理器;用于存储处理器可执行指令的存储器;其中,所述处理器被配置为上述方法。
在实际应用中,上述存储器可以是易失性存储器(volatile memory),例如RAM;或者非易失性存储器(non-volatile memory),例如ROM,快闪存储器(flash memory),硬盘(Hard Disk Drive,HDD)或固态硬盘(Solid-State Drive,SSD);或者上述种类的存储器的组合,并向处理器提供指令和数据。
上述处理器可以为ASIC、DSP、DSPD、PLD、FPGA、CPU、控制器、微控制器、微处理器中的至少一种。可以理解地,对于不同的设备,用于实现上述处理器功能的电子器件还可以为其它,本公开实施例不作具体限定。
电子设备可以被提供为终端、服务器或其它形态的设备。
基于前述实施例相同的技术构思,本公开实施例还提供了一种计算机程序,该计算机程序被处理器执行时实现上述方法。
图6是根据本公开实施例的一种电子设备800的框图。例如,电子设备800可以是移动电话,计算机,数字广播终端,消息收发设备,游戏控制台,平板设备,医疗设备,健身设备,个人数字助理等终端。
参照图6,电子设备800可以包括以下一个或多个组件:处理组件802,存储器804,电源组件806,多媒体组件808,音频组件810,输入/输出(I/O)的接口812,传感器组件814,以及通信组件816。
处理组件802通常控制电子设备800的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件802可以包括一个或多个处理器820来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件802可以包括一个或多个模块,便于处理组件802和其他组件之间的交互。例如,处理组件802可以包括多媒体模块,以方便多媒体组件808和处理组件802之间的交互。
存储器804被配置为存储各种类型的数据以支持在电子设备800的操作。这些数据的示例包括用于在电子设备800上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器804可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。
电源组件806为电子设备800的各种组件提供电力。电源组件806可以包括电源管理***,一个或多个电源,及其他与为电子设备800生成、管理和分配电力相关联的组件。
多媒体组件808包括在所述电子设备800和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件808包括一个前置摄像头和/或后置摄像头。当电子设备800处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜***或具有焦距和光学变焦能力。
音频组件810被配置为输出和/或输入音频信号。例如,音频组件810包括一个麦克风(MIC),当电子设备800处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器804或经由通信组件816发送。在一些实施例中,音频组件810还包括一个扬声器,用于输 出音频信号。
I/O接口812为处理组件802和***接口模块之间提供接口,上述***接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。
传感器组件814包括一个或多个传感器,用于为电子设备800提供各个方面的状态评估。例如,传感器组件814可以检测到电子设备800的打开/关闭状态,组件的相对定位,例如所述组件为电子设备800的显示器和小键盘,传感器组件814还可以检测电子设备800或电子设备800一个组件的位置改变,用户与电子设备800接触的存在或不存在,电子设备800方位或加速/减速和电子设备800的温度变化。传感器组件814可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件814还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件814还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。
通信组件816被配置为便于电子设备800和其他设备之间有线或无线方式的通信。电子设备800可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件816经由广播信道接收来自外部广播管理***的广播信号或广播相关人员信息。在一个示例性实施例中,所述通信组件816还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。
在示例性实施例中,电子设备800可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。
在示例性实施例中,还提供了一种非易失性计算机可读存储介质,例如包括计算机程序指令的存储器804,上述计算机程序指令可由电子设备800的处理器820执行以完成上述方法。
图7是根据本公开实施例的一种电子设备1900的框图。例如,电子设备1900可以被提供为一服务器。参照图7,电子设备1900包括处理组件1922,其进一步包括一个或多个处理器,以及由存储器1932所代表的存储器资源,用于存储可由处理组件1922的执行的指令,例如应用程序。存储器1932中存储的应用程序可以包括一个或一个以上的每一个对应于一组指令的模块。此外,处理组件1922被配置为执行指令,以执行上述方法。
电子设备1900还可以包括一个电源组件1926被配置为执行电子设备1900的电源管理,一个有线或无线网络接口1950被配置为将电子设备1900连接到网络,和一个输入输出(I/O)接口1958。电子设备1900可以操作基于存储在存储器1932的操作***,例如Windows ServerTM,Mac OS XTM,UnixTM,LinuxTM,FreeBSDTM或类似。
在示例性实施例中,还提供了一种非易失性计算机可读存储介质,例如包括计算机程序指令的存储器1932,上述计算机程序指令可由电子设备1900的处理组件1922执行以完成上述方法。
本公开可以是***、方法和/或计算机程序产品。计算机程序产品可以包括计算机可读存储介质,其上载有用于使处理器实现本公开的各个方面的计算机可读程序指令。
计算机可读存储介质可以是可以保持和存储由指令执行设备使用的指令的有形设备。计算机可读存储介质例如可以是――但不限于――电存储设备、磁存储设备、光存储设备、电磁存储设备、半导体存储设备或者上述的任意合适的组合。计算机可读存储介质的更具体的例子(非穷举的列表)包括:便携式计算机盘、硬盘、随机存取存储器 (RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、静态随机存取存储器(SRAM)、便携式压缩盘只读存储器(CD-ROM)、数字多功能盘(DVD)、记忆棒、软盘、机械编码设备、例如其上存储有指令的打孔卡或凹槽内凸起结构、以及上述的任意合适的组合。这里所使用的计算机可读存储介质不被解释为瞬时信号本身,诸如无线电波或者其他自由传播的电磁波、通过波导或其他传输媒介传播的电磁波(例如,通过光纤电缆的光脉冲)、或者通过电线传输的电信号。
这里所描述的计算机可读程序指令可以从计算机可读存储介质下载到各个计算/处理设备,或者通过网络、例如因特网、局域网、广域网和/或无线网下载到外部计算机或外部存储设备。网络可以包括铜传输电缆、光纤传输、无线传输、路由器、防火墙、交换机、网关计算机和/或边缘服务器。每个计算/处理设备中的网络适配卡或者网络接口从网络接收计算机可读程序指令,并转发该计算机可读程序指令,以供存储在各个计算/处理设备中的计算机可读存储介质中。
用于执行本公开操作的计算机程序指令可以是汇编指令、指令集架构(ISA)指令、机器指令、机器相关指令、微代码、固件指令、状态设置数据、或者以一种或多种编程语言的任意组合编写的源代码或目标代码,所述编程语言包括面向对象的编程语言—诸如Smalltalk、C++等,以及常规的过程式编程语言—诸如“C”语言或类似的编程语言。计算机可读程序指令可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络—包括局域网(LAN)或广域网(WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。在一些实施例中,通过利用计算机可读程序指令的状态人员信息来个性化定制电子电路,例如可编程逻辑电路、现场可编程门阵列(FPGA)或可编程逻辑阵列(PLA),该电子电路可以执行计算机可读程序指令,从而实现本公开的各个方面。
这里参照根据本公开实施例的方法、装置(***)和计算机程序产品的流程图和/或框图描述了本公开的各个方面。应当理解,流程图和/或框图的每个方框以及流程图和/或框图中各方框的组合,都可以由计算机可读程序指令实现。
这些计算机可读程序指令可以提供给通用计算机、专用计算机或其它可编程数据处理装置的处理器,从而生产出一种机器,使得这些指令在通过计算机或其它可编程数据处理装置的处理器执行时,产生了实现流程图和/或框图中的一个或多个方框中规定的功能/动作的装置。也可以把这些计算机可读程序指令存储在计算机可读存储介质中,这些指令使得计算机、可编程数据处理装置和/或其他设备以特定方式工作,从而,存储有指令的计算机可读介质则包括一个制造品,其包括实现流程图和/或框图中的一个或多个方框中规定的功能/动作的各个方面的指令。
也可以把计算机可读程序指令加载到计算机、其它可编程数据处理装置、或其它设备上,使得在计算机、其它可编程数据处理装置或其它设备上执行一系列操作步骤,以产生计算机实现的过程,从而使得在计算机、其它可编程数据处理装置、或其它设备上执行的指令实现流程图和/或框图中的一个或多个方框中规定的功能/动作。
附图中的流程图和框图显示了根据本公开的多个实施例的***、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段或指令的一部分,所述模块、程序段或指令的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个连续的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执 行规定的功能或动作的专用的基于硬件的***来实现,或者可以用专用硬件与计算机指令的组合来实现。
以上已经描述了本公开的各实施例,上述说明是示例性的,并非穷尽性的,并且也不限于所披露的各实施例。在不偏离所说明的各实施例的范围和精神的情况下,对于本技术领域的普通技术人员来说许多修改和变更都是显而易见的。本文中所用术语的选择,旨在解释各实施例的原理、实际应用或对市场中的技术改进,或者使本技术领域的其它普通技术人员能理解本文披露的各实施例。

Claims (13)

  1. 一种图像处理方法,其特征在于,包括:
    响应于针对用户图像的美化操作,确定所述用户图像中待进行美化的目标部位;
    根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果;
    根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果;
    根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像。
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果,包括:
    将所述目标部位复制至第一图层,得到第一目标部位;
    在所述第一图层中,对所述第一目标部位中像素点的颜色信息进行模糊处理,得到第一美化结果。
  3. 根据权利要求2所述的方法,其特征在于,在得到第一美化结果之后,所述方法还包括:
    保存得到所述第一美化结果的美化信息;
    响应于所述第一美化处理中的撤销操作,根据所述美化信息,对所述第一美化结果进行撤销美化处理,得到所述第一目标部位。
  4. 根据权利要求1至3中任意一项所述的方法,其特征在于,所述根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果,包括:
    将所述目标部位复制至第二图层,得到第二目标部位,其中,所述第二图层位于第一图层的上方,所述第一图层用于对所述目标部位进行第一美化处理;
    在所述第二图层中,对所述第二目标部位中的纹理信息进行混合处理,得到第二美化结果。
  5. 根据权利要求4所述的方法,其特征在于,所述在所述第二图层中,对所述第二目标部位中的纹理信息进行混合处理,得到第二美化结果,包括:
    根据所述第一美化结果,对所述第二目标部位进行减去混合处理,得到中间第二美化结果;
    根据所述第一美化结果,对所述中间第二美化结果进行亮光混合处理,得到所述第二美化结果。
  6. 根据权利要求1至5中任意一项所述的方法,其特征在于,所述根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像,包括:
    将所述第一美化结果所属的第一图层与所述第二美化结果所属的第二图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层用于对所述目标部位进行第二美化处理,所述第二图层位于所述第一图层的上方;
    将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
  7. 根据权利要求1至6中任意一项所述的方法,其特征在于,所述方法还包括:
    将所述目标部位复制至第三图层,得到第三目标部位,其中,所述第三图层位于第 二图层的上方,所述第二图层用于对所述目标部位进行第二美化处理;
    在所述第三图层中,对所述第三目标部位进行锐化处理,得到第三美化结果;
    所述根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像,包括:
    将所述第一美化结果所属的第一图层、所述第二美化结果所属的第二图层与所述第三美化结果所属的第三图层进行叠加,得到目标美化结果;其中,所述第一图层用于对所述目标部位进行第一美化处理,所述第二图层位于所述第一图层的上方;
    将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
  8. 根据权利要求6或7所述的方法,其特征在于,所述将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像,包括:
    获取与所述目标部位匹配的掩模图像;
    根据所述掩模图像的灰度分布状态,确定所述目标美化结果与所述用户图像之间的融合强度;
    根据所述融合强度,将所述目标美化结果与所述用户图像进行融合,得到所述目标用户图像。
  9. 根据权利要求1至8中任意一项所述的方法,其特征在于,所述目标部位包括人脸部位,所述美化操作包括磨皮操作。
  10. 一种图像处理装置,其特征在于,包括:
    确定模块,用于响应于针对用户图像的美化操作,确定所述用户图像中待进行美化的目标部位;
    第一美化模块,用于根据所述目标部位的颜色信息,对所述目标部位进行第一美化处理,得到第一美化结果;
    第二美化模块,用于根据所述目标部位的纹理信息,对所述目标部位进行第二美化处理,得到第二美化结果;
    生成模块,用于根据所述第一美化结果和所述第二美化结果,生成对所述目标部位进行美化后的目标用户图像。
  11. 一种电子设备,其特征在于,包括:
    处理器;
    用于存储处理器可执行指令的存储器;
    其中,所述处理器被配置为调用所述存储器存储的指令,以执行权利要求1至9中任意一项所述的方法。
  12. 一种计算机可读存储介质,其上存储有计算机程序指令,其特征在于,所述计算机程序指令被处理器执行时实现权利要求1至9中任意一项所述的方法。
  13. 一种计算机程序产品,包括计算机可读代码,或者承载有计算机可读代码的非易失性计算机可读存储介质,当所述计算机可读代码在电子设备的处理器中运行时,所述电子设备中的处理器执行用于实现权利要求1-9中的任一权利要求所述的方法。
PCT/CN2022/120275 2021-09-27 2022-09-21 图像处理方法及装置、电子设备和存储介质 WO2023045979A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111135696.5 2021-09-27
CN202111135696.5A CN113763285B (zh) 2021-09-27 2021-09-27 图像处理方法及装置、电子设备和存储介质

Publications (1)

Publication Number Publication Date
WO2023045979A1 true WO2023045979A1 (zh) 2023-03-30

Family

ID=78797823

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/120275 WO2023045979A1 (zh) 2021-09-27 2022-09-21 图像处理方法及装置、电子设备和存储介质

Country Status (2)

Country Link
CN (1) CN113763285B (zh)
WO (1) WO2023045979A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113763285B (zh) * 2021-09-27 2024-06-11 北京市商汤科技开发有限公司 图像处理方法及装置、电子设备和存储介质
CN115953313A (zh) * 2022-12-23 2023-04-11 百度在线网络技术(北京)有限公司 用于处理图像的方法,装置,设备以及存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011065339A (ja) * 2009-09-16 2011-03-31 Pioneer Electronic Corp 画像処理装置、画像処理方法、画像処理プログラム、及び、記憶媒体
CN104282002A (zh) * 2014-09-22 2015-01-14 厦门美图网科技有限公司 一种数字图像的快速美容方法
CN107358241A (zh) * 2017-06-30 2017-11-17 广东欧珀移动通信有限公司 图像处理方法、装置、存储介质及电子设备
CN111080747A (zh) * 2019-12-26 2020-04-28 维沃移动通信有限公司 一种人脸图像处理方法及电子设备
CN113222844A (zh) * 2021-05-14 2021-08-06 上海绚显科技有限公司 一种图像美化方法、装置、电子设备及介质
CN113763285A (zh) * 2021-09-27 2021-12-07 北京市商汤科技开发有限公司 图像处理方法及装置、电子设备和存储介质

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3367509B2 (ja) * 1999-12-16 2003-01-14 株式会社セガ 画像生成方法及びこれを用いた画像生成装置
US10339685B2 (en) * 2014-02-23 2019-07-02 Northeastern University System for beauty, cosmetic, and fashion analysis
CN105354810B (zh) * 2015-12-07 2019-02-12 厦门美图之家科技有限公司 一种图像祛斑处理的方法、***及拍摄终端
CN108090876B (zh) * 2016-11-23 2020-09-04 北京金山云网络技术有限公司 一种图像处理方法及装置
CN106846281A (zh) * 2017-03-09 2017-06-13 广州四三九九信息科技有限公司 图像美化方法以及终端设备
CN108765273B (zh) * 2018-05-31 2021-03-09 Oppo广东移动通信有限公司 人脸拍照的虚拟整容方法和装置
CN111476735B (zh) * 2020-04-13 2023-04-28 厦门美图之家科技有限公司 人脸图像处理方法、装置、计算机设备及可读存储介质
CN112150393A (zh) * 2020-10-12 2020-12-29 深圳数联天下智能科技有限公司 人脸图像磨皮方法、装置、计算机设备及存储介质
CN112435197A (zh) * 2020-12-02 2021-03-02 携程计算机技术(上海)有限公司 图像美化方法、装置、电子设备和存储介质
CN112766204A (zh) * 2021-01-26 2021-05-07 京东方科技集团股份有限公司 图像处理方法、装置及计算机可读存储介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011065339A (ja) * 2009-09-16 2011-03-31 Pioneer Electronic Corp 画像処理装置、画像処理方法、画像処理プログラム、及び、記憶媒体
CN104282002A (zh) * 2014-09-22 2015-01-14 厦门美图网科技有限公司 一种数字图像的快速美容方法
CN107358241A (zh) * 2017-06-30 2017-11-17 广东欧珀移动通信有限公司 图像处理方法、装置、存储介质及电子设备
CN111080747A (zh) * 2019-12-26 2020-04-28 维沃移动通信有限公司 一种人脸图像处理方法及电子设备
CN113222844A (zh) * 2021-05-14 2021-08-06 上海绚显科技有限公司 一种图像美化方法、装置、电子设备及介质
CN113763285A (zh) * 2021-09-27 2021-12-07 北京市商汤科技开发有限公司 图像处理方法及装置、电子设备和存储介质

Also Published As

Publication number Publication date
CN113763285B (zh) 2024-06-11
CN113763285A (zh) 2021-12-07

Similar Documents

Publication Publication Date Title
CN110675310B (zh) 视频处理方法、装置、电子设备及存储介质
WO2023045979A1 (zh) 图像处理方法及装置、电子设备和存储介质
CN110929651B (zh) 图像处理方法、装置、电子设备及存储介质
WO2022179026A1 (zh) 图像处理方法及装置、电子设备和存储介质
WO2022179025A1 (zh) 图像处理方法及装置、电子设备和存储介质
WO2023045941A1 (zh) 图像处理方法及装置、电子设备和存储介质
CN113160094A (zh) 图像处理方法及装置、电子设备和存储介质
CN112767288B (zh) 图像处理方法及装置、电子设备和存储介质
WO2023142645A1 (zh) 图像处理方法、装置、电子设备、存储介质和计算机程序产品
CN111091610B (zh) 图像处理方法及装置、电子设备和存储介质
CN113570581A (zh) 图像处理方法及装置、电子设备和存储介质
CN113822798B (zh) 生成对抗网络训练方法及装置、电子设备和存储介质
WO2023121898A1 (en) Real-time upper-body garment exchange
CN115205172A (zh) 图像处理方法及装置、电子设备和存储介质
WO2023045946A1 (zh) 图像处理方法及装置、电子设备和存储介质
WO2023045950A1 (zh) 图像处理方法及装置、电子设备和存储介质
CN114067085A (zh) 一种虚拟对象的显示方法及装置、电子设备和存储介质
WO2023045961A1 (zh) 虚拟对象的生成方法及装置、电子设备和存储介质
CN111131692B (zh) 用于使用机器学习创建增强现实自摄像的方法和***
CN113570583B (zh) 图像处理方法及装置、电子设备和存储介质
CN116320597A (zh) 直播图像帧处理方法、装置、设备、可读存储介质及产品
WO2023121897A1 (en) Real-time garment exchange
CN113763284B (zh) 图像处理方法及装置、电子设备和存储介质
CN113762212B (zh) 图像处理方法及装置、电子设备和存储介质
CN113763284A (zh) 图像处理方法及装置、电子设备和存储介质

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: 22872025

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE