# Methods for Improving Image Quality for Contour and Textures Analysis Using New Wavelet Methods
## 2 Materials and Methods
### Wiener Filter in the Field Transformed
In the procedure of hard truncation of wavelet coefficients, the \(\rm N_{\lambda}\) weighting coefficients of the filter \(\rm H_{hard}\) representing this operation are:  
A particularity of this algorithm is the use of two different wavelet bases, one for obtaining the estimate and another for designing the Wiener filter. We implemented this type of filter using both hard and soft truncation of wavelet coefficients and semisoft truncation to obtain the estimated solution [41]. Both the results reported by [PERSON], [PERSON] and [PERSON], and their own simulations, show that the use of this algorithm leads to an improvement of the filtered image quality but also to the preservation of contours, both in peak signal-to-noise ratio (PSNR) and visual terms. This can also be seen from the data presented in Table 1.  
In the case of noise reduction algorithms, the problem is to evaluate the amount of noise removed, the distortions introduced and the loss of information. One such measure can be the mean square error (MSE) between the pixel values in the original image and those in the remade image:  
\[MSE\ =\ \frac{1}{\text{MN}}\sum_{i}^{\text{M}}\sum_{j}^{\text{N}}(\text{x}( i,j)-\mathfrak{x}(i,j))^{2} \tag{19}\] \begin{table}
\begin{tabular}{c c c c c c} \hline  & **Lena** & \multicolumn{2}{c}{**Wavelet Coefficients**} & \multicolumn{2}{c}{**PSNR (dB)**} & \multicolumn{1}{c}{**C (\%)**} \\ \hline Initial & \multicolumn{3}{c}{Estimated Solution} & Daubechies 6 & 30.03 & 63.67 \\ \hline \multirow{2}{*}{**PSNR (dB)**} & \multirow{2}{*}{**C (\%)**} & \multirow{2}{*}{**PSNR (dB)**} & \multirow{2}{*}{**C (\%)**} & Daubechies 12 & 30.56 & 64.65 \\ \cline{3-5}  & & & Coifman 6 & 30.49 & 64.75 \\ \hline
26.00 & 63.94 & 29.74 & 61.87 & Coifman 12 & 30.56 & 64.65 \\ \hline \multirow{2}{*}{} & \multirow{2}{*}{**Camera**} & \multicolumn{2}{c}{**Wavelet Coefficients**} & \multicolumn{2}{c}{**PSNR (dB)**} & \multicolumn{1}{c}{**C (\%)**} \\ \hline Initial & \multicolumn{3}{c}{Estimated Solution} & [PERSON] 6 & 30.39 & 63.11 \\ \hline \multirow{2}{*}{**PSNR (dB)**} & \multirow{2}{*}{**C (\%)**} & \multirow{2}{*}{**PSNR (dB)**} & \multirow{2}{*}{**C (\%)**} & [PERSON] 12 & 30.97 & 63.66 \\ \cline{3-5}  & & & [PERSON] 6 & 30.91 & 63.22 \\ \hline
26.24 & 65.72 & 29.98 & 62.20 & [PERSON] 12 & 30.97 & 63.66 \\ \hline \end{tabular}
\end{table} 
Table 1: Dependence on performance obtained by processing with empirical Wiener filter. Figure 1: Scheme of the empirical Wiener filter in the wavelet domain proposed by [PERSON], [PERSON] and [PERSON] [40]. where M and N are the image sizes; x(\(i,j\))--pixel intensities in the original image; \(\hat{\mathrm{x}}(i,j)\)--pixel intensities in the restored image. Another measure of the similarity between the two images is the ratio between the peak value of the signal and the mean square error (MSE), defined by:  
\[\mathrm{PSNR}\ =\ 10\log_{10}\frac{\left(2^{k}-1\right)^{2}}{MSE} \tag{20}\]  
where k is the bits number with which the pixel intensity is quantized. PSNR is a metric widely used both in the evaluation of image compression algorithms and in the evaluation of image noise reduction algorithms. Quantitative evaluation of the quality of images processed based on MSE or other derived metrics does not provide sufficient information on the preservation of image contours. Thus, images with the same PSNR may have different visual qualities. If the PSNR can be used to evaluate the amount of noise removed from the image, instead for the quantitative evaluation of images processed in terms of preserving contours this metric is not sufficiently suggestive [42]. Therefore, for the purpose of quantitative evaluation of the images under this aspect, the coefficient C is introduced, defined by:  
\[\mathrm{C}\ =\ \frac{\mathrm{N_{c}}}{\mathrm{N_{0}}} \tag{21}\]  
where Nc is the number of common pixels, determined as belonging to the contours in both the original and the processed image, and N0 is the total number of pixels determined as belonging to the contours in the original image.