Image copyright protection method based on beautified image, electronic equipment and medium

By clustering and beautifying image datasets, combined with feature extraction models and multi-objective optimization genetic algorithms, the problem of unauthorized editing of facial images by image editing models is solved, achieving effective image copyright protection.

CN120976044APending Publication Date: 2025-11-18ZHEJIANG UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510956446.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-11
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

Existing image editing models, especially for facial images, are prone to unauthorized editing and infringement of portrait rights, making it difficult for current technologies to effectively protect image copyrights.

Method used

By clustering the image dataset, the images are divided into several clusters. After beautification processing, a fitness function is constructed using a feature extraction model and a multi-objective optimization genetic algorithm to obtain the optimal solution set of beautification processing parameters, ensuring that the image is not distorted during editing and does not conform to the user's input editing instructions.

Benefits of technology

It effectively protects unauthorized images, prevents image editing models from producing images that match user-input editing instructions, improves the efficiency and accuracy of image protection, and strengthens user privacy and copyright protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120976044A_ABST
    Figure CN120976044A_ABST
Patent Text Reader

Abstract

The invention discloses an image copyright protection method based on a beautified image, electronic equipment and a medium, and the method comprises the steps: obtaining an image data set, carrying out the clustering, and dividing the image data set into a plurality of clusters; randomly selecting one original image S from one cluster to perform facial beautification processing to obtain a facial beautification image layer M, and recording facial beautification processing parameters; fusing the beautified image layer M and the original image S to obtain a beautified image A; applying an editing instruction I to the original image S and the beautified image A to obtain a first image IS and a second image IA; extracting features of each image, constructing a fitness function based on the features and the facial beautification processing parameters, and obtaining an initial facial beautification processing parameter optimal solution set Yk for the original image S based on multi-objective optimization inheritance according to the fitness function; and performing intra-cluster generalization, multi-editing instruction generalization and cross-cluster generalization to obtain an optimal solution set Yfinall of the general facial beautification processing parameters.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application belongs to the technical field of computers, and particularly relates to an image copyright protection method based on a beautified image, an electronic device and a medium. BACKGROUND

[0002] The diffusion model is an advanced machine learning algorithm, and in the field of image generation, the diffusion model has the same ability as other generation models GAN and VAE to generate target data samples from noise. The difference is that the diffusion model divides the generation process into two stages. First, by adding random noise to the data, the stage is called the forward diffusion process of the diffusion model, which is a process of gradually increasing the complexity of the data. Subsequently, the inverse operation of recovering the original high-quality data from the data sample full of noise is called the reverse diffusion process of the diffusion model.

[0003] Due to the powerful image generation capability of the diffusion model, the diffusion model is applied to the field of image editing. Early image editing models are traditionally targeted at a single editing task, such as style conversion or object addition. And most methods are to invert the image or encode the image into the latent space, and manipulate the latent vector in the latent space to realize the operation of editing the image. Now, there are models that use CLIP embedding to guide image editing using text, and there are pre-trained text-to-image diffusion models for image editing, further improving the level of models in the field of image editing. However, targeted editing using these models still has deficiencies, because in most cases, it cannot be guaranteed that similar text prompts will produce similar images. But through the later proposed Prompt-to-Prompt method, the generated image is assimilated into a similar text prompt, thereby solving the problem. Subsequently, editing research based on text labels, input / output image titles or descriptions is proposed.

[0004] Compared with these methods, the latest image editing model combines the knowledge of two large pre-trained models-language model and diffusion model, and does not require users to provide additional information, such as example images or descriptions of visual content that remain unchanged between input and output images. By giving an input image and telling the conditional diffusion model what kind of editing operation instruction it needs to do, it can generate an edited image.

[0005] With the increasing maturity of image editing technology based on conditional diffusion models, problems in the field of image editing have also arisen. Due to the powerful editing capability of the model, they can easily edit the target image to obtain the required edited image, which also includes unauthorized images, especially unauthorized face images. For image copyright owners, this to some extent infringes their portrait rights. SUMMARY

[0006] In view of the deficiencies in the prior art, the present application provides an image copyright protection method based on a beauty image, an electronic device and a medium.

[0007] In a first aspect, the present application provides an image copyright protection method based on a beauty image, the method comprising the following steps:

[0008] Obtaining an image dataset; clustering the image dataset to divide the image dataset into a plurality of clusters;

[0009] Randomly selecting an original image S from any one of the divided clusters to perform beauty processing to obtain a beauty image layer M and record the beauty processing parameters; performing fusion operation on the beauty image layer M and the original image S to obtain a beauty image A;

[0010] Obtaining an editing instruction I; inputting the original image S and the editing instruction I into an image editing model to obtain a first image IS; inputting the beauty image A and the editing instruction I into the image editing model to obtain a second image IA;

[0011] Inputting the first image IS, the second image IA, the original image S and the beauty image A into a feature extraction model to obtain the features corresponding to each image; constructing an fitness function based on all the features and the beauty processing parameters, and obtaining a first beauty processing parameter optimal solution set Y k based on the fitness function and multi-objective optimization genetic algorithm for the original image S;

[0012] The first beauty processing parameter optimal solution set Y k is used to test each image in the current cluster to update the beauty processing parameter optimal solution set to obtain a second beauty processing parameter optimal solution set Y k ’;

[0013] The second beauty processing parameter optimal solution set Y k ’ is combined with the remaining editing instructions except the editing instruction I to test the original image S to update the beauty processing parameter optimal solution set to obtain a third beauty processing parameter optimal solution set Y k ”;

[0014] The third beauty processing parameter optimal solution set Y k ” is used to test the images of other clusters, and each cluster is traversed to obtain a universal beauty processing parameter optimal solution set Y finall .

[0015] In a second aspect, the present application provides an electronic device, comprising:

[0016] At least one processor; and

[0017] A memory in communication with the at least one processor; wherein

[0018] The memory stores one or more computer programs executable by the at least one processor, and the one or more computer programs are executed by the at least one processor to enable the at least one processor to perform the image copyright protection method based on the beautified image described above.

[0019] In a third aspect, the present application provides a computer readable storage medium having a computer program stored thereon, the computer program, when executed by a processor, implements the image copyright protection method based on the beautified image described above.

[0020] In a fourth aspect, the present application provides a computer program product comprising computer programs / instructions, which, when executed by a processor, implement the image copyright protection method based on the beautified image described above.

[0021] Compared with the prior art, the present application has the following beneficial effects:

[0022] The present application provides an image copyright protection method based on a beautified image, which obtains a beautified image by performing a beautifying operation on an original image to be protected, inputs the original image and the beautified image into an image editing model together with the same editing instruction, obtains the edited images of the two, and then uses a multi-objective optimization genetic algorithm to consider the differences between the beautified image and the original image before editing and the differences between the two after editing, and a universal beautifying processing parameter optimal solution set, so as to select a beautifying processing parameter that can beautify the original image to be protected without distortion and can make the editing result of the image editing model on the picture not comply with the editing instruction input by the user, so as to successfully protect the original image without authorization. BRIEF DESCRIPTION OF DRAWINGS

[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0024] Figure 1 The overall framework flowchart provided for the embodiments of the present application;

[0025] Figure 2 The image processing flowchart provided for the embodiments of the present application;

[0026] Figure 3 The optimization selection flowchart provided for the embodiments of the present application;

[0027] Figure 4 This is a schematic diagram of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0028] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0029] It should be noted that, unless otherwise specified, the features in the following embodiments and implementation methods can be combined with each other.

[0030] like Figure 1 As shown, this embodiment of the invention provides an image copyright protection method based on beautified images, the method comprising the following steps:

[0031] Step S1: Obtain the image dataset; perform clustering processing on the image dataset to divide the image dataset into several clusters.

[0032] Specifically, in this example, the image dataset used is the Columbia University Public Figures Face Database (PFFD), which contains over 58,000 facial images of approximately 200 celebrities captured in real-world online environments. It is characterized by highly natural variations in lighting, angle, and expression, and its core objective is to provide a standardized benchmark dataset for face recognition research, especially in unconstrained settings.

[0033] Furthermore, in this example, the DBSCAN clustering algorithm is used to process the features corresponding to each image, thereby dividing the PFFD dataset. DBSCAN is a density-based clustering algorithm that can discover clusters of arbitrary shapes and is robust to noise and outliers. Using the DBSCAN algorithm, this example divides the PFFD dataset into several clusters. Images within each cluster are similar in features, while images between different clusters show significant differences.

[0034] It should be noted that when processing the face image dataset, a core challenge is the differences between different images. These differences may be caused by factors such as shooting angle, lighting conditions, facial expressions, etc., and these factors may cause the algorithm to waste power when finding the optimal solution set for each image. Therefore, before performing specific processing at the image level, the clustering algorithm is selected in this example to divide the images in order to better manage and optimize the processing process. The clustering algorithm is an unsupervised learning method that divides input data points based on similarity measures between data. In the application scenario of this example, the clustering algorithm can divide the dataset into several clusters according to the similarity between images. The images in each cluster are relatively small in difference, while the images between different clusters have large differences. By this method, images with similar features can be gathered together to form a relatively independent data subset. In this way, when processing images in the same cluster, more attention can be paid to the common features of the images in the cluster, thereby avoiding the waste of power consumption caused by too large differences when processing different images. At the same time, using the clustering algorithm to divide the images also helps to optimize the power consumption of the scheme. Since the images are divided into multiple clusters, the images in each cluster have small differences, so when processing images in the same cluster, the search space of the multi-objective optimization genetic algorithm is also reduced. This means that the algorithm needs to traverse a smaller number of images when finding the optimal solution set, thereby reducing the complexity of the algorithm and reducing the consumption of power consumption.

[0035] Step S2, randomly selecting an original image S from any divided cluster for beautifying processing to obtain a beautifying image layer M, and recording the beautifying processing parameters; performing fusion operation on the beautifying image layer M and the original image S to obtain a beautifying image A.

[0036] Specifically, the process of beautifying the original image S includes:

[0037] The beautifying processing operation on the original image S includes bilateral filtering, sharpening, contrast adjustment, etc., thereby effectively improving the visual effect of the image and keeping it clear and natural. At the same time, the current beautifying processing parameters need to be recorded, denoted as a beautifying processing parameter list Y = [y1, y2, y3, y4, y5, y6, y7].

[0038] At the same time, attention should also be paid to maintaining the details and color balance of the image during the fusion operation of the beautifying image layer M and the original image S to ensure the quality of the fused image.

[0039] Step S3, obtaining an editing instruction I; inputting the original image S and the editing instruction I into an image editing model to obtain a first image IS; inputting the beautifying image A and the editing instruction I into the image editing model to obtain a second image IA.

[0040] Further, the editing instructions are numerous and it is difficult to determine the specific form of the instructions, but all editing operations can be classified into types, and in this example, the operations are classified into seven types: background change, global image change, style change, object deletion, object addition, local change, and color / texture change. Then, an optimal solution for the editing instructions of the seven types is found.

[0041] Specifically, as shown in the figure, in this example, one of the above-mentioned seven types of editing instructions I is randomly selected, the original image S and the editing instruction I are input into the image editing model in the form of a pair (S, I) to obtain a first image IS; and the beauty image A and the editing instruction I are input into the image editing model in the form of a pair (A, I) to obtain a second image IA. Figure 2

[0042] Step S4, input the first image IS, the second image IA, the original image S, and the beauty image A into the feature extraction model to obtain the features corresponding to each image; construct a fitness function based on all the features and the beauty processing parameters, and obtain a first beauty processing parameter optimal solution set Y for the original image S based on the fitness function and multi-objective optimization genetic algorithm. k .

[0043] Specifically, as shown in the figure, the step S4 includes the following sub-steps: Figure 3

[0044] Step S401, input the first image IS, the second image IA, the original image S, and the beauty image A into the feature extraction model respectively to obtain a first feature is corresponding to the first image IS, a second feature ia corresponding to the second image IA, a third feature s corresponding to the original image S, and a fourth feature a corresponding to the beauty image A.

[0045] Further, in this example, the feature extraction model uses a FaceNet network, which is a deep convolutional neural network that can accurately extract feature information of a face image after being trained with a large number of face images.

[0046] Step S402, construct a fitness function based on the first feature is, the second feature ia, the third feature s, the fourth feature a, and the beauty processing parameters, and the expression is as follows:

[0047]

[0048] It should be noted that in this example, the similarity between the third feature s and the fourth feature a is calculated as follows: Meanwhile, the difference between the original image S and the beauty image A is calculated as follows: ​​The improvement of the similarity P can enhance the probability of the image editing model failing to edit the beautified image A, but can easily cause the difference D between the processed beautified image A and the original image S to be too large, and thus distortion occurs. Therefore, under the premise of ensuring that the beautified image A is sufficiently protected and distortion is avoided, the effect that the image editing model cannot effectively edit the processed image is realized, and a multi-objective optimization genetic algorithm is used to process the problem, and the similarity P and the difference D are used to form a fitness function

[0049] In step S403, based on the multi-objective optimization genetic algorithm, the first beautified processing parameter optimal solution set Y for the original image S is obtained according to the fitness function k .

[0050] Specifically, the fitness score is calculated, and a non-dominated sorting algorithm is used for sorting operation. After sorting, it is judged whether the initial population meets the condition. If it meets the condition, the optimal solution set corresponding to the adversarial sample is output. If it does not meet the condition, selection, crossover and mutation operations are performed, and then a generation of sub-population is obtained. The parent and child generations are merged, and the merged population is quickly non-dominated sorted. The crowding degree of the population is calculated, and the appropriate individuals are selected to form a new parent generation, and one generation evolution is completed. After the evolution is completed, the new population of the next generation is used for the protection of the original image S, and the result after the image editing model processing is observed. If the result meets the termination condition, the iteration process is ended and the beautified processing parameter optimal solution set is output. If the result generated by the new population at this time still does not meet the requirement, the above evolution operation is continued to iterate until the termination condition is met.

[0051] In step S5, the first beautified processing parameter optimal solution set Y k is used to test each image in the current cluster to update the beautified processing parameter optimal solution set, and a second beautified processing parameter optimal solution set Y k is obtained.

[0052] It should be noted that the first beautified processing parameter optimal solution set Y k obtained in step S4 is a local optimal solution, and the following example needs to continue to solve the global optimal solution. The goal of the global optimal solution is to find an optimal beautified processing operation parameter that can ensure that no matter what type of editing instruction is applied to the unauthorized image, the image editing model cannot successfully edit. In other words, malicious users cannot always obtain the edited image they expect from the output of the image editing model.

[0053] In step S6, the second beautified processing parameter optimal solution set Y k is combined with the remaining editing instructions except the editing instruction I, and is used to test the original image S to update the beautified processing parameter optimal solution set, and a third beautified processing parameter optimal solution set Yk

[0054] Further, in this example, one editing instruction I' is randomly selected from the remaining editing instructions, and the original image S and the editing instruction I' are input into the image editing model to obtain a first image IS'; the beauty image A and the editing instruction I' are input into the image editing model to obtain a second image IA'. The features of the first image IS' and the second image IA' are extracted, and based on the features and the fitness function, the optimal solution set of the beauty processing parameters is solved and updated again, thereby obtaining a third optimal solution set Y of the beauty processing parameters. k

[0055] Specifically, in this example, the solution set of the beauty processing parameters obtained by the local optimal solution before is paired with the newly selected editing instruction I', and the local optimal solution operation is performed again. If the combination of the solution set of the beauty processing parameters and the newly selected editing instruction I' meets the requirement of the termination condition, i.e., the image editing model still cannot successfully perform editing, it can be considered that the solution set has certain global universality, and subsequent evolution operation is not required. However, if the combination of the solution set of the beauty processing parameters and the newly selected editing instruction I' does not meet the requirement of the termination condition, i.e., the image editing model can still successfully perform editing, the evolution operation needs to be repeated, and the solution set of the beauty processing parameters is continuously optimized until the termination condition is met. Through this series of iteration and optimization process, this example hopes to find a truly globally universal optimal solution set of the beauty processing parameters, thereby realizing effective protection of all types of editing instructions.

[0056] Step S6: traversing each cluster, inputting the third optimal solution set Y of the beauty processing parameters and the image of the cluster into the image editing model to obtain a new image. k finall

[0057] Further, the universal optimal solution set Y of the beauty processing parameters finall can make the image to be protected not only not distorted, but also make the editing result of the diffusion model on the image not meet the requirement of the editing instruction input by the user. At the same time, the universal optimal solution set Y of the beauty processing parameters finall is not only suitable for the current data set, but also has certain generalization ability and can be applied to other similar data sets and scenes.

[0058] ​​​​In summary, the present application provides an image copyright protection method based on beautified images, which obtains a beautified image by performing beautification operation on an original image to be protected, inputs the original image and the beautified image into an image editing model together with the same editing instruction, obtains the edited images of the two, and then uses a multi-objective optimization genetic algorithm to consider the differences between the beautified image and the original image before editing and the differences between the two after editing through intra-cluster generalization, multi-editing instruction generalization and cross-cluster generalization, and obtains a universal beautification processing parameter optimal solution set, so as to select a beautification processing parameter that can beautify the original image to be protected without distortion and can make the image editing model not meet the user's input editing instruction for the editing result of the image, so as to successfully protect the original image without authorization. At the same time, the universal beautification processing parameter optimal solution set can not only adapt to the feature changes of different face images, but also effectively cope with various potential image tampering and unauthorized use risks. Through the method, the present application not only improves the efficiency and accuracy of image protection, but also fundamentally strengthens the protection of user privacy and copyright.

[0059] Correspondingly, the present application also provides an electronic device, comprising: one or more processors; a memory for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the image copyright protection method based on beautified images as described above. As shown in Figure 4 The hardware structure diagram of the electronic device provided by the embodiment of the present application is shown in Figure 4 In addition to the processor, the memory and the network interface shown in the figure, any data processing capable device where the device is located in the embodiment usually includes other hardware according to the actual function of the any data processing capable device, which will not be described here.

[0060] Correspondingly, the application further provides a computer readable storage medium, which stores computer instructions, and the instructions are executed by a processor to implement the image copyright protection method based on the beautified image. The computer readable storage medium can be an internal storage unit of any device with data processing capability, such as a hard disk or a memory. The computer readable storage medium can also be an external storage device, such as a plug-in hard disk, a smart media card (SMC), an SD card, a flash card, etc. Further, the computer readable storage medium can include both the internal storage unit of any device with data processing capability and the external storage device. The computer readable storage medium is used to store the computer program and other programs and data required by the device with data processing capability, and can also be used to temporarily store data that has been output or will be output.

[0061] The above embodiments are only used to illustrate the design ideas and characteristics of the present application, and the purpose is to enable those skilled in the art to understand the present application and implement it, and the protection scope of the present application is not limited to the above embodiments. Therefore, any equivalent changes or modifications made according to the disclosed principles and design ideas of the present application are within the protection scope of the present application.

Claims

1. A method for protecting image copyright based on beautified images, characterized in that, The method includes the following steps: Obtain the image dataset; perform clustering on the image dataset to divide it into several clusters; Randomly select an original image S from any predefined cluster and perform beautification processing to obtain a beautification layer M, and record the beautification processing parameters; perform a fusion operation on the beautification layer M and the original image S to obtain the beautified image A; Obtain editing instruction I; input the original image S and editing instruction I into the image editing model to obtain the first image IS; input the beautified image A and editing instruction I into the image editing model to obtain the second image IA; The first image IS, the second image IA, the original image S, and the beautified image A are input into the feature extraction model to obtain the features corresponding to each image. A fitness function is constructed based on all features and beautification parameters. Based on the fitness function and multi-objective optimization genetic model, the optimal solution set Y for the first beautification parameters of the original image S is obtained. k ; The optimal solution set Y of the first beauty processing parameters k This is used to test each image in the current cluster to update the optimal solution set of beautification processing parameters, thus obtaining the second optimal solution set Y of beautification processing parameters. k '; The optimal solution set Y of the second beauty processing parameters k 'Combining all editing commands except for editing command I, the original image S is tested to update the optimal solution set of beautification processing parameters, resulting in the third optimal solution set of beautification processing parameters Y.' k ”; The optimal solution set Y of the third beauty processing parameters k "Images used to test other clusters are traversed to obtain the optimal solution set Y for general beautification processing parameters in each cluster." finall .

2. The image copyright protection method based on beautified images according to claim 1, characterized in that, The editing commands are selected from background change, global image change, style change, object deletion, object addition, local change, color and / or texture change.

3. The image copyright protection method based on beautified images according to claim 1, characterized in that, The image editing model used is InstructionPix2Pix.

4. The image copyright protection method based on beautified images according to claim 1, characterized in that, The beautification process includes bilateral filtering, sharpening, and contrast adjustment.

5. The image copyright protection method based on beautified images according to claim 1, characterized in that, The feature extraction model used is FaceNet.

6. The image copyright protection method based on beautified images according to claim 1, characterized in that, Based on the features and beautification parameters corresponding to the first image IS, the second image IA, the original image S, and the beautified image A, a fitness function is constructed, as follows: In the formula, is represents the first feature corresponding to the first image IS, ia represents the second feature corresponding to the second image IA, s represents the third feature corresponding to the original image S, a represents the fourth feature corresponding to the beautified image A, and Y... k This indicates the parameters for beauty enhancement.

7. The image copyright protection method based on beautified images according to claim 1, characterized in that, The optimal solution set of the general beautification processing parameters ensures that the original image S to be protected is not distorted after beautification processing, while also ensuring that the image editing model's editing results for the original image and the beautified image do not conform to the editing instructions.

8. An electronic device, characterized in that, include: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores one or more computer programs that can be executed by the at least one processor, and the one or more computer programs are executed by the at least one processor to enable the at least one processor to perform the image copyright protection method based on beautified images as described in any one of claims 1-7.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the image copyright protection method based on beautified images as described in any one of claims 1-7.

10. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instruction is executed by the processor, it implements the image copyright protection method based on beautified images as described in any one of claims 1-7.