CN113496449A - Data processing method and device, electronic equipment and storage equipment - Google Patents

Data processing method and device, electronic equipment and storage equipment Download PDF

Info

Publication number
CN113496449A
CN113496449A CN202010202490.9A CN202010202490A CN113496449A CN 113496449 A CN113496449 A CN 113496449A CN 202010202490 A CN202010202490 A CN 202010202490A CN 113496449 A CN113496449 A CN 113496449A
Authority
CN
China
Prior art keywords
carrier object
watermark
image
correlation
self
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010202490.9A
Other languages
Chinese (zh)
Inventor
刘永亮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN202010202490.9A priority Critical patent/CN113496449A/en
Publication of CN113496449A publication Critical patent/CN113496449A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/0021Image watermarking
    • G06T1/005Robust watermarking, e.g. average attack or collusion attack resistant
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2201/00General purpose image data processing
    • G06T2201/005Image watermarking
    • G06T2201/0065Extraction of an embedded watermark; Reliable detection

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Editing Of Facsimile Originals (AREA)
  • Image Processing (AREA)

Abstract

The application discloses a data processing method, which comprises the following steps: obtaining a carrier object and target watermark information; embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information; obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information; and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation. By adopting the method, the problem that the watermark cannot be effectively extracted when the image is subjected to the geometric attack of small-angle rotation in the prior art is solved.

Description

Data processing method and device, electronic equipment and storage equipment
Technical Field
The present application relates to the field of computer technologies, and in particular, to two data processing methods and apparatuses, an electronic device, and a storage device.
Background
With the rapid development of the internet, the information propagation speed is far higher than that of any past period. Digital images are a common information carrier, and are widely applied today in the digital information era. But digital images are easy to spread, copy and tamper, and the problems of difficult definition of image copyright attribution, anti-counterfeiting and anti-tampering still exist in practical application. To this end, researchers have proposed digital image watermarking techniques. The digital image watermarking technology is to embed some identification information into the digital image without influencing the use value of the original carrier. The information hidden in the image can achieve the purposes of confirming an image creator and a purchaser, transmitting secret information, judging whether the image is falsified and the like. Digital image watermarking is an effective method for protecting digital image safety, realizing anti-counterfeiting tracing and copyright protection, and is an important branch and research direction in the field of information hiding technology research.
Images, when propagated, are subject to geometric attacks such as rotation, scaling, translation, tiling, compression, and the like. Under these geometric attacks, watermarks embedded in digital images are at risk of failure. Due to the wide existence of the attack mode, if the problems caused by the spread mode cannot be solved in time, great troubles are brought to the copyright protection of the image.
The existing digital image watermarking technology is only suitable for embedding and extracting the watermark under the condition that the image is subjected to geometric attack of large-angle rotation, and when the image is subjected to geometric attack of small-angle rotation, the embedded watermark cannot be effectively extracted by adopting the existing scheme.
Disclosure of Invention
The application provides a data processing method, a data processing device, an electronic device and a storage device, and aims to solve the problem that watermarks cannot be effectively extracted when an image is subjected to geometric attack of small-angle rotation.
The application provides a data processing method, which comprises the following steps:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
Optionally, the embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain coefficient of the carrier object;
embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength;
and carrying out inverse transformation processing on the frequency domain coefficient embedded with the target watermark information to obtain a carrier object containing the target watermark information.
Optionally, the transforming the carrier object from the space domain to the frequency domain to obtain the frequency domain coefficient of the carrier object includes:
carrying out Fourier transform on the carrier object to obtain Fourier coefficients of the carrier object;
the embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength includes:
and embedding the target watermark information into an amplitude value of a Fourier coefficient of the carrier object according to the current embedding strength.
Optionally, the parameter for characterizing the extracted watermark effect is obtained by:
calculating the autocorrelation of the carrier object containing the target watermark information under the current watermark embedding strength to obtain an autocorrelation image;
and obtaining parameters for representing the extracted watermark effect according to the detectable autocorrelation peak of the autocorrelation image and the correlation peak template.
Optionally, the parameter for characterizing the watermark hiding effect is a structural similarity between the carrier object before embedding the watermark and the carrier object containing the target watermark information.
Optionally, the preset relationship is:
the value of the parameter characterizing the extracted watermark effect is larger than the value of the parameter characterizing the watermark hiding effect.
Optionally, the updating the current watermark embedding strength includes:
and adding a preset step length to the current watermark embedding strength to serve as the updated current watermark embedding strength.
The present application further provides a data processing method, including:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
Optionally, the obtaining the rotation angle and the scaling factor of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining a rotation angle and a scaling coefficient of the carrier object;
and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak.
Optionally, the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and judging whether the correlation between the self-synchronized self-correlation image and the correlation peak template meets a preset correlation relationship, and if so, taking a phase correlation peak corresponding to the self-synchronized self-correlation image as a target phase correlation peak.
Optionally, the correlation between the self-correlation image after self-synchronization and the correlation peak template is: a weighted cross-correlation between phase cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template and spatial cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template.
Optionally, the preset correlation relationship is:
the difference between the weighted cross-correlation and a preset constant is less than a preset difference threshold.
Optionally, the method further includes:
sharpening the self-synchronized self-correlation image to obtain a sharpened self-synchronized self-correlation image;
the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and obtaining a target phase correlation peak according to the correlation between the self-correlation image after the self-synchronization and the correlation peak template after the sharpening.
Optionally, the method further includes:
and obtaining an autocorrelation image of the carrier object according to the carrier object.
Optionally, the obtaining an autocorrelation peak image of the carrier object according to the carrier object includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain signal of the carrier object;
and filtering the frequency domain signal of the carrier object to obtain an autocorrelation image of the carrier object.
Optionally, the method further includes:
carrying out noise removal processing on the autocorrelation image of the carrier object to obtain an autocorrelation image with noise removed;
the obtaining a phase correlation peak according to the autocorrelation image of the carrier object and the correlation peak template includes:
obtaining a phase correlation peak according to the autocorrelation image after the noise is removed and the correlation peak template;
the obtaining of the autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object includes:
and obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image after the noise is removed and the phase correlation peak.
Optionally, the obtaining the autocorrelation image after the self-synchronization according to the autocorrelation image after the noise removal and the phase correlation peak includes:
calculating a rotation angle and a scaling coefficient of an autocorrelation image of the carrier object according to the phase correlation peak;
and carrying out rotation and scaling processing on the autocorrelation image of the carrier object according to the rotation angle and the scaling coefficient to obtain the autocorrelation image after self-synchronization.
The present application also provides a data processing apparatus, comprising:
an information obtaining unit, configured to obtain a carrier object and target watermark information;
the target watermark information embedding unit is used for embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
a parameter relation obtaining unit, configured to obtain, according to the carrier object containing the target watermark information, a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect;
and the current watermark embedding strength updating unit is used for updating the current watermark embedding strength when the relation does not meet the preset relation until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
The present application further provides an electronic device, comprising:
a processor;
a memory for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
The present application also provides a storage device storing a program of a data processing method, the program being executed by a processor to perform the steps of:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
The present application also provides a data processing apparatus, comprising:
a carrier object obtaining unit for obtaining a carrier object containing watermark information;
the after-self-synchronization autocorrelation image obtaining unit is used for obtaining an after-self-synchronization autocorrelation image according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
a rotation angle and scaling coefficient obtaining unit, configured to obtain a rotation angle and a scaling coefficient of the carrier object according to a correlation between the self-correlation image after self-synchronization and the correlation peak template;
and the watermark information extraction unit is used for extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
The present application further provides an electronic device, comprising:
a processor;
a memory for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
The present application also provides a storage device storing a program of a data processing method, the program being executed by a processor to perform the steps of:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
Compared with the prior art, the method has the following advantages:
the application provides a data processing method, after embedding target watermark information into a carrier object according to the current watermark embedding strength, obtaining the relation between a parameter for representing the watermark hiding effect and a parameter for representing the extracted watermark effect; when the relation does not meet the preset relation, the current watermark embedding strength is updated, the new current watermark embedding strength is adopted, then the target watermark information is embedded into the carrier object, the carrier object containing the target watermark information is obtained, the relation between the two parameters is calculated again until the embedding of the target watermark information is completed when the preset relation is met, and because the parameters for representing the watermark hiding effect and the parameters for representing the extracted watermark effect reach a certain balance after the watermark is embedded, the watermark can be effectively extracted even if the carrier object is subjected to geometric attack of small-angle rotation.
The application also provides a data processing method, which is used for obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template; obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and a preset correlation peak template; and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient. When the method obtains the rotation angle and the scaling factor of the carrier object, the method can obtain the accurate rotation angle and the scaling factor due to the consideration of the correlation between the self-correlation image after self-synchronization and the preset correlation peak template, and further can effectively extract the watermark information.
In the preferred scheme, a target phase correlation peak is obtained according to the correlation between the self-correlation image after self-synchronization and a preset correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining the rotation angle and the scaling factor of the carrier object; and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak. In the above scheme, when the target phase correlation peak is obtained, the correlation between the self-synchronized autocorrelation image and the preset correlation peak template is considered, so that the obtained target phase correlation peak can accurately reflect the rotation angle and the scaling coefficient of the carrier object.
Drawings
Fig. 1 is a flowchart of a data processing method according to a first embodiment of the present application.
Fig. 2 is a schematic diagram of a watermark tiling mode provided in the first embodiment of the present application.
Fig. 3 is a flowchart of a data processing method according to a second embodiment of the present application.
Fig. 4 is a schematic diagram of a phase correlation peak according to a second embodiment of the present application.
Fig. 5 is a schematic diagram of a convex hull mask of a synchronized autocorrelation peak image and a predetermined correlation peak template according to a second embodiment of the present application.
Fig. 6 is a schematic diagram of a data processing apparatus according to a third embodiment of the present application.
Fig. 7 is a schematic diagram of an electronic device according to a fourth embodiment of the present application.
Fig. 8 is a schematic diagram of a data processing apparatus according to a sixth embodiment of the present application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present invention. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein, but rather construed as limited to the embodiments set forth herein.
A first embodiment of the present application provides a data processing method, which is applied to a watermark embedding end, and is described below with reference to fig. 1 and fig. 2.
As shown in fig. 1, in step S101, a carrier object and target watermark information are obtained.
The carrier object refers to a carrier image or a carrier video to be embedded with the target watermark information. The carrier image may be a dynamic image or a static image, for example, the image may be a dynamic image in a format of gif (graphics Interchange format), or may also be a static image in a format of jpeg (joint Photographic Experts group). For example, when a copyright owner of an image needs to distribute a content to a plurality of partners, different watermarks need to be embedded so as to trace from which partner the image flows when piracy occurs, and the image is a carrier object. In addition, the carrier video may be a physical video file, for example, the carrier video is a video file stored in a remote server for local download and play; the streaming media can also be in a streaming media (streaming media) form, for example, a carrier video is a video stream which is provided by an online video-on-demand platform or an online live platform and can be directly streamed; in addition, the carrier video may be video in AR, VR, etc. form, or stereo video, and of course, as technology advances, the carrier video may also be video in other formats and other forms related to video, and is not limited herein.
The target watermark information refers to extra information added in the carrier object. The target watermark information may be a bit sequence of a predetermined number of bits. For example, copyright information is added to the carrier object as a watermark, which can prevent piracy.
As shown in fig. 1, in step S102, the target watermark information is embedded into the carrier object according to the current watermark embedding strength, so as to obtain the carrier object containing the target watermark information.
The embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain coefficient of the carrier object;
embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength;
and carrying out inverse transformation processing on the frequency domain coefficient embedded with the target watermark information to obtain a carrier object containing the target watermark information.
The transforming the carrier object from the space domain to the frequency domain to obtain the frequency domain coefficients of the carrier object includes:
carrying out Fourier transform on the carrier object to obtain Fourier coefficients of the carrier object;
the embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength includes:
and embedding the target watermark information into an amplitude value of a Fourier coefficient of the carrier object according to the current embedding strength.
The following describes a specific process of embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information, with reference to an example:
firstly, performing discrete fourier transform on a carrier object, generating a watermark signal according to target watermark information, modulating the watermark signal to form a rectangular watermark block with the size of 128x100, and embedding the rectangular watermark block in an 8x8 area which is symmetrical about the center of a frequency domain in a tiled mode, as shown in fig. 2. The watermark signal may be embedded in amplitude values of fourier coefficients according to equation (1).
Re{F′(u,v)}=Re{F(u,v)}+α(u,v)W(u,v) (1)
Wherein, Re { F (u, v) } represents the carrier video/image fourier amplitude spectrum before embedding the watermark signal, Re { F' (u, v) } represents the carrier video/image fourier amplitude spectrum after embedding the watermark signal, W (u, v) is the watermark signal, and α (u, v) represents the watermark embedding strength. And after watermark embedding is completed, combining the phase of Fourier transform, and performing inverse transform to obtain a carrier video/image containing the watermark.
As shown in fig. 1, in step S103, a relationship between a parameter for characterizing a watermark hiding effect and a parameter for characterizing an extracted watermark effect is obtained according to the carrier object containing the target watermark information.
The parameter for characterizing the extracted watermark effect may be obtained by:
calculating the autocorrelation of the carrier object containing the target watermark information under the current watermark embedding strength to obtain an autocorrelation image;
and obtaining parameters for representing the extracted watermark effect according to the detectable autocorrelation peak of the autocorrelation image and the correlation peak template.
And the parameter for representing the watermark hiding effect is the structural similarity between the carrier object before embedding the watermark and the carrier object containing the target watermark information.
In the first embodiment of the present application, the parameter for characterizing the watermark hiding effect may be a normalized correlation coefficient NCA between the autocorrelation image and the correlation peak template, and the parameter for characterizing the watermark hiding effect may be a structural similarity SSIM between the carrier object before embedding the watermark under the current watermark embedding strength and the carrier object containing the target watermark information. Where NCA is defined as follows:
Figure BDA0002419860480000091
wherein A (i, j) is the autocorrelation image of the image after the self-synchronizing watermark is embedded, AT(i, j) is a correlation peak template, and the closer the normalized cross-correlation coefficient of the two is to 1, the stronger the correlation of the two is. Thus, NCA (α) can measure how close the correlation peak is to the correlation peak template when the current watermark embedding strength is α. SSIM is an index for measuring the similarity of two images. The SSIM index defines image structure information as being independent of brightness and contrast, and can reflect the attributes of the structure of objects in a scene. SSIM is a combination of three different factors of brightness, contrast and structure, where the brightness metric is the mean, the contrast metric is the standard deviation, and the structural similarity metric is the covariance. As the intercalation strength increases, the SSIM index of the water-containing imprinted image decreases while the detectable autocorrelation peak signal increases, resulting in an increase in NCA (α). When the NCA (α) coefficient exceeds the SSIM coefficient for the first time, the current watermark embedding strength α at this time is taken as the optimum embedding strength.
As shown in fig. 1, in step S104, when the relationship does not satisfy the preset relationship, the current watermark embedding strength is updated until the relationship between the parameter for characterizing the watermark hiding effect and the parameter for characterizing the extracted watermark effect satisfies the preset relationship.
The preset relation is that the value of the parameter for representing the extracted watermark effect is larger than the value of the parameter for representing the watermark hiding effect.
The updating the current watermark embedding strength comprises:
and adding a preset step length to the current watermark embedding strength to serve as the updated current watermark embedding strength.
The current watermark embedding strength is obtained by the algorithm 1, the current watermark embedding strength traverses in an interval of [ iniA, iniA + wA ] according to a certain step length sA, the initial value iniA can be determined by a unitary linear regression model of the variance of the Fourier magnitude spectrum of the embedded watermark signal region, and the model is obtained by fitting of an image training set. And increasing sA every time in the traversal process, calculating a new NCA (alpha) coefficient and an SSIM coefficient for the new embedding strength, and taking the watermark embedding strength alpha as the optimal embedding strength if the NCA (alpha) coefficient exceeds the SSIM coefficient for the first time. Otherwise, continuing the next cycle, and increasing the current watermark embedding strength by sA again.
Algorithm 1 calculation algorithm of current watermark embedding strength
Input, original carrier object (I), embedded intensity initial value (iniA), intensity step length (sA), and intensity traversal window width (wA);
output, optimal watermark embedding strength (optA), and carrier object (Iw) after embedding watermark;
1 for alpha is iniA, and sA (iniA + wA) number;
2, embedding a watermark into the original carrier object I by using the strength alpha according to the formula (1) to obtain a carrier object (Iw) embedded with the watermark;
3 calculating the autocorrelation of the carrier object after the watermark is embedded under the current embedding strength to obtain an autocorrelation image A;
4, calculating the NCA coefficient according to the formula (2);
5 calculating the SSIM coefficient of Iw at the moment;
6 if NCA(alpha)>SSIM
7optA ═ alpha, and exit the loop;
8endif
9end
10 outputs optA and Iw;
corresponding to the data processing method provided in the first embodiment of the present application, a second embodiment of the present application provides another data processing method, which is applied to a watermark extraction end, and is described below with reference to fig. 3, fig. 4, and fig. 5.
As shown in fig. 3, in step S301, a carrier object containing watermark information is obtained.
And the carrier object refers to a carrier image or a carrier video in which the target watermark information is embedded.
As shown in fig. 3, in step S302, an autocorrelation image after self-synchronization is obtained according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to the autocorrelation image of the carrier object and a preset correlation peak template.
When the size of the embedded rectangular watermark template is consistent with the tiling mode, the position of the template autocorrelation peak is a determined value, and the preset correlation peak template refers to an autocorrelation peak template automatically generated according to the position of the template autocorrelation peak. The second embodiment of the present application may further include:
and obtaining an autocorrelation image of the carrier object according to the carrier object.
The obtaining of the autocorrelation image of the carrier object according to the carrier object includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain signal of the carrier object;
and filtering the frequency domain signal of the carrier object and calculating the autocorrelation of the filtered carrier object to obtain an autocorrelation image of the carrier object.
The second embodiment of the present application may further include:
carrying out noise removal processing on the autocorrelation image of the carrier object to obtain an autocorrelation image with noise removed;
the obtaining a phase correlation peak according to the autocorrelation image of the carrier object and the correlation peak template includes:
obtaining a phase correlation peak according to the autocorrelation image after the noise is removed and the correlation peak template;
the obtaining of the autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object includes:
and obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image after the noise is removed and the phase correlation peak.
In specific implementation, firstly, performing discrete Fourier transform on a carrier object to obtain a frequency domain signal, then removing the interference of the carrier object on a watermark signal in the frequency domain informatization by adopting high-pass filtering in the early stage, calculating an autocorrelation image of a filtered carrier image, then performing high-pass filtering on the autocorrelation image to obtain an autocorrelation peak of the carrier image, and performing central region removing operation in order to remove high-correlation peak noise in a central region; then, logarithmic polar coordinate transformation is respectively performed on the autocorrelation image after the noise is removed and the preset correlation peak template, and then phase matching is performed on the autocorrelation image after the transformation and the preset correlation peak template to obtain a POMF (phase only matched filtering) phase correlation peak. In the log-polar domain, the rotation and scaling attack of the image is represented as displacement along the coordinate axis, and the specific relationship is shown in formula (3),
Figure BDA0002419860480000121
wherein (ρ ', θ') is a new coordinate in the log polar coordinate system after the original coordinate (ρ, θ) is attacked by the scaling rotation parameters σ and α, it can be seen from formula (3) that the scale transformation of the video/image will cause the image to generate a displacement of ln σ on the basis of ρ initial position (original scale) on the log polar coordinate system, and the rotation of the image will cause the image to generate an angular offset of α on the basis of the initial angle along the angular axis θ on the log polar coordinate system.
When the carrier object is subjected to autocorrelation operation, a plurality of autocorrelation peaks are formed in the area around the central peak, and the peaks belong to noise, so that the subsequent phase matching filtering result is influenced, and a plurality of wrong POMF phase correlation peaks are easily formed. Therefore, in order to reduce the effect of these noises on the true watermark autocorrelation peak during the detection process, the central region should be removed. According to the embodiment of the application, the correlation peak noise in a 32x25 rectangular area around the center of the self-correlation domain of the Fourier domain of the watermark image is removed, and the area value is set to be 0. The region size is selected to be related to the size of the embedded rectangular watermark template, the size of the template adopted in the embodiment of the application is 128x100, and the position of the related peak is at the position away from the central region (64, 50). The rotation angle mainly considered in the embodiment of the application is 0-5 degrees, the scaling coefficient is 0.5-1.5, and therefore the position of the correlation peak is out of the range of (32,25) after rotation scaling, so that the correlation peak noise in the rectangular area of 32x25 in the central area is removed, and only the autocorrelation peak at the position of the central point is reserved.
The obtaining the autocorrelation image after the self-synchronization according to the autocorrelation image after the noise removal and the phase correlation peak comprises:
calculating a rotation angle and a scaling coefficient of an autocorrelation image of the carrier object according to the phase correlation peak;
and carrying out rotation and scaling processing on the autocorrelation image of the carrier object according to the rotation angle and the scaling coefficient to obtain the autocorrelation image after self-synchronization.
As shown in fig. 3, in step S303, the rotation angle and the scaling factor of the carrier object are obtained according to the correlation between the autocorrelation image after the self-synchronization and the correlation peak template.
The obtaining of the rotation angle and the scaling factor of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining a rotation angle and a scaling coefficient of the carrier object;
and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak.
The obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and judging whether the correlation between the self-synchronized self-correlation image and a preset correlation peak template meets a preset correlation relationship, and if so, taking a phase correlation peak corresponding to the self-synchronized self-correlation image as a target phase correlation peak.
The correlation between the self-correlation image after self-synchronization and the correlation peak template is as follows: a weighted cross-correlation between phase cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template and spatial cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template.
The preset correlation relationship is as follows:
the difference between the weighted cross-correlation and a preset constant is less than a preset difference threshold.
The following describes a process of obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and a preset correlation peak template.
In video/image watermarking applications, most of the cases are that an original image or a reference image is difficult to obtain at a watermark extraction end, so that only an autocorrelation peak formed by repeatedly embedded watermarks which can be detected can be obtained, and phase matching is carried out on the autocorrelation peak and a preset correlation peak template. These watermarks have relatively weak signal strength, and the number of autocorrelation peaks that can be detected by a general automation method is often insufficient, so that phase correlation is easily formed between the watermark and a preset correlation peak template under various rotation scaling parameters, and interference is formed as shown in fig. 4, which is difficult to be determined by the highest POMF phase correlation peak. Therefore, the application provides a method for accurately screening the POMF target phase correlation peak by taking the cross-correlation coefficient between the self-synchronized correlation peak and a preset correlation peak template as a judgment condition, and pseudo codes of an algorithm can be as follows:
input, ordered phase correlation peak (SPC), autocorrelation image (Wa) of carrier object, preset correlation peak template (Ha)
Output rotation angle theta, scaling parameter s
For i < SPC number
2. Calculating theta and s according to SPC (i);
3. carrying out rotation scaling transformation on Wa by using theta and s to obtain self-synchronized Wa';
4. sharpening the peak in the Wa' after resynchronization by using a local maximum method;
5. calculating the inter-template phase cross-correlation coefficient PCorr of Ha and Wa' according to formula (4);
6. calculating the inter-template spatial cross-correlation coefficient SCorr of Ha and Wa' according to formula (5);
7. calculating a weighted cross-correlation Corr according to formula (6);
8. if Corr is close to 1, this SPC (i) is chosen as the correct POMF peak;
9.end
10. calculating theta and s according to SPC;
in the second embodiment of the present application, the peak value of the POMF is automatically screened by a method of calculating a cross-correlation coefficient between the self-correlation peak image Wa' after self-synchronization and the preset correlation peak template Ha, where the cross-correlation coefficient includes weighting of phase cross-correlation and spatial cross-correlation, and thus, the influence of rotation and scaling attack is considered at the same time. Firstly, in the phase cross-correlation aspect, a fourier-mellin phase cross-correlation method is mainly adopted, and as shown in formula (4), the correlation between the synchronized correlation peak image and a preset correlation peak template (Ha) is calculated. The specific method comprises the steps of sequencing phase correlation output in the POMF step from large to small, traversing from the highest peak, and calculating a rotation angle and a scaling coefficient according to the position of the phase correlation in a Log-polar coordinate system (Log-polar). And then, the watermark autocorrelation image Wa is rotationally scaled back to a state synchronous with the original carrier image according to the rotation angle and the scaling coefficient to obtain the synchronized Wa'. Then, the phase cross correlation between the synchronized autocorrelation peak image Wa' and the preset correlation peak template Ha is calculated again according to the formula (4):
Figure BDA0002419860480000141
next, the spatial cross-correlation between the synchronized autocorrelation peak image Wa' and the preset correlation peak template Ha is calculated. The spatial cross-correlation is defined by the cross-correlation between the patterns enclosed by the convex hull formed by the self-synchronized Wa' and the position of the correlation peak on the template Ha. The convex hull masks of Wa 'and Ha are shown in fig. 5(a) and (b), where fig. 5(b) is a binary image surrounded by the convex hull formed from Wa' after synchronization, and fig. 5(a) is a binary image surrounded by the convex hull of Ha. The two graphs can more accurately reflect the correlation between the original image and the image subjected to the geometric attack, the correlation between the original image and the image subjected to the geometric attack can be calculated by a normalized correlation coefficient defined by formula (2), and the specific definition is shown in formula (5),
Figure BDA0002419860480000151
the convex hull generating algorithm specifically comprises the following steps: firstly, two-dimensional triangulation is carried out on spatial points in Wa', and a Delaunay triangulation algorithm is adopted. Then, theAnd searching the convex hull of the triangulation by using a Graham scanning method according to the triangulation result. Filling the convex hull to obtain a binary image Bw. Finally, the convex hull binary image B of Wa' is mappedwAnd Ha's convex hull binary image BHAnd substituting the formula (5) to obtain a spatial correlation coefficient NCB. In order to comprehensively consider the correlation coefficients of the phase correlation and the spatial correlation between the self-synchronized image and the original image, the method calculates weighted correlation coefficients, as shown in equation (6),
Corr=wPcorr+(1-w)Scorr (6)
wherein w is the weight, w takes the value of 0.5, and Corr is the weighted cross-correlation coefficient. When the cross-correlation coefficient Corr in the formula (5) is closer to 1, it means that the correlation between the self-synchronized image and the self-correlation template is stronger, and the rotation angle corresponding to the corresponding phase cross-correlation peak SPC is the correct rotation angle.
As an implementation manner, the second embodiment of the present application may further include: and carrying out sharpening processing on the self-synchronized self-correlation image to obtain the sharpened self-synchronized self-correlation image.
The obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and obtaining a target phase correlation peak according to the correlation between the self-correlation image after the self-synchronization and the correlation peak template after the sharpening.
The second embodiment of the application provides sharpening processing on the self-correlation image after self-synchronization, which can effectively improve the calculation precision of the cross-correlation coefficient between the self-correlation image and a preset correlation peak template. Before calculating the cross-correlation coefficient between the watermark autocorrelation peak and the preset correlation peak template, the watermark autocorrelation peak needs to be resynchronized, the watermark autocorrelation image needs to be rotated and scaled during resynchronization, the rotation scaling includes linear interpolation operation, and interpolation can cause high signals to be generated around the peak value and influence the accurate position of the peak value, so that sharpening optimization of the autocorrelation peak after self-synchronization is necessary. The specific sharpening method is to adopt a sliding window of 5x5 to perform local maximum calculation in a local window on an image Wa' subjected to resynchronization according to a rotation angle and a scaling coefficient determined by a current phase correlation peak. The sharpening algorithm pseudo-code is as follows:
inputting: sliding window of size 5x5, threshold 0.1 (empirical value), autocorrelation peak image Wa of carrier object
Outputting 9 local maximums in the watermark autocorrelation peak image and sharpened autocorrelation peak image Wa'
1. Finding a local maximum in a local window lw (i) and setting lw (i) to 0;
2. traversing Wa by a sliding window to find all local maximum values;
3. sorting all the local maximum values found in the step 2, and reserving the maximum 9 of the local maximum values;
4. generate sharpened Wa' with 9 maximum peaks and the remainder of 0
It should be noted that the above sharpening algorithm is only one embodiment, and when the sharpening algorithm is implemented specifically, other numbers of maximum peaks may be selected.
As shown in fig. 3, in step S304, watermark information is extracted from the carrier object according to the rotation angle and the scaling factor.
The local area maxima algorithm looks for its local maxima in the input matrix Wa. The specific method is to realize local maximum search by comparing the maximum value in the matrix Wa with a threshold value specified by a user. When the maximum value is greater than or equal to a specified threshold, its value is considered a valid local maximum. The determination of the local maxima is based on a local sliding window. After the local maximum is found, all matrix values (including the maximum) in the sliding window are set to 0. This step ensures that subsequent searches do not include this maximum. The size of the local sliding window must be adapted so that enough values around the maximum can be eliminated to reduce false peaks. The sliding window repeats the process until all valid maxima are found. Finally, the highest value of the highest required number of local maxima is retained.
In practical application, most of the geometric attacks on the video/image are attacks under a small rotation angle, and the rotation angle is in the range of 1-5 degrees. However, at a small rotation angle, the rotation and scaling parameters of the geometric attack are difficult to detect, because unlike the large rotation angle, after the small rotation angle, the periodicity brought to the video/image by the linear interpolation is very weak. If detection is performed by a periodically embedded watermark template, there is also a problem of signal weakness, and it is difficult to balance between robustness and invisibility. The highest phase correlation peak in the logarithmic polar coordinate system does not necessarily correspond to the exact rotational scaling factor of the geometric attack. Since in many videos/images the texture content itself contains a very strong periodicity, which has a large impact on the geometric attack parameter detection. Therefore, it is necessary to find a peak corresponding to an accurate geometric attack parameter in the phase correlation peak, which is helpful to improve the robustness and invisibility of the watermarking algorithm. The embodiment of the application provides a novel log-polar domain self-synchronizing watermark algorithm which combines an optimized self-adaptive watermark embedding strength algorithm, an accurate POMF target phase correlation peak value screening method taking a self-correlation peak cross-correlation coefficient as a judgment condition and a self-correlation peak sharpening algorithm, and improves the performance of the self-synchronizing watermark algorithm.
To illustrate the effectiveness of the present application, the performance of the log-polar domain POMF rotation scaling test with and without the method proposed by the embodiments of the present application was tested experimentally. The test picture adopts 8 spokes of multiple resolution images, the angle detection accuracy under the attack of the rotation angle of 1-5 degrees (step length of 1 degree) is tested, and the detection accuracy of the rotation angle and the zoom coefficient under the mixed attack condition when the zoom coefficient is 0.7-1.3 (step length of 0.1) is tested. Under the above experimental conditions, the test includes both the rotation or scaling geometric attack alone and the performance of the algorithm under the mixed geometric attack combining rotation and scaling, and table 1 shows the test results of the more typical image 1.
According to table 1, if the method proposed in the embodiments of the present application is used, the rotation average angle error detected with the POMF filter in the log polar domain is 5 °, and if the method proposed herein is not used, the angle error is 6 °. The scaling error obtained by the method is 0.0328, and the scaling error without the method is 0.0403. Since the angle error is large in some cases, the average angle error is large. If the preset detected angle error is acceptable within 1 °, for the method of the embodiment of the present application, there are 8 total detected rotation angle errors greater than 1 °. If the method is not adopted, 10 cases of detecting the error of the rotation angle larger than 1 degree are totally included. Table 2 shows the average of the test results of 8-spoke images. It can be seen from the comparison of the above results that due to the effectiveness of the method, accurate geometric attack parameters can be found in the phase correlation peaks in a plurality of log-polar domains, and if the method is not adopted, only the highest phase correlation peak is used for judgment, a larger geometric parameter error is generated. This experiment thus illustrates the effectiveness of the method proposed in the examples of the present application.
TABLE 1 results of geometric attack parameter testing
Figure BDA0002419860480000171
Figure BDA0002419860480000181
TABLE 2 mean values of different resolution image test results
Figure BDA0002419860480000182
Figure BDA0002419860480000191
A third embodiment of the present application provides an image processing apparatus corresponding to a data processing method provided in the first embodiment of the present application.
As shown in fig. 6, the data processing apparatus includes:
an information obtaining unit 601, configured to obtain a carrier object and target watermark information;
a target watermark information embedding unit 602, configured to embed the target watermark information into the carrier object according to the current watermark embedding strength, so as to obtain a carrier object containing the target watermark information;
a parameter relation obtaining unit 603, configured to obtain, according to the carrier object containing the target watermark information, a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect;
a current watermark embedding strength updating unit 604, configured to update the current watermark embedding strength when the relationship does not satisfy the preset relationship until the relationship between the parameter used for representing the watermark hiding effect and the parameter used for representing the extracted watermark effect satisfies the preset relationship.
Optionally, the target watermark information embedding unit is specifically configured to:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain coefficient of the carrier object;
embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength;
and carrying out inverse transformation processing on the frequency domain coefficient embedded with the target watermark information to obtain a carrier object containing the target watermark information.
Optionally, the target watermark information embedding unit is specifically configured to:
carrying out Fourier transform on the carrier object to obtain Fourier coefficients of the carrier object;
the embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength includes:
and embedding the target watermark information into an amplitude value of a Fourier coefficient of the carrier object according to the current embedding strength.
Optionally, the parameter for characterizing the extracted watermark effect is obtained by:
calculating the autocorrelation of the carrier object containing the target watermark information under the current watermark embedding strength to obtain an autocorrelation image;
and obtaining parameters for representing the extracted watermark effect according to the detectable autocorrelation peak of the autocorrelation image and the correlation peak template.
Optionally, the parameter for characterizing the watermark hiding effect is a structural similarity between the carrier object before embedding the watermark and the carrier object containing the target watermark information.
Optionally, the preset relationship is:
the value of the parameter characterizing the extracted watermark effect is larger than the value of the parameter characterizing the watermark hiding effect.
Optionally, the current watermark embedding strength updating unit is specifically configured to:
and adding a preset step length to the current watermark embedding strength to serve as the updated current watermark embedding strength.
It should be noted that, for the detailed description of the apparatus provided in the third embodiment of the present application, reference may be made to the related description of the first embodiment of the present application, and details are not described here again.
A fourth embodiment of the present application provides an electronic device corresponding to the data processing method provided in the first embodiment of the present application.
As shown in fig. 7, the electronic device includes:
a processor 701;
a memory 702 for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
Optionally, the embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain coefficient of the carrier object;
embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength;
and carrying out inverse transformation processing on the frequency domain coefficient embedded with the target watermark information to obtain a carrier object containing the target watermark information.
Optionally, the transforming the carrier object from the space domain to the frequency domain to obtain the frequency domain coefficient of the carrier object includes:
carrying out Fourier transform on the carrier object to obtain Fourier coefficients of the carrier object;
the embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength includes:
and embedding the target watermark information into an amplitude value of a Fourier coefficient of the carrier object according to the current embedding strength.
Optionally, the parameter for characterizing the extracted watermark effect is obtained by:
calculating the autocorrelation of the carrier object containing the target watermark information under the current watermark embedding strength to obtain an autocorrelation image;
and obtaining parameters for representing the extracted watermark effect according to the detectable autocorrelation peak of the autocorrelation image and the correlation peak template.
Optionally, the parameter for characterizing the watermark hiding effect is a structural similarity between the carrier object before embedding the watermark and the carrier object containing the target watermark information.
Optionally, the preset relationship is:
the value of the parameter characterizing the extracted watermark effect is larger than the value of the parameter characterizing the watermark hiding effect.
Optionally, the updating the current watermark embedding strength includes:
and adding a preset step length to the current watermark embedding strength to serve as the updated current watermark embedding strength.
It should be noted that, for the detailed description of the electronic device provided in the fourth embodiment of the present application, reference may be made to the related description of the first embodiment of the present application, and details are not repeated here.
In correspondence with a data processing method provided in the first embodiment of the present application, a fifth embodiment of the present application provides a storage device storing a program of the data processing method, the program being executed by a processor to perform the steps of:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
It should be noted that, for the detailed description of the storage device provided in the fifth embodiment of the present application, reference may be made to the related description of the first embodiment of the present application, and details are not described here again.
A sixth embodiment of the present application provides a data processing apparatus corresponding to the data processing method provided in the second embodiment of the present application.
As shown in fig. 8, the data processing apparatus includes:
a carrier object obtaining unit 801 for obtaining a carrier object containing watermark information;
a post-self-synchronization autocorrelation image obtaining unit 802, configured to obtain a post-self-synchronization autocorrelation image according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
a rotation angle and scaling factor obtaining unit 803, configured to obtain a rotation angle and a scaling factor of the carrier object according to a correlation between the self-correlation image after self-synchronization and the correlation peak template;
a watermark information extracting unit 804, configured to extract watermark information from the carrier object according to the rotation angle and the scaling factor.
Optionally, the rotation angle and scaling factor obtaining unit is specifically configured to:
obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining a rotation angle and a scaling coefficient of the carrier object;
and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak.
Optionally, the rotation angle and scaling factor obtaining unit is specifically configured to:
and judging whether the correlation between the self-synchronized self-correlation image and the preset correlation peak template meets a preset correlation relationship, and if so, taking the phase correlation peak corresponding to the self-synchronized self-correlation image as a target phase correlation peak.
Optionally, the correlation between the self-correlation image after self-synchronization and the preset correlation peak template is as follows: a weighted cross-correlation between phase cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template and spatial cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template.
Optionally, the preset correlation relationship is:
the difference between the weighted cross-correlation and a preset constant is less than a preset difference threshold.
Optionally, the apparatus further comprises:
a sharpening processing unit, configured to perform sharpening processing on the self-synchronized autocorrelation image to obtain a sharpened self-synchronized autocorrelation image;
the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and obtaining a target phase correlation peak according to the correlation between the self-correlation image after the self-synchronization and the correlation peak template after the sharpening.
Optionally, the apparatus further comprises: and the autocorrelation image obtaining unit is used for obtaining the autocorrelation image of the carrier object according to the carrier object.
Optionally, the autocorrelation image obtaining unit is specifically configured to:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain signal of the carrier object;
and filtering the frequency domain signal of the carrier object to obtain an autocorrelation image of the carrier object.
Optionally, the apparatus further comprises: the autocorrelation image denoising unit is used for carrying out noise removal processing on the autocorrelation image of the carrier object to obtain the autocorrelation image after noise removal;
the obtaining a phase correlation peak according to the autocorrelation image of the carrier object and the correlation peak template includes:
obtaining a phase correlation peak according to the autocorrelation image after the noise is removed and the correlation peak template;
the post-self-synchronization autocorrelation image obtaining unit is specifically configured to:
and obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image after the noise is removed and the phase correlation peak.
Optionally, the post-self-synchronization autocorrelation image obtaining unit is specifically configured to:
calculating a rotation angle and a scaling coefficient of an autocorrelation image of the carrier object according to the phase correlation peak;
and carrying out rotation and scaling processing on the autocorrelation image of the carrier object according to the rotation angle and the scaling coefficient to obtain the autocorrelation image after self-synchronization.
It should be noted that, for the detailed description of the apparatus provided in the sixth embodiment of the present application, reference may be made to the related description of the second embodiment of the present application, and details are not described here again.
A seventh embodiment of the present application provides an electronic device corresponding to the data processing method provided in the second embodiment of the present application, including:
a processor;
a memory for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
Optionally, the obtaining the rotation angle and the scaling factor of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template includes:
obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining a rotation angle and a scaling coefficient of the carrier object;
and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak.
Optionally, the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and judging whether the correlation between the self-synchronized self-correlation image and the preset correlation peak template meets a preset correlation relationship, and if so, taking the phase correlation peak corresponding to the self-synchronized self-correlation image as a target phase correlation peak.
Optionally, the correlation between the self-correlation image after self-synchronization and the preset correlation peak template is as follows: and the weighted cross correlation between the phase cross correlation coefficient between the self-synchronized autocorrelation image and the preset correlation peak template and the spatial cross correlation coefficient between the self-synchronized autocorrelation image and the correlation peak template.
Optionally, the preset correlation relationship is:
the difference between the weighted cross-correlation and a preset constant is less than a preset difference threshold.
Optionally, the electronic device further performs the following steps:
sharpening the self-synchronized self-correlation image to obtain a sharpened self-synchronized self-correlation image;
the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template includes:
and obtaining a target phase correlation peak according to the correlation between the self-correlation image after the sharpening process and the preset correlation peak template.
Optionally, the electronic device further performs the following steps: and obtaining an autocorrelation image of the carrier object according to the carrier object.
Optionally, the obtaining an autocorrelation peak image of the carrier object according to the carrier object includes:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain signal of the carrier object;
and filtering the frequency domain signal of the carrier object to obtain an autocorrelation image of the carrier object.
Optionally, the electronic device further performs the following steps: carrying out noise removal processing on the autocorrelation image of the carrier object to obtain an autocorrelation image with noise removed;
the obtaining a phase correlation peak according to the autocorrelation image of the carrier object and the preset correlation peak template includes:
obtaining a phase correlation peak according to the autocorrelation image after the noise is removed and the correlation peak template;
the obtaining of the autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object includes:
and obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image after the noise is removed and the phase correlation peak.
Optionally, the obtaining the autocorrelation image after the self-synchronization according to the autocorrelation image after the noise removal and the phase correlation peak includes:
calculating a rotation angle and a scaling coefficient of an autocorrelation image of the carrier object according to the phase correlation peak;
and carrying out rotation and scaling processing on the autocorrelation image of the carrier object according to the rotation angle and the scaling coefficient to obtain the autocorrelation image after self-synchronization.
It should be noted that, for the detailed description of the electronic device provided in the seventh embodiment of the present application, reference may be made to the related description of the second embodiment of the present application, and details are not described here again.
In accordance with a data processing method provided in the second embodiment of the present application, a seventh embodiment of the present application provides a storage device storing a program of the data processing method, the program being executed by a processor to perform the steps of:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
It should be noted that, for the detailed description of the electronic device provided in the eighth embodiment of the present application, reference may be made to the related description of the second embodiment of the present application, and details are not described here again.
Although the present application has been described with reference to the preferred embodiments, it is not intended to limit the present application, and those skilled in the art can make variations and modifications without departing from the spirit and scope of the present application, therefore, the scope of the present application should be determined by the claims that follow.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include non-transitory computer readable media (transient media), such as modulated data signals and carrier waves.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.

Claims (23)

1. A data processing method, comprising:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
2. The method of claim 1, wherein the embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information comprises:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain coefficient of the carrier object;
embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength;
and carrying out inverse transformation processing on the frequency domain coefficient embedded with the target watermark information to obtain a carrier object containing the target watermark information.
3. The method of claim 2, wherein the transforming the carrier object from a spatial domain to a frequency domain to obtain frequency domain coefficients of the carrier object comprises:
carrying out Fourier transform on the carrier object to obtain Fourier coefficients of the carrier object;
the embedding the target watermark information into the frequency domain coefficient of the carrier object according to the current watermark embedding strength includes:
and embedding the target watermark information into an amplitude value of a Fourier coefficient of the carrier object according to the current embedding strength.
4. The method according to claim 1, wherein the parameters characterizing the extracted watermark effect are obtained by:
calculating the autocorrelation of the carrier object containing the target watermark information under the current watermark embedding strength to obtain an autocorrelation image;
and obtaining parameters for representing the extracted watermark effect according to the detectable autocorrelation peak of the autocorrelation image and the correlation peak template.
5. The method according to claim 4, wherein the parameter for characterizing the watermark hiding effect is a structural similarity between the carrier object before embedding the watermark and the carrier object containing the target watermark information.
6. The method of claim 5, wherein the predetermined relationship is:
the value of the parameter characterizing the extracted watermark effect is larger than the value of the parameter characterizing the watermark hiding effect.
7. The method of claim 1, wherein updating the current watermark embedding strength comprises:
and adding a preset step length to the current watermark embedding strength to serve as the updated current watermark embedding strength.
8. A data processing method, comprising:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
9. The method according to claim 8, wherein the obtaining the rotation angle and the scaling factor of the carrier object according to the correlation between the self-correlation image after self-synchronization and the correlation peak template comprises:
obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template; the target phase correlation peak refers to a phase correlation peak used for determining a rotation angle and a scaling coefficient of the carrier object;
and obtaining the rotation angle and the scaling coefficient of the carrier object according to the target phase correlation peak.
10. The method according to claim 9, wherein obtaining a target phase correlation peak according to the correlation between the self-synchronized autocorrelation image and the correlation peak template comprises:
and judging whether the correlation between the self-synchronized self-correlation image and the correlation peak template meets a preset correlation relationship, and if so, taking a phase correlation peak corresponding to the self-synchronized self-correlation image as a target phase correlation peak.
11. The method according to claim 10, wherein the correlation between the self-synchronized autocorrelation image and the correlation peak template is: a weighted cross-correlation between phase cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template and spatial cross-correlation coefficients between the post-auto-sync auto-correlation image and the correlation peak template.
12. The method of claim 11, wherein the predetermined correlation relationship is:
the difference between the weighted cross-correlation and a preset constant is less than a preset difference threshold.
13. The method of claim 9, further comprising:
sharpening the self-synchronized self-correlation image to obtain a sharpened self-synchronized self-correlation image;
the obtaining a target phase correlation peak according to the correlation between the self-correlation image after self-synchronization and the correlation peak template includes:
and obtaining a target phase correlation peak according to the correlation between the self-correlation image after the self-synchronization and the correlation peak template after the sharpening.
14. The method of claim 8, further comprising:
and obtaining an autocorrelation image of the carrier object according to the carrier object.
15. The method of claim 14, wherein obtaining the autocorrelation peak image of the carrier object based on the carrier object comprises:
carrying out space domain to frequency domain transformation on the carrier object to obtain a frequency domain signal of the carrier object;
and filtering the frequency domain signal of the carrier object to obtain an autocorrelation image of the carrier object.
16. The method of claim 15, further comprising:
carrying out noise removal processing on the autocorrelation image of the carrier object to obtain an autocorrelation image with noise removed;
the obtaining a phase correlation peak according to the autocorrelation image of the carrier object and the correlation peak template includes:
obtaining a phase correlation peak according to the autocorrelation image after the noise is removed and the correlation peak template;
the obtaining of the autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object includes:
and obtaining the autocorrelation image after the autocorrelation according to the autocorrelation image after the noise is removed and the phase correlation peak.
17. The method according to claim 16, wherein obtaining the self-synchronized autocorrelation image based on the denoised autocorrelation image and the phase correlation peak comprises:
calculating a rotation angle and a scaling coefficient of an autocorrelation image of the carrier object according to the phase correlation peak;
and carrying out rotation and scaling processing on the autocorrelation image of the carrier object according to the rotation angle and the scaling coefficient to obtain the autocorrelation image after self-synchronization.
18. A data processing apparatus, comprising:
an information obtaining unit, configured to obtain a carrier object and target watermark information;
the target watermark information embedding unit is used for embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
a parameter relation obtaining unit, configured to obtain, according to the carrier object containing the target watermark information, a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect;
and the current watermark embedding strength updating unit is used for updating the current watermark embedding strength when the relation does not meet the preset relation until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
19. An electronic device, comprising:
a processor;
a memory for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
20. A storage device storing a program of a data processing method, the program being executed by a processor, and performing the steps of:
obtaining a carrier object and target watermark information;
embedding the target watermark information into the carrier object according to the current watermark embedding strength to obtain the carrier object containing the target watermark information;
obtaining a relation between a parameter for representing a watermark hiding effect and a parameter for representing an extracted watermark effect according to the carrier object containing the target watermark information;
and when the relation does not meet the preset relation, updating the current watermark embedding strength until the relation between the parameter for representing the watermark hiding effect and the parameter for representing the extracted watermark effect meets the preset relation.
21. A data processing apparatus, comprising:
a carrier object obtaining unit for obtaining a carrier object containing watermark information;
the after-self-synchronization autocorrelation image obtaining unit is used for obtaining an after-self-synchronization autocorrelation image according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
a rotation angle and scaling coefficient obtaining unit, configured to obtain a rotation angle and a scaling coefficient of the carrier object according to a correlation between the self-correlation image after self-synchronization and the correlation peak template;
and the watermark information extraction unit is used for extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
22. An electronic device, comprising:
a processor;
a memory for storing a program of a data processing method, the apparatus performing the following steps after being powered on and running the program of the data processing method by the processor:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
23. A storage device storing a program of a data processing method, the program being executed by a processor, and performing the steps of:
obtaining a carrier object containing watermark information;
obtaining an autocorrelation image after self-synchronization according to the autocorrelation image and the phase correlation peak of the carrier object; the phase correlation peak is obtained according to an autocorrelation image of the carrier object and a preset correlation peak template;
obtaining a rotation angle and a scaling coefficient of the carrier object according to the correlation between the self-correlation image after self-synchronization and the preset correlation peak template;
and extracting watermark information from the carrier object according to the rotation angle and the scaling coefficient.
CN202010202490.9A 2020-03-20 2020-03-20 Data processing method and device, electronic equipment and storage equipment Pending CN113496449A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010202490.9A CN113496449A (en) 2020-03-20 2020-03-20 Data processing method and device, electronic equipment and storage equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010202490.9A CN113496449A (en) 2020-03-20 2020-03-20 Data processing method and device, electronic equipment and storage equipment

Publications (1)

Publication Number Publication Date
CN113496449A true CN113496449A (en) 2021-10-12

Family

ID=77993737

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010202490.9A Pending CN113496449A (en) 2020-03-20 2020-03-20 Data processing method and device, electronic equipment and storage equipment

Country Status (1)

Country Link
CN (1) CN113496449A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115187444A (en) * 2022-09-08 2022-10-14 杭州海康威视数字技术股份有限公司 Image tracing information safety protection method and device and electronic equipment

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115187444A (en) * 2022-09-08 2022-10-14 杭州海康威视数字技术股份有限公司 Image tracing information safety protection method and device and electronic equipment

Similar Documents

Publication Publication Date Title
Lin et al. Rotation, scale, and translation resilient watermarking for images
Zheng et al. A survey of RST invariant image watermarking algorithms
Hou et al. Blind 3D mesh watermarking for 3D printed model by analyzing layering artifact
Yang et al. A 3D steganalytic algorithm and steganalysis-resistant watermarking
Solachidis et al. Fourier descriptors watermarking of vector graphics images
Kalivas et al. Watermarking of 3D models using principal component analysis
US8103054B2 (en) Method for identifying marked images using statistical moments based at least in part on a JPEG array
Lin et al. Rotation, scaling, and translation resilient watermarking for images
EP1163753A1 (en) Rotation, scale, and translation resilient public watermarking for images
CN111968027B (en) Robust color image zero watermarking method based on SURF and DCT features
Hamid et al. A Comparison between using SIFT and SURF for characteristic region based image steganography
Chen et al. Statistical moments based universal steganalysis using JPEG 2-D array and 2-D characteristic function
Sun et al. A geometrically robust multi-bit video watermarking algorithm based on 2-D DFT
CN112788342A (en) Watermark information embedding method and device
CN112241929A (en) Watermark embedding method, watermark detecting method, watermark embedding device, watermark detecting device and electronic equipment
CN102024244B (en) Method and device for embedding and detecting watermarks based on image characteristic region
Zope-Chaudhari et al. Copyright protection of vector data using vector watermark
CN113496449A (en) Data processing method and device, electronic equipment and storage equipment
CN109461110B (en) Method and device for determining traceability information of picture
JP6138706B2 (en) Digital watermark embedding method or digital watermark detection method
JP3651319B2 (en) Digital watermark information recording method, reproduction method, digital watermark information recording apparatus, and reproduction apparatus
JP2007510335A (en) Method for estimating affine relationships between images
Chang et al. Watermarking 2D/3D graphics for copyright protection
Singh et al. Entropy based image watermarking using discrete wavelet transform and singular value decomposition
KR100945724B1 (en) Line watermarking resilient against local deformation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination