Adversarial sample generation method based on invisible watermark and its application and storage medium

By embedding invisible watermarks in images and using discrete wavelet transform technology to generate adversarial samples, the problem of inability to add and extract disturbance information in the existing technology is solved, and the robustness and security of adversarial samples are achieved, which is suitable for artificial intelligence security. field of application.

CN114897095BActive Publication Date: 2024-10-22XIAMEN SIXIN INTERNET OF THINGS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210611169.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-31
Publication Date
2024-10-22
Estimated Expiration
2042-05-31

AI Technical Summary

Technical Problem

Existing technology cannot effectively add meaningful perturbation information to the original image, and the embedded perturbation information cannot be completely extracted, resulting in large distortion of the generated adversarial samples and cannot be applied in the field of artificial intelligence security.

Method used

Adopting an adversarial sample generation method based on invisible watermarks, through discrete wavelet transform technology in the frequency domain and basin hopping optimization algorithm, invisible watermarks are embedded as perturbation information, and the original image scaled size and watermark disruption are saved in the pixel channel of the adversarial sample. The random number seed and the random number seed scrambled by the original image are used to achieve the generation of adversarial samples and information extraction.

Benefits of technology

It achieves the embedding and extraction of invisible watermarks. The generated adversarial samples have good robustness and security and are difficult to detect by the human eye. They are suitable for copyright protection of adversarial samples and training of image classification models.

✦ Generated by Eureka AI based on patent content.
Patent Text Reader

Abstract

The present invention discloses an adversarial sample generation method based on invisible watermark, its application and storage medium. The scheme of the present invention is based on discrete wavelet transform technology and basin jumping optimization algorithm in frequency domain, and proposes a new adversarial sample method for realizing invisible watermark based on discrete wavelet transform and basin jumping algorithm. The method can be used to solve the problem of minimizing the confidence that the adversarial sample belongs to a specific category. During the execution of the method, the adversarial sample is generated by embedding the invisible watermark as disturbance information, wherein a certain pixel channel of the adversarial sample respectively stores the scaled size of the original image, the scrambled random number seed of the watermark, and the scrambled random number seed of the original image. In terms of invisible watermark information extraction, the scheme of the present invention can completely extract the entire watermark according to the information stored in a certain pixel channel of the adversarial sample, thereby realizing information extraction of the invisible watermark. The scheme can be applied to adversarial sample copyright protection, and has good security and robustness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to neural network training technology and artificial intelligence security fields, and in particular to an adversarial sample generation method based on invisible watermarks, and its application and storage medium. Background Art

[0002] Artificial intelligence security is currently a very popular research field, and adversarial samples are an important branch of artificial intelligence security. Traditional adversarial sample generation methods (single-pixel attack, boundary attack, point-by-point attack, etc.) mainly focus on artificially adding imperceptible perturbation information to the original image, but the perturbation information usually has no practical meaning, so it cannot be applied to the real world. In recent years, researchers have proposed new adversarial sample generation methods. They produce adversarial samples by adding meaningful perturbation information to the original image. Although the perturbation information they embed in the adversarial sample has practical significance, the adversarial samples generated based on their method are highly distorted, or the embedded perturbation information cannot be fully extracted. At present, the field of artificial intelligence security has not yet proposed a method to add meaningful perturbation information to the original image and enable the embedded perturbation to be fully extracted. Summary of the invention

[0003] In view of this, the purpose of the present invention is to propose an invisible watermark-based adversarial sample generation method and its application and storage medium, which are reliable in implementation and can completely extract disturbance information.

[0004] In order to achieve the above technical objectives, the technical solution adopted by the present invention is:

[0005] A method for generating adversarial samples based on invisible watermarks, comprising:

[0006] Obtain the original image to be processed, and generate adversarial samples by embedding invisible watermarks as perturbation information;

[0007] Among them, a certain pixel channel of the adversarial sample saves the scaled size of the original image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled.

[0008] As a possible implementation, further, a method of embedding an invisible watermark as disturbance information into the image to be processed is as follows:

[0009] S01, obtaining an original image to be processed, and determining that the original image to be embedded with a watermark is a digital image;

[0010] S02, converting the watermark of the digital image into binary;

[0011] S03. Conduct three adversarial attacks to generate adversarial samples. In the three adversarial attacks, the original image is scaled to a preset size multiple.

[0012] As a preferred implementation mode, preferably, during the first adversarial attack, the scaling size of the original image is set to 0.5-0.9, and during the second adversarial attack and the third adversarial attack, the scaling size of the original image is set to 10-10.1 and 0.35-12 respectively.

[0013] As a preferred implementation mode, preferably, S03 includes:

[0014] S031. The first adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled; embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack;

[0015] S032. Second adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack;

[0016] S033. The third adversarial attack: Find the specific scaling size of the host image, the random number seed of the scrambled watermark, and the random number seed of the scrambled original image, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack.

[0017] As a preferred implementation method, preferably, this solution also includes:

[0018] According to the scaled size of the original image saved in a certain pixel channel of the adversarial sample, the random number seed of the scrambled watermark and the random number seed of the scrambled original image, the watermark embedded in the adversarial sample is completely extracted to realize the information extraction of the invisible watermark.

[0019] The solution of the present invention formulates the problem as follows: the goal is to minimize the confidence that the adversarial sample belongs to a certain category, thereby fooling the deep classification model into classifying the image.

[0020] In the solution to the above problem, the solution of the present invention is based on the discrete wavelet transform technology in the frequency domain and the basin jumping optimization algorithm, and proposes a new adversarial sample method based on discrete wavelet transform and basin jumping algorithm to realize invisible watermarks. This method can be used to solve the problem of minimizing the confidence that the adversarial sample belongs to a specific category. During the execution of this method, an adversarial sample is generated by embedding an invisible watermark as perturbation information. During the execution, a certain pixel channel of the adversarial sample saves the scaled size of the original image, the scrambled random number seed of the watermark, and the scrambled random number seed of the original image.

[0021] In terms of invisible watermark information extraction, the scheme of the present invention can completely extract the entire watermark based on the information stored in a certain pixel channel of the adversarial sample, thereby realizing the information extraction of the invisible watermark;

[0022] Based on the above scheme, the present invention also provides a training method for an image classification model, which includes the above-mentioned adversarial sample generation method based on invisible watermark.

[0023] Based on the above scheme, the present invention also provides a computer-readable storage medium, characterized in that: the storage medium stores at least one instruction, at least one program, code set or instruction set, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by a processor to implement the above-mentioned adversarial sample generation method based on invisible watermark, or is loaded and executed by a processor to implement the above-mentioned image classification model training method.

[0024] Based on the above scheme, the present invention also provides an image copyright marking method, which includes the above-mentioned adversarial sample generation method based on invisible watermark.

[0025] By adopting the above technical solution, the present invention has the following beneficial effects compared with the prior art:

[0026] 1. The solution of the present invention can realize the embedding and extraction of invisible watermarks and can be applied to adversarial sample copyright protection.

[0027] 2. The scheme of the present invention has good invisibility. The direct difference between the adversarial sample and the original image is difficult to be detected by the human eye, and has a relatively good visual effect.

[0028] 3. The scheme of the present invention has good robustness. Compared with other traditional adversarial sample methods, the adversarial samples generated based on our method are more robust.

[0029] 4. The scheme of the present invention has good security. The adversarial samples generated based on our method are usually considered to be original images, thereby preventing the adversarial samples from being attacked and being safer. DETAILED DESCRIPTION

[0030] The present invention will be further described in detail below in conjunction with the embodiments. It is particularly noted that the following embodiments are only used to illustrate the present invention, but are not intended to limit the scope of the present invention. Similarly, the following embodiments are only partial embodiments of the present invention rather than all embodiments, and all other embodiments obtained by those of ordinary skill in the art without creative work are within the scope of protection of the present invention.

[0031] This embodiment provides a method for generating adversarial samples based on invisible watermarks, which includes:

[0032] Obtain the original image to be processed, and generate adversarial samples by embedding invisible watermarks as perturbation information;

[0033] Among them, a certain pixel channel of the adversarial sample saves the scaled size of the original image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled;

[0034] In this scheme, the method of embedding invisible watermark as disturbance information in the processed image is:

[0035] S01, obtaining an original image to be processed, and determining that the original image to be embedded with a watermark is a digital image;

[0036] S02, converting the watermark of the digital image into binary;

[0037] S03. Conduct three adversarial attacks to generate adversarial samples. In the three adversarial attacks, the original image is scaled to a preset size multiple.

[0038] Among them, during the first adversarial attack, the scaling size of the original image was set to 0.5-0.9, and during the second and third adversarial attacks, the scaling sizes of the original image were set to 10-10.1 and 0.35-12 respectively.

[0039] This solution S03 includes:

[0040] S031. The first adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled; embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack;

[0041] S032. Second adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack;

[0042] S033. The third adversarial attack: Find the specific scaling size of the host image, the random number seed of the scrambled watermark, and the random number seed of the scrambled original image, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack.

[0043] That is, in this scheme, the second and third adversarial attacks are the same as the first adversarial attack steps, which are to find the specific scaling size of the host image, the random number seed of the watermark, and the random number seed of the original image. The invisible watermark is embedded through the discrete wavelet transform technology to generate adversarial samples, and those adversarial samples are directly retained, and those non-adversarial samples are allowed to enter the next adversarial attack.

[0044] In terms of watermark information extraction, as a preferred implementation method, preferably, this solution also includes:

[0045] According to the scaled size of the original image saved in a certain pixel channel of the adversarial sample, the random number seed of the scrambled watermark and the random number seed of the scrambled original image, the watermark embedded in the adversarial sample is completely extracted to realize the information extraction of the invisible watermark.

[0046] Based on the above scheme, the scheme of this embodiment can be used in the training method of the image classification model, and the adversarial training samples are generated by the above-mentioned adversarial sample generation method based on invisible watermark.

[0047] In addition, the solution of this embodiment can also be used in a method for marking copyright of an image, which helps to mark copyright information of a digital image by generating an invisible but extractable watermark without affecting the visual effect of the digital image.

[0048] In addition, each function in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0049] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, server, or network device, etc.) or a processor (processor) to perform all or part of the steps of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0050] The above descriptions are only some embodiments of the present invention, and are not intended to limit the protection scope of the present invention. Any equivalent device or equivalent process transformation made using the contents of the present invention specification, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A method for generating adversarial samples based on invisible watermarks. It is characterized in that It includes: Obtain the original image to be processed, and generate adversarial samples by embedding invisible watermarks as perturbation information; Among them, a certain pixel channel of the adversarial sample saves the scaled size of the original image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled; The method of embedding invisible watermark as disturbance information into the processed image is: S01, obtaining an original image to be processed, and determining that the original image to be embedded with a watermark is a digital image; S02, converting the watermark of the digital image into binary; S03, performing three adversarial attacks to generate adversarial samples, wherein the original image is scaled to a preset size multiple in the three adversarial attacks; Among them, S03 includes: S031. The first adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled; embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack; S032. Second adversarial attack: Find the specific scaling size of the host image, the random number seed of the watermark scrambled, and the random number seed of the original image scrambled, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack; S033. The third adversarial attack: Find the specific scaling size of the host image, the random number seed of the scrambled watermark, and the random number seed of the scrambled original image, embed the invisible watermark through discrete wavelet transform technology to generate adversarial samples, directly retain the adversarial samples, and make the non-adversarial samples enter the next adversarial attack.

2. The method for generating adversarial samples based on invisible watermarks as claimed in claim 1, It is characterized in that In the first adversarial attack, the scaling size of the original image is set to 0.5-0.9, and in the second and third adversarial attacks, the scaling size of the original image is set to 10-10.1 and 0.35-12, respectively.

3. The method for generating adversarial samples based on invisible watermark according to claim 1 or 2, It is characterized in that It also includes: The watermark embedded in the adversarial sample is extracted according to the scaled size of the original image saved in a certain pixel channel of the adversarial sample, the random number seed of the watermark scrambled and the random number seed of the original image scrambled, thereby realizing the information extraction of the invisible watermark.

4. A training method for an image classification model, It is characterized in that It includes the invisible watermark-based adversarial sample generation method described in one of claims 1 to 3.

5. A computer-readable storage medium, Features: The storage medium stores at least one instruction, at least one program, code set or instruction set, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by the processor to implement the invisible watermark-based adversarial sample generation method as described in one of claims 1 to 3.

6. A computer-readable storage medium, Features: The storage medium stores at least one instruction, at least one program, code set or instruction set, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by the processor to implement the training method of the image classification model as described in claim 4.

7. A method for marking image copyright. Features: It includes the adversarial sample generation method based on invisible watermark as described in claim 3.