{'fraction_non_alphanumeric': 0.031915561977759625, 'fraction_numerical': 0.012313878243387573, 'mean_word_length': 4.839325018341893, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 1, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Robust Image Watermarking Using Non-Regular Wavelets

An approach to watermarking digital images using non-regular wavelets is advanced. Non-regular transforms spread the energy in the transform domain. The proposed method leads at the same time to increased image quality and increased robustness with respect to lossy compression. The approach provides robust watermarking by suitably creating watermarked messages that have energy compaction and frequency spreading. Our experimental results show that the application of non-regular wavelets, instead of regular ones, can furnish a superior robust watermarking scheme. The generated watermarked data is more immune against non-intentional JPEG and JPEG2000 attacks.

robustness of spatial techniques are sensitive to compression and lowpass filters. Nevertheless, it continues to find recent applications [12].
Another possible venue is the insertion of the watermark into the spectral domain of the subject data.
There are approaches that embed the watermark in the low-frequency subbands to improve the robustness against a variety of attacks, e.g. lowpass filtering and compression. Several transform techniques have been employed to fulfill this purpose. Among them, the discrete Fourier transform, the discrete cosine transform, and a number of wavelet transforms deserve mention. However, current investigations in this area significantly embrace the application of wavelets. Publications [13][14][15][16] describe several wavelet domain watermarking methods and include comparisons.
In this paper, we propose a new watermarking technique that is based on non-regular wavelet transforms. The application of non-regular transforms to image processing is novel. Our experimental results show that non-regular transforms are superior to regular transforms for robust watermarking purposes. The reason that non-regular wavelet filters are more robust is that they offer energy spreading, while regular wavelet filters offer energy concentration.
The paper is organized as follows. Section 2 presents non-regular discrete wavelet transforms (DWT) and a watermarking method using non-regular wavelets is proposed in Section 3. In Section 4, a statistical method for watermarking detection is elaborated. Computational experiments and discussions are presented in Section 5. Finally, Section 6 summarizes the obtained results.

Non-regular Discrete Wavelet Transforms
Frequently, wavelet generation is based on filter bank methods. Filter banks that perform DWT have always been designed so that in addition to perfect reconstruction the filters have in some sense good frequency responses, e.g. in two-channel transforms H 0 (z) has always been required to be a good lowpass filter and H 1 (z) -to be a good highpass filter. Good lowpass and highpass filters have the energy compaction property. Provided that H 0 (z) is regular, iterative algorithms for wavelet generation converge and smooth functions can be obtained [17]. If H 0 (z) is non-regular, then iterative processes fail to converge [18]. For example, complementary or Golay-Rudin-Shapiro (GRS) polynomials, which have coefficients equal to +1 or −1 [19], can be utilized to design non-regular wavelet filters. Two polynomials, H 00 (z) and H 01 (z), each with l coefficients, are complementary if Then the filter pair H 0 (z) = H 00 (z 2 ) + z −1 H 01 (z 2 ), and H 1 (z) = −z −N H 0 (−z −1 ) defines an orthogonal wavelet transform. In particular, the non-regular filters h 0 = 1 1 1 −1 and h 1 = −1 −1 1 −1 , called here GRS4 filters, have frequency responses as shown in Figure 1. For instance, this pair of filters induce the generation of the GRS4 wavelets. It is worth to note that these filters do not offer energy compaction, but offer energy spreading. Starting from a kernel with four coefficients, other wavelet filters can be obtained recursively. These non-regular filters have been used in other communications applications [20], where energy spreading is desirable. Unlike regular filters, when non-regular filters are used, a given signal and its DWT share similar statistical properties. To illustrate this, Figure 2 Figure 2(b)). Clearly, the non-regular transform spreads the energy in all subbands. In Figure 2(c) and (d), histograms of the original image and the GRS4 DWT subbands are depicted, exhibiting noticeable visual similarity. In order to quantify this behavior, techniques for measuring the statistical proximity between two probability distributions were considered. A useful tool for this purpose is the Jensen-Shannon divergence [21]. This particular divergence is based on the Kullback-Leibler divergence [22]. Extensive computer simulations have been performed with 20 different test images from the USC-SIPI image database [23]. Then the Jensen-Shannon divergence among each image and its GRS4 DWT subbands was calculated. Table 1 shows the average of the obtained values for the Jensen-Shannon divergence. Note that the distances are extremely small, clearly indicating a high statistical proximity among the examined images and their GRS4 DWT subbands. Other GRS wavelets also offer comparable results.
The energy spreading property of the non-regular filter banks explains the obtained statistical similarities. In fact, this information theoretical proximity between spatial and transform domains is explored to propose a new robust watermarking scheme.

Image Watermarking Using Non-regular DWT
The block diagram of the proposed watermarking algorithm is shown in Figure 3. The scheme includes three generic steps: watermark insertion, attack, and detection. The watermark insertion begins by computing  the DWT of the input image to obtain the low-low (LL), low-high (LH), high-low (HL), and high-high (HH) subbands. The watermark message is inserted in the wavelet domain by where Y is the watermarked data in transform domain, X is the wavelet transform of the original image I, W is the watermark message, and α is a scalar value associated to the watermark strength. Usually, the watermark can be embedded in all subbands except LL, or -as discussed here -when non-regular filters are used, in all subbands, including LL. The size of the watermarking message is equal to the size of the image when the watermark is embedded in all subbands. When the watermark is inserted in the LH, HL, and HH subbands, the size of the watermarking message is equal to the combined size of these subbands. The watermark strength α should be chosen to satisfy the two requirements of image quality and robustness.
The first requirement is that the watermarked image be indistinguishable from the original image. While this can be verified subjectively using just-noticeable-difference [24], the quality of the watermarked image can be calculated using the universal quality index (UQI) proposed in [25]. Although the UQI is not based on any HVS model, it outperforms, for example the mean squared error and the peak signal-to-noise ratio, as a measure of quality. It is accepted that a UQI value of 0.9 or greater generally indicates an imperceptibly distorted image. Based on a set of twelve standard images available at the USC-SIPI image database [23], the average UQI of the images as a function of the watermark strength α, for several wavelets with and without using the subband LL, was calculated and shown in Figure 4. Therefore, a reliable range for the selection of the watermark strength is α ≤ 3.5. Judiciously, α was set to three in all instances of this work. Figure 4 also clearly indicates that non-regular filters lead to higher values of the universal quality index. Additionally, when regular filters are used and the watermark is inserted in the LL subband, the image quality is lower, as the watermark becomes noticeable. Posterior to the insertion of the watermark according to Equation 2, the computation of the inverse DWT of Y furnished the watermarked image I W .
In the next step, the watermarked image is submitted to non-intentional attacks, modeled by lossy signal processing. Specifically, both JPEG and JPEG2000 compression schemes are employed. Unlike JPEG coding, JPEG2000 is a wavelet based scheme. The compression attack can be recognized as an additive noise signal V, which produces a corrupted image I ′ W = I W + V. The final step consists of a statistical analysis aiming the estimation and detection of the watermark message. The estimated watermarkŴ is obtained using a non-blind approach, in which the original image is required. After a forward DWT application on I ′ W , the quantity Y ′ is returned and the watermark message is estimated by the following expression: Once the watermark message is estimated, it is necessary to establish whether it matches the authentic watermark W. The detection phase is based on the correlation coefficient ρ between W andŴ. This quantity is evaluated as follows where ·, · denotes the usual inner product and · 2 is the L 2 norm. In this study, the watermarks were generated by random binary sequences of +1 and −1 with equal probabilities. A same random message is added to each subband. Observe that, for a fixed image, each step of the watermarking procedure is deterministic. Then, a suggested approach to investigate the behavior of ρ is to perform the watermarking procedure employing different random watermarks. Therefore, the resulting ρ becomes a random variable to be analyzed.

Detection Method
According to an observed value of ρ, a binary hypothesis test was taken in consideration attempting to decide between the following two hypothesis: (i) the null hypothesis (H 0 ), corresponding to the absence of a correct watermark, and (ii) the alternative hypothesis (H 1 ), implying the existence of a matching watermark. It is worth to note that the complete absence of the watermark, i.e. W = 0, is categorized as a mismatch. Using a conservative approach, a detector based on the Neyman-Pearson (NP) lemma was devised [26].
The NP lemma establishes a threshold based test that maximizes the probability of detection P D subject to a prescribed probability of false alarm P F A . In symbols, for a given correlation coefficient ρ 0 , the decision otherwise, decide H 0 . The function L(·) is the likelihood ratio, p(·; H 0 ) and p(·; H 1 ) are the probability density functions (pdfs) of ρ for each hypothesis, respectively, and the threshold γ is given by [26] {x:L(x)>γ} Unfortunately, the NP detector assumes that the pdfs of ρ, for each hypothesis, are known. However, no analytical expressions for the above mentioned pdfs are available. Consequently, exhaustive numerical simulations were performed to obtain the empirical pdfs of ρ, p ′ (ρ; H 0 ) and p ′ (ρ; H 1 ), as approximations for p(ρ; H 0 ) and p(ρ; H 1 ), respectively [27].
To compute the empirical pdfs of ρ, an initial set of twelve standard images available at the USC SIPI database [23] was selected, as shown in Figure 5. Each image was submitted to the discussed watermarking procedure. All the factors that contribute to the quantification of the response variable ρ were considered and, in a sense, a factorial experiment was designed [28]. Several wavelets were employed, namely Daubechies-4, Daubechies-8, Coiflet-6, biorthogonal 6/2, and GRS4, where the numbering indicates the size of the respective filters. Also various degrees of attack were utilized. For the standard JPEG compression, the attack strength can be measured by the JPEG quality factor Q, which is inversely proportional to the compression. The            Tables 2 and 3 show -for the JPEG and JPEG2000 attack, respectively -the average and the standard deviation of correlation coefficients. Regardless the conditions, the empirical pdfs related to the non-regular wavelet GRS4 are in the rightmost locations as they exhibit greater averages.
The GRS4 filter offers the highest correlation coefficients in all scenarios, being followed by the Daubechies-4 wavelet in the JPEG case and by the biorthogonal 6/2 in the JPEG2000. The GRS4 filter leads to the highest correlation coefficients because watermarked messages using the GRS4 wavelet domain are more immune to compression due the energy spreading property in the transform domain. Effectively, the watermark is inserted simultaneously in low and high frequency subbands. Therefore, having in mind the most severe attacks discussed above, it is accepted that under less severe attacks the detection performance would be enhanced. Then further analysis focuses mainly the worst case scenario. Subsequently, the NP criterion was suitably adjusted to handle empirical pdfs instead of analytically expressed pdfs. Moreover, numerical integration techniques were employed to solve Equation 6 for the threshold γ [29]. Selecting a probability of false alarm P F A = 10 −2 , the Neyman-Pearson approach furnished the values of γ shown in Table 4.

Results and Discussion
To assess the detection performance of the watermarking scheme based on the GRS4 wavelet, the probability of detection and the probability of false alarm needed to be calculated. By simulating the algorithm a number of times, the relative frequency of detection p D and false alarm p F A can be used as estimators for the sought probabilities.
For simulation purposes, only the worst case scenario were taken in consideration, namely JPEG compression for Q = 10 and JPEG2000 compression at 0.25 bpp. Additionally, we considered an entirely new set of eight images from the USC SIPI database. Otherwise, the use of previously examined images would introduce bias to the results. This set of images were submitted to the proposed watermarking scheme with the GRS4 wavelet for 8000 trials. Table 5 shows the obtained relative frequencies.
We argue that the high frequency subbands of regular filters are less resistant to compression because compression algorithms such as JPEG and JPEG2000 behave as lowpass filters. As a result, watermark messages that are added to the high frequency subbands are likely be filtered out by compression. On the other hand, the subbands of non-regular transforms contain all frequency components.
To emphasize this point, the correlation coefficient was computed separately for each subband, considering regular and non-regular wavelets. Again examining the worst case scenario, we compared, in the JPEG attack at Q = 10, the results derived from the Daubechies-4 and the GRS4 wavelets. Analogously, for the JPEG2000 attack at 0.25 bpp, the biorthogonal wavelet was set against the GRS4 wavelet. These particular wavelets were elected because they granted the largest values of average ρ in their respective empirical pdfs, as shown in Tables 2 and 3. As a result, Figures 10 and 11 depict box and whisker plots of ρ categorized by subband. Note that in all subbands the average value of ρ for the non-regular wavelets is greater than the quantities offered by the regular wavelets. The correlation coefficients of the LL subbands are generally superior when compared with other subbands. This result is not surprising as most of the energy is concentrated in the LL subband. More than that, when non-regular wavelets are utilized, the variance of the average ρ throughout the subbands are considerably lower when compared with the regular wavelets. This indicates that the information stored in the higher subbands is significant for watermarking detection when non-regular wavelet are employed.
Computational evidence also demonstrates that the above discussed behavior remains valid for the other values of quality factor and bit rate considered in this work.

Conclusions
In this paper non-regular wavelet filters are shown to have useful properties for image watermarking. These filters provide energy spreading. As a result, at the same time image quality is high and the watermark is very robust to lossy operations furnished by the JPEG and JPEG2000 compression schemes.