Image Watermarking Based on DWT Coefficients Modification for Social Networking Services Kharittha Thongkor, Narong Mettripun, Thitiporn Pramoun, Thumrongrat Amornraksa Multimedia Communications Lab., Computer Engineering Department, Faculty of Engineering, King Mongkut’s University of Technology 126 Pracha-uthit Rd., Bangmod, Thungkru, Bangkok, 10140, Thailand
[email protected],
[email protected],
[email protected],
[email protected]
techniques developed for social networking services should be robust against image compression attacks. The researches on this relevant topic are shown as follow. In 2006, T. Amornraksa et al. [4] proposed the method to embed a watermark bit into an image pixel in blue component by balancing the watermark bits around the embedding pixels, tuning the strength of embedding watermark in according with the nearby luminance, and reducing the bias in the prediction of the original image pixel from the surrounding watermarked image pixels. Their approach was proved to be robust against various types of attacks especially geometrical attacks, but it could not robust against JPEG attack same as previous methods in [5] and [6]. In 2009, C-H. Lai et al. [7] proposed to embed watermark if standard derivation of its nearby pixels in window size 3x3 was smaller than or equal a predefined Keywords— social networks, digital image watermarking, threshold. The extracted watermark can be extracted by discrete wavelet transform (DWT), mean filter measuring the sign of difference value between watermarked image in blue component and average value of blue I. INTRODUCTION component of watermarked image. This method can extract Presently, social networking services, e.g. Facebook, watermark from distorted image which local geometric Google+, Instagram and etc., have more influence to our daily distortions and small RST distortions were occurred by using life than they did in the past, judged from an on-going multi-scaled neighborhood-matching method. Nonetheless, increasing number of social network subscribers. For example, the embedded watermark was easy to destroy by mean filter. Facebook which have been launched since February 2004 had In 2010, J.A. Hussein [8] proposed a digital watermarking over 100 million subscribed users in July 2008, over 500 method based on log-average luminance. Some 8×8 pixels million in July 2010 and over one billion in September 2012 blocks were chosen and used for watermark embedding if they [1]. Because of attractive features provided for multimedia had a log-average luminance greater than or equal to the logdata, subscribers can simply publish and/or exchange these average luminance of the whole image. Their method was data. However, multimedia data published in the social robust against geometric attacks, e.g. cropping. However, their networks is easy to be copied and distributed without any method degraded the image quality, which could be perceived permission from the real owner, and very difficult to by the human eyes since they modified the luminance differentiate the copied version from the original one. In order components of host image. In 2011, Y-H. Chen et al. [9] to protect the copyright of the distributed data, digital proposed a copyright information embedding system for watermarking techniques have been developed and android platform. Firstly, pre-specified copyright information implemented. Good introduction on digital watermarking can is embedded into images by using digital watermarking be found on [2]. Although the digital watermarking techniques technique when these images are taken. Then, watermarked can be applied for social networking services, there is still a image will be automatically uploaded to the internet. In problem. Because the images/photos published on them are addition, original images can be preserved electively. Their always changed and/or compressed [3] by the uploading approach reduced the complexity of watermark embedding process such as JPEG quantization table, pixel resolution and process for handheld mobile system. However, this system related metadata. Therefore, the digital watermarking can embed the watermark bits only about 0.0064 - 3.125 % of the original image bits. Recently, A. Zigomitros et al. [10] proposed social network content management through Abstract—this paper considers a situation where the copyright of distributed images/photos in social networks is violated. Since the images/photos published on social networks are usually modified and/or compressed to the match the template provided by the service providers, we thus propose a digital image watermarking based on DWT coefficients modification to be used for such images/photos. Basically, in the embedding process, the blue component of original host image is decomposed by the Discrete Wavelet Transform (DWT) to obtain the coefficients in LL subband, and some of them are used to carry watermark signal. In the extraction process, original coefficients prediction in the LL sub-band based on mean filter is employed to extract the embedded watermark. The experimental results show that the performance of our proposed method in term of average NC is superior to the previous ones.
978-1-4799-0545-4/13/$31.00 ©2013 IEEE
watermarking. Their approach mainly focused on the image authentication for social networks. They discussed about the policy that could be implemented using digital watermarking to make the social networks become more privacy. However, they do not specifically design any digital watermarking method for the social networking services. In this paper, we propose a digital image watermarking for social networking services based on DWT coefficients modification. In the embedding process, the blue component of original host image is decomposed by the Discrete Wavelet Transform (DWT) to obtain the coefficients in LL sub-band in order to embed watermark. In the extraction process, original coefficients prediction based on mean filter is used to increase the accuracy of the extracted watermark. Section 2 describes the detail of the proposed method. Section 3 presents the experimental setting and results. The performance obtained from the proposed method are evaluated and compared to the previous methods. Finally, the conclusion of our paper is drawn in section 4.
After that, wϕNew (i, j ) is permuted by using Gaussian distribution for spreading the watermark bits pattern, and XORed with a pseudo-random bit stream generated from a key based stream cipher to provide security to finally obtain wϕE (i, j ) . The resultant coefficient is converted to 1 and -1 before embedding it to the coefficients in LL sub-band of the original host image, one bit by one coefficient. The blue component of original host image (B) is decomposed by the 2D-DWT to obtain 4 sub-bands, which are approximation sub-band ( Bϕ (i, j ) ), horizontal sub-band ( BψH (i, j ) ), vertical sub-band ( BψV (i, j ) ) and diagonal subband ( BψD (i, j ) ) (see Fig. 2). The coefficient in LL sub-band ( Bϕ (i, j ) ) is selected to embed watermark ( wϕE (i, j ) ) by using equation (2).
II. PROPOSED METHOD The proposed watermarking method is separated into two processes: watermark embedding and extraction processes. A. Watermark Embedding Process In this process, a black and white logo image ( I w ) with the same size (M×N) as original host image ( I ) is considered as a watermark logo. It is first decomposed by the 2D-DWT to obtain four sub-bands [11] (see Fig. 1).
a) Host image
b) Sub-bands of host image
Fig. 2 The host image ‘Lena’ and its sub-bands, respectively
Bϕ′ (i, j ) = Bϕ (i, j ) + wϕE (i, j ) sT (i, j )
Fig. 1 Watermark logo ‘Panda’ and its sub-bands, respectively
Then, the watermark coefficients in LL sub-band whose value can be 0, 1, 1.5, and 2 are selected and converted to two-value coefficients, 1 or 0, as follow.
⎧1 ; if w (i, j ) ≥ 1.5 ⎪ ϕ New wϕ (i, j ) = ⎨ ⎪0 ; if wϕ (i, j ) < 1.5 ⎩
where Bϕ′ (i, j ) is watermarked coefficient, s is signal strength which is a constant factor used for the entire watermarking area and T (i, j ) is the tuned coefficient value for each embedding bit which is derived from resizing the luminance of original host image, L(i,j)=0.2999R(i,j)+0.587G(i,j)+0.114B(i,j). Finally, Bϕ′ (i, j ) , BψH (i, j ) , BψV (i, j ) and BψD (i, j ) are inverse transformed by using the 2D-IDWT, and then the result B T (i, j ) is combined with original red (R) and green (G)
components to construct the watermarked image ( I ' ) as shown in Fig. 3.
(1)
(2)
{
Coefficient convertion
2D-DWT
I w (i, j)
2D-DWT
Permutation s
Bϕ (i, j )
wϕE (i, j )
BψH (i, j ) BψV (i, j ) BψD (i, j )
Bϕ′ (i, j )
T(i,j) Key based stream cipher
2D-IDWT
Secret key
BT (i, j)
wϕ′ E (i, j ) is 1 (or -1, respectively). After that wϕ′ E (i, j ) is XORed with the same pseudo-random bit stream as used in the embedding process and then the result is passed to invert permutation to obtain wϕ′′ E (i, j ) . Finally, wϕ′′ E (i, j ) is combined
sub-band ( wψD (i, j ) ) set to 0, and the result is inverse transformed using the 2D-IDWT to obtain the extracted watermark ( I w′ (i, j ) ). Block diagram of the extraction process is shown in Fig. 4.
B. Watermark Extraction Process It can also be seen from equation (2) that embedding the permuted watermark into the coefficients in LL sub-band of the original host image is similar to adding the high frequency noise to those coefficients. Therefore, the watermarked coefficients are considered as noisy coefficients ( Bϕ′ (i, j ) )
formed by the addition of random noise (n(i,j)) to Bϕ (i, j ) . The equation (2) can be rewritten as Bϕ′ (i, j ) = Bϕ (i, j ) + n(i, j )
⎛ m n ⎞ 1 ⎜ Bϕ′ (i , j ) ⎟ ⎟ (2 m + 1)(2 n + 1) ⎜⎝ i = − m j = − n ⎠
∑∑
(4)
Then, with the expectation that E Bϕ (i, j ) = Bϕ (i, j )
Bϕ′ (i, j )
B T (i, j ) wψH (i, j )
wϕ′ E (i, j )
wψV (i , j ) ′′ E
wϕ (i , j )
wψD (i , j)
(3)
To extract the embedded watermark, B T (i, j ) is decomposed by the 2D-DWT to obtain noisy coefficients for a prediction of original coefficients in LL sub-band. With the assumption that at every pair of coefficient (i,j), the noise is uncorrelated [9]. Therefore, it can be shown that if a coefficient Bϕ (i, j ) is formed by averaging m×n coefficients around (i,j) of the noisy coefficients as follow.
}
}
E Bϕ (i, j ) =
with coefficients in LH ( wψH (i, j ) ), HL ( wψV (i, j ) ) and HH
Fig. 3 Block diagram of proposed watermark embedding process
{
{
(6)
1 1 1 ∑ ∑ Bϕ′ (i + m, j + n) . To 9 m=−1 n=−1 recover the original watermark logo, the value of wϕ′ New (i, j ) = 0 is set as a threshold, and its sign is used to estimate the value of wϕ′ E (i, j ) . That is, if wϕ′ New (i, j ) is positive (or negative), where
B(i, j )
wϕNew (i, j )
B ϕ (i , j ) =
}
wϕ′ New (i, j ) = Bϕ′ (i, j ) − E Bϕ (i, j )
wϕ (i, j )
(5)
The expectation of Bϕ (i, j ) can be represented by using mean filter with the window size of m×n coefficients. These predicted coefficients are finally subtracted from watermarked coefficients in LL sub-band to extract the embedded watermark. This step can be described by equation (6).
I w′ (i, j) Fig. 4 Block diagram of proposed watermark extraction process
III. EXPERIMENTAL SETTING AND RESULTS A. Experimental setting In the experiments, a standard color image, namely ‘Lena’ with various image sizes, i.e. 128×128, 256×256 and 512×512 pixels, were used as original host images. The black & white images containing a logo ‘Panda’ with the same image sizes as host images were used as watermark logo. Firstly, each watermark logo was embedded to its original host image at the same size in the embedded process. Then, watermarked image at various PSNRs and various image sizes were uploaded to the four chosen social networking services which are famous in the present [3], i.e. Facebook, Goolge+, Myspace and Pinterest, after that, those uploaded watermarked images were downloaded from each of them to extract the watermark.
⎡ ⎢ ⎢ PSNR (dB) = 20 log10 ⎢ ⎢ ⎢ ⎢ ⎣ M
⎤ ⎥ ⎥ 255 3MN ⎥ N ⎥ ( I ' (i, j ) − I (i, j )) 2 ⎥ ⎥ j =1 ⎦
M
N
M
N
∑∑ w(i, j) ∑∑ w' (i, j ) 2
i =1 j =1
Proposed method
0.81 0.74
0.6 25
30
35
40
PSNR (dB)
N
Fig. 5 Performance comparison in term of average NC at various PSNRs for Facebook
i =1 j =1
M
Previous method [7]
0.67
(7)
∑∑ w(i, j)w' (i, j ) NC =
Previous method [8]
0.88
∑∑ i =1
Previous method [4]
0.95
Average NC
In all experiments, the quality of watermarked image was evaluated by measuring its Peak Signal-to-Noise Ratio (PSNR) while the accuracy of extracted watermark was evaluated by measuring its Normalize Correlation (NC). For both evaluation methods, the higher value indicates a better result obtained. Note that both of them are performed in spatial domain.
(8) 2
Previous method [4]
Previous method [8]
Previous method [7]
Proposed method
i =1 j =1
0.95 0.88
Avera ge NC
where M and N are the numbers of row and column in the images, respectively. w(i,j) and w’(i,j) are the original and the extracted watermark bits at pixel (i,j), respectively. Table 1 shows the file sizes before uploading and after downloading the watermarked images at various input image sizes. From our observation, we found that if image size of input image is larger than the limitation, Facebook will automatically resize it to 960×960 pixels and Google+ will automatically resize it to 570×570 - 640×640 pixels.
0.81 0.74 0.67 0.6 25
TABLE I THE FILE SIZE OF THE WATERMARKED IMAGES BEFORE UPLOADING AND AFTER DOWNLOADING FROM FOUR SOCIAL NETWORKING SERVICES AT VARIOUS IMAGE SIZES
256×256
512×512
48 Kbytes 48 Kbytes 48 Kbytes 49 Kbytes
192 Kbytes 192 Kbytes 192 Kbytes 192 Kbytes
768 Kbytes 768 Kbytes 768 Kbytes 768 Kbytes
6.62 Kbytes 9.92 Kbytes 9.06 Kbytes 49 Kbytes
18 Kbytes 30.9 Kbytes 21.3 Kbytes 192 Kbytes
147 Kbytes 100 Kbytes 61.2 Kbytes 768 Kbytes
40
Fig. 6 Performance comparison in term of average NC at various PSNRs for Google+
Image size (pixels)
128×128
35 PSNR (dB)
Previous method [4]
Previous method [8]
Previous method [7]
Proposed method
0.95 0.88
Avera ge NC
Name of social networking services Upload 1. Facebook 2. Google+ 3. Myspace 4. Pinterest Download 1. Facebook 2. Google+ 3. Myspace 4. Pinterest
30
0.81 0.74 0.67 0.6
B. Experimental results We evaluated the accuracy of the extracted watermark from our proposed method compared to three previous methods at various PSNRs for each social networking service. The results were then represented shown in Fig. 5-8.
25
30
35
40
PSNR (dB)
Fig. 7 Performance comparison in term of average NC at various PSNRs for Myspace
Previous method [4]
Previous method [8]
Previous method [7]
Proposed method
Facebook
Google+
Myspace
Pinterest
0.95
Average NC
0.88
Uploaded watermarked images (512×512 pixels)
0.81 0.74 0.67
Previous method[4]
0.6 25
30
35
40
PSNR (dB)
Fig. 8 Performance comparison in term of average NC at various PSNRs for Pinterest
It can be clearly seen from the above results that on average our proposed method obtained the better performance than previous methods for all chosen social networking services. Fig. 9 shows the performance comparison in term of average NC of proposed method and three previous methods at PSNR 35 dB and various image sizes. The examples of 512×512 pixels extracted watermarks from our proposed method and three previous methods at PSNR 35 dB are also illustrated in Fig. 10.
Previous method[7]
Previous method[8]
Proposed method Previous method[4]
Previous method[8]
Previous method[7]
Proposed method
0.93
From all results obtained, it is clear that our proposed method outperforms the other methods. This is because all watermark energy was embedded into the low frequency component, i.e. LL sub-band, only. Moreover, most of them could thus survive various types of attacks, especially image compression always occurred from the social networking services.
0.86
Avera ge NC
Fig. 10 Examples of the extracted watermark of our proposed method and three previous methods
0.79
0.72
0.65 128×128
256×256
512×512
Image size(Pixels)
Fig. 9 Performance comparison in term of average NC at PSNR 35 dB and various image sizes
IV. CONCLUSIONS The digital watermarking method based on DWT coefficients modification for social networking services has been presented in this paper. In the embedding process, the coefficients in LL sub-band were used to embed watermark. In the extraction process, original coefficient prediction based on mean filter is used to increase the accuracy of the extracted watermark.The experimental results showed a better performance, in term of average NC value obtained, from the proposed method at various PSNRs and image sizes.
REFERENCES [1] [2] [3]
[4]
[5]
[6]
(2012) The Facebook website. [Online]. Available: http://newsroom.fb.com/Key-Facts. F. Y. Shih, Digital Watermarking and Steganography Fundamental and Techniques, CRC Press, New York, USA, 2007. A. Castiglione, G. Cattaneo, and A. D. Santis, “A Forensic Analysis of Images on Online Social Networks,” in Proc. INCoS’11, 2011, Fukuoka, Japan, 30 Nov-2 Dec, pp. 679-684. T. Amornraksa, and K. Janthawongwilai, “Enhanced Images Watermarking based on Amplitude Modulation,” Image and Vision Computing, vol. 24, no. 2, pp. 111-119, 2006. K. Thongkor, and T. Amornraksa, "Method of Image Watermarking by Dividing Watermark into Two Chrominance Channels", in Proc. of ISCIT’10, 2010, Tokyo, Japan, 26-29 Oct, pp. 498-503. K. Thongkor, and T. Amornraksa, "Image Watermarking by Embedding Watermark into Two Chrominance Channels", in Proc. of ISPACS’10, 2010, Cheng Du, China, 6-8 Dec, pp. 253-256.
[7]
C-H. Lai, and J-L. Wu, “Robust Image Watermarking Against Local Geometric Attacks Using Multiscale Block Matching Method,” Journal of Visual Communication and Image, vol. 20, no. 6, pp. 377-388, 2009. [8] J. A. Hussein, “Spatial Domain Watermarking Scheme for Colored Images Based on Log-Average Luminance,” Journal of Computing, vol. 2, no. 1, pp. 100-103, 2010. [9] Y-H. Chen, and C. H. C. Huang, “A Copyright Information Embedding System for Android Platform,” in Proc. IIH-MSP’11, 2011, Dalian, China, 14-16 Oct, pp. 21-24. [10] A. Zigomitros , A. Papageorgiou, and C. Patsakis, “Social Network Content Management through Watermarking,” in Proc. TrustCom’12, 2012, Liverpool, England, 25-27 Jun, pp.1381-1386. [11] R. C. Gonzalez, and R. E. Woods, Digital Image Processing, Prentice Hall, New Jersey, USA, 2002.