{'fraction_non_alphanumeric': 0.033108658617880156, 'fraction_numerical': 0.00960422684739402, 'mean_word_length': 4.657773432043581, 'pattern_counts': {'":': 0, '<': 2, '<?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': 5, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Speckle Reduction in Polarimetric SAR Imagery with Stochastic Distances and Nonlocal Means

This paper presents a technique for reducing speckle in Polarimetric Synthetic Aperture Radar (PolSAR) imagery using Nonlocal Means and a statistical test based on stochastic divergences. The main objective is to select homogeneous pixels in the filtering area through statistical tests between distributions. This proposal uses the complex Wishart model to describe PolSAR data, but the technique can be extended to other models. The weights of the location-variant linear filter are function of the p-values of tests which verify the hypothesis that two samples come from the same distribution and, therefore, can be used to compute a local mean. The test stems from the family of (h-phi) divergences which originated in Information Theory. This novel technique was compared with the Boxcar, Refined Lee and IDAN filters. Image quality assessment methods on simulated and real data are employed to validate the performance of this approach. We show that the proposed filter also enhances the polarimetric entropy and preserves the scattering information of the targets.


Introduction
Among the remote sensing technologies, Polarimetric Synthetic Aperture Radar (PolSAR) has achieved a prominent position. PolSAR imaging is a well-developed coherent microwave remote sensing technique for providing large-scale two-dimensional (2-D) high spatial resolution images of the Earth's surface dielectric properties [20].
In SAR systems, the value at each pixel is a complex number: the amplitude and phase information of the returned signal. Full PolSAR data is comprised of four complex channels which result from the combination of the horizontal and vertical transmission modes, and horizontal and vertical reception modes.
The speckle phenomenon in SAR data hinders the interpretation these data and reduces the accuracy of segmentation, classification and analysis of objects contained within the image. Therefore, reducing the noise effect is an important task, and multilook processing is often used for this purpose in single-and fullchannel data. In the latter, such processing yields a covariance matrix in each pixel, but further noise reduction is frequently needed.
According to Lee and Pottier [20], Polarimetric SAR image smoothing requires preserving the target polarimetric signature. Such requirement can be posed as: (i) each element of the image should be filtered in a similar way to multilook processing by averaging the covariance matrix of neighboring pixels; and (ii) homogeneous regions in the neighborhood should be adaptively selected to preserve resolution, edges and the image quality. The second requirement, i.e. selecting homogeneous areas given similarity criterion, is a common problem in pattern recognition. It boils down to identifying observations from different stationary stochastic processes.
Usually, the Boxcar filter is the standard choice because of its simple design. However, it has poor performance since it does not discriminate different targets. Lee et al. [17,18] propose techniques for speckle reduction based on the multiplicative noise model using the minimum mean-square error (MMSE) criterion. Lee et al. [19] proposed a methodology for selecting neighboring pixels with similar scattering characteristics, known as Refined Lee filter. Other techniques use the local linear minimum mean-squared error (LLMMSE) criterion proposed by Vasile et al. [37], in a similar adaptive technique, but the decision to select homogeneous areas is based on the intensity information of the polarimetric coherency matrices, namely intensity-driven adaptive-neighborhood (IDAN).
Ç etin and Karl [4] presented a technique for image formation based on regularized image reconstruction. This approach employs a tomographic model which allows the incorporation of prior information about, among other features, the sensor. The resulting images have many desirable properties, reduced speckled among them. Our approach deals with data already produced and, thus, does not require interfering in the processing protocol of the data.
Osher et al. [25] presented a novel iterative regularization method for inverse problems based on the use of Bregman distances using a total variation denoising technique tailored to additive noise. The authors also propose a generalization for multiplicative noise, but no results with this kind of contamination are show. The main contributions were the rigorous convergence results and effective stopping criteria for the general procedure, that provides information on how to obtain an approximation of the noise-free image intensity. Goldstein and Osher [15] presented an improvement of this work using the class of L 1 -regularized optimization problems, that originated in functional analysis for finding extrema of convex functionals. The authors apply this technique to the Rudin-Osher-Fatemi model for image denoising and to a compressed sensing problem that arises in magnetic resonance imaging. Our work deals with full polarimetric data, for which, to the best of our knowledge, there are no similar results that take into account its particular nature: the pixels values are definite positive Hermitian complex matrices.
Soccorsi et al. [28] presented a despeckling technique for single-look complex SAR image using nonquadratic regularization. They use an image model, a gradient, and a prior model, to compute the objective function. We employ the full polarimetric information provided by the multilook scaled complex Wishart distribution.
Chambolle [5] proposed a Total Variation approach for a number of problems in image restoration (denoising, zooming and mean curvature motion), but under the Gaussian additive noise assumption.
Li et al. [21] propose the use of a particle swarm optimization algorithm and an extension of the curvelet transform for speckle reduction. They employ the homomorophic transformation, so their technique can be used either in amplitude or intensity data, but not in complex-valued imagery, as is the case we present here.
Wong and Fieguth [41] presented a novel approach for performing blind decorrelation of SAR data. They use a similarity technique between patches of the point-spread function using a Bayesian least squares estimation approach based on a Fisher-Tippett log-scatter model. In a similar way, Sølbo and Eltoft [29] assume a Gamma distribution in a wavelet-based speckle reduction procedure, and they estimate all the parameters locally without imposing a fixed number of looks (which they call "degree of heterogeneity") for the whole image.
Buades et al. [3] proposed a methodology, termed Nonlocal Means (NLmeans), which consists in using similarities between patches as the weights of a mean filter; it is known to be well suited for combating additive Gaussian noise. Deledalle et al. [11] applied this methodology to PolSAR data using the Kullback-Leibler distance between two zero-mean complex circular Gaussian laws. Following the same strategy, Chen et al. [6] used the test for equality between two complex Wishart matrices proposed by Conradsen et al. [8].
This paper proposes a new approach for speckle noise filtering in PolSAR imagery: an adaptive nonlinear extension of the NL-means algorithm. This is an extension of previous works [33,34], where we used an approach similar to that of Nagao and Matsuyma [23]. Overlapping samples are compared based on stochastic distances between distributions, and the p-values resulting from such comparisons are used to build the weights of an adaptive linear filter. The goodness-of-fit tests are derived from the divergences discussed by Frery et al. [14] and Nascimento et al. [24]. The new proposal is called Stochastic Distances Nonlocal Means (SDNLM), and amounts to using those observations which are not rejected by a test seeking for a strong stationary process. This paper is organized as follows. First, we summarize the basic principles that lead to the complex Wishart model for full polarimetric data. In Section 3 we recall the Nonlocal Means method. Our approach for reducing speckle in PolSAR data using stochastic distances between two complex Wishart distributions is proposed in Section 4. Image Quality Assessment is briefly discussed in Section 5. Results are presented in Section 6, while Section 7 concludes the paper.

The Complex Wishart Distribution
PolSAR imaging results in a complex scattering matrix, which includes intensity and relative phase data [14]. Such matrices have usually four distinct complex elements, namely S VV , S VH , S HV , and S HH , where H and V refer to the horizontal and vertical wave polarization states, respectively. In a reciprocal medium, which is most common situation in remote sensing, S VH = S HV so the complex signal backscattered from each resolution cell can be characterized by a scattering vector Y with three complex elements [36].
Thus, we have a scattering complex random vector Y = [S HH , S VH , S VV ] t , where [·] t indicates vector transposition. In general, PolSAR data are locally modeled by a multivariate zero-mean complex circular Gaussian distribution that characterize the scene reflectivity [35,36], whose probability density function is where | · | is the determinant, and the superscript ' * ' denotes the complex conjugate of a vector; Σ is the covariance matrix of Y . This distribution is defined on C 3 . The covariance matrix Σ, besides being Hermitian and positive definite, has all the information which characterizes the scene under analysis. Multilook processing enhances the signal-to-noise ratio. It is performed averaging over L ideally independent looks of the same scene, and it yields the sample covariance matrix Z given, in each pixel, by where L is the number of looks.
The resulting distribution has the same form as in (1) and is termed the "relaxed" Wishart. We assume this last model, and we allow variations of L along the image. The support of this distribution is the cone of positive definite Hermitian complex matrices [12].
The parameters are usually estimated by maximum likelihood (ML) due to its statistical properties. Let Z r be a random matrix which follows a W(Σ, L) law. Its log-likelihood function is given by resulting in the following score function: where ψ 0 is the digamma function. Let {Z 1 , Z 2 , . . . , Z N } be an i.i.d. random sample of size N from the W(Σ, L) law. The ML estimator ( Σ, L) of its parameters is Σ = Z = N −1 Σ N r=1 Z r and the solution of The case L < q was also treated by Anfinsen et al. [2].

Nonlocal Means
The NL-means method was proposed by Buades et al. [3] based on the redundancy of neighboring patches in images. In this method, the noise-free estimated value of a pixel is defined as a weighted mean of pixels in a certain region. Under the additive white Gaussian noise assumption, these weights are calculated based on Euclidean distances which are used to measure the similarity between a central region patch and neighboring patches in a search window. The filtered pixel is computed as: where w(u, v) are the weights defined on the search window W . The resulting image g is, thus, the convolution of the input image f with the mask w = w / w (u, v). The factor w (u, v) is inversely proportional to a distance between the patches, and is given by where h > 0 controls the intensity, in a similar way the temperature controls the Simulated Annealing algorithm, f (ρ u (k)) and f (ρ v (k)) are the observations in the k-th pixels of the patches centered in u and v, respectively. When h → ∞ the weights tend to be equal, while when h → 0 they tend to zero unless f (ρ u (k)) = f (ρ v (k)). In the first case the filter becomes a mean over the search window; in the last case, the filtered value will remain unaltered. The NL-Means proposal and its extensions rely on computing the weights of a convolution mask as functions of similarity measures: the closer (in some sense) two patches are, the heavier the contribution of the central pixel to the filter.
Deledalle et al. [10] analyze several similarity criteria for data which depart from the Gaussian assumption. In particular, the authors consider the Gamma and Poisson noises, because they are good image models. Deledalle et al. [9] extended the NL-means method to speckled imagery using statistical inference in an iterative procedure. The authors derive the weights using the likelihood function of Gaussian and square root of Gamma (termed "Nakagami-Rayleigh") noises. This idea is extended by Deledalle et al. [11] to PolSAR data under the complex Gaussian distribution, and by Su et al. [30] to multitemporal PolSAR data.
Chen et al. [6] presented a NL-Means filter for PolSAR data under the complex Wishart distribution. The authors employ the likelihood ratio test of equality between two W(Σ, L) laws with the same number of looks L, as presented by Conradsen et al. [8], to calculate the weights between the patches.
Our proposal addresses the problem in a more general fashion: we use the p-value of a goodness-of-fit test between two samples. The tests are derived using an Information Theory approach to compute stochastic divergences, which are turned into distances and then scaled to exhibit good asymptotic properties: they obey a χ 2 distribution. The weights are computed with a soft threshold which incorporates all the observations which were not rejected by the test, and some of the others. As presented in the next section, all these elements can be easily generalized to other models, tests and weight functions.

The weights
In this paper we use a 7×7 search window. The shape and size of the neighboring patches and the central patch are the same: squares of 3 × 3 pixels. The central patch, with center pixel Z 1 , is thus compared with 24 neighboring patches, whose center pixels are Z i , i = 2, . . . , 25, as illustrated in Figure 1.
The estimate of the noise-free observation at Z 1 is a weighted sum of the observations at Z 2 , . . . , Z 25 , being each weight a function of the p-value (p(1, i)) observed in a test of same distribution between two complex Wishart laws: where η is the significance of the test, specified by the user. By definition, p(1, 1) = 1. This function is illustrated in Figure 2. In this way we employ a soft threshold instead of an accept-reject decision. This allows the use of more evidence than with a binary decision, as the one used in [32,34] which was 1 if the sample was not rejected and 0 otherwise.
When all weights are computed, the mask of convolution coefficients is scaled to add one.
This setup can be generalized in many ways, among them: -The support, i.e., the set of positions i do not need to be local; it can extend arbitrarily. -The shape and size of the local windows.
-The weight function; we opted for the piecewise linear function presented in equation (4) as a good compromise between generality and computational cost. -The test which produces each p-value.
The rationale for using the weight function specified in equation (4) is the following. If the p-values were used instead, the presence of a single sample with excellent match to the central sample would dominate the weights in the mask, forcing other samples that were not rejected by the test to be practically discarded. For instance, consider the case p(1, i 1 ) = 0.89, p(1, i 2 ) = 0.05 and all other p-values close to zero. Without the weight function, the nonzero weights would be, approximately, 0.46 and 0.03, so the second observation would have a negligible influence on the filtered value while the first, along with the central value, dominate the result. Using the aforementioned expression, the three weights would equal 1/3. This increases the smoothing effect without loosing the discriminatory ability.

The statistical test
As defined in the previous section, filtering each pixel requires computing a number of goodness-of-fit tests between the patch around the central pixel Z 1 and the patches surrounding pixels Z i , 2 ≤ i ≤ 25. This will be performed using tests derived from stochastic distances between samples.
Denote θ 1 the estimated parameter in the central region Z 1 , and θ 2 , . . . , θ 25 the estimated parameters in the remaining areas. To account for possible departures from the homogeneous model, we estimate θ = ( Σ, L) by maximum likelihood.
The proposal is based on the use of stochastic distances between the patches. Consider that Z 1 and Z i , 2 ≤ i ≤ 25, are random matrices defined on the same probability space, whose distributions are characterized by the densities f Z1 (Z ; θ 1 ) and f Zi (Z ; θ i ), respectively, where θ 1 and θ i are parameters. Assuming that the densities have the same support given by the cone of Hermitian positive definite matrices A, the h-φ divergence between f Z1 and f Zi is given by Choices of functions h and φ result in several divergences. Divergences sometimes are not symmetric. A simple solution, described in Frery et al. [14,24,13], is to define a new measure d h φ given by Distances, in turn, can be conveniently scaled to present good statistical properties that make them suitable as test statistics [26]: where θ 1 and θ i are maximum likelihood estimators based on samples size m and n, respectively. When , and the null hypothesis θ 1 = θ i can be rejected at significance level η if p ≤ η; details can be seen in the work by Salicrú et al. [26]. Since we are using the same central sample for 24 nontrivial tests (notice that S h φ ( θ 1 , θ 1 ) = 0). Frery et al. [14,13] obtained several distances between W(Σ, L) distributions. The test used in this paper was derived from the Hellinger distance, yielding: provided L ≥ 3. If L < 3, the following expression can be used ; it was also derived by Frery et al. [14,13] for the case when L 1 = L 2 = L; in this last case, the equivalent number of looks L should be estimated using all the available data, for instance as presented by Anfinsen et al. [2]. The setup presented in Section 4.1 leads to m = n = 9 since squared windows of side 3 are used.
The tests based on the Kullback-Leibler, Bhattacharyya and Rényi of order β ∈ {.1, .5, .9} were also used. They produced almost exactly the same results as of the Hellinger distance, at the expense of more computational load.
Although the distribution of the test statistics given in equation (5) is only known in the limit when m, n → ∞ such that m/(m+n) → λ ∈ (0, 1), it has been observed that the difference between the asymptotic and empirical distributions is negligible in samples as small as the ones considered in this setup [13,14].
The filter obtained using the p-values produced by the test statistic given in equation (6) can be applied iteratively. The complex Wishart distribution is preserved by convolutions, and since the number of looks is estimated in every pairwise comparison, the evolution of the filtered data is always controlled. This also holds for any filter derived from h-φ divergences and the setup presented in Section 4.1.
Computational information about our implementation is provided in A.

Image Quality Assessment
According to Wang et al. [39] image quality assessment in general, and filter performance evaluation in particular, are hard tasks and crucial for most image processing applications. We assess the filters using simulated and real input data by means of visual inspection and quantitative measures. Visual inspection includes edges, small features and color preservation. The measures are computed on the HH, HV and VV intensity channels, and they amount to (a) the Equivalent Number of Looks (ENL) in homogeneous areas; and (b) the Structural Similarity Index Measure (SSIM), proposed by Wang et al. [40] for measuring the similarity between two images. (c) the Blind/Referenceless Image Spatial QUality Evaluator (BRISQUE), proposed by Mittal et al. [22] to a holistic measure of quality on no-reference images.
The equivalent number of looks N can be estimated by maximum likelihood solving equation (2). The ENL although it is a measure of the signal to noise ratio, and it must be considered carefully since it will repute highly blurred data as excellent: for this measure, the best result is a completely flat (constant) image, i.e., an image with no information whatsoever. The Boxcar filter usually has a higher ENL than other proposals because it will always use all the pixels in the filtering window and the result is a large loss of spatial resolution. Therefore, the equivalent number of looks should be used with care and only to assess noise reduction and not image quality in general.
The SSIM index is a structural information measure that represents the structure of objects in the scene, regardless the average luminance and contrast. The SSIM index takes into account three factors: (I) correlation between edges; (II) brightness distortion; and (III) distortion contrast. Let f and g be the original data and the filtered version, respectively, the SSIM index is expressed by where f and g are sample means, σ 2 f and σ 2 g are the sample variances, Cov(f, g) is the sample covariance between f and g, and the constants C 1 , C 2 , C 3 are intended to stabilize the index. Following [40], we used the following values: C 1 = (K 1 L) 2 , C 2 = (K 2 L) 2 and C 3 = C 2 /2, where L is the observed dynamic range and both K 1 , K 2 1; we used K 1 = 0.01 and K 2 = 0.03. The SSIM is defined for scalar-valued images and it ranges in the [−1, 1] interval, being the bigger value observed is the better result. It was computed on each intensity channel as the means over squared windows of side 8, and the reported value is the mean over the three channels. This index is a particular case of the Universal Quality Index proposed by Wang and Bovik [38]. We also applied this last measure to all the images here discussed, and the results were in full agreement with those reported by the SSIM index.
The BRISQUE is a model that operates in the spatial domain and requires no-reference image. This image quality evaluator does not compute specific dis-tortions such as ringing, blurring, blocking, or aliasing, but quantifies possible losses of "naturalness" in the image. This approach is based on the principle that natural images possess certain regular statistical properties that are measurably modified by the presence of distortions. No transformation to another coordinate frame (DFT, DCT, wavelets, etc) is required, distinguishing it from previous blind/no-reference approaches. The BRISQUE is defined for scalarvalued images and it ranges in the [0, 100] interval, and smaller values indicate better results.

Results
The proposed filter, termed "SDNLM (Stochastic Distances Nonlocal Means) filter" was compared with the Refined Lee (Scattering-model-based), IDAN (intensity-driven adaptive-neighborhood) and Boxcar filters. These filters act on a well defined neighborhood (as our implementation of the SDNLM): a squared search window of side of 5 × 5 pixels, and the former is adaptive (as is the SDNLM). The noise reduction is noticeable in all the four filtered images. The speckled effect was mitigated without loosing the color balance, but the Boxcar filter produces a blurred image. The Refined Lee filter also introduces some blurring, but less intense that the Boxcar filter. The IDAN filter also reduces noise, but less effectively that the Refined Lee. The SDNLM filter is the one which best preserves edges. This is particularly noticeable in the fine strip which appears light, almost white, to the upper left region of the image. After applying the Boxcar filter it appears wider than it is. The star-shaped bright spot in the middle of the blue field looses detail after Boxcar, Refined Lee and IDAN filters are applied, while the SDNLM noise reduction technique preserves its details well. The Refined Lee filter introduces a noticeable pixellation effect which is evident mainly in the brown areas.
The Canny detector was applied to the HH band of all the available data presented in Figure 3, and the results are presented in Figure 4. Even when applied to the phantom, the Canny detector fails to produce continuous edges in a few situations. In particular, it completely misses the small light features and a few edges between regions; see Figure 4(a). Edge detection with this method is, in practice, impossible using the original single-look data, cf. Figure 4(b) with the other results, although a few large linear features are visible in the clutter of noisy edges. As expected, the edges detected in the Boxcar filtered image are smooth, but they neither grant continuity nor identify fine details; this information is lost by the filter, see Figure 4(c). The edges detected in the image processed by the IDAN filter are only marginally better than those observed in the original, unfiltered, data; see Figure 4(e). Figures 4(d) and 4(f) are the edges detected on the data filtered by the Refined Lee and SDNLM filters, respectively. Although they look alike, it is noticeable that the latter preserves better the small details; see, for instance, the star-shaped object to the center-right of the image. It appears round in the former, while in the latter it is possible to identify minute variations.
The phantom is available, so it is possible to make a quantitative assessment of the results. Table 1 presents the assessment of the filters in the three intensity channels HH, HV and VV of the data presented in Figure 3 using the Equivalent Number of Looks (ENL) and the SSIM index. Table 1. Image quality indexes in the images shown in Figure 3. The ENL was estimated on homogeneous areas far from edges, so no smudging from other areas contaminated these values. As expected, the most intense blurring produces the best results with respect to this criterion: the Boxcar filter outperforms in two out of three bands and, when, it is not the best, the Refined Lee filter is. Regarding the Equivalent Number of Looks, IDAN produces worse results, but a good performance in SSIM index. The SDNLM filter improves with respect to the ENL criterion when the significance level increases. In order to make it competitive with the Boxcar, Refined Lee and IDAN filters, the application to real data was done using η = 90%. Regarding the SSIM index, our proposal consistently outperforms the other three filters and, as expected, the smallest the significance of the test the better the performance is with respect to this criterion since the least the image is blurred.
Physical-based simulation Sant'Anna et al. [27] proposed a methodology for simulating PolSAR imagery taking into account the electromagnetic characteristics of the targets and of the sensing system. The simulated images are more realistic than the ones obtained by merely stipulating the posterior distribution given the classes, in particular spatial correlation among pixels emerges and mixture of classes in the borders as observed.
Each simulated pixel is a complex scattering matrix based on a phantom image (an idealized cartoon model) with five distinct regions. Multifrequency sets of single-look PolSAR images have been generated in the L-, Cand X-bands, corresponding to 1.25 , 5.3 and 9.6 GHz, respectively. The acquisition geometry is that of an airborne monostatic sensor flying at 6,000 m of altitude and 35 • grazing angle imaging a 290 × 290 m 2 area terrain. The 3.0 m spatial resolution and 2.8 m pixel spacing were set in the range and the azimuth directions. The data have 128 × 128 pixels; details in [27]. Figure 5 shows the simulated images in the L-, Cand X-bands ( Figures 5(a), 5(f) and 5(k), resp.) and its filtered versions by the Boxcar (Figures 5(b The three main visual drawbacks of the Boxcar, Refined Lee and IDAN filters are noticeable in these results, namely the excessive blurring introduced by the former, and the pixellate effect produced by the latter. The SDNLM filter consistently presents a good compromise between smoothing and edge preservation. Table 2 presents the assessment of the filters in three intensity channels by means of the ENL (computed in the central region, a homogeneous area), and by means of the SSIM index. The best results are highlighted in boldface. The results are consistent with those observed in Table 1: the Boxcar filter is the best with respect to the ENL computed in homogeneous areas far from edges, but the SDNLM filter outperforms the other three filters when a more sophisticated metric is used: the SSIM index, which takes into account not only smoothness but structural information. Regarding these data, the ideal significance level lies approximately between η = 80% and η = 90%; these values provide a good smoothing without compromising the structural information.

Real data
In the remainder of this section the data will be presented in false color using the Pauli decomposition [20]. This representation of PolSAR data has the advantage of being interpretable in terms of types of backscattering mechanisms. It consists of assigning |S HH +S VV | 2 to the Red channel, |S HH −S VV | 2 to the Green channel, and 2|S HV | 2 to the Blue channel. This is one of many possible representations, and it is noteworthy that the data are filtered in their original domain, before being decomposed for visualization. Table 2. Image quality indexes in the images shown in Figure 5. The four filters employ a kernel of 5×5 pixels, and the patches in our proposal are 3 × 3 windows. Figure 6(c) shows the effect of the Boxcar filter. Albeit the noise reduction is evident, it is also clear that the blurring introduced eliminates useful information as, for instance, the Presidio Golf Course: the curvilinear dark features to the center of the image: a forested area. Figure 6(d) is the result of applying the Refined Lee filter, which shows a good performance, but some details in the edges are eliminated. In particular, the Mountain Lake, the small brown spot to the center of the image, is blurred, as well as the blocks in the urban area. The results of the IDAN filter and of our proposal with η = 90% are shown in Figures 6(e) and 6(f), respectively. Both filters are able to smooth the image in a selective way, but the SDNLM filter enhances more the signal-to-noise ratio while preserving fine details than the IDAN filter.
In image quality assessment, the SSIM requires a reference image, as was the case of sections 6.1 and 6.1, therefore this index is not applied with ease on real images. Table 3 presents the result of assessing the filters in the three intensity channels by means of the ENL in the large forest area, a homogeneous area, and of the BRISQUE index. Again, the results are consistent with what was observed before: the mere evaluation of the noise reduction by the ENL suggests the Boxcar filter as the best one, but the natural scene distortion-generic BRISQUE index is better after applying the SDNLM filter in all intensity channels.

Effect of the filters on the scattering characteristics
Polarimetric target decompositions aim at expressing the physical properties of the scattering mechanisms. Among them, the entropy-based decomposition proposed by Cloude and Pottier [7] is widely used in PolSAR image classification. It extracts two parameters from each observed covariance matrix: the scattering entropy H ∈ [0, 1], and α ∈ [0, 90], an indicator of the type of scattering. The (H, α) plane is then divided into nine regions which provide both a classification rule and an interpretation for the observed data. Figure 7 shows the effect of the filters on the entropy of the data. Three classes of entropy are barely visible corresponding, in increasing brightness, to the sea, urban area an forest. The difference between the classes is small. All filters enhance the discrimination ability of the entropy, cf. figures Figures 7(b), 7(c), 7(d) and 7(e) with Figure 7(a). Again, the best preservation of detail is obtained by the IDAN and SDNLM techniques that, among others, retain the information of the Presidio Golf Course. Additionally, our proposal is the one that best preserves the low entropy small spots within the urban area, a feature typical of the high variability of these areas due to their heterogeneous composition.
Samples from the sea, the urban area, and the forest, identified in red, blue and magenta, respectively, in Figure 6(b), were taken. The (H, α) value of each point from these samples is presented in Figure 8 before and after applying the filters. The improvement of using filters is notorious when comparing Figure 8 The sea samples are confined to Zone 9 in all datasets, and all filters have the effect of reducing their variability. While the Boxcar and Refined Lee filters produce very similar clusters of data, the IDAN and SDNLM filters reduce both the entropy and the α coefficient, but still within the zone of low entropy surface scatter, making the sample much more distinguishable from the rest of the data.
The samples from urban (in blue) and forest (in magenta) areas have different mean values of entropy and α. The former occupy mostly zones 4 (medium entropy multiple scattering) and 5 (medium entropy vegetation scattering), while the latter span mostly zones 2 (high entropy vegetation scattering) and 5. While both are present in Zone 5, they seldom overlap; the forest samples have higher values of α. Comparing these two samples in the images filtered by the Refined Lee and SDNLM techniques, one notices that they would produce very similar classifications. The SDNLM produces clusters with more spread than the Refined Lee, but not at the expense of mixing different classes.
In this manner, the filters preserve the scattering properties of the samples, a central feature of every speckle smoothing technique for PolSAR data, according to Lee and Pottier [20].

Effect of iterations number in filtering
As previously discussed, SDNLM can be iterated since the properties upon which it is based are preserved by convolutions. Figure 9 presents the original image for reference (Figure 6(b)), and the result of applying each technique (Boxcar, Refined Lee, IDAN and SDNLM with η = 80% in each row) one, three and five times (first, second and third column, respectively).
The most notorious new result stems from comparing the IDAN and SDNLM filters. Three iterations are enough for the former to smudge the original data, and with five iterations the blurring it produces is comparable with that of the Refined Lee and Boxcar filters. The SDNLM filter, even after five iterations, still preserves most of the spatial information. Figure 10 presents the (H, α) scatter plot of the samples before and after iterating the filters one, three and five times. Each new iteration adds cohesion to the clusters, whatever the filter employed. Regarding the SDNLM, the difference between one and three iterations is noticeable. Table 4 presents the quantitative analysis of the resulting images. Again, the Boxcar procedure yields the best noise reduction in smudge-free areas in most of the situations, followed by the Refined Lee filter. The SDNLM filter tuned somewhere between 80% and 90% of significance produces the best BRISQUE indexes. Table 5 presents the values of mean, variance and ENL estimator on the samples from the three regions of interest (sea, urban and forest), in the crosspolarized band (HV ). The fist line in Table 5 presents the values observed in the original (unfiltered) image. The best values are highlighted in bold; being the best mean the closest to the original value, and the best standard deviation the smallest one.
The SDNLM filter is the best at preserving the original mean values, and with reduced standard deviation. Our proposal does not provide the best variability reduction, a behavior that may be associated with the preservation of fine structures and a smaller loss of spatial resolution, as can be noted in Figure 9. The equivalent number of looks behaves consistently with what was observed in previous examples.

Conclusions
The use h-φ divergences, a tool in Information Theory, led to test statistics (with a known and tractable asymptotic distribution) able to check if two samples cannot be described by the same complex Wishart distribution, the classical model for PolSAR data. Using one of these test statistics, namely the one based on the Hellinger distance, we devised a convolution filter whose weights are function of the p-value of tests which compare two patches of size 3 × 3 in a search window of size 5 × 5 pixels.
The filter obtained in this manner (SDNLM -Stochastic Distances Nonlocal Means) was compared with the Boxcar, Refined Lee and IDAN filters in a variety of PolSAR imagery: data simulated from the complex Wishart law over a realistic phantom using parameters observed in practice, data simulated from the electromagnetic properties of the scattering over a simplified cartoon model, and a real PolSAR image over San Francisco, CA. The quantitative assessment verified the equivalent number of looks (a measure of noise reduction) over smudge-free samples, the structural SSIM index, and the BRISQUE index used appropriately on no-references images (real images or blind). The Boxcar filter promotes the strongest noise reduction in these conditions, but at the expense of obliterating small details. The Refined Lee and IDAN filters are competitive, but produce a pixellated effect and their SSIM index is worse than the produced by the SDNLM filter in all instances. We noted this same feature with the BRISQUE index applied to real data and the index values remain stable even during iteration of the SDNLM filter, which does not happen with other filters assessed.
A qualitative assessment was also made checking how the polarimetric entropy is affected by the filters. We noticed that all the filters enhance it but, in particular, our proposal performs the most refined enhancement since it preserves very small details which are characteristic of complex urban areas.
The effect of the filters and of applying them iteratively was also verified in the (H, α) plane. All filters produced more and more compact clusters of observations in this plane as more iterations were applied. The SDNLM filter yielded the best separation of the sea sample, while the other two were treated at least as well as they were by the other filters.
The SDNLM filter has three tuning parameter: (i) filtering window size, (ii) the size of the patches, and (iii) the significance of the test. We provide a range of suggested values for the latter, and show good results with an economic choice for the two former. The filter can also be applied iteratively if more smoothing is requested and, provided an adequate statistical model, it can also be applied to other types of data.
We conclude that our proposal is a good candidate for smoothing PolSAR imagery without compromising either small details or the scattering characteristics of the targets.
The test statistics are invariant with respect to permutations of the sample; directional features will be considered in forthcoming works. Future research includes the proposal of quality measures for PolSAR imagery, and the use of tests based on entropies [12].

A Computational information
Computing the ML estimator of the equivalent number of looks L given in equation (2) and the test statistic based on the Hellinger distance, c.f. equation (6), are part of the computational core of this proposal. Each weight requires computing these quantities. It is noteworthy that they involve only two operations on complex matrices: the determinant and the inverse. Using the fact that the matrices are Hermitian and positive definite, it is possible to reduce drastically the number of operations required to calculate these two quantities. Specialized accelerated function in the R programming language [31] were developed with the speed of the filters in mind.
The time required to filter a 128 × 128 pixels image with one iteration is of about 75 s in an Intel R Core TM i7-3632QM CPU 2.20 GHz, with software developed in R version 2.14.1 running on Ubuntu 12.04. R was the choice because of its excellent accuracy with respect to similar platforms [1].

B Observed covariance matrices
In the following we present the observed covariance matrices that were used to simulate the data presented in Figure 3