Background Self-adaptive Weakly-monotonic Averaging Image Reduction Operator

Image reduction can simplify the raw image while preserve the structure feature and details information of pictures. Traditional monotonic averaging-based image reduction operator usually lose the detail features of the raw image after reduction. Recent proposed weakly-monotone image reduction algorithm need to specify the background colour manually in the image reduction process, if the background colour of the image to be reduced is not consistent with the former specified colour, this method does not work as expect. For filling this research gap, a new background adaptive weakly-monotonic averaging image reduction operator which can identify the background and adjust the weight according to the pixel distribution of the image was proposed in this paper. The experiment shows that compared with the previous image reduction operator, it has a better applicability and robustness.


Introduction
With the continuous development of electronic information technology, high-performance image acquisition equipment began to be equipped with a variety of instruments, such as drone, nuclear magnetic resonance and remote sensing satellite et al.Highprecision images captured by these instruments either does not need to be displayed in full size on these devices or due to the image size does not meets the storage requirements, thus requires the image reduction techniques [1] to pre-process these images.
Image reduction is to reduce the image size before image processing so that the reduced image can meets specified storage and processing needs.The core of image reduction is retaining the original image details and structural features in the image size reduce process to ensure that the reduced image does not affect the follow-up analysis and calculation.The earliest methods of image reduction is sub-sampling based methods, it reduces the image by sampling pixel from disjoint local neighbourhoods.According the Shannon sampling theorem, once image contains frequencies above the Nyquist limit the information lost will be inevitable.As such, global based image reduction method has been proposed by scholars, such as discrete fuzzy transform base image reduction method [2], least squared trimming based image reduction method [3], minimum cosine variation correction based image reduction method [4] and so on.Compare with the traditional image reduction technique those global based image reduction methods has significantly improves the quality of the reduced image, however, those global based image reduction methods takes the full image as the input resort to the computational cost and hardware requirements relatively high, do not suitable for large-scale image reduction tasks.
As the image reduction task can be regarded as a type of low pass filtering operation, so it can be transformed as an averaging operation.From this point of view, recent years, researches began to put forward local block aggregation based image reduction method, such as [5] [6] and [7].Block-based image reduction focus on reducing the image size while preserving the effective features of the image.Assuming an image has M * N pixels and it can be divided into m * n disjoint image blocks.In block image reduction process, a representative value is generated by a certain method to represent each pixel block.Thus the original image will be reduced to ⌊M / n⌋ * ⌊N / n⌋.The core of block-based image reduction is to use certain function to generate the representative pixels for each image block.This kind of function must have averaging behaviour and impotency, the averaging behaviour means that the value of the generated representative pixel is within range of the original pixel value of the block, the impotency means if all the pixels in the pixel block have the same value, then the generated represent pixel must equal to all the pixel values.Generally this kind of function is called averaging aggregation function.The image reduction based on the averaging aggregation function has linear complexity and high computational efficiency, so it gradually becomes the main method used in image reduction filed [7].Initially, the averaging aggregation function used in image reduction is monotonic averaging function, such as arithmetic averaging and median.The monotonic means any increase in the original input data will result to the increase (as least not decrease) of the representative value.This is reasonable when the input data are noiseless, once the original data are noisy this  [8], which is a more general averaging architecture.The weaklymonotonic averaging refers to the selected averaging function such that (1) the representative value generated will do not decrease when all the values in the pixel block increase; (2) the representative value generated will increase when the partial value in the pixel block increases; (3) if some of the values in the pixel block suddenly increase violently, the resulting representative value will be reduced, because suddenly and dramatically increased pixel values are likely to represent a noise .Due to the superiority of the weaklymonotonic averaging, they proposed a penalty function based weakly-monotonic averaging based image reduction operator p-mode [9].The penalty function is an optimization based averaging representation method, which can integrate the application requirements in image reduction process by minimizing certain performance metric [10].However, the p-mode operator consider only the position between pixels without consider the special organization of the pixel block.Thus, Beliakov et al. propose a pixel block compactness based weakly-monotonic averaging image reduction operator which utilize the minimum spanning tree weight to measure the special organization of pixel block [11].This method has a good small feature preserve ability, but it default the image background is black when calculate the weight this cause the performance decrease when reduce the image with white background.And although we can change the background colour manually when calculate the weight, it decrease the operator's realtime processing ability.This will results in the method can't deal with some real-time image reduction task.
For filling this gap, this paper propose a background self-adaptive image reduction operator which can automatically determine the background colour of the image according to the pixel distribution in the image so as to ensure the quality of the image reduction and improve the real-time processing capability of the operator.

Preliminaries
This section we will briefly introduce the principal mathematical conceptions of the weakly-monotonic averaging image reduction.

Averaging aggregation function
As described in the above section, the core of block based image reduction is to find out a suitable representative value to represent this block.This can be regard as an aggregation problem to solve through the aggregation function.

Weakly-monotonic averaging and penalty function
As mentioned in the above section, compare with traditional monotonic averaging aggregation function the weakly-monotonic averaging aggregation function is more suitable for the image reduction task.Because the definition of weak monotonicity is prompted by applications and intuition perspective, it has better denoise ability than monotonic averaging.The definition of weakly-monotonic function as follows: If F is directionally differentiable, then the weakly monotonic is equivalent to the directional derivative 1 ( )( ) 0 D F x  Comparing this with a directional derivative of a monotonic function reveals that a weak monotonic function is actually a superset of monotonic functions because it only needs to be monotonically oriented in one direction.
In image reduction background, the weaklymonotonic averaging are usually designed as the penalty function based formation such as above mentioned pmode operator, because it can integrate the specific application requirements in the image reduction process.The penalty function transforms the averaging aggregation problem into the following minimization solving task: (1) ( , ) 0, II, II P x y x y     ; (2) ( , ) 0 P x y is pseudo-convex for any x in y .
The first condition ensure that P has a solution of the minimize problem, the second condition providing impotence of P, the third condition guarantees that the penalty function P has a unique minimum value.Intuitively, the penalty function can be regard as a function describing the difference between the input and the output, which dedicate to find out the representative value that has the minimum difference of input.

Background self-adaptive weaklymonotonic averaging
In [6], D. Paternain et al. first proposed the use of averaging aggregation function on local image block to solve the image reduction problem.The mainly steps of this method as follows: Step 1: Divide the raw image into n*m disjoint image block.
Step 2: Choose a suitable averaging aggregation function.
Step 3: Generate the representative value of each pixel block using the founded averaging aggregation function.
This local block averaging based image reduction method has the advantages of simple calculation and easy parallelization so it has been widely used.In order to improve the de-noise ability of above method, T. wilkin et al. proposed use the following penalty function based averaging function to complete the image reduction task [9].It is obvious that the above penalty averaging is a modelike weakly-monotonic averaging, that means this operator have better de-noise performance than the traditional monotonic-averaging based reduction operators.However, the weight  in this operator is the normalized Euclidean distance that means the operator only consider the location of pixels in image block not insight into its spatial organization structure.
  Hence, Gleb et al. proposed a weakly-monotonic averaging based image reduction operator c-mode, which can measure the spatial organization structure of pixels in image block by replacing the above Euclidean distance with the following fuzzy measure based weight [11].
Where A the number of feature pixel in image block, T is the cardinality of the pixel cluster, M is the largest distance between pixels in image block, W (a) represent the weight of minimum spanning tree.This operator ensures that it can prefers to special compact pixel clusters by assigning larger weights to spatial compact cluster, because the more closely packed pixel clusters are likely to represent a small feature rather than noise, thus the c-mode operator shows a perfect small feature retention ability than traditional image reduction operators.However, it needs to pre-specify the background color of the image to be reduced when calculating the minimum spanning tree weight W (A). If the background color of the reduced image does not match the specified background color, a large compactness error will be generated.As shown in Figure 3.1, if the pre-specified background color is black, for the 3 × 3 pixel block with the first pixel of the feature pixel, the correct weight is 0.787.However, for a white background image with the same structure, due to the white background pixels are misjudged as feature pixels then it will get a wrong weight 0.9466.The BANA operator can determine the background color and generate weigh according to the number of pixels in the image, so as to ensure the correctness and rationality of background color settings during image reduction thus ensure the quality of the reduced image.And compare with c-mode operator, the BANA operator avoids manually determining the background color, which improves the real-time processing ability of the operator and make it suitable for large-scale real-time image processing task.For pixel block as shown in figure 3.1, the BANA operator first determines the background color by counting the number of black and white color pixels in the image and then weights it according to the proportion of different colors, and finally obtains unified weight of 0.8115.

Experiment and analysis
In order to evaluate the performance of proposed image reduction operator, first we adopt the most commonly used series of concentric test image for operator reduction performance testing.Which is generated from Bresenham algorithm [12] by specifying the pixel value of particular location.It can be seen from Figure 4.1 that the arithmetic averaging based reduction operator will result in image blurring and radial gradient stretching after reduction, the image distortion is large.The median based reduction operator almost completely loses the small detail features in the raw image after reduction, because in the above image the median of image block is almost 0.However, compare with these two monotonic averaging based reduction operators, the BANA operator can save more details information and structural features obviously after image reduction.In order to further compare the performance of the proposed BANA operator with the traditional weakly-monotonic averaging reduction operator C-mode, we use the correct   As can be seen from Figure 4.3, the proposed BANA operator and c-mode operator have the similar averaging compactness errors when the background of reduce image is pure black or partially white.However, when the blending of white background When the ratio is greater than 50%, BANA operator obviously has smaller average compactness error than C-mode operator.That is to say, the BANA operator and the C-mode operator have similar reduction performance on the black background images or partial white background images, but when the background proportion of the image is more than 50%, the BANA operator has better reduction performance.

Conclusions
In this paper, we propose a background adaptive weaklymonotonic averaging based image reduction operator, which make up the shortcomings of existing weaklymonotonic averaging based reduction operators that need to specify the color of the background manually, avoiding the error caused by the incorrect settings of the background color, improved the real-time processing ability of the former operator.The operator can adaptively identify and weight the background color according to the pixel number distribution of the image to generate a weight that can comprehensively describe the compactness of the pixel block so as to ensure that the image feature and detail information of images with different background colors can be maximizing preserved during the reduction process.The experimental results show that compared with the previous monotonic averaging based reduction operator which has better detail feature preserve ability and compare with existing weakly-monotonic image reduction operator which can greatly reduce the error of white background images.It has better applicability and robustness and real-time processing capability than previous image operators.

5 .
P x y represent the penalty function which defined as follows: Definition Penalty function: If and only if a function II n R → satisfies the following condition then can be called as penalty-function:

r
denotes the k-th smallest difference.

Figure 3 . 1
Figure 3.1 The weight of c-mode in different background color image

Figure 4 .
1 shows the reduction performance comparison between the proposed BANA operator and the traditional monotone averaging based reduction operator median and arithmetic mean.

Figure 4 . 1
Figure 4.1 The reduction image of BANA and arithmetic mean and median operator.
compactness measure as benchmark to compare the Mean compactness error (MCE) of the C-mode operator and BANA operator in different background color images.The test image sequence is shown in Figure 4.2, which contains test images with different proportions of black-and-white color background.The experimental result is shown in Figure 4.3.

Figure 4 . 3
Figure 4.3 The MAE of BANA and c-mode operators The aggregation function refers a class of function which can aggregate a series of limited MATEC Web of Conferences 173, (2018) https://doi.org/10.1051/matecconf/2018173SMIMA 2018