chapter-6 watermarking of jpeg imagesietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter...

34
97 CHAPTER-6 WATERMARKING OF JPEG IMAGES 6.1 INTRODUCTION In the Chapter 4, we have discussed that we can improve the robustness of DCT and DWT based watermarking schemes against some well known attacks by preprocessing the images. Since, “Fingerprinting” is the most crucial demand of today, we developed an ICAR scheme for the watermarking of gray level images also. We further expanded our scope for the colored images watermarking in Chapter 5 and developed an ICAR scheme for watermarking of 24-bit colored BMP images. Since, most of the images present on World Wide Web are in JPEG format, which is a highly compressed image format and store the images in the transformed domain, i.e. store the frequencies not the pixels values, we decided to develop an ICAR watermarking scheme for JPEG images. We also explored a relationship between the robustness and some of the image characteristics. 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the images present on WWW are in the Joint Photographic Experts Group (JPEG) format where as relatively less work is found for watermarking the JPEG images. Therefore, we decided to extend our earlier proposed ICAR schemes for the watermarking of JPEG images also. In our earlier proposed ICAR schemes, we inserted the ICAR nature in by introducing redundancy in the coefficients swapping of FM region. We also made the swapping criteria dependent on some very robust data elements (in the scheme presented in Section 4.4, it was the relative value of low frequency coefficient and in the scheme presented in 5.3, it was the average value of all middle band coefficients) so that decoding algorithm may perform a good recovery of the watermark data. But as it may be observed that we deployed the coefficients of FM region which were generated by taking the 8 x 8 DCT of pixels values. So, to continue the same

Upload: others

Post on 29-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

97

CHAPTER-6

WATERMARKING OF JPEG IMAGES

6.1 INTRODUCTION

In the Chapter 4, we have discussed that we can improve the robustness of DCT and

DWT based watermarking schemes against some well known attacks by preprocessing

the images. Since, “Fingerprinting” is the most crucial demand of today, we developed an

ICAR scheme for the watermarking of gray level images also. We further expanded our

scope for the colored images watermarking in Chapter 5 and developed an ICAR scheme

for watermarking of 24-bit colored BMP images. Since, most of the images present on

World Wide Web are in JPEG format, which is a highly compressed image format and

store the images in the transformed domain, i.e. store the frequencies not the pixels

values, we decided to develop an ICAR watermarking scheme for JPEG images. We also

explored a relationship between the robustness and some of the image characteristics.

6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES

Most of the images present on WWW are in the Joint Photographic Experts Group

(JPEG) format where as relatively less work is found for watermarking the JPEG images.

Therefore, we decided to extend our earlier proposed ICAR schemes for the

watermarking of JPEG images also. In our earlier proposed ICAR schemes, we inserted

the ICAR nature in by introducing redundancy in the coefficients swapping of FM region.

We also made the swapping criteria dependent on some very robust data elements (in the

scheme presented in Section 4.4, it was the relative value of low frequency coefficient

and in the scheme presented in 5.3, it was the average value of all middle band

coefficients) so that decoding algorithm may perform a good recovery of the watermark

data. But as it may be observed that we deployed the coefficients of FM region which

were generated by taking the 8 x 8 DCT of pixels values. So, to continue the same

Page 2: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

98

approach for the JPEG images, we needed to use coefficients belonging to FM region.

More pricelessly, JPEG image format does not store the pixel’s actual value but it stores

the image in frequency domain. So, we need to convert the JPEG image into spatial

domain and then take 8x8 block DCT on its color channels to get the FM region.

To inject the ICAR nature, we need to introduce redundancy in coefficient swapping.

Since JPEG is a very high compressed format, we know that as soon as we convert this

spatial domain image into JPEG format, lots of its coefficients will be changed. This

would create problem in recovering the watermark data by only considering the relative

strengths of coefficients of FM region. We must, therefore, provide extra robustness by

involving some coefficients whose value does not change much during the conversion of

spatial domain to frequency domain and vise versa. To resolve this issue, we decided to

take the advantage of JPEG compression-decompression scheme itself. In an 8x8 DCT

block, large value of the top-left corner is called the DC coefficient. The remaining 63

coefficients are called the AC coefficients. This DC coefficient is the major dominating

value while decompressing. This DC value alone can regenerate the best approximated

image by taking the IDCT. If this value is altered, then image is largely affected. So we

decided to take the contribution of this DC coefficient apart from coefficients from FM

region to interpret the watermark data to make our scheme robust. We have seen that in

our earlier scheme, we developed a swapping criteria based on the average of all 22

coefficients of FM region by claiming that it was difficult for any attacker or for any

image manipulation to alter this value significantly if the image has to remain

perceptually similar. Therefore, for our newly proposed watermarking scheme for JPEG

images, we interpreted the watermark data in FM region based on the average of 22

coefficients from FM region and the DC coefficient. More details of the watermark

embedding algorithms are described in Section 6.2.3. To ensure ICAR property, liker our

earlier proposed schemes, we watermarked each copy of a single JPEG image with a

different policy.

The proposed watermarking scheme can be defined as a 7-tuple (X, W, P, T, G, E, D)

where:

Page 3: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

99

1. X denotes the set of instances Xi, of a particular JPEG image, (If N copies of

an image are to be watermarked, then 0 ≤ i ≤ N);

2. W denotes the monochrome watermark logo;

3. P denotes the set of policies Pi, 0 ≤ i ≤ N;

4. “T” is the “watermark strength parameter”;

5. G denotes the policy generator algorithm G: Xi Pi, where

Each Xi will have a unique Pi, i.e. a different policy to hide the watermark

data;

6. E denotes the watermark embedding algorithm, E: Xi x W x Pi Xi’;

7. D denotes the watermark detection algorithm, D: Xi’ x Pi W’, where W’

represents the extracted watermark.

The parameter “T” is analogous to “K” of classical MBCE scheme. In classical MBCE

scheme, relative strength of two coefficients value of FM region decides the decoding of

“1” or “0”. If the relative strength of two values has to decide the decoding of “0” or “1”,

then larger value should remain larger even after image manipulations. So, we adjust

these values in such a way that the difference between the two values becomes larger

than a certain threshold value. We name this threshold value as “Watermark Strength

Parameter” because this value decides the robustness of watermark data. Certainly, it has

an impact on the image perceptibly. So, we need to decide this threshold value in such a

way that our image does not loose its quality much. The value of “T” may differ for each

image.

Out of these 7 tuples, last 3 tuples are algorithms, which are discussed below:

6.2.1 G, THE POLICY GENERATOR ALGORITHM

Similar to our earlier proposed ICAR watermarking scheme for the gray image

watermarking and colored image watermarking, we need to watermark each copy Xi of

an JPEG image X differently. Therefore, we need a different watermarking policy for

Page 4: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

100

each copy of the image to be watermarked. Here “Policy” means that, for every copy of

the image, there will be unique combination of 4 middle band coefficients. First we had

to convert the source JPEG image into its equivalent true colored 24-bit BMP image.

Then, to generate a policy, we simply take 8 x 8 DCT of a chosen color channel of the

input image Xi and randomly select 4 coefficients out of 22 middle band coefficient of

FM region from any of the red, green or blue color channel. So, numbers of policies that

can be generated are 22C 4 = 7315 which means that 7315 copies of a single image can be

watermarked such that no two watermarked images have same policy. This step ensures

that attacker can not conclude the location of watermark data by colluding many

watermarked copies of an image. This also depicts that our proposed scheme is an ICAR

scheme. Policy generator algorithm also returns the color channel to be used to carry the

watermark.

6.2.1.1 COLOR CHANNEL SELECTION: Bossen et al. [9] have stated that the

watermarks should be embedded mainly in the BLUE color channel of an image because

human eye is least sensitive to change in BLUE channel. However, the suitability of color

channel to hide the watermark data depends on the image itself. The color channel which

should be used can be found on the basis of the amount of the color present in the image

or on the basis of histogram of each color channel (i.e. color with spreader histogram

should be given priority). We also know that for few images, BLUE channel may not

give the optimum results. We, therefore propose that the color channel with the lowest

“Standard Deviation (SD)” should be selected. More details of this finding and result

related to this issue are given in the Section 6.2.4.1.

6.2.2 E, THE WATERMARK EMBEDDING ALGORITHM

In this algorithm, each 8x8 DCT block of an image is used to hide a single bit of

watermark logo. Our embedding algorithm is based on averaging the coefficients of FM

region and the DC coefficient. As we know that attacker cannot alter this “average (Av)”

of coefficients of FM region and the DC coefficient badly as it will heavily impact the

quality of image, we are hiding “1” or “0” by using the relative values of four coefficients

with this “Av”.

Page 5: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

101

This algorithm is given as follows:

1. Repeat steps 2 to13 for i = 1…..n; // where ‘n’ is the number of copies of a single image to be watermarked //

2. INPUT (Xi);

3. Convert the Xi into its equivalent spatial domain 24-bit colored image;

4. Take 8 x 8 block DCT of Xi;

5. INPUT (W);

6. Convert W into a string S = (Sj | Sj = {0,1}, for j = 1…..length of the watermark);

7. Let L = STRING_LENGTH (S); // L is the length of watermark data. If L = 1000, then first 1000 DCT block of Xi are used //

8. Pi = CALL (G); // Each generated Pi shall be stored in an author’s database for the detection purpose in future.

Let the Pi for chosen Xi be, Pi = {(5,1), (4,2), (6,3) and (5,4)} in the chosen color channel //

9. Calculate the average “Av” of remaining 18 middle band coefficients and DC

coefficient.

Av = (DCT (0, 0) + Sum (22 Middle band coefficients) - Sum (4 chosen

coefficients chosen by Pi)) / 19.

10. Repeat steps 11 to13 for r = 1…..L;

11. Read Sr;

// Now like classical MBCE scheme, relative strength of average “Av” and chosen 4 coefficients

in step 7 will interpret “0” or “1” of watermark data. To hide “0” for all 4 chosen coefficients

in step 7, we assigned the value of coefficients which is ‘T’ less than the average “Av”. To hide

“1”, for all 4 chosen coefficients in step 7, we assigned the value of coefficients which is ‘T’

greater than the average “Av” //

If (Sr = 0)

DCT (5, 1) = Av - T;

DCT (4, 2) = Av - T;

DCT (5, 4) = Av - T;

Page 6: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

102

DCT (6, 3) = Av - T;

Else

DCT (5, 1) = Av + T;

DCT (4, 2) = Av + T;

DCT (5, 4) = Av + T;

DCT (6, 3) = Av + T;

End;

12. Take IDCT to reconstruct Xi;

13. Convert Xi back to its JPEG format;

14. End.

6.2.3 D, THE WATERMARK DETECTION ALGORITHM

Watermark extraction is the reverse procedure of watermark embedding. To extract the

watermark from the watermarked JPEG image, first we convert it into its equivalent 24

bit colored images and then calculate the average “Av” in a same way, as in embedding

algorithm. Owner has a record of all policies used to watermark the images. Based on

“policies”; owner of the image can recover watermark using following rule:

1) If at least 1 out of 4 chosen coefficients are less then Av, Interpret “0”; and

2) If at least 1 out of 4 chosen coefficients are greater then Av, interpret “1”.

The detection algorithm steps are as follows:

1. INPUT (Xi’); // Xi’ is the attacked copy of a watermarked image//

2. Convert Xi into its equivalent 24 bit colored image;

3. Take 8x8 block DCT of Xi’ and calculate Av;

4. For all Pi stored in author’s database, repeat the steps 5; // If initially 10 copies were watermarked, then out of 10 policies, for 1 policy, watermark will be

recovered correctly. To explain further steps, we are assuming that now algorithm is in a loop

where Pi is {(5, 1) (4, 2) (5, 4) and (6, 3)}, which was used to watermarked this particular Xi’ //

Page 7: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

103

5. Repeat the steps 5 for j = 1….L; // L is the length of watermark data. A single bit will be recovered form one 8x8 DCT block.//

Take jth DCT block to form jth bit of watermark as follows:

If (DCT (5, 1) < = Av)

T1 = 1;

Else T1 = 0;

If (DCT (4, 2) < = Av)

T2 = 1;

Else T2 = 0;

If (DCT (5, 4) < = Av)

T3 = 1;

Else T3 = 0;

If (DCT (6, 3) < = Av)

T4 = 1;

Else T4 = 0;

If ( T1 + T2 + T3 + T4 > = 1 )

Decode “0”

If (DCT (5, 1) > Av)

P1 = 1;

Else P1 = 0;

If (DCT (4, 2) > Av)

P2 = 1;

Else P2 = 0;

If (DCT (5, 4) > Av)

P3 = 1;

Else P3 = 0;

If (DCT (6, 3) > Av)

P4 = 1;

Else P4 = 0;

If ( P1 + P2 + P3 + P4 > = 1)

Page 8: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

104

Decode “1”;

End;

6. Store W’, the recovered watermark;

7. End.

It may be observed from both the algorithms that even if attacker alters the values of the

coefficient of FM region, if “Av” is not changed much, then we can recover the

watermark data correctly and attacker cannot aim to attack the image in such a manner

which modifies the “Av”.

6.2.4 PERFORMANCE OF THE PROPOSED SCHEME

Our proposed scheme does not need any testing to check whether or not it is robust

against the collusion attack as it is designed in such a way that the attacker can not

analyze the pattern by colluding many watermarked copies. We needed to check the

performance of the proposed scheme against the JPEG compression and other common

image manipulations and known attacks. We have tested our scheme on four JPEG test

images of Lena, Mandrill, Pepper and Goldhill shown in Figure 3.12 and watermark logo

is shown in Figure 3.13. We measured the image quality in terms of Peak Signal to Noise

Ratio (PSNR) and Correlation Coefficient (CC).

Firstly, we choose an appropriate value of “T” which affects least the image quality as

well as optimizes the recovery of the watermark data. Based on our earlier experiences

discussed in Section 5.3.5, we embedded the watermark logo in test images by keeping

T = 150 (in blue color channel) and then recovered watermark logos. Our experiments

suggested that in Lena, Mandrill and Pepper test images, there was, almost no loss in the

perceptual quality of the images (as shown in Figure 6.1) and recovered watermark logos

were of very fine quality. Figure 6.2 shows the watermark logos obtained from Lena,

Mandrill, Pepper and Goldhill. It was observed that for Goldhill test image, recovery was

not good. Therefore, we continued to experiment the same process for the Goldhill test

image at various values of T and we found that at T = 100, Goldhill test image was giving

the best recovered logo without much loosing its perceptibility. Figure 6.3 shows the

Page 9: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

105

goldhill test image after the watermark logo was embedded and the recovered logo.

Therefore, considering the “imperceptibility versus Robustness” trade-off, we fixed up

the value of T = 150 for the further tests for Lena, Mandrill, and Pepper JPEG test

images, and T = 100 for the Goldhill test image.

Figure 6.1: Watermarked test images generated by keeping T = 150

Figure 6.2: Extracted watermark logos from watermarked Lena, Mandrill, Pepper and Goldhill test

images respectively at T = 150

Figure 6.3: Goldhill test image after hiding the watermark logo and the recovered logo at T = 100

6.2.4.1 COLOR CHANNEL SELECTION AND PERFORMANCE AGAINST

JPEG COMPRESSION: Standard deviation (SD) depicts the spread of the frequency

values in a range. If the histogram of a chosen color channel of a particular image has less

spread, the image has less number of frequencies of the chosen color channel. Since, it is

the color channel i.e. the particular color frequencies that actually carry the watermark

data, we conclude that SD must play an important role. To explore the relationship

Page 10: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

106

between the selection of a color channel to carry the watermark data and the efficiency of

recovery, we decided to experiment on SD of all three color channels. Table 6.1 shows

the standard deviation of all three color channels for test images.

Table 6.1: SD values of color channels for test images

Lena Mandrill Pepper Goldhill

R channel 49.05 55.5 45.17 56.6

G channel 52.88 47.78 75.05 54

B channel 34.06 61.7 44.29 61

First, we hid the watermark data in the BLUE channel of all four test images. Then, we

compressed watermarked images using JPEG technique at various quality factors and

then recovered the watermark logos. We calculated the PSNR and CC values of extracted

logo. Table 6.2 summarizes the results. It was found that extracted watermark from

Mandrill and Goldhill test images were having poor values of PSNR and CC. Therefore,

for these two images, we repeated the above process by using “GREEN’ Channel. The

qualities of the extracted watermark logos from these two images were improved.

Therefore, we have related the performance of our scheme with color channel selection.

As, it may be observed from the Table 6.1 that for Lena’s and Pepper’s test images,

BLUE channel have lesser SD, whereas for Mandrill’s and Goldhill’s images, GREEN

channel has lesser SD. So it was concluded that lesser the SD better is the recovery of the

watermark data. This fixed up the BLUE channel for Lena’s and Pepper’s watermarking

and GREEN channel for rest two images. It is clear from Table 6.2 and Table 6.3 that

after using GREEN channel for Mandrill’s and Goldhill’s images, performance was

increased. It may be further observed from Table 6.3 that our proposed scheme is quite

robust against JPEG compression.

6.2.4.2 PERFORMANCE AGAINST IMAGE MANIPULATIONS: We performed

the following attacks on the watermarked test images:

Page 11: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

107

Attack-1: Equalize the Histogram;

Attack-2: Add 10 % Uniform noise;

Attack-3: Adjust the brightness to + 40 and contrast to + 25;

Attack-4: Adjust the hue and saturation to + 10 each;

Attack-5: Flip Horizontal; and

Attack-6: Apply uniform scaling (Zoom).

Our proposed scheme sustained all the attacks and qualities of extracted watermark logos

were very fine. Table 6.4 summarizes the CC of extracted logos from all test images.

Figure 6.4 shows the recovered logos from attacked images.

Table 6.2: PSNR and CC of extracted logo by using BLUE channel for all images

JPEG

Quality

Factor Lena Mandrill Pepper Goldhill

PSNR 20.898 10.53 24.876 12.53

Q = 60 CC 84.78 51.8 90.55 54.8

PSNR 21.672 9.756 25.412 12.11

Q = 40 CC 86.25 46.11 91.16 48.54

PSNR 19.597 9.27 23.508 9.88

Q = 20 CC 82.59 41 88.95 45.76

Page 12: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

108

Table 6.3: PSNR and CC of extracted logo by using BLUE and GREEN channels for images

JPEG

Quality

Factor

Lena

(BLUE),

T = 150

Mandrill

(GREEN)

T = 150

Pepper

(BLUE)

T = 150

Goldhill

(GREEN)

T = 100

PSNR 20.898 21.06 24.876 22.31

Q = 60 CC 84.78 85.12 90.55 91.45

PSNR 21.672 20.682 25.412 23.32

Q = 40 CC 86.25 84.98 91.16 92.56

PSNR 19.597 20.682 23.508 21.43

Q = 20 CC 82.59 84.97 88.95 91.45

6.2.4.3 COMPARATIVE STUDY WITH SIMILAR, STATE-OF-THE-ART

SCHEMES: We compared the performance of the proposed scheme against JPEG

compression with other similar schemes which are DCT based and well-known for their

robustness against JPEG compression.

Table 6.4: CC of the extracted logos

Test Images /Attacks

Lena

(BLUE),

T = 150

Mandrill

(GREEN),

T = 150

Pepper

(BLUE),

T = 150

Goldhill

(GREEN),

T = 100

Histogram Equalization 83.82 82.15 84.04 81.30

Uniform Noise (10%) 57.97 80.64 58.37 79.75 Brightness (+ 40) & Contrast

(+ 25) 81.05 77.13 80.69 76.25 Hue and saturation adjust (10

each) 86.09 85.62 86.35 85.65

Horizontal Flip 97.01 96.98 96.56 96.36

Uniform scaling 92.31 91.67 92.41 92.27

Page 13: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

109

Figure 6.4: Extracted logos from attacked watermarked images

The schemes chosen were:

Scheme-A: Correlation based Scheme (Section 2.1.3.1)

Scheme-B: The Classical Middle Band coefficient exchange scheme (Section 2.2.2.1)

Scheme-C: Collusion attack resistant watermarking scheme (Section 4.4): Scheme

proposed in Section 4.4 is also based on MBCE scheme and ICAR in nature. This scheme

swaps 4 pairs of coefficients in FM region in correlation with low band coefficients. We

are naming this scheme as Scheme-C.

Scheme-D: We named our proposed scheme as Scheme-D.

We re-implemented the first three chosen schemes ideas for JPEG colored images. In

their work “A Novel DCT-based Approach for Secure Color Image Watermarking” [7]

author have compared their proposed scheme against JPEG compression with Tsai [102],

cox [19], Fridrich [28] and Koch [48] approaches but they have given the results only up

to JPEG Quality factor Q = 20. Therefore, we compared our proposed scheme for very

Page 14: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

110

less JPEG quality factors such as Q = 5 and Q = 10. Most of the schemes started loosing

their efficiency at these quality factors.

We conclude that all the above schemes were very robust against JPEG compression

attack but if we compressed the watermark images at very low quality factors (less than

Q = 20), our proposed scheme outperformed the other schemes. No scheme, other than

the proposed one, was able to extract the detectible watermark logo at Q = 10 and 5.

Figure 6.5 shows the graph of CC values of recovered logos obtained from JPEG

compressed (at Q = 10) images which were watermarked using various schemes.

Figure 6.6 shows the graph of CC values obtained from JPEG compressed (at Q = 5)

images.

Therefore, the proposed scheme is not only an ICAR scheme but also enhances the

performance. Results indicate that the proposed scheme recovers the watermark even

from highly attacked images which are compressed up to Q = 5 quality factor of JPEG

(i.e. after 95-99% size reduction). In addition to this, the proposed scheme is resisting

common image manipulations like cropping, scaling, flipping, histogram equalization,

brightness- contrast adjustment, hue-saturation alteration and Gaussian noise.

0102030405060708090

100

Lena(Blue)

Mandrill ( Green)

peper(Blue)

Goldhill(Green)

Scheme-A Scheme-BScheme-C Scheme-D

Figure 6.5: Comparison of correlation coefficients at Q = 10

Page 15: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

111

Figure 6.6: Comparison of correlation coefficients at Q = 5

6.3 A DWT BASED WATERMARKING SCHEME FOR JPEG IMAGES

During the development of the above schemes, popularity of JPEG2000 image

compression/encoding increased. JPEG2000 is a wavelet-based image compression

standard. This standard has also been created by the Joint Photographic Experts Group

committee in the year 2000 with the intention of superseeding their original DCT based

JPEG standard (created in the year 1991). The standardized filename extension for

JPEG2000 image is .jp2. JPEG 2000 has a much more significant advantage over certain

modes of JPEG in that the artifacts are less visible and there is almost no blocking. The

compression gains over JPEG are attributed to the use of DWT and a more sophisticated

entropy encoding scheme.

Since .jp2 format is new upcoming image format and very less watermarking efforts have

been presented against this format conversion in the literature, we need to focus this

attack because BMP and JPEG images may have to undergo .jp2 image format

conversion/compression. To ensure that our watermarked images do not lose their

robustness against JPEG2000 format conversion attack, we further develop a

watermarking scheme which can sustain JPEG2000 format conversion attack also.

0102030405060708090

Lena(Blue)

Mandrill (Green)

peper(Blue)

Goldhill(Green)

Scheme-A Scheme-BScheme-C Scheme-D

Page 16: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

112

6.3.1 EXPLORATION OF DWT DOMAIN

Till now, all of our proposed watermarking schemes are DCT based, and therefore, very

robust against JPEG compression attack because JPEG encodes the images using DCT.

Both, DCT and DWT encode (or compress) the image very differently. Since JPEG2000

encodes the image using DWT, a DCT based scheme may not be fruitful if we are

targeting .jp2 conversion attack resistant nature in our watermarking scheme. Our earlier

results of “preprocessing” (Sections 4.2) also supported this fact. So, we decided to

explore DWT domain for the watermarking of JPEG images.

6.3.1.1 ISSUES IN USING DWT: Because of their inherent multi-resolution nature,

wavelet-coding schemes are especially suitable for applications where scalability is

important. The use of DWT is gaining popularity in signal processing, image

compression and watermarking. DWT gives extremely good results in the case of lossless

compression. But DWT has a serious issue when it comes to comparison with DCT for

the watermarking purposes. We cannot assume lossless manipulation in images; both in

watermark embedding and while the image is being attacked. In watermarking, one has to

ensure that the watermark data is recoverable even from highly

destroyed/manipulated/compressed/lossy cover image. Now, while using DCT domain, in

most of the cases, we take 8 x 8 DCT and thus have hundreds of DCT blocks. In each

DCT block, there are FL, FM and FH regions, as shown in Figure 2.3. We cannot use FH

because any manipulation operation will attack first on FH. FL has the major dominating

coefficient to recreate the image. If we use FL to hide the watermark data, cover image

perceptibility will be affected seriously. Therefore, we use FM region, or since, there are

so many FL regions, we can work out to devise a watermarking scheme that takes FL

region also into consideration without changing FL coefficient values.

On the other hand, DWT takes the complete image into consideration as shown in

Figure 6.7 and breaks it into four parts, namely LL, HL, LH, and HH region. This policy

may have several advantages but for watermarking, it has a very serious issue. Like DCT

blocks, we should not use HH region. LL region coefficients can also not be altered much

because these will heavily affect the image perceptibility (LL coefficients will alone

Page 17: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

113

generate a very good approximated image and we cannot alter these coefficients much).

HL and LH coefficients may be altered seriously by any image manipulation operation.

Unlike DCT based transformation (where there are so many FM regions to hide the

watermark data), there is only one LL region in DWT. Therefore, we have very less space

to hide the watermark data. Either we disturb heavily DWT coefficients and thus affect

the image perceptibility while hiding watermark data or to preserve to image quality, hide

watermark data in those regions which are less susceptible to get modified by image

manipulation operations and thus affecting the robustness of the watermarking scheme.

We thus conclude that if we use DWT for watermarking purpose, “Imperceptibility vs.

Robustness” balance is the new challenge for us. More precisely, the classical CDMA-

DWT based scheme as given in Section 2.2.3.1, a highly referred scheme which is very

robust against JPEG compression, affects the image quality up to a great extent. On the

other hand, if sub-band based technique [36] does not affect the image perceptibility after

hiding the watermark data, we may recover the watermark data from JPEG compressed

image only up to compression ratio 10-15 (Q = 70 approx). So, both the above well-

known schemes do not have a good balance in “Imperceptibility vs. Robustness” trade-

off.

Figure 6.7: 2-D Haar DWT

Page 18: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

114

Therefore, in this section, our target is to develop a watermarking scheme which is:

1) ICAR in nature (because it ensures the maximum coverage of financial

implications.)

2) JPEG2000 attack resilient (because it is upcoming DWT based image format).

3) Being a DWT based scheme, achieve a good balance in “Imperceptibility vs.

Robustness” trade-off, as most of the DWT based watermarking scheme do not

satisfy much of this quality.

We decided to explore Haar DWT for watermarking purposes because CDMA-DWT

[42][52] and Sub-band based scheme [36] used Haar DWT and in both these schemes,

use of Haar DWT has shown its robustness against “JPEG compression” as well as

“image imperceptibility” separately.

6.3.2 BACKGROUND OF THE PROPOSED SCHEME

We used a monochrome logo as a watermark data which we first converted into a string

of ‘0’s and ‘1’s. Now, we needed to hide ‘0’ and ‘1’, in our JPEG image, which we

converted into its equivalent RGB image. As we have said above that a single DWT

block of the image does not give us enough space to hide the data, we planned to take 8 x

8 DWT on a specified color channel of JPEG so that we have a large number of DWT

blocks and thus have enough opportunities to hide the watermark data. We used color

channel with lesser Standard Deviation (SD) (as discussed in Section 6.2). We inherited

the idea of classical MBCE scheme i.e. instead of actually embedding any data, we

interpret ‘0’ or ‘1’ by using the relative strength of two values. We claim that the

“average” value of all coefficients of a single LL region is less susceptible to

modification because LL coefficients are the major dominating coefficients and one

cannot change all coefficients much. Even if some of these have been altered after one

pass of coding and decoding (Taking DWT and then IDWT), the altered coefficients will

again try to get their original value (if we are not changing the perceptual quality of the

image). Therefore, “Average of all LL coefficients” may provide us a good robustness.

Page 19: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

115

Even if it is slightly modified, it is very less probable that relative values of “Averages”

of two consecutive LL blocks get modified. So we decided to hide “0” or “1” by using

the relative value of average of LL coefficients of two consecutive 8x8 DWT blocks.

6.3.3 DUAL WATERMARKING

Both DCT and DWT encode the image very differently. Since DWT based watermarking

scheme provides coverage against DWT based attack, our watermarking scheme may not

give good result against DCT transformation based attacks as in the case of JPEG

compression. Since we have a very robust DCT based scheme in hand (proposed in

Section 6.2), we decided to watermark the images using both schemes, one after another,

to ensure the maximum coverage against attacks.

So, first we watermark an image (I) using a DWT based approach to generate a

watermarked copy (I’) and the on I’, we again apply a DCT based scheme, presented in

Section 6.2, to generate a final watermarked copy I’’.

6.3.4 THE DWT BASED WATERMARKING

In our proposed dual watermarking, the DWT based watermarking scheme for JPEG

images is defined as a 7-tuple (X, W, P, T, G, E, D) where:

1. X denotes the set of instances Xi, of a particular JPEG image, (If N copies of

an image are to be watermarked, then 0 ≤ i ≤ N);

2. W denotes the monochrome watermark logo;

3. P denotes the set of policies Pi, 0 ≤ i ≤ N;

4. “T” is the “watermark strength parameter”.

5. G denotes the policy generator algorithm G: Xi Pi, where each Xi will have

a unique Pi, i.e. a different policy to hide the watermark data. This ensures the

ICAR nature;

6. E denotes the watermark embedding algorithm, E: Xi x W x Pi Xi’; 7. D denotes the watermark detection algorithm, D: Xi’ x Pi W’, Where W’

represents the extracted watermark.

Page 20: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

116

6.3.4.1 P, THE POLICY: P is a set of policies Pi, where each Pi belongs to a unique Xi,

the instance of an image. A Pi is generated by G and is of the form (Starting block (r,s),

offset, color channel). For example, for Lena test image which we used in our

experiments, Pi is (starting block (0,0), offset (1), Blue).

6.3.4.2 G, THE POLICY GENERATOR ALGORITHM: Similar to our earlier

proposed ICAR watermarking scheme for the gray image watermarking and colored

image watermarking, we need to watermark each copy Xi of a JPEG image X differently

to ensure the ICAR nature. Policy generator algorithm is called by E, after taking 8 x 8

DWT of the image. Since average of two consecutive LL blocks have to interpret “0” or

“1”, G ensures that no two copies of the same original image use the same pattern. So, G

achieves this by providing E, the calling routine, a starting block (which is chosen

randomly) and an offset. E can start grouping of 2 consecutive blocks using this data. For

example, consider an image of size 80 x 80. There will be 100, 8 x 8 DWT blocks in each

color channel as shown in Figure 6.8 and 6.9. If G returns the starting block (0,0) and

offset 1 in a specific color channel, then the blocks to be chosen to hide the watermark

data are shown in Figure 6.8. If G returns the starting block (5,5) and offset 2, then blocks

to be chosen to hide the watermark data are shown in Figure 6.9.

We assume the circular queue of the DWT blocks. If our source image is of 512 x 512

size, then there are 4096, 8 x 8 DWT blocks. Using G, we can generate thousands of

policies which ensure that no two watermarked copies will share same way to hide the

watermark data. The overhead of this G is that the author / owner has to record all

policies in his / her database to use in the decoding phase. This depicts that our proposed

scheme is an ICAR scheme.

Page 21: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

117

Figure 6.8: An example of 2 consecutive DWT blocks

Figure 6.9: An example of 2 consecutive DWT blocks

These first 2 blocks will hide first bit

These 2 consecutives blocks will hide second bit

These 2 blocks will hide second bit

These 2 blocks, having offset 2, will hide first bit

(5, 5) block

Page 22: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

118

Policy generator algorithm also returns the color channel to be used to carry the

watermark data. As discussed in the Section 6.2.4.1, we used the color channel with

lesser Standard Deviation (SD) to hide the watermark data.

6.3.4.3 E, THE WATERMARK EMBEDDING ALGORITHM: To explain the

embedding algorithm, we assume that G returns the DWT (0, 0) block as starting block

with offset as 1. A simple watermark embedding approach is shown in Figure 6.10.

Embedding algorithm steps are as follows:

1. Repeat steps 2 to12 for i = 1…..n;

// where ‘n’ is the number of copies of a single image X to be watermarked//

2. INPUT (Xi); // Xi is the instance of X.

3. Convert the Xi into its equivalent spatial domain 24-bit colored image;

4. Take 8 x 8 block DWT of Xi;

5. INPUT (W);

6. Convert W into a string S = (Sj | Sj = {0,1}, for j = 1…..length of the watermark);

7. Let L = STRING_LENGTH (S); // L is the length of watermark data. If L = 1000, then first 2000 DWT block of Xi are used to hide

the watermark data //

8. Pi = CALL (G); // Each Pi shall be stored in an author’s database for the detection purpose in future. Let the Pi,

for chosen Xi, be Pi = {DWT (0, 0), Offset (1), BLUE} which is shown in Figure 6.8 //

9. Repeat steps 10 to 12 for r = 1…..L;

10. Read Sr; // Based on Pi, the average “AV1” and “AV2” of 2 chosen DWT blocks is calculated as follows: //

AV1 = (Sum of all LL coefficients of DWT (0, 0))/16;

AV2 = (Sum of all LL coefficients of DWT (0, 1))/16;

If (Sr = 0)

If (AV1 - AV2 > 0)

v = (AV1 - AV2) / 16;

Page 23: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

119

Subtract v from all coefficients of DWT (0, 0);

Add v in all coefficients of DWT (0, 1);

End;

// Now relative value of AV1 and AV2 reflects the watermark bit. To further increase the

robustness, we adjust the LL coefficients values such that difference of AV1 and AV2 become at

least ‘T’, the watermark strength parameter //

Subtract T / 2 from all LL coefficients of DWT (0, 0);

Add T / 2 in all LL coefficients of DWT (0, 1);

Else If (Sr = 1)

If (AV1 - AV2 < = 0)

v = (AV2 - AV1) / 16;

Subtract v from all coefficients of DWT (0, 1);

Add v in all coefficients of DWT (0, 0);

End;

// Now relative value of AV1 and AV2 reflects the watermark bit. To further increase the

robustness, we adjust the LL coefficients values such that difference of AV1and AV2 become at

least ‘T’, the watermark strength parameter //

Subtract T / 2 from all L coefficients of DWT (0, 1);

Add T / 2 in all LL coefficients of DWT (0, 0);

End;

11. Take IDWT to reconstruct Xi;

12. Convert Xi back to its JPEG format;

13. End.

Page 24: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

120

6.3.4.4 D, THE WATERMARK DETECTION ALGORITHM: Watermark

extraction is the reverse procedure of watermark embedding. To extract the watermark

from the watermarked JPEG image, first we converted it into its equivalent 24 bit colored

images, took 8 x 8 DWT and then calculated the average “AV” of consecutive blocks

based on policies stored in author’s database.

The detection algorithm steps are as follows:

LL LL

Divide image in 8x8 block

2 Consecutive 8x8 blocks will hide a single bit “0” or “1”

Take average of these 16 coefficients (AV1)

Take average of these 16 coefficients (AV2)

Adjust AV1 and AV2 (By changing LL coefficients little bit) such that their relative values reflect the watermark bits “0” or ‘1”. If AV1 > AV2 => “1” else “0”.

So, 1000 watermark bits will be hidden using 2000 consecutive 8 x 8 DWT blocks. Then IDWT will be taken. After then, image will be dual watermarked using DCT based watermarking scheme presented in Section 6.2.

Generated using G

Now consider next 2 consecutive blocks to hide next bit and so on

Figure 6.10: Watermark embedding approach

Page 25: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

121

1. INPUT (Xi’);

// Xi’ is the attacked copy of a watermarked image //

2. Convert Xi’ into its equivalent 24 bit colored image;

3. Take 8 x 8 block DWT of Xi’ for the specific color channel;

// Based on Pi, author knows which color channel was used to hide the watermark data for a

specific image //

4. Repeat step 5 to step 7 for each Pi;

5. Based on each Pi, group the DWT blocks in pairs;

6. For i = 1 to 2 * (L-1) repeat step 7;

// L is the length of W //

7. For each pair (AV1, AV2) of DWT blocks;

If (AV 1 > AV2)

Decode ‘1’;

Else Decode “0”;

8. Reconstruct W’, the extracted watermark;

9. End.

6.3.5 THE DCT BASED WATERMARKING

After hiding the watermark logo using DWT based watermarking presented above, we

dual watermarked the images using DCT based watermarking presented in Section 6.2.

6.3.6 RESULTS

We applied the proposed dual watermarking scheme on three standard JPEG test images

of Lena, Mandrill and Pepper. In this section, we used a different watermark logo, which

is shown in Figure 6.11.

Page 26: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

122

Figure 6.11: The watermark logo

6.3.6.1 THE VALUE OF “T”: Our proposed DWT based scheme takes a watermark

strength parameter as an input. This T itself tries to balance the “Imperceptibility versus

Robustness” trade-off. To decide the optimal value of this parameter, we hid the

watermark data in test images at various values of T and then calculated the PSNR values

of the watermarked images. Some of those values (which will lead us to a final value) are

shown in Table 6.5. After this, the watermark data was recovered and the quality of the

watermark data was measured using Correlation Coefficient.

Table 6.5: PSNR of watermarked image and CC of extracted logo for various values of T

Lena Mandrill Pepper

T

(LL

Band)

PSNR of

color channel

CC of

recovered logo

PSNR of

color

channel

CC of

recovered logo

PSNR of

color

channel

CC of recovered

logo

500 30.23 64.36 31.2844 51.8 31.3257 56.49

600 28.65 71.88 29.7187 60.29 29.7521 63.19

700 27.32 74.7 28.3907 64.5 28.4188 65.76

Table 6.6: Revised Table 6.5

T = 500 T = 600 T = 700

PSNR 75.575 71.625 68.3

Lena CC 64.36 71.88 74.7

PSNR 78.211 74.29675 70.97675

Mandrill CC 51.8 60.29 64.5

PSNR 78.31425 74.38025 71.047

Pepper CC 56.49 63.19 65.76

Page 27: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

123

0

10

20

30

40

50

60

70

80

90

PSNR CC PSNR CC PSNR CC

Lena Mandrill Pepper

T=500T=600T=700

Figure 6.12: Graph of the values shown in Table 6.6

Table 6.5 represents the above results. It is obvious that for the higher values of “T”, the

PSNR values of the watermarked images decrease but at the same time, the CC of the

extracted logos increase. To decide the value of T, we first brought the values of PSNR

data in the range of CC data, by multiplying by 2.5 and then reproduced the Table 6.6.

Figure 6.12 shows the graph of the values shown in Table 6.6. It may be observed that

series for T = 600 is always lying between the series of T = 500 and T = 700. It means

that value T = 600 is the best value, under the “Imperceptibility versus robustness trade

off”. Similarly for other values of T, if PSNR value is good, CC value is poor and vice-

versa.

We conducted further tests by using T = 600 for all test images. It may be noted that our

target was to embed the JPEG2000 attack resistant nature using DWT based embedding

without loosing the robustness against those attacks which our DCT based scheme could

sustain. Therefore, first we hid the watermark logo using DWT based scheme, and then

checked its robustness against JPEG2000 attack. As presented in Table 6.6, the quality of

the watermarked image did not decrease considerably. We converted the watermarked

Page 28: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

124

JPEG images (without applying DCT based scheme) to JPEG2000 format. Then, we

recovered the watermark logos from these watermarked images (which are converted to

JPEG2000 format). Table 6.7 represents the CC coefficients of extracted logos.

Figure 6.13 shows the extracted logos from JPEG2000 converted watermarked Lena,

mandrill and Pepper’s test images.

Table 6.7: CC of extracted logos from JPEG2000 attacked images

Test Image CC

Lena 67.71

Mandrill 55.45

Pepper 58.94

Figure 6.13: Extracted logos from Lena, Mandrill and Pepper’s test images

It may be observed from Table 6.7 and Figure 6.13 that our proposed DWT based

watermarking scheme is capable of sustaining JPEG2000 format conversion attack.

In order to implement the dual watermarking scheme, we further applied the DCT based

scheme on the watermarked images which were generated by applying DWT based

scheme. Now we had to check the effect on the image perceptibility as well as robustness

against JPEG2000 format conversion attack. Table 6.8 shows the decrement in the PSNR

values after the application of DCT based scheme. Though decrement is natural, it is not

perceptually visible in the PSNR values. It is a compromise with the image quality to

make the watermarked images very robust against more DCT based attacks, which we

will present later in this section.

Page 29: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

125

Table 6.8: Decrement in the PSNR values after the application of DCT based scheme

PSNR if only DWT

based scheme is applied

PSNR if both DWT &

DCT based scheme are

applied

Lena 25.69 25.23

Mandrill 25.83 24.97

Pepper 24.15 23.76

After applying dual watermarking scheme, we again conducted the JPEG2000 format

conversion attack on the watermarked images. Now we had a choice. We could recover

the watermark logos either by applying DWT based recovery or by applying DCT based

recovery. Table 6.9 shows the CC values of the extracted watermark logos recovered by

both recovery methods which clearly indicate that DCT based recovery gave better

results.

Figure 6.14 shows the extracted logos using DWT based method and Figure 6.15 shows

the extracted logos using DWT based method.

Table 6.9: CC values of the extracted watermark logos recovered by both recovery methods

CC if DWT based

recovery is applied

CC if DCT based

recovery is applied

Lena 64.7 91.56

Mandrill 52.14 44.1

Pepper 57.4 88.35

Figure 6.14: Extracted logos using DWT based method

Page 30: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

126

Figure 6.15: Extracted logos using DCT based method

6.3.6.2 PERFORMANCE AGAINST JPEG COMPRESSION: We have seen in the

previous section that our proposed DCT based scheme is very robust against JPEG

compression attack. We need to check the robustness of the dual watermarking scheme

presented in this section against JPEG compression. We compressed all test images after

applying dual watermark at very low JPEG quality factor Q = 20, 10 and 5 and recovered

the watermark logos using DCT based recovery. Our proposed dual watermarking

sustained this attack very strongly even at Q = 5. Table 6.10 shows the CC of the

extracted logos. Figure 6.16 shows the extracted logos.

Table 6.10: CC of extracted logo from highly compressed jpeg image using DCT based recovery

Q = 20 Q = 10 Q = 5

Lena 94.39 77.36 76.5

Mandrill 55.95 60.73 57.24

Pepper 92.63 80.35 76.37

Q = 20 Q = 10 Q = 5

Lena

Mandrill

Pepper

Figure 6.16: Extracted logos from highly compressed JPEG images

Page 31: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

127

6.3.6.3 PERFORMANCE AGAINST COMMON ATTACKS AND IMAGE

MANIPULATIONS: Since we know that transform domain based schemes are very

robust against those attacks which can reduce the size but not the perceptual quality, we

conducted some attacks on our dual watermarked images, which change the perceptual

quality of an image too. The attacks are as follows:

Attack 1: Adding uniform noise (10%),

Attack 2: Adding Gaussian noise (10 %),

Attack 3: Equalizing histogram,

Attack 4: Applying uniform scaling,

Attack 5: Adjusting brightness (+ 40) and contrast (+ 25),

Attack 6: Horizontal flipping, and

Attack 7: Adjustment of hue and saturation (+ 10 each).

Table 6.11 shows the CC of the extracted watermark logos and Figure 6.17 shows the

extracted watermark logos. It may be observed that the proposed dual watermarking

scheme sustained all the above mentioned attacks.

6.3.6.4 COMPARATIVE STUDY WITH DCT BASED SCHEMES: We compared

the performance of the proposed scheme against JPEG compression with other similar

schemes which are DCT based and well known for their robustness against JPEG

compression. We re-implemented these schemes for JPEG images. Schemes chosen

were:

Scheme-A: Correlation based scheme (Section 2.1.3.1)

Scheme-B: The classical Middle Band Coefficient Exchange scheme (Section 2.2.2.1)

Scheme-C: Collusion attack resistant watermarking scheme (Section 4.4): Scheme

proposed in Section 4.4 is also based on MBCE scheme and ICAR in nature. This scheme

swaps 4 pairs of coefficients in FM region in correlation with low band coefficients. We

are naming this scheme as Scheme-C.

Scheme-D: The scheme presented in Section 6.2.

Scheme E: The proposed dual scheme in this section.

Page 32: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

128

Table 6.11: CC of the extracted watermark logos

Attacks Lena Mandrill Pepper

Adding uniform noise (10%) 80.6 52.39 84.83

Adding Gaussian noise (10 %) 56.8 47.42 74.56

Equalizing histogram 91.45 52.42 92.73

Applying uniform scaling 91.56 53.67 93.11

Adjusting brightness (+ 40) and contrast (+ 25) 87.3 53.95 89.12

Horizontal flipping 90.46 51.68 92.12

Adjustment of hue and saturation (+ 10 each) 93.75 56.78 92.87

Figure 6.17: Extracted watermark logos after applying common attacks

Page 33: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

129

We watermarked the test images by using all chosen watermarking schemes and then

conducted very low JPEG compression (up to Q = 5, whereas most of the research papers

presented results only up to Q = 20). Then we calculated the CC of the extracted logos. It

may be observed from Table 6.12 and 6.13 that Scheme-E performs better than Scheme-

A, B and C. As compared to scheme-D, Scheme-E did not lower the performance but at

some point (Lena’s image at both Q = 5 and 10, and Pepper’s image at Q = 5) improves

the CC of the extracted logos.

6.3.6.5 COMPARATIVE STUDY WITH DWT BASED SCHEMES: As compared

to Classical CDMA-DWT based schemes presented in Section 2.2.3.1, our scheme

outperforms in the quality of the watermarked image (refer Table 6.8).

Table 6.12: Comparison of CC of Extracted logos from JPEG compressed (Q = 10) watermarked images

Lena Mandrill Pepper

Scheme-A 5.6 6.5 4.5

Scheme-B 4.5 6.7 6.5

Scheme-C 12.23 12.65 11.65

Scheme-D 71.12 74.53 84.28

Scheme-E 77.36 60.73 80.35

Table 6.13: Comparison of CC of Extracted logos from JPEG compressed (Q = 5) watermarked images

Lena Mandrill Pepper

Scheme-A 3.98 5.34 3.40

Scheme-B 3.47 5.02 4.98

Scheme-C 10.59 11.21 10.24

Scheme-D 72.32 72.33 75.04

Scheme-E 76.5 57.24 76.37

Page 34: CHAPTER-6 WATERMARKING OF JPEG IMAGESietd.inflibnet.ac.in/jspui/bitstream/10603/2413/14/16_chapter 6.pdf · 6.2 DEVELOPMG AN ICAR WATERMARKING ALGORITHM FOR JPEG IMAGES Most of the

130

Sub-band filtering based watermarking scheme [36] is very good in preserving the

perceptual quality of the watermark images but when it come to the robustness against

JPEG compression, authors presented results only up to the compression ratio 10 to 15

whereas our proposed watermarking scheme can decode the watermark data up to the

quality factor Q = 5 (refer Table 6.13) i.e. the compression ratio 2 to 3.

It further proves that our proposed scheme has achieved a very good balance in

“imperceptibility versus robustness tradeoff while using DWT based watermarking

scheme.

6.4 CONCLUSION

In this chapter, we provided 2 watermarking schemes for watermarking the JPEG images.

The first scheme is DCT based and the other one is a dual watermarking scheme having a

DWT based watermarking as a component. Both schemes are very robust especially

against JPEG compression and other common image manipulation and attacks. Both

schemes also achieve a very good balance in “Image-imperceptibility vs. robustness”

trade-off and are ICAR in nature.