Image processing method and device, electronic equipment and storage medium
By utilizing noise feature information to adjust facial regions and change image label categories during image processing, facial images become untrainable, thus solving the problem of user privacy information leakage and improving security and device efficiency.
Patent Information
- Application Number
- CN202111277582.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-29
- Publication Date
- 2025-12-23
- Estimated Expiration
- 2041-10-29
AI Technical Summary
In existing technologies, user privacy information is easily leaked on social media platforms, and the increased number of user-defined blocking actions reduces device usage efficiency.
By acquiring facial regions from images and processing them using noise feature information, images with different label categories are generated. These untrainable images prevent the possibility of user facial information leakage. Adjustments are made using noise feature information to change the image label category, making the facial images untrainable in current technical models. This reduces the likelihood of user faces being automatically scanned and recognized, thus preventing the leakage of user facial information and further enhancing the security of user privacy information.
Without affecting human eye recognition, changing the image label category makes the face image untrainable, reducing the possibility of the user's face being automatically scanned and recognized, protecting user privacy information, and improving the security of user privacy information and the efficiency of device use.
Smart Images

Figure CN113920566B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application belongs to the technical field of image processing, and particularly relates to an image processing method, device, equipment and storage medium. BACKGROUND
[0002] With the development of electronic devices and Internet technology, users can share or browse information in the Internet through electronic devices. In this process, social platforms in the Internet can obtain user privacy information stored in the electronic devices. Therefore, how to reduce the leakage of user privacy information has become a problem to be solved.
[0003] In the prior art, a user can set the electronic device to intercept the information scanning behavior of a social platform. However, such a method cannot effectively prevent the leakage of user privacy information and will increase the operation of setting interception by the user and reduce the efficiency of using the electronic device by the user. SUMMARY
[0004] The embodiments of the present application provide an image processing method, device, equipment and storage medium, which can solve the problem of easy leakage of user privacy information in the prior art.
[0005] In a first aspect, the embodiments of the present application provide an image processing method, which can include:
[0006] obtaining a first image, the first image including a photographed object, a face of the photographed object corresponding to a first region in the first image;
[0007] processing the first region according to noise feature information to obtain a second image, the noise feature information being information of a face feature of an interference object, an image label category of the second image being different from an image label category of the first image.
[0008] In a second aspect, the embodiments of the present application provide an image processing method, which can include:
[0009] displaying a first interface including a shooting control and a preview screen in a case where a first input of a user to a first application program in an electronic device is received, the shooting control being a control for shooting a private image, the private image being an image including a face of a photographed object, the shooting control corresponding to noise feature information, the noise feature information being information of a face feature of an interference object;
[0010] generating a first image including a photographed object according to the preview screen in a case where a second input to the shooting control is received, a face of the photographed object corresponding to a first region in the first image;
[0011] According to the noise feature information, the first region is processed, a second image is generated and displayed, and an image label category of the second image is different from an image label category of the first image.
[0012] The second image is saved as a privacy image in the electronic device.
[0013] In a third aspect, an embodiment of the present application provides an image processing apparatus, which can include:
[0014] An acquisition module is configured to acquire a first image, the first image including a photographed object, a face of the photographed object corresponding to a first region in the first image.
[0015] A processing module is configured to process the first region according to noise feature information to obtain a second image, the noise feature information being information of a face feature of an interference object, and an image label category of the second image being different from an image label category of the first image.
[0016] In a fourth aspect, an embodiment of the present application provides an image processing apparatus, which can include:
[0017] A display module is configured to display a first interface including a photographing control and a preview picture in a case where a first input of a first application program in an electronic device is received, the photographing control being a control for photographing a privacy image, the privacy image being an image including a face of a photographed object, the photographing control corresponding to noise feature information, and the noise feature information being information of a face feature of an interference object.
[0018] A generation module is configured to generate a first image according to the preview picture in a case where a second input of the photographing control is received, the first image including a photographed object, a face of the photographed object corresponding to a first region in the first image.
[0019] The display module is further configured to process the first region according to the noise feature information, generate and display a second image, and an image label category of the second image being different from an image label category of the first image.
[0020] A storage module is configured to save the second image as a privacy image in the electronic device.
[0021] In a fifth aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory storing computer program instructions.
[0022] The processor implements the image processing method shown in any one of the embodiments of the first aspect and the second aspect when executing the computer program instructions.
[0023] In a sixth aspect, an embodiment of the present application provides a computer storage medium, and the computer storage medium stores computer program instructions. When the computer program instructions are executed by a processor, the image processing method shown in any one of the embodiments of the first aspect and the second aspect is implemented.
[0024] The image processing method, device, equipment and storage medium provided by the embodiments of the present application can adjust the region of the face of the photographed object in the first image through the noise feature information, so as to change the image label category of the first image without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, that is, cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and identification of the face of the user, preventing the face information of the user from being leaked, and protecting the privacy information of the user. In addition, the embodiments of the present application are applied to the electronic device end, that is, the possibility of leakage of user privacy information is controlled from the source of the user privacy information, and the security of the user privacy information is further improved. BRIEF DESCRIPTION OF DRAWINGS
[0025] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required to be used in the embodiments of the present application will be briefly introduced. Those skilled in the art can obtain other drawings according to these drawings without creating any creative labor.
[0026] Figure 1 is a schematic diagram of a user privacy information leakage process;
[0027] Figure 2 is a schematic diagram of an image processing architecture according to one embodiment of the image processing method provided by the present application;
[0028] Figure 3 is a schematic diagram of a display interface of an image processing method provided by the embodiments of the present application;
[0029] Figure 4 is a flowchart of an image processing method provided by the embodiments of the present application;
[0030] Figure 5 is a schematic diagram of a logical relationship of one embodiment of an image processing method provided by the embodiments of the present application;
[0031] Figure 6 is a flowchart of an image processing method in a photographing process provided by the embodiments of the present application;
[0032] Figure 7 is a schematic diagram of image training of one embodiment of an image processing method provided by the embodiments of the present application;
[0033] Figure 8Figure 1 is a display interface interaction diagram of an image processing method in a photographing process according to an embodiment of the present application;
[0034] Figure 9 Figure 2 is another display interface interaction diagram of an image processing method in a photographing process according to an embodiment of the present application;
[0035] Figure 10 Figure 3 is a structural schematic diagram of an image processing device according to an embodiment of the present application;
[0036] Figure 11 Figure 4 is another structural schematic diagram of an image processing device according to an embodiment of the present application;
[0037] Figure 12 Figure 5 is a structural schematic diagram of an image processing device according to an embodiment of the present application. DETAILED DESCRIPTION
[0038] The features and exemplary embodiments of various aspects of the present application will be described below in detail, in order to make the purpose, technical solutions and advantages of the present application more clear and apparent, the present application will be further described in detail below in combination with the drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain the present application, but not to limit the present application. For those skilled in the art, the present application can be implemented without some of these specific details. The following description of the embodiments is only to provide a better understanding of the present application by showing examples of the present application.
[0039] It should be noted that in this paper, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between the entities or operations. Moreover, the terms "include", "contain" or any other variants thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such process, method, article or device. Without more limitations, the elements defined by the statement "include" do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0040] At present, with the development of electronic equipment and Internet technology, such as Figure 1As shown, users can take pictures using electronic devices and share or store them on the internet. During this process, some social media platforms may acquire the information shared or stored by users. If the shared information includes private information such as facial images, it is highly likely that these images will be collected by various social media platforms, data providers, and operators as training samples for network models, leading to the leakage of user privacy information and infringing on users' privacy rights. Related technologies allow users to set up settings on their electronic devices to block information scanning behavior from social media platforms; however, this method is not effective in preventing the leakage of user privacy information and also increases the effort required for users to set up blocking, reducing the efficiency of using electronic devices.
[0041] To address the problems of the prior art, embodiments of this application provide an image processing method, apparatus, device, and storage medium. The following will describe in conjunction with the accompanying drawings. Figures 2 to 6 This application describes in detail the image processing methods, apparatus, server, and storage medium of the embodiments thereof. It should be noted that these embodiments are not intended to limit the scope of this application.
[0042] First, the image processing architecture of the image processing method provided in the embodiments of this application will be described, such as... Figure 2 As shown, the image processing architecture includes an electronic device 20, which may include a display screen, a camera assembly, and a processor. Here, the camera assembly may include at least one camera, such as at least one front-facing camera 221 and at least one rear-facing camera 222, which is used to capture image sequences. The processor may be a digital signal processing (DSP) chip or an image processor. Based on this, the processor can perform the image processing methods described in this embodiment on the image sequences captured by the camera assembly to obtain images for saving or uploading to the Internet.
[0043] Based on the above architecture, the image processing method provided in the embodiments of this application will be described in detail below using electronic device 20.
[0044] When a user wants to take an image or video using the electronic device 20, they can launch the first application in the electronic device 20, namely the camera application, such as the camera application provided by the operating system of the electronic device 20 or the shooting application provided by a third-party platform, to take the image or video required by the user. In this way, the optical information is transmitted to the corresponding sensor through the camera component, and then optimized by the image algorithm built into the processor, such as the image processing chip, to generate and display the image.
[0045] Based on this, such as Figure 3As shown, the electronic device 20 displays a first interface in a case where the electronic device 20 receives a user starting a first application in the electronic device 20, the first interface including a shooting control 31 and a preview screen 32, the shooting control 31 being a control for shooting a private image, the private image being an image including a face of a shooting object, the shooting control corresponding to noise feature information, the noise feature information being information interfering with a feature of a face of an object. Then, the electronic device 20 generates a first image including a shooting object according to the preview screen 32 in a case where the electronic device 20 receives a second input to the shooting control 31, a face of the shooting object corresponding to a first region in the first image, such as a region 33 where a face is located. Further, the electronic device 20 can process the first region according to the noise feature information to obtain a second image, an image label category of the second image being different from an image label category of the first image. Then, the second image can be saved to the electronic device 20 or shared to an Internet network through the electronic device 20 in a case where a user confirms storing the second image. It should be noted that the first image in the embodiments of the present application can be a photo or an image including a face of a shooting object in a video.
[0046] In this way, the region of the face of the shooting object in the first image can be adjusted according to the noise feature information, so that the image label category of the first image is changed without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, i.e., cannot be used as a training sample of the face image, reducing the possibility of automatic scanning and identification of the face of the user, preventing the user's face information from being leaked, and protecting the user's private information. In addition, the embodiments of the present application are applied to the electronic device end, i.e., control the possibility of user privacy leakage from the source of user private information, further improving the security of user private information. In addition, the image processing method of the embodiments of the present application can be applied in the scene of shooting an image by a user, so that the user does not need to increase the operation for setting information interception, and effectively prevents the user's private information from being leaked without the user's awareness, improving the efficiency of the user using the electronic device.
[0047] In addition, the image processing method provided by the embodiments of the present application can be applied not only to the electronic device, but also to the server and the cloud server, such as the server and the cloud server corresponding to the shooting application provided by the third party platform, the server corresponding to the social platform, and the server for storing user private information, so as to prevent the user's private information from being leaked and protect the interests of the platform and the user.
[0048] It should be noted that the image processing method provided in the embodiments of the present application can be applied to the above-mentioned scene of processing the captured image acquired in real time, and can also be applied to the scene of processing the image downloaded by the user, that is, the electronic device can process the first region according to the noise feature information when the first image is acquired, to obtain the second image, the image label category of the second image being different from the image label category of the first image. Then, the second image can be saved or shared to the Internet under the condition that the user confirms to store the second image. Of course, the image processing method provided in the embodiments of the present application can also be applied to any scene of processing the image in order to prevent the user privacy from being leaked.
[0049] Based on the above image processing architecture and application scenario, the image processing method provided in the embodiments of the present application will be described in detail below. Figure 4 The image processing method provided in the embodiments of the present application will be described in detail.
[0050] Figure 4 A flowchart of the image processing method provided in the embodiments of the present application.
[0051] As shown in the above-mentioned image processing architecture, the image processing method provided in the embodiments of the present application can be applied to the electronic device as shown in the above-mentioned application scenario. Figure 4 The image processing method provided in the embodiments of the present application can be applied to the electronic device as shown in the above-mentioned application scenario. Figure 2 The image processing method provided in the embodiments of the present application can include the following steps:
[0052] In step 410, a first image is acquired, the first image including a photographed object, the face of the photographed object corresponding to a first region in the first image. In step 420, the first region is processed according to noise feature information to obtain a second image, the noise feature information being information of a face feature of an interference object, the image label category of the second image being different from the image label category of the first image.
[0053] Therefore, the region of the face of the photographed object in the first image can be adjusted by the noise feature information, so that the image label category of the first image is changed without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, that is, cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and identification of the face of the user, preventing the face information of the user from being leaked, and protecting the privacy information of the user. In addition, the embodiments of the present application are applied to the electronic device end, that is, the possibility of user privacy leakage is controlled from the source of user privacy information, and the security of the user privacy information is further improved.
[0054] The above steps will be described in detail as follows:
[0055] Firstly, in relation to step 410, the first image in the embodiments of the present application can be a real scene photo of a person, or an image with a face of a person such as an image of an identity document.
[0056] In addition, the receiving user's photographing input in the embodiments of the present application can include receiving user's photographing video input, receiving user's photographing portrait image input, and by default, when receiving the user's photographing portrait image, the obtained first image will include the first region corresponding to the face of the photographed object, i.e., the portrait.
[0057] Then, step 420 is involved, which in one or more optional embodiments can include step 4201 and step 4202.
[0058] Step 4201: obtaining a face noise model corresponding to the photographed object, the face noise model including noise feature information, and the face noise model being obtained by adding face interference noise information to each sample in a face sample set.
[0059] It should be noted that in addition to being able to perform step 4201 after obtaining the first image, the face noise model corresponding to the photographed object can also be obtained when receiving the user's photographing portrait image input, so as to improve the speed of obtaining the second image.
[0060] Step 4202: inputting the first image into the face noise model to obtain the second image.
[0061] Further, the first image is input into the face noise model to obtain a noise interval corresponding to the first image in the face noise model;
[0062] The first noise feature information is selected from the noise interval, and the face feature of the photographed object in the first region is adjusted through the first noise feature information, and any noise feature information of the noise interval is added to the first region without affecting the recognition of the face of the photographed object by the human eye;
[0063] In a case where the adjusted face feature of the photographed object satisfies a preset processing condition, the second image is output from the face noise model.
[0064] Exemplarily, the first noise feature information can be superimposed with the first image to obtain the second image with a privacy protection function. Here, as shown in the figure, the second image in the embodiments of the present application can be an image that does not affect the recognition of the face of the photographed object in the image by the human eye, does not affect the clarity of the image, and is untrainable, so that the second image does not contribute to the current network model. Or, the second image can be a normal sample that does not affect the recognition of the face of the photographed object in the image by the human eye, nor the clarity of the image, but because the image processing method provided by the embodiments of the present application interferes with the image label category of the first image through the noise feature information, the second image cannot be recognized as a face image, so it cannot be used as a training sample of the face image in the current network model. Figure 5
[0065] It should be noted that the face noise model involved in the embodiments of the present application can include at least one of the following: a deep neural network (DNN), a convolutional neural network (CNN), a VGG (Visual Geometry Group Network), and a deep residual network (ResNet).
[0066] In another or more alternative embodiments, before obtaining the face noise model corresponding to the shooting object, i.e., before step 4201, the sample is selected to train the initial face noise model, and the specific steps are as follows:
[0067] Obtain a preset number of face image samples required for each round of training from the face sample set;
[0068] According to the gradient value of the last round of training, determine the noise interval;
[0069] According to the gradient value and the noise interval, determine the second noise feature information added to the face image sample, and the second noise feature information does not affect the recognition of the face region in the face image sample by the human eye after being added to the face image sample;
[0070] The face image sample with the added second noise feature information is used as a training sample to train the initial face noise model, and in the case that the initial face noise model meets the preset training condition, the face noise model is obtained.
[0071] Illustratively, according to the face sample set, the related parameters of the minimum training difference are applied to generate the noise interval. Wherein, the optimization of the initial face noise model can be that the gradient value and the loss function are limited in a small range in the case of minimizing the model classification loss function, so as to ensure that the image output by the trained face noise model is lossless in the human eye range.
[0072] It should be noted that the face sample set in the embodiments of the present application can be a face sample set generated based on the image of the shooting object, or a face sample set generated according to the image of other objects.
[0073] Further, the initial face noise model can be determined whether it meets the preset training condition by the following two ways.
[0074] The first way, i.e., before the step of obtaining the face noise model, can also include:
[0075] Obtain the first face image output by the initial face noise model of the last round;
[0076] inputting the first face image into the face discrimination network model to obtain a first image classification label of the first face image, and inputting the second face image into the face discrimination network model to obtain a second image classification label of the second face image, the second face image being a face image sample input by the initial face noise model in a previous round, and the second image classification label being a real classification result of the face image;
[0077] In a case where the first image classification label is different from the second image classification label, it is determined that the initial face noise model satisfies the preset training condition.
[0078] Exemplarily, in the process of training the initial face noise model, two network models, i.e., the initial face noise model and the face discrimination network model, can be provided in the embodiment of the present application. The initial face noise model is a network model for generating images, and the initial face noise model can adjust a user face in an image A to obtain an image B through noise feature information in the initial face noise model. The face discrimination network model is a network model for discriminating images, and the face discrimination network model is used to judge an image classification label of the image B. In this way, the image B is input into the face discrimination network model to obtain the image classification label A. At this time, if the image classification label of the image A is also the image classification label A, it indicates that the initial face noise model does not satisfy the preset training condition. Conversely, if the image classification label of the image A is the image classification label B, it indicates that the initial face noise model satisfies the preset training condition.
[0079] It should be noted that the initial face noise model in this embodiment can be a DNN model, i.e., the image and the image classification label pair noise feature information can be associated and trained, so as to improve the overall training effect.
[0080] Mode two, which is different from mode one, is that the condition for determining whether the initial face noise model satisfies the preset training condition can be further limited, i.e., the initial face noise model satisfying the preset training condition can be determined based on the mode one in combination with the following steps, and the specific steps include:
[0081] obtaining a probability value of the first face image being judged as a real face image;
[0082] In a case where the probability value is less than a preset probability value, it is determined that the initial face noise model satisfies the preset training condition.
[0083] For example, still taking the example in mode one, the face discrimination network model can also be used to determine the probability that image B is a real face image. Thus, image B is input into the face discrimination network model to obtain a probability value X that image B is a real face image. If X is 1, it means that image B is a real face image. If X is 0, it means that image B is not a real face image. The training process described above is to adjust the noise feature information in the initial face noise model to the first image, so as to obtain an image that is determined by the face discrimination network model as having no contribution to the model training or being unable to identify whether it includes a face. Thus, in the case that the probability value is less than 1 and tends to 0, such as less than 0.1, it is determined that the initial face noise model meets the preset training condition. Otherwise, in the case that the probability value is greater than or equal to 0.1, it is determined that the initial face noise model does not meet the preset training condition.
[0084] Therefore, the image processing method provided by the embodiment of the present application can adjust the first region in the first image by the extracted noise feature information, to obtain the second image, so that the second image does not contribute to the current network model, thereby protecting the privacy information of the photographed object in the first image. In addition, the face noise model trained in the above manner can effectively train the noise feature information in the initial face noise model, and the noise feature information adjusts the first image, so as to obtain an image that is determined by the face discrimination network model as having no contribution to the model training or being unable to identify whether it includes a face, while not affecting the human eye observation of the user on the second image, effectively improving the user experience.
[0085] It should be noted that the condition for triggering the execution of step 420 described above can be real-time processing, that is, after obtaining the real-time photographed image, step 420 is executed. Of course, in some scenarios, in order to avoid affecting the use efficiency of the electronic device, step 420 can also be triggered according to the arbitrary time selected by the user after the first image is selected as a privacy image, that is, the condition for triggering the execution of step 420 can also be selected by the user. Based on this, the step 420 can also include:
[0086] In the case that the fourth input of the user selecting the first image as a privacy image is received, a setting time interface is displayed;
[0087] The fifth input of the target time selected by the user in the setting time interface is received;
[0088] In response to the fifth input, in the case that the system time of the electronic device matches the target time, the first region is processed according to the noise feature information to obtain the second image.
[0089] In addition, based on the architecture described above, such as Figure 2 the embodiment of the present application combines Figure 6The image processing method provided in the embodiment of the present application is described in detail.
[0090] Figure 6 A flowchart of the image processing method in the photographing process provided in the embodiment of the present application is shown.
[0091] As shown in Figure 6 , the image processing method can be applied to an electronic device as shown in Figure 2 , and the image processing method can specifically include the following steps:
[0092] Step 610: In the case where a first input of a user to a first application program in the electronic device is received, a first interface is displayed, the first interface including a photographing control and a preview picture, the photographing control being a control for photographing a private image, the private image being an image including a face of a photographing object, the photographing control corresponding to noise feature information, the noise feature information being information interfering with a feature of a face of an object; Step 620: In the case where a second input to the photographing control is received, a first image is generated according to the preview picture, the first image including the photographing object, the face of the photographing object corresponding to a first region in the first image; Step 630: The first region is processed according to the noise feature information, a second image is generated and displayed, an image label category of the second image being different from an image label category of the first image; Step 640: The second image is saved as the private image in the electronic device.
[0093] Thus, the region of the face of the photographing object in the first image can be adjusted through the noise feature information, so as to change the image label category of the first image without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, i.e., cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and identification of the face of the user, preventing the face information of the user from being leaked, and protecting the private information of the user. In addition, the image processing method of the embodiment of the present application can be used in the scene of photographing an image by the user, so that the user does not need to increase the operation for setting information interception, and the user privacy information is effectively prevented from being leaked without the user's awareness, thereby improving the efficiency of the user in using the electronic device.
[0094] The above steps are described in detail as follows:
[0095] First, the step 630 can specifically include:
[0096] In the memory of the electronic device, the first region is processed through the noise feature information, and the second image is generated and displayed.
[0097] It should be noted that the noise feature information provided by the embodiments of the present application can be stored in the content of the electronic device, so that when the first region is processed by the noise feature information, the step of calling the noise feature information from other devices in the electronic device is reduced, and the speed of generating the second image is improved. Of course, in some embodiments, the noise feature information can also be stored in other positions of the electronic device, such as solid state storage.
[0098] Based on this, step 640 can specifically include:
[0099] In the case of receiving the input of the user determining to store the second image, the second image in the memory is sent to the solid state storage in the electronic device, and the second image is saved as a privacy image to the solid state storage.
[0100] In this way, the image processing method provided by the embodiments of the present application can encrypt the privacy region in the image before storing it in the solid state storage of the electronic device, effectively preventing the leakage of user privacy information without the user's awareness, and improving the user's efficiency of using the electronic device.
[0101] In order to better describe the image processing method provided by the embodiments of the present application, the following will be described in combination with Figures 7-9 The image processing method provided by the embodiments of the present application will be described in detail.
[0102] As Figure 7 indicated, taking the user shooting a privacy image through the electronic device as an example, that is, shooting a first image through the electronic device, then inputting the first image after shooting to a face noise model, then adjusting the first region including the face of the shooting object in the first image through the noise feature information in the face noise model, obtaining a second image, and storing the obtained second image, so that the image after human eye recognition processing is lossless, and the image after processing is not trainable in the current network model, so as to protect the user's face information.
[0103] Further, as Figure 8 indicated, in the case that the electronic device receives the first input of the user starting a first application program such as a camera application program, the shooting process is started, that is, a second interface 82 is displayed, and the second interface can include at least one shooting mode selection control and a preview picture 83, wherein the at least one shooting mode selection control can include a panoramic shooting mode selection control 84, a portrait shooting mode selection control 85, a video shooting mode selection control 86, and a beauty shooting mode selection control 87.
[0104] Then, as Figure 9As shown, in a case where the electronic device receives a user selection of the portrait shooting mode selection control 85, the first interface 90 is displayed while the face noise model is invoked, the first interface including a shooting control 91 for shooting a private image, a shooting control 92 for shooting a normal (i.e., non-private) image, and a preview image 93, the private image being an image including a face of a shooting subject, the shooting control for shooting a private image corresponding to noise feature information, the noise feature information being information interfering with a feature of the face of the subject.
[0105] Further, in a case where the electronic device receives a shooting control 92 for shooting a normal (i.e., non-private) image, a first image can be shot by a camera in the electronic device, and the first image is directly stored in a solid-state storage of the electronic device.
[0106] In a case of input of the shooting control 91 for shooting a private image, a first image including a face of a shooting subject is acquired according to the preview image, the first image including a first region corresponding to the face of the shooting subject. Then, the first image is transmitted to a memory in the electronic device, and in the memory, the first image is input to the face noise model, pixels of the first region are adjusted by the noise feature information in the face noise model so as to interfere with a feature of the face of the user, and a second image that is untrainable is output from the face noise model. In this way, in a case where the user confirms storage of the second image, the second image in the memory is transmitted to the solid-state storage of the electronic device, and the second image is stored in the solid-state storage, thereby completing a process of private processing of a shooting image in a shooting mode.
[0107] In this way, in the embodiments of the present application, the region of the face of the shooting subject in the first image can be adjusted by the noise feature information so as to change the image label category of the first image without affecting the recognition of the first image by the human eye, so that the face image is untrainable in the current network model, i.e., cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and recognition of the face of the user, preventing the face information of the user from being leaked, and thus protecting the private information of the user.
[0108] In addition, the embodiments of the present application are applied to the electronic device end, i.e., control the possibility of leakage of private information of the user from the source of the private information of the user, and further improve the security of the private information of the user.
[0109] In addition, the image processing method of the embodiments of the present application can be applied in a scenario of shooting an image by the user, thereby not requiring the user to increase an operation for setting information interception, effectively preventing leakage of private information of the user without awareness of the user, and improving the efficiency of the user in using the electronic device.
[0110] Based on the same inventive concept, the present application also provides an image processing apparatus. The specific embodiments are described in detail in combination with Figure 10 the foregoing description.
[0111] Figure 10 is a structural schematic diagram of an image processing apparatus provided in an embodiment of the present application.
[0112] In some embodiments of the present application, Figure 10 The apparatus shown can be provided in an electronic device as shown. Figure 2 The apparatus shown can be provided in an electronic device as shown.
[0113] As shown in the figure, Figure 10 The image processing apparatus 100 can specifically include:
[0114] The acquisition module 1001 is configured to acquire a first image, the first image including a photographed object, a face of the photographed object corresponding to a first region in the first image;
[0115] The processing module 1002 is configured to process the first region according to noise feature information to obtain a second image, the noise feature information being information of a face feature of an interference object, an image label category of the second image being different from an image label category of the first image.
[0116] In the embodiments of the present application, the region of the face of the photographed object in the first image can be adjusted through the noise feature information, so as to change the image label category of the first image without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, i.e., cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and identification of the user's face, preventing the user's face information from being leaked, and protecting the user's privacy information. In addition, the embodiments of the present application are applied to the electronic device end, i.e., control the possibility of user privacy leakage from the source of user privacy information, and further improve the security of user privacy information.
[0117] The image processing apparatus 100 in the embodiments of the present application will be described in detail below.
[0118] In one or more optional embodiments, the processing module 1002 can specifically be configured to acquire a face noise model corresponding to the photographed object, the face noise model including the noise feature information, the face noise model being trained by adding face interference noise information to each sample in a face sample set;
[0119] The first image is input to the face noise model to obtain the second image.
[0120] Further, the processing module 1002 can specifically be configured to input the first image to the face noise model to acquire a noise interval corresponding to the first image in the face noise model;
[0121] The first noise feature information is selected from the noise interval, and the face feature of the shooting object in the first region is adjusted through the first noise feature information. Any noise feature information of the noise interval is added to the first region, without affecting the recognition of the face of the shooting object by the human eye.
[0122] In a case where the adjusted face feature of the shooting object meets a preset processing condition, a second image is output from the face noise model.
[0123] In another or more optional embodiments, the image processing apparatus 100 can further include a first determination module and a training module; wherein,
[0124] The acquisition module 1001 can also be used to acquire a preset number of face image samples required for each round of training from the face sample set;
[0125] The first determination module is configured to determine a noise interval according to the gradient value of the last round of training, and determine second noise feature information added to the face image sample according to the gradient value and the noise interval. After the second noise feature information is added to the face image sample, the recognition of the face region in the face image sample by the human eye is not affected.
[0126] The training module is configured to train the initial face noise model by taking the face image sample to which the second noise feature information is added as a training sample, and obtain the face noise model in a case where the initial face noise model meets a preset training condition.
[0127] In yet another or more optional embodiments, the image processing apparatus 100 can further include a second determination module; wherein,
[0128] The acquisition module 1001 can also be used to acquire a first face image output by the initial face noise model of the last round;
[0129] The processing module 1002 can also be used to input the first face image into the face discrimination network model to obtain a first image classification label of the first face image, and input a second face image into the face discrimination network model to obtain a second image classification label of the second face image. The second face image is the face image sample input by the initial face noise model of the last round, and the second image classification label is the true classification result of the face image.
[0130] The second determination module is configured to determine that the initial face noise model meets the preset training condition in a case where the first image classification label is different from the second image classification label.
[0131] In still another or more optional embodiments, the image processing apparatus 100 can further include a third determination module; wherein,
[0132] The acquisition module 1001 can also be configured to acquire a probability value of the first face image being determined as a real face image.
[0133] The third determination module is configured to determine that the initial face noise model meets the preset training condition when the probability value is less than a preset probability value.
[0134] In still another or more optional embodiments, the image processing apparatus 100 can further include a display module and a receiving module, wherein,
[0135] The display module is configured to display a setting time interface when the first input of selecting the first image as the private image by the user is received.
[0136] The receiving module is configured to receive a second input of a target time selected by the user in the setting time interface.
[0137] The processing module 1002 can specifically be configured to, in response to the second input, perform processing on the first region according to the noise feature information to obtain a second image when the system time of the electronic device matches the target time.
[0138] In addition, the present application also provides an image processing apparatus. Specifically, the image processing apparatus is as shown in Figure 11 which will be described in detail.
[0139] Figure 11 FIG. 2 is a structural schematic diagram of the image processing apparatus according to an embodiment of the present application.
[0140] In some embodiments of the present application, Figure 11 the apparatus shown in Figure 2 may be arranged in an electronic device as shown in
[0141] As shown in Figure 11 , the image processing apparatus 110 can specifically include:
[0142] The display module 1101 is configured to display a first interface when a first input of a first application program in the electronic device by the user is received, the first interface including a shooting control and a preview picture, the shooting control being a control for shooting a private image, the private image being an image including a face of a shooting object, the shooting control corresponding to noise feature information, and the noise feature information being information interfering with a feature of a face of an object.
[0143] The generation module 1102 is configured to generate a first image according to the preview picture when a second input of the shooting control is received, the first image including a shooting object, and a face of the shooting object corresponding to a first region in the first image.
[0144] The display module 1101 is further configured to process the first region according to the noise feature information, and generate and display a second image, the image label category of the second image being different from the image label category of the first image.
[0145] The storage module 1103 is configured to save the second image as a private image in the electronic device.
[0146] The image processing apparatus 110 in the embodiments of the present application will be described in detail below.
[0147] In one or more optional embodiments, the display module 1101 is specifically configured to process the first region by using the noise feature information in the memory of the electronic device, and generate and display a second image.
[0148] Based on this, the storage module 1103 is specifically configured to, in the case that the input of determining to store the second image is received, send the second image in the memory to a solid-state storage in the electronic device, and save the second image as a private image in the solid-state storage.
[0149] In the embodiments of the present application, the region of the face of the photographed object in the first image can be adjusted by using the noise feature information, so as to change the image label category of the first image without affecting the identification of the first image by the human eye, so that the face image cannot be trained in the current network model, i.e., cannot be used as a training sample of the face image, thereby reducing the possibility of automatic scanning and identification of the user's face, preventing the user's face information from being leaked, and protecting the user's private information. In addition, the embodiments of the present application are applied to the electronic device end, i.e., control the possibility of user privacy leakage from the source of user private information, and further improve the security of user private information.
[0150] In addition, the image processing method of the embodiments of the present application can be applied in the scene of user photographing, so that the user does not need to increase the operation for setting information interception, and the user privacy information leakage is effectively prevented without the user's awareness, and the efficiency of the user using the electronic device is improved.
[0151] Based on the same inventive concept, the present application further provides an image processing device. The image processing device will be described in detail below in combination with Figure 12 the specific description.
[0152] Figure 12 FIG. 1 is a structural schematic diagram of an image processing device provided by an embodiment of the present application.
[0153] As Figure 12 shown, the image processing device can include at least one of the following: an electronic device, a server, involved in the embodiments of the present application. The image processing device can include a processor 1201 and a memory 1202 storing computer program instructions.
[0154] In particular, the processor 1201 can include a central processing unit (CPU), or an application-specific integrated circuit (ASIC), or can be configured to implement one or more integrated circuits that embody the embodiments of the present application.
[0155] The memory 1202 can include a mass storage for data or instructions. By way of example, and not limitation, the memory 1202 can include a hard disk drive (HDD), a floppy disk drive, flash memory, an optical disc (e.g., a compact disc (CD) or a digital versatile disc (DVD)), a tape drive, a universal serial bus (USB) drive, or a combination of two or more of these. Where appropriate, the memory 1202 can include removable or non-removable (or fixed) media, where appropriate. The memory 1202 can be internal or external to the integrated gateway disaster recovery device, as appropriate. In a particular embodiment, the memory 1202 is non-volatile solid-state memory. In a particular embodiment, the memory 1202 includes solid-state storage (SSS). Where appropriate, this SSS can be a masked-blank ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically alterable ROM (EAROM), or a flash memory or a combination of two or more of these. It is to be appreciated that the memory 1202 stores data and / or instructions that can be executed by the processor 1201.
[0156] The processor 1201 implements any of the image processing methods in the above embodiments by reading and executing computer program instructions stored in the memory 1202.
[0157] In one example, the image processing device can further include a communication interface 1203 and a bus 1210. As shown, the processor 1201, the memory 1202, and the communication interface 1203 are connected by the bus 1210 and complete communication among each other. Figure 12
[0158] The communication interface 1203 is mainly used to realize the communication between the modules, devices, units and / or equipment in the embodiments of the present application.
[0159] Bus 1210 includes hardware, software, or both, to couple components of the traffic control device to each other and to couple components to other components within the traffic control device. While bus 1210 is shown as a single bus, alternative embodiments include two or more buses. Although this application describes and illustrates a particular bus, this application contemplates any suitable bus or interconnect.
[0160] The data processing device can execute the image processing method in the embodiments of the present application, thereby realizing the image processing method and device described in combination Figures 1 to 10 with the image processing method in the embodiments of the present application.
[0161] In addition, in combination with the image processing method in the above embodiments, the embodiments of the present application can provide a computer readable storage medium to realize. The computer readable storage medium has computer program instructions stored thereon; the computer program instructions are executed by a processor to realize any one of the image processing methods in the above embodiments.
[0162] It needs to be clear that the present application is not limited to the specific configurations and processes described above and shown in the drawings. For the sake of brevity, detailed descriptions of well-known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between steps, after understanding the spirit of the present application.
[0163] The functional blocks shown in the above structural block diagrams can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application specific integrated circuits (ASICs), appropriate firmware, plug-ins, functional cards, and the like. When implemented in software, the elements of the present application are program or code segments that are used to perform the required tasks. The program or code segments can be stored in a machine-readable medium or transmitted through a data signal carried in a carrier wave over a transmission medium or communication link. A "machine-readable medium" includes any medium that can store or transport information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, and the like. The code segments can be downloaded via computer networks such as the Internet, intranets, and the like.
[0164] It should also be noted that the exemplary embodiments mentioned in the present application describe some methods or systems based on a series of steps or devices. However, the present application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiments, or in an order different from that in the embodiments, or several steps can be performed simultaneously.
[0165] The above is only a specific implementation of the present application, and those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described systems, modules and units can refer to the corresponding processes in the foregoing method embodiments, which will not be described here. It should be understood that the protection scope of the present application is not limited thereto, and any person skilled in the art can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements should be covered within the protection scope of the present application.
Claims
1. An image processing method comprising: obtaining a first image, the first image comprising a photographed object, a face of the photographed object corresponding to a first region in the first image; obtaining a face noise model corresponding to the photographed object, the face noise model comprising noise feature information, the face noise model being obtained by adding face interference noise information to each sample in a face sample set; inputting the first image into the face noise model to obtain a noise interval corresponding to the first image in the face noise model; selecting first noise feature information from the noise interval, and adjusting a face feature of the photographed object in the first region through the first noise feature information, any noise feature information in the noise interval being added to the first region without affecting human eye recognition of the face of the photographed object; in a case where the adjusted face feature of the photographed object satisfies a preset processing condition, outputting a second image from the face noise model, the noise feature information being information of an interference object face feature, an image label category of the second image being different from an image label category of the first image.
2. The method of claim 1, wherein, Before the obtaining of the face noise model corresponding to the photographed object, the method further comprises: obtaining a preset number of face image samples required for each round of training from a face sample set; determining a noise interval according to a gradient value of a last round of training; determining second noise feature information to be added to the face image samples according to the gradient value and the noise interval, the second noise feature information not affecting human eye recognition of a face region in the face image samples after being added to the face image samples; training an initial face noise model by taking the face image samples to which the second noise feature information is added as training samples, and obtaining the face noise model in a case where the initial face noise model satisfies a preset training condition.
3. The method of claim 2, wherein, Before the obtaining of the face noise model, the method further comprises: obtaining a first face image output by the initial face noise model in a last round; inputting the first face image into a face discrimination network model to obtain a first image classification label of the first face image, and inputting a second face image into the face discrimination network model to obtain a second image classification label of the second face image, the second face image being a face image sample input by the initial face noise model in a last round, and the second image classification label being a true classification result of the face image; in a case where the first image classification label is different from the second image classification label, determining that the initial face noise model satisfies a preset training condition.
4. The method of claim 3, wherein, Before the determining that the initial face noise model satisfies the preset training condition, the method further comprises: obtaining a probability value of the first face image being judged as a true face image; in a case where the probability value is less than a preset probability value, determining that the initial face noise model satisfies the preset training condition.
5. The method of claim 1, wherein, Before the inputting of the first image into the face noise model, the method further comprises: In a case where a first input of the user selecting the first image as a private image is received, a setting time interface is displayed; A second input of a target time selected by the user in the setting time interface is received; In response to the second input, in a case where a system time of the electronic device matches the target time, the first image is input to the face noise model.
6. An image processing method, comprising: In a case where a first input of a user to a first application in an electronic device is received, a first interface is displayed, the first interface including a shooting control and a preview screen, the shooting control being a control for shooting a private image, the private image being an image including a face of a shooting object, the shooting control corresponding to noise feature information, the noise feature information being information interfering with a feature of an object face; In a case where a second input to the shooting control is received, a first image is generated according to the preview screen, the first image including a shooting object, a face of the shooting object corresponding to a first region in the first image; The first image is input to a face noise model to obtain a noise interval corresponding to the first image in the face noise model; First noise feature information is selected from the noise interval, and a feature of the face of the shooting object in the first region is adjusted by the first noise feature information, any noise feature information of the noise interval being added to the first region without affecting the recognition of the face of the shooting object by the human eye; in a case where the adjusted feature of the face of the shooting object meets a preset processing condition, a second image is output from the face noise model and displayed, an image label category of the second image being different from an image label category of the first image, the face noise model being trained by adding face interference noise information to each sample in a face sample set; The second image is saved as a private image in the electronic device.
7. The method of claim 6, wherein, The first image is input to the face noise model to obtain a noise interval corresponding to the first image in the face noise model; first noise feature information is selected from the noise interval, and a feature of the face of the shooting object in the first region is adjusted by the first noise feature information, any noise feature information of the noise interval being added to the first region without affecting the recognition of the face of the shooting object by the human eye; In a case where the adjusted feature of the face of the shooting object meets a preset processing condition, a second image is output from the face noise model, comprising: In the memory of the electronic device, the first image is input to the face noise model to obtain a noise interval corresponding to the first image in the face noise model; first noise feature information is selected from the noise interval, and the face feature of the shooting object in the first region is adjusted through the first noise feature information, any noise feature information of the noise interval is added to the first region, and the recognition of the face of the shooting object by the human eye is not affected; in a case where the adjusted face feature of the shooting object satisfies a preset processing condition, a second image is output from the face noise model and the second image is displayed; The saving of the second image as a privacy image to the electronic device includes: In a case where an input of a user determining to store the second image is received, the second image in the memory is sent to a solid-state storage in the electronic device, and the second image is saved as a privacy image to the solid-state storage.
8. An image processing apparatus, the apparatus comprising: an obtaining module configured to obtain a first image, the first image comprising a shooting object, a face of the shooting object corresponding to a first region in the first image; a processing module configured to input the first image to a face noise model to obtain a noise interval corresponding to the first image in the face noise model; select first noise feature information from the noise interval, and adjust the face feature of the shooting object in the first region through the first noise feature information, any noise feature information of the noise interval being added to the first region without affecting the recognition of the face of the shooting object by the human eye; in a case where the adjusted face feature of the shooting object satisfies a preset processing condition, output a second image from the face noise model, the noise feature information being information of an interfering object face feature, an image label category of the second image being different from an image label category of the first image, and the face noise model being trained by adding face interference noise information to each sample in a human face sample set.
9. An image processing apparatus, comprising: a display module configured to, in a case where a first input of a user to a first application program in an electronic device is received, display a first interface, the first interface comprising a shooting control and a preview picture, the shooting control being a control for shooting a privacy image, the privacy image being an image comprising a face of a shooting object, the shooting control corresponding to noise feature information, the noise feature information being information of an interfering object face feature; a generation module configured to, in a case where a second input to the shooting control is received, generate a first image according to the preview picture, the first image comprising a shooting object, a face of the shooting object corresponding to a first region in the first image. The display module is further configured to input the first image into a face noise model, acquire a noise interval corresponding to the first image in the face noise model, select first noise feature information from the noise interval, and adjust a face feature of a shooting object in the first region through the first noise feature information, wherein any noise feature information of the noise interval is added to the first region without affecting the recognition of the face of the shooting object by a human eye; in a case where the adjusted face feature of the shooting object satisfies a preset processing condition, output a second image from the face noise model and display the second image, wherein an image label category of the second image is different from an image label category of the first image, and the face noise model is trained by adding face interference noise information to each sample in a face sample set; a storage module configured to save the second image as a private image in the electronic device.
10. An electronic device, the device comprising: a processor and a memory having computer program instructions stored therein; the processor executes the computer program instructions to implement the image processing method of any one of claims 1-5 or the image processing method of claim 6 or 7.
11. A storage medium having computer program instructions stored thereon, wherein the computer program instructions are executed by a processor to implement the image processing method of any one of claims 1-5 or the image processing method of claim 6 or 7.
Citation Information
Patent Citations
Image noise adding processing method and device
CN110648289A