Image watermarking method based on SVD, SWT and APDCBT

By combining SVD, DWT and APDCBT transformation technologies to embed and extract watermarks from images, it solves the problems of blockiness and robustness, and achieves high-quality watermark extraction and copyright protection at lower bit rates.

CN118747704APending Publication Date: 2024-10-08KUNMING UNIV OF SCI & TECH
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410886853.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-03
Publication Date
2024-10-08

AI Technical Summary

Technical Problem

Existing technologies are prone to block effects when embedding watermarks in images or videos at low bit rates, resulting in low quality of reconstructed images, and the watermark information cannot be effectively extracted after the carrier image is attacked, affecting the copyright protection effect.

Method used

The image watermarking method based on SVD, DWT and APDCBT is used to achieve efficient embedding and extraction of watermarks by performing grayscale conversion, DWT decomposition, APDCBT transformation, singular value decomposition and watermark embedding on the carrier image, combined with Haar wavelet transform and inverse wavelet transform. , reduce blocking effects and improve robustness.

Benefits of technology

Reduce blocking effects at lower bit rates, improve image quality, ensure that high-quality watermark information can be effectively extracted after the carrier image is severely attacked, and enhance copyright protection capabilities.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118747704A_ABST
    Figure CN118747704A_ABST
Patent Text Reader

Abstract

The invention relates to an image watermarking method based on SVD, DWT and APDCBT, and belongs to the technical field of image processing. The method comprises the following steps: firstly, reading an n * n carrier color image I, and converting the color image I into a grayscale image; watermark embedding is carried out on the obtained grayscale image, then DWT decomposition is carried out to obtain four sub-bands, two high-frequency sub-bands LH and HL are selected to embed the same watermark W, block-based APDCBT is carried out on each sub-band, a direct current coefficient of each sub-block is extracted to form a coefficient matrix M, singular value decomposition is carried out on the coefficient matrix M in an SVD domain to obtain a singular value matrix S of the matrix M, and the singular value matrix S of the matrix M is obtained; carrying out inverse wavelet transform to obtain a carrier image with a watermark; the method comprises the following steps: carrying out watermark extraction on a carrier image with a watermark, carrying out primary wavelet transform on the received image with the watermark by using a Haar wavelet to obtain two high-frequency sub-bands LHW and HLW, executing block-based APDCBT on each sub-band, generating a matrix M * by using a direct current coefficient in an APDCBT coefficient matrix, carrying out singular value correction in an SVD (Singular Value Deviation) domain, and obtaining a matrix M *; and extracting the watermark of each sub-band by using an inverse process of watermark embedding, and calculating a watermark W'by using the two extracted watermarks.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to an image watermark method based on SVD, DWT and APDCBT, and belongs to the technical field of image processing. Background Art

[0002] With the continuous development of network technology, copyright protection of digital multimedia has become a research hotspot in recent years. As an effective solution, digital watermarking schemes have emerged. In order to achieve the strongest robustness, the modification of the carrier image should be as small as possible during the watermark embedding and extraction process. After embedding the watermark information, even if the carrier image is subjected to a strong attack, the watermark information can be extracted, thereby achieving the copyright protection effect.

[0003] The prior art embeds and extracts watermarks from carrier images to verify whether the watermark information can be successfully extracted after the image is attacked, so as to achieve the copyright protection effect of the carrier image. For example, the patent with the publication number CN117114955A, entitled A secure image watermarking method based on DWT, SVD and DCT, describes a DCT transform, i.e., a discrete cosine transform, watermark embedding and extraction method. In this method, at a low bit rate, the DCT-processed image or video may have obvious block effects, i.e., the boundaries between blocks become obvious.

[0004] To solve the above problems, this paper adopts the APDCBT transformation method, which uses adaptive prediction to reduce block effects at lower bit rates and make the reconstructed image or video higher in quality. Compared with traditional watermarking methods based on singular value decomposition and other watermarking technologies, the watermarked image obtained by the method of the present invention has higher image quality and is more robust to various image processing attacks. Summary of the invention

[0005] The technical problem to be solved by the present invention is to provide an image watermarking method based on SVD, DWT and APDCBT to extract the watermark from the image embedded with the watermark, so as to solve the problem that a watermark image with good quality cannot be extracted when the carrier image suffers from a serious attack.

[0006] The technical solution of the present invention is: an image watermarking method based on SVD, DWT and APDCBT, the specific steps are:

[0007] Step 1: Read a color carrier image I with a length and width of n×n, and convert the color carrier image I into a grayscale image, that is, average the RGB channels of the image to convert the color image into a grayscale image.

[0008] Step 2: Embed the watermark into the carrier image I, specifically:

[0009] The obtained grayscale image is decomposed by DWT to obtain four sub-bands.

[0010] Select two high-frequency sub-bands to insert two identical watermarks W, divide each sub-band image into several sub-blocks, perform block-based APDCBT on each obtained sub-block, and extract the DC coefficients of each sub-block to form a coefficient matrix M.

[0011] Perform SVD decomposition on the coefficient matrix M, calculate the singular value matrix S of the matrix M, embed the watermark W into the singular value matrix S to obtain the matrix S containing the watermark information W .

[0012] Apply inverse SVD to S W , get the correction coefficient matrix M′, and after inverse APDCBT, get the subband embedded with the watermark W, and use IDWT (inverse wavelet transform) to get the carrier image I1 with the watermark.

[0013] Step 3: Extract the watermark from the carrier image I1 with the watermark:

[0014] The received watermarked image is transformed by Haar wavelet, and then two high-frequency sub-bands LH are obtained. W and HL W .

[0015] Each sub-band image is divided into 8×8 non-overlapping sub-blocks of equal size, and block-based APDCBT is performed. The DC coefficient in the APDCBT coefficient matrix is ​​used to generate a coefficient matrix M * .

[0016] The newly generated coefficient matrix M * Use SVD transformation to get three new matrices U * , S * and V * , and then calculate the watermark W′.

[0017] Step 4: Finally, the watermark is corrected to obtain the extracted watermark image, further improving the quality of the extracted watermark.

[0018] The Step 2 is specifically as follows:

[0019] Step 2.1: Perform a first-level DWT decomposition on the grayscale image using Haar wavelet transform, thereby obtaining four sub-bands of different frequencies, namely, horizontal component high frequency sub-band LH, vertical component high frequency sub-band HL, diagonal component high frequency sub-band HH and approximate component low frequency sub-band LL.

[0020] The DWT refers to discrete wavelet transform. The present invention uses the wavelet basis function Haar wavelet transform to divide the original image signal into two parts, low frequency and high frequency, and decompose the image information layer by layer, that is, firstly, the grayscale image is row filtered along the column direction, and then down-sampled, and then column filtered along the row direction, and down-sampled again, so as to obtain four sub-bands with different frequencies.

[0021] Step 2.2: To reduce the impact of watermark insertion, select the high-frequency subband HL to embed the watermark W, divide the HL subband into 8×8 sub-blocks of equal size, and apply block-based APDCBT to each sub-block to obtain the DC coefficient of each sub-block.

[0022] APDCBT refers to full-phase discrete cosine biorthogonal transform, which is based on the combination of discrete cosine transform (DCT) and biorthogonal transform (BDT) and extracts texture features by dividing the image into non-overlapping sub-blocks and transforming each sub-block.

[0023] DCT refers to discrete cosine transform, which decomposes each sub-block into a set of frequency coefficients, where low-frequency coefficients represent the overall characteristics of the image and high-frequency coefficients represent the details of the image.

[0024] BDT refers to a special biorthogonal transform, which obtains biorthogonal coefficients by linearly combining frequency domain coefficients.

[0025] In the process of APDCBT transformation, the transformation matrix B with dimension N×N is defined as:

[0026]

[0027] For an image block X of size N×N, APDCBT can be expressed as:

[0028] Y=BXB T

[0029] Wherein, Y is the transformation coefficient matrix after APDCBT transformation.

[0030] Step 2.3: Construct a coefficient matrix of the DC coefficients of each sub-block, denoted as M, and then perform SVD decomposition on the coefficient matrix, according to the formula M = USV T Decompose the matrix M into three matrices U, S and V, where U and V are two orthogonal matrices and S is a diagonal matrix.

[0031] SVD refers to singular value decomposition, which is a matrix decomposition method that decomposes a matrix into the product of three matrices.

[0032] Step 2.4: Use the watermark W to W=S+a×W Modify the S matrix in the subband HL coefficient matrix, where a is the watermark embedding strength, S W is a matrix containing watermark information.

[0033] Step 2.5: Use the formula M′=US W V T Apply inverse SVD to S W , and obtain the correction coefficient matrix M′. After the inverse APDCBT transformation, the HL subband with the embedded watermark W is obtained.

[0034] Step 2.6: In order to embed the watermark W in the LH subband, the process of Step 2.2 to Step 2.5 is performed on the LH subband.

[0035] Step 2.7: Perform inverse wavelet transform (IDWT) on the HL and LH subbands embedded with the watermark to obtain the carrier image I1 with the watermark.

[0036] The Step 3 is specifically as follows:

[0037] Step 3.1: Since the received carrier image I1 with watermark may be distorted by various attacks, the carrier image I1 with watermark is transformed by Haar wavelet to obtain four sub-bands with different frequencies: horizontal component LH W , vertical component HL W , diagonal component HH W and approximate component LL W , corresponding to the watermark embedding process, two high-frequency sub-bands LH are selected W and HL W .

[0038] Step 3.2: In order to W Extract watermark W1 from subband * First, the sub-band image is divided into 8×8 non-overlapping sub-blocks, and APDCBT is performed on each sub-block to obtain the DC coefficient of each sub-block, and the DC coefficient matrix M of each sub-block is obtained. * .

[0039] Step 3.3: The obtained matrix M * Using formula M * =U * S * (V * ) T Perform singular value decomposition and get U * , S * and V * Three new matrices, where U * and V * are two orthogonal matrices, S* is a diagonal matrix.

[0040] Step 3.4: Using formula W1 * =(S * -S) / a to extract the watermark W1*, where a is the scaling factor.

[0041] Step 3.5: LH W The subband executes Step 3.2 to Step 3.4 to obtain the extracted watermark W2 * .

[0042] Step 3.6: By * and W2 * Find the average value to calculate the watermark W′, that is, W′=(W1 * +W2 * ) / 2.

[0043] The Step 4 is specifically as follows:

[0044] In order to further improve the quality of the extracted watermark, a sign function is used to correct the watermark, specifically:

[0045]

[0046] Where T is a threshold between 0 and 1, here we take T = 0.5, W * is the extracted watermark after correction, and (i, j) is the coordinate of the pixel in the watermark image.

[0047] The beneficial effects of the present invention are as follows: the present invention extracts watermarks from images embedded with watermarks, and even if the image is subjected to severe attacks, it can still extract a watermark image with good quality and has good robustness. The closer the extracted watermark is to the original watermark, the better the robustness and the better the copyright protection for the original image. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Attached Figure 1 is a flow chart of the watermark embedding process of the present invention;

[0049] Attached Figure 2 It is a flow chart of the watermark extraction process of the present invention;

[0050] Attached Figure 3 is the original image I of the present invention;

[0051] Attached Figure 4 The image I1 with a watermark of the present invention;

[0052] Attached Figure 5 This is the image from which the watermark of the present invention is extracted. DETAILED DESCRIPTION

[0053] The present invention will be further described below in conjunction with the accompanying drawings and specific implementation methods.

[0054] Implementation method 1: Figure 1-4 As shown in FIG. 1 , an image watermarking method based on SVD, DWT and APDCBT is shown in FIG. 1 . The specific steps are as follows:

[0055] Step 1: Use Python 3.11.5 to read a 512×512 pixel color carrier image I and convert the color carrier image into a grayscale image.

[0056] Step 2: Decompose the obtained grayscale image into four sub-bands of 256×256 pixels by discrete wavelet transform, select two high-frequency sub-bands LH and HL to insert the same watermark, divide each sub-band image into 8×8 sub-blocks, perform block-based full-phase discrete cosine biorthogonal transform on each obtained sub-block, extract the DC coefficient matrix M of each sub-block, perform singular value decomposition SVD on the coefficient matrix, calculate the singular value matrix S of the matrix M, use a binary logo image of size 32×32 pixels as the watermark W, embed the watermark W into the coefficient matrix, and obtain the matrix S containing the watermark information W , apply the inverse SVD to the matrix S containing the watermark information W , get the correction coefficient matrix M′, and after inverse APDCBT, get the subband embedded with the watermark W, and then use the inverse wavelet transform (IDWT) to get the carrier image I1 with the watermark.

[0057] Step 3: Perform a first-level wavelet transform on the received watermarked image I1 using Haar wavelet transform, and then obtain the high-frequency subband LH W and HL W , divide each sub-band image into 8×8 non-overlapping sub-blocks, perform block-based APDCBT, and generate the coefficient matrix M * , the generated matrix M * Use SVD transformation to get three new matrices U * , S * and V * , using the obtained singular value matrix S * The watermark W′ is further calculated.

[0058] Step 4: In order to further improve the quality of the extracted watermark, a sign function is used to correct the watermark.

[0059] The Step 2 is specifically as follows:

[0060] The obtained grayscale image is decomposed into four sub-bands of 256×256 pixels by discrete wavelet transform, and three high-frequency sub-bands LH, HL, HH and one low-frequency sub-band LL are obtained.

[0061] Two high-frequency sub-bands LH and HL are selected to insert two identical watermarks, and the two sub-band images are equally divided into sub-blocks of the same size of 8×8. Block-based APDCBT transform is applied to each obtained sub-block to obtain the DC coefficient matrix of each sub-block, denoted as M.

[0062] Perform singular value decomposition on the coefficient matrix to obtain the singular value matrix S of the matrix M, and obtain the modified singular value matrix S after watermark insertion W .

[0063] Apply inverse SVD to the modified singular value matrix S W , and obtain the correction coefficient matrix M′. After inverse APDCBT, the HL subband with the embedded watermark W is obtained.

[0064] The same process is performed on the LH subband to embed the watermark W.

[0065] The LH and HL subbands embedded with watermarks are transformed by inverse wavelet transform to obtain the carrier image I1 with watermark.

[0066] The Step 3 is specifically as follows:

[0067] The Haar wavelet is used to perform a first-level wavelet transform on the carrier image I1 with the watermark, and then the high-frequency subband LH is obtained. W and HL W .

[0068] The sub-band image is divided into 8×8 sub-blocks of the same size and non-overlapping, and block-based APDCBT is performed on each sub-block to obtain the DC coefficient matrix M of each sub-block * .

[0069] The resulting matrix M * Perform singular value decomposition and get U * , S * and V * Three new matrices.

[0070] The watermark W1 is calculated by using the inverse process of watermark embedding * .

[0071] The same method is used to calculate the watermark W2 in the LHw subband * .

[0072] The two watermarks are averaged to calculate the watermark W'.

[0073] The Step 4 is specifically as follows:

[0074] In order to further improve the quality of the extracted watermark, the following sign function is used to correct the watermark, and T=0.5 is taken.

[0075]

[0076] Finally, the watermark extraction is completed, such as Figure 5 shown.

[0077] The specific implementation modes of the present invention are described in detail above in conjunction with the accompanying drawings, but the present invention is not limited to the above implementation modes, and various changes can be made within the knowledge scope of ordinary technicians in this field without departing from the purpose of the present invention.

Claims

1. An image watermarking method based on SVD, DWT and APDCBT, characterized in that: The specific steps are: Step 1: Read a color carrier image I with a length and width of n×n, and convert the color carrier image I into a grayscale image; Step 2: Embed watermark into carrier image I: The obtained grayscale image is decomposed by DWT to obtain four sub-bands; Select two high-frequency sub-bands to insert two identical watermarks W, divide each sub-band image into several sub-blocks, perform block-based APDCBT on each obtained sub-block, and extract the DC coefficients of each sub-block to form a coefficient matrix M; Perform SVD decomposition on the coefficient matrix M, calculate the singular value matrix S of the matrix M, embed the watermark W into the singular value matrix S to obtain the matrix S containing the watermark information W ; Apply inverse SVD to S W , get the correction coefficient matrix M′, after inverse APDCBT, get the subband embedded with watermark W, and use inverse wavelet transform to get the carrier image I1 with watermark; Step 3: Extract the watermark from the carrier image I1 with the watermark: The received watermarked image is transformed by Haar wavelet, and then two high-frequency sub-bands LH are obtained. W and HL W ; Each sub-band image is divided into 8×8 non-overlapping sub-blocks of equal size, and block-based APDCBT is performed. The DC coefficient in the APDCBT coefficient matrix is ​​used to generate a coefficient matrix M * ; The newly generated coefficient matrix M * Use SVD transformation to get three new matrices U * , S * and V * , and then calculate the watermark W′; Step 4: Finally, correction processing is performed to obtain the extracted watermark image.

2. The image watermarking method based on SVD, DWT and APDCBT according to claim 1, characterized in that: The Step 2 is specifically as follows: Step 2.1: Perform a first-level DWT decomposition on the grayscale image using Haar wavelet transform to obtain four sub-bands of different frequencies, namely: Horizontal component high frequency subband LH, vertical component high frequency subband HL, diagonal component high frequency subband HH and approximate component low frequency subband LL; Step 2.2: Select the high-frequency subband HL to embed the watermark W, divide the HL subband into 8×8 sub-blocks of equal size, apply block-based APDCBT to each sub-block, and obtain the DC coefficient of each sub-block; Step 2.3: Construct a coefficient matrix of the DC coefficients of each sub-block, denoted as M, and then perform SVD decomposition on the coefficient matrix, according to the formula M = USV T Decompose the matrix M into three matrices U, S and V, where U and V are two orthogonal matrices and S is a diagonal matrix; Step 2.4: Use the watermark W to W =S+a×W Modify the S matrix in the subband HL coefficient matrix, where a is the watermark embedding strength, S W is a matrix containing watermark information; Step 2.5: Use the formula M′=US W V T Apply inverse SVD to S W , get the correction coefficient matrix M′, and then perform inverse APDCBT transformation to get the HL subband embedded with the watermark W; Step 2.6: In order to embed the watermark W in the LH subband, perform the process of Step 2.2 to Step 2.5 on the LH subband; Step 2.7: Perform inverse wavelet transform on the HL and LH subbands embedded with the watermark to obtain the carrier image I1 with the watermark.

3. The image watermarking method based on SVD, DWT and APDCBT according to claim 1 is characterized in that: The Step 3 is specifically as follows: Step 3.1: Use Haar wavelet to perform a first-level wavelet transform on the carrier image I1 with watermark, and then obtain four sub-bands with different frequencies: horizontal component LH W , vertical component HL W , diagonal component HH W and approximate component LL W , select two high frequency sub-bands LH W and HL W ; Step 3.2: First, divide the sub-band image into 8×8 non-overlapping sub-blocks, perform APDCBT on each sub-block, obtain the DC coefficient of each sub-block, and obtain the DC coefficient matrix M of each sub-block * ; Step 3.3: The obtained matrix M * Using formula M * =U * S * (V * ) T Perform singular value decomposition and get U * , S * and V * Three new matrices; Step 3.4: Using formula W1 * =(S * -S) / a extracts the watermark W1*; Step 3.5: LH W The subband executes Step 3.2 to Step 3.4 to obtain the extracted watermark W2 * ; Step 3.6: By * and W2 * Find the average value to calculate the watermark W′, that is, W′=(W1 * +W2 * ) / 2.

4. The image watermarking method based on SVD, DWT and APDCBT according to claim 1, characterized in that: The Step 4 is specifically as follows: The symbol function is used to correct the watermark, specifically: In the formula, T is the threshold between 0 and 1, W * is the extracted watermark after correction, and (i, j) is the coordinate of the pixel in the watermark image.

Citation Information

Cited By

  • Self-adaptive image watermark embedding and recovering system

    CN120147098A