CN102609904A - Bivariate nonlocal average filtering de-noising method for X-ray image - Google Patents

Bivariate nonlocal average filtering de-noising method for X-ray image Download PDF

Info

Publication number
CN102609904A
CN102609904A CN201210007379XA CN201210007379A CN102609904A CN 102609904 A CN102609904 A CN 102609904A CN 201210007379X A CN201210007379X A CN 201210007379XA CN 201210007379 A CN201210007379 A CN 201210007379A CN 102609904 A CN102609904 A CN 102609904A
Authority
CN
China
Prior art keywords
mrow
msub
image
msup
noise
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201210007379XA
Other languages
Chinese (zh)
Other versions
CN102609904B (en
Inventor
魏杰
王达达
王妍玮
于虹
王磊
赵现平
吴章勤
梁洪
闫文斌
李金�
郭涛涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Harbin Engineering University
Yunnan Electric Power Experimental Research Institute Group Co Ltd of Electric Power Research Institute
Original Assignee
Harbin Engineering University
Yunnan Electric Power Experimental Research Institute Group Co Ltd of Electric Power Research Institute
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Harbin Engineering University, Yunnan Electric Power Experimental Research Institute Group Co Ltd of Electric Power Research Institute filed Critical Harbin Engineering University
Priority to CN201210007379.XA priority Critical patent/CN102609904B/en
Publication of CN102609904A publication Critical patent/CN102609904A/en
Application granted granted Critical
Publication of CN102609904B publication Critical patent/CN102609904B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Processing (AREA)

Abstract

The invention provides a bivariate nonlocal average filtering de-noising method for an X-ray image. The method is characterized by comprising the following steps: 1) a selecting method of a fuzzy de-noising window; and 2) a bivariate fuzzy adaptive nonlocal average filtering algorithm. The method has the beneficial effects that in order to preferably remove the influence caused by the unknown quantum noise existing in an industrial X-ray scan image, the invention provides the bivariate nonlocal fuzzy adaptive non-linear average filtering de-noising method for the X-ray image, in the method, a quantum noise model which is hard to process is converted into a common white gaussian noise model, the size of a window of a filter is selected by virtue of fuzzy computation, and a relevant weight matrix enabling an error function to be minimum is searched. A particle swarm optimization filtering parameter is introduced in the method, so that the weight matrix can be locally rebuilt, the influence of the local relevancy on the sample data can be reduced, the algorithm convergence rate can be improved, and the de-noising speed and precision for the industrial X-ray scan image can be improved, so that the method is suitable for processing the X-ray scan image with an uncertain noise model.

Description

Bivariate non-local average filtering X-ray image denoising method
Technical Field
The invention belongs to the field of X-ray image denoising, and particularly relates to a denoising method for an X-ray image by a Fuzzy Adaptive parameter adjusted bivariate Non-Local average Filtering (FANL) algorithm.
Background
With the continuous development of industrial X-ray inspection technology, more and more requirements are put on the quality of X-ray scanning images, which requires effective elimination of noise information generated in the real-time detection process. Due to the characteristics of narrow gray scale interval, fuzzy defect edge, more image noise and sometimes submerged defect characteristics of the X-ray scanning image, the effect of analyzing and evaluating the detected workpiece according to the X-ray image is influenced. With the continuous update of the X-ray acquisition equipment, the new X-ray scanner can more comprehensively and accurately describe the information of the industrial image, which results in more pixels in the image and greatly increased redundancy among the pixels. Therefore, irrelevant quantities in information are removed through a fuzzy self-adaptive optimization operator, and invariance of an internal structure of the fuzzy self-adaptive optimization operator is kept as a key technology to be solved urgently.
The non-local average filtering algorithm utilizes redundant information to perform noise elimination, which is an innovation of a traditional local noise elimination model, and the main idea is to compare the distribution conditions of the whole gray around a pixel instead of comparing the gray values of the single pixel in the image, estimate a weight according to the similarity of the whole gray distribution, and essentially map the correlation among the pixels of the original image to an image space for processing. Buades indicates that redundant information is fully utilized as noise elimination service, theoretical analysis and experimental results of recent research of Buades indicate that the traditional non-local average filtering noise elimination algorithm is superior to the common image noise elimination algorithm in subjective and objective performance, such as Gaussian filtering, anisotropic filtering, total error minimization, neighborhood filtering and the like, the traditional non-local average filtering noise elimination algorithm is originated from the neighborhood filtering algorithm, the popularization of the neighborhood filtering algorithm is realized, the weight is obtained according to the similarity of the gray distribution of the whole area around a pixel, and the strong capacity of keeping the spatial resolution of an image is realized while the image noise is reduced. When a complex image is processed by utilizing a traditional non-local average filtering algorithm, the calculation amount is large, the processing speed is low, and the problem is more prominent particularly when a large image is processed; in addition, this method introduces artifacts in the smooth regions of the image, the image becomes blurred, and the spatial resolution is affected.
The noise elimination method of the bivariate non-local average filtering X-ray image with fuzzy self-adaptive parameter adjustment is characterized in that self-adaptive adjustment of a filtering parameter selection window is realized by using a fuzzy algorithm, on the basis of the concept and the theory of a particle swarm optimization operator, when a plurality of optimized filtering parameters need to be selected, the optimal filtering parameters are selected by using a fuzzy control rule, evolution search is completed by selecting and opening an optimization window, and the better processing effect, the faster convergence speed and the global optimization capability are obtained. However, to date, no one has applied this algorithm to the non-local mean optimization aspect.
Aiming at the problems, the invention improves the traditional NL-means method, and the algorithm searches for the weight value which minimizes the reconstruction error from the intrinsic characteristics among data, thereby achieving the purpose of minimizing the error function. Meanwhile, the essence of the intelligent optimization algorithm determines that the determination of the weight does not depend on the distance between data points, the correlation between image neighborhood pixels is effectively reduced, the operation complexity is reduced, the calculation time is saved, and the operation speed of the algorithm is increased so as to meet the detection requirement in industrial production tasks.
Disclosure of Invention
The invention researches the noise elimination condition of a random noise model generated in the industrial X-ray scanning image, and realizes effective noise elimination processing of the industrial X-ray scanning image by adopting a bivariate non-local average filtering rapid noise elimination method based on fuzzy adaptive parameter adjustment.
The fuzzy adaptive parameter adjustment effectively processes the X-ray block images in parallel, reduces the correlation among image blocks, realizes the rapid denoising processing of the X-ray scanning images, simultaneously, introduces X and y double variables to ensure the position invariance of the image denoising process, and can also obtain better convergence by adopting a particle swarm optimization method. Therefore, the invention uses the particle swarm optimization algorithm to search the weighted value which minimizes the reconstruction error in the X-ray scanning image from the intrinsic characteristic among data, thereby leading the industrial X-ray noise-eliminating image to obtain higher processing speed under the condition of ensuring the precision.
The method of the present invention is further described below, specifically as follows:
the invention discloses a bivariate non-local average filtering X-ray image denoising method, which is characterized by comprising the following steps:
1) selection method of fuzzy noise-canceling window
The non-local average filtering algorithm has a premise assumption: the local space where the sampling data is located is linear, namely each sampling point has a similar relation with its adjacent points and is linearly represented by a weight contribution value;
the learning objectives of the algorithm are: setting the weight of each neighborhood according to the similarity of gray distribution by fully utilizing the redundancy relation among pixels in a low-dimensional space, namely, reconstructing an original image by minimizing irrelevant pixels under the condition that an embedded mapping window is locally linear;
let c (X, y) be the X-ray scanning image function, r (X, y) be the ideal image function, n (X, y) be the noise image function, and X, y be the coordinates of image pixel points in the rectangular coordinate system, then:
c(x,y)=r(x,y)+n(x,y) (1)
now, a template is needed to be found to determine the correlation between each element of c (x, y) and r (x, y), so that n (x, y) is eliminated effectively;
the gray value corresponding to the pixel point x, y in the c (x, y) image is represented by c (i), and then there is
<math> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>I</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>Y</mi> </munderover> <munderover> <mi>&Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>X</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>x</mi> <mo>,</mo> <mi>y</mi> <mo>)</mo> </mrow> <mo>+</mo> <mi>&gamma;</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>2</mn> <mo>)</mo> </mrow> </mrow> </math>
Wherein, I ═ X × Y is the size of the image, I is the gray pixels in the image points X, Y, I belongs to (1, 2.. I), X belongs to (1, 2.. X), Y belongs to (1, 2.. Y) c (I) is the gray value of the ith point in the X-ray scanned image, c (X, Y) reflects the gray information of the points X, Y in the image, and γ is the image gray correction factor, therefore, the local contrast of the X-ray scanned image is adjusted by adjusting the γ value of each point, so that the de-noised image gray distribution is suitable;
(ii) random noise model conversion
The main reason for the image degradation of the X-ray imaging system is the system random noise, which appears as horizontal or vertical stripes on the X-ray scanning image, and studies show that the distribution of the noise generated by the generation of X-rays and the interaction with the substance is considered as a state discrete, time continuous markov process, which satisfies the poisson random process both in time and space, and if the independent increment process Δ c (t) and the probability distribution of the increment obey the poisson distribution, the following are provided:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>&ap;</mo> <mfrac> <msup> <mi>&lambda;</mi> <mi>k</mi> </msup> <mrow> <mi>k</mi> <mo>!</mo> </mrow> </mfrac> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>&lambda;</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>3</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein K is the number of times of occurrence of a random variable increment Δ c (t), K belongs to (1, 2.. K), and when K is larger, it is very inconvenient in practical application that the error is very complicated to calculate according to a poisson distribution formula, so that a stipling (Stirling) approximation formula is adopted for a noise image to convert poisson noise into white gaussian noise;
the stipling approximation formula holds that when k is large, k! Approximated by equation (4):
<math> <mrow> <mi>k</mi> <mo>!</mo> <mo>&ap;</mo> <msqrt> <mn>2</mn> <mi>&pi;k</mi> </msqrt> <msup> <mi>k</mi> <mi>k</mi> </msup> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>k</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>4</mn> <mo>)</mo> </mrow> </mrow> </math>
at this time, the noise is converted from poisson distribution to gaussian distribution, and then the X-ray noise distribution expression is:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <msqrt> <mn>2</mn> <mi>&pi;h</mi> </msqrt> </mfrac> <msup> <mi>e</mi> <mrow> <mo>[</mo> <mo>-</mo> <mfrac> <msup> <mrow> <mo>(</mo> <mi>h</mi> <mo>-</mo> <mi>k</mi> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mrow> <mn>2</mn> <mi>h</mi> </mrow> </mfrac> <mo>]</mo> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>5</mn> <mo>)</mo> </mrow> </mrow> </math>
the original image conforms to a gaussian white noise model, whose mathematical expectation E is given by equation (6):
<math> <mrow> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>=</mo> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>+</mo> <msup> <mrow> <mn>2</mn> <mi>&sigma;</mi> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein,
Figure BDA0000130219160000035
the method comprises the steps that the Gaussian weighted Euclidean distance of a neighborhood where pixels i and j are located is used, a is larger than 0 and is a standard Gaussian convolution kernel, the noise variance is sigma, and the size of the sigma determines the size of a fuzzy denoising window;
noise level estimation
The noise level has a close relationship with the module window size and the filter parameters, so that the noise level in an image needs to be estimated to achieve a good denoising effect. For white Gaussian noise, the mean value is 0, and only the standard deviation parameter of the white Gaussian noise needs to be estimated;
there are many gaussian noise estimation methods, and two methods, image block-based and filter-based, are commonly used. Dividing an image into a plurality of small blocks based on an image block method, calculating respective variances of the small blocks, and taking the mean value of a plurality of minimum variances as an estimation result; the filter-based method first smoothes the image once, and then calculates the difference between the original image and the smoothed image, thereby estimating the noise level from the difference image. According to the method, an image is divided into a plurality of subblocks by using a block dividing method, each subblock is filtered by using a parallel filtering method, and then the maximum noise level in the subblocks is found by using a particle swarm optimization algorithm to serve as an overall noise level estimation result;
theoretical analysis and experimental results of Buades research in recent years indicate that the NL-Means algorithm is superior to common image denoising algorithms in subjective and objective performance, such as Gaussian filtering, anisotropic filtering, total error minimization, neighborhood filtering and the like, weight of the NL-Means algorithm is obtained according to the similarity of gray distribution of the whole area around a pixel, and the NL-Means algorithm has strong capacity of keeping image spatial resolution while reducing image noise;
(iii) fuzzy noise filtering template window
In order to improve the calculation efficiency, two windows are selected for parallel operation, two window sizes are set, one is the pixel neighborhood window size A multiplied by A, the other is the window size B multiplied by B of the pixel neighborhood window search range, namely the neighborhood size of a selected pixel in the area with the size of B multiplied by B is A multiplied by A, an Adaptive Non Local averaging (ANL-means) algorithm is executed, the B multiplied by B window slides in the area with the size of A multiplied by A, and the contribution weight of the central pixel gray level of the area is determined according to the similarity of the areas.
2) Bivariate fuzzy adaptive non-local average filtering algorithm
The most core problem in the FANL means algorithm is to use gaussian additive noise level to find the relevant local reconstruction weight matrix that minimizes the reconstruction error, however, the algorithm is operated for local image blocks, researchers all use variables related to euclidean distance to define the weight matrix, and the magnitude of influence is measured by the distance, which makes the algorithm sensitive to the noise in the sample, and the convergence speed of the algorithm is not fast enough. The bivariate fuzzy self-adaptive non-local average filtering algorithm is established on the basis of fuzzy denoising window selection, each small image block is subjected to non-local average filtering denoising processing, a pair of optimized filtering parameters are obtained in each module, the particle swarm optimization algorithm is utilized to achieve updating operation of the optimal parameters, and accordingly optimization solving of the target is achieved. Therefore, the invention uses the particle swarm optimization algorithm to search the weight value which minimizes the dimension reduction reconstruction error of the characteristic vector of the X-ray scanning image from the optimal parameter of the filter, thereby obtaining the effective denoising method of the X-ray scanning image.
According to the invention, ANL means filtering processing is carried out in an image subblock, an individual of a particle swarm optimization algorithm is constructed according to a related program of a sample point and a near point of the sample point, then the individual of the particle swarm finds out a global optimal speed in an optimization process, a global optimal position is determined, and finally a most relevant near local reconstruction weight matrix is obtained, so that irrelevant redundant information is effectively removed, and effective noise elimination of X-rays is realized;
first, bivariate non-local average filtering
Let c (X, y) be an observation image, i.e., an X-ray inspection image, n be a mean of 0 and a variance of σ2The input image R (x, y) is mapped into the observation space through a Non Local means (NL means) algorithm, wherein (x, y) defines a two-dimensional bounded region, and (x, y) belongs to R2,xi,yiAnd neighborhood point xj,yjCorrelation value NL (c (x)) betweeni,yi) Is determined from equation (6):
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> </mfrac> <mo>&Integral;</mo> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </mrow> </msup> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mi>dxdy</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein the variables are (x, y),
Figure BDA0000130219160000052
is a Gaussian convolution kernel with standard deviation a, h is a filtering parameter, which is mainly determined by the noise standard deviation of the image, D (x)i,yi) For NL means transform coefficients, it is found from the gray values of the relative positions of the coordinates (x, y):
<math> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>=</mo> <msup> <mrow> <mo>&Integral;</mo> <mi>e</mi> </mrow> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>t</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>t</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </msup> <msup> <mi>x</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <msup> <mi>y</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mi>di</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>7</mn> <mo>)</mo> </mrow> </mrow> </math>
for a digital X-ray scanning image, which is expressed as C (I) in a discrete domain, a pixel point I belongs to (X, y), C ═ C (I), I belongs to I }, and I is a pixel set in the image, a pixel point NL means algorithm calculates a correlation value NL (C (I)) between the pixel point I and a neighborhood according to a form that a most relevant neighbor local reconstruction weight matrix is converted into a formula (8) and is expressed by a relevant neighbor local reconstruction weight w (I, j) and a gray value C (j) of a neighboring point thereof:
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mo>=</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>s</mi> <mo>&Element;</mo> <mi>I</mi> </mrow> </munder> <mi>w</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>,</mo> <mi>j</mi> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <mi>j</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>8</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein, in the formula (2), the point (x)i,yi) The gray value of (d) is c (i), and the change correction coefficient gamma is converted by c (x, y), and the adjacent point (x, y) is adjacent to the gray valuej,yj) I is the total number of pixels of the X-ray detection image, X is the width value of c (X, Y), and Y is the height value of c (X, Y);
wherein, I { (1, 1), (1, 2), · (xi, yi) · (X, Y) } where, the associated neighbor local reconstruction weight w (I, j) is expressed as:
w ( i , j ) = 1 Z ( i ) e | | c ( NL ( x i , , y i ) c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 9 )
Z ( i ) = e - | | c ( NL ( x i , , y i ) - c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 10 )
wherein, the related near neighbor local reconstruction weight w (i, s) between the pixel point i and the near point j is constructed in the relation of the vertical type (9), Z (i) is a weight weighting transformation coefficient,
Figure BDA0000130219160000057
the gray level-based Gaussian weighted Euclidean distance of two neighborhoods where points i and j are located, a weight value w (i, s) is mainly determined by parameters a and h, a is the standard deviation of a standard Gaussian convolution kernel, h is a filtering parameter of a bivariate NL means, if a is larger, the weight value is smaller, and the pixel x is indicatedi,yiThe farther away from the central pixel, the size of a is determined by the size of the window of the selected pixel neighborhood, a x a; with the increase of the filtering parameter h, the artificial artifact is gradually weakened, but the spatial resolution is also reduced, and the filtering parameter h is determined by the standard deviation of the noise;
(ii) particle swarm optimization
Setting the obtained local optimal parameter in the p-th sub-module as apAnd hpFor local optimal solution vectors, each particle can estimate an adaptive value of the position of the particle through a certain rule by using a particle swarm optimization algorithm; each particle can remember its own currently found local best position zpNamely, it is a p h p , Local position of the particle is zpq,zp∈zpq={zp1,zp2,....,zpq..zpQ},zpqFor the position of the particles in the local population, Q is the number of particles contained in the population, and in addition, the best position found by all individuals in the population, called globally optimal z, is kept in mindgI.e. by a h , Selecting the best of the population a h Solving the vector;
the particle swarm optimization algorithm indicates that all particles have a speed to determine their direction and distance, called local optimal speed, vpRepresents; the particles search in the solution space following the current optimal particle, and in each iteration, the particles update the position and velocity according to the following equation:
zp+1=zp+vp+1 (11)
vp+1=w1vp+g1(spq-zp)+g2(sgq-zp) (12)
where Q is the dimension of the target search space and P represents the populationNumber of bodies, calculate spCurrent position adaptation value, vpIs the flight velocity, s, of the particle pp∈(sp1,sp2,spq,...spQ) For the optimum position, s, of the particles searched so farpqThe position through which the particles pass in the population, spIs a velocity vpThe optimal position searched in time; sg=(sg1+sg1+...sgq+...sgQ) Optimum position sum, s, searched for the entire particle swarm so fargqBest position currently recorded for the particle swarm, g1And g2For a self-learning factor, w1Is the inertial weight;
third, the evaluation function of the degree of suitability
The fitness evaluation function is a mark for measuring the quality of an individual and has the function of finding out the overall optimal parameters a and h in the block sub-graph module. According to the invention, according to the particularity of an industrial X-ray scanning image noise model as an individual model, the adopted fitness evaluation function is as follows:
<math> <mrow> <mi>f</mi> <mrow> <mo>(</mo> <mi>u</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>p</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>P</mi> </munderover> <msup> <mrow> <mo>|</mo> <mo>|</mo> <msub> <mi>v</mi> <mi>p</mi> </msub> <mo>-</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>d</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>D</mi> </munderover> <msub> <mi>u</mi> <mi>pq</mi> </msub> <msup> <msub> <mi>z</mi> <mi>pq</mi> </msub> <mo>&prime;</mo> </msup> <mo>|</mo> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>13</mn> <mo>)</mo> </mrow> </mrow> </math>
in the formula upqExpressing the qth individual of the p generation in the particle swarm, and D expressing the number of individuals in the swarm, wherein the optimization method comprises the following specific steps:
firstly, initializing a population: selecting a threshold value epsilon and a maximum number of iterations umaxThe initial iteration number u is 0 and the particle position range is zmin~zmaxParticle velocity range vmax~vmin
Measuring individuals in the population: measuring the adaptation value u for each particlepqSelecting the optimal adaptation value of the group at this time to compare with the optimal adaptation value of the historical group to obtain the current optimal adaptation value u of the grouppAnd u isp∈{upq|up1,up2,...upq,...upQAnd the value zg epsilon { z } of the corresponding position is takenpq|zp1,zp2,...zpq,...zpQ}; each particle obtains the current optimal adaptive value u by comparing the sizes of the historical adaptive valuesg∈{ugq|ug1,ug2,...ugq,...ugQAnd access the corresponding position zg∈{zgq|zg1,zg2,...zgq,...zgQ};
③ evaluation of population UpAnd keeping the optimal solution;
particle swarm operation: if U is presentpIf the value is more than epsilon, executing in sequence, otherwise, ending the circulation;
v is updated according to the rulep,zp
Sixthly, changing evolution algebra: adding 1 to the evolution algebra, e.g. the maximum evolution algebra P has not yet been metmaxStep of algorithm transfer to this sectionAnd ② continuing to proceed.
The invention has the beneficial effects that in order to better eliminate the influence of unknown quantum noise in the industrial X-ray scanning image, the bivariate fuzzy adaptive non-linear average filtering X-ray image denoising method is provided, wherein the quantum noise model which is difficult to process is converted into a common Gaussian additive noise model, the size of a filter window is selected by using fuzzy operation, and a correlation weight matrix which enables an error function to be minimum is searched. In the invention, particle swarm optimization filtering parameters are introduced, so that a weight matrix is locally reconstructed, the influence of local correlation on sample data is reduced, the algorithm convergence speed is increased, the speed and the precision of the denoising processing of the industrial X-ray scanning image are increased, and the method is suitable for the processing of the X-ray scanning image with uncertain noise models.
Drawings
FIG. 1 is a flow chart of a particle swarm optimization algorithm;
FIG. 2 is a schematic diagram of de-noising an industrial X-ray scanning image;
FIG. 3 is a diagram of membership functions for fuzzy window types at different noise levels.
Detailed Description
A noise elimination method for bivariate non-local average filtering X-ray image includes such steps as filtering the average X-ray image,
1) selection method of fuzzy noise-canceling window
The non-local average filtering algorithm has a premise assumption: the local space where the sampling data is located is linear, namely each sampling point has a similar relation with its adjacent points and is linearly represented by a weight contribution value;
the learning objectives of the algorithm are: setting the weight of each neighborhood according to the similarity of gray distribution by fully utilizing the redundancy relation among pixels in a low-dimensional space, namely, reconstructing an original image by minimizing irrelevant pixels under the condition that an embedded mapping window is locally linear;
let c (X, y) be the X-ray scanning image function, r (X, y) be the ideal image function, n (X, y) be the noise image function, and X, y be the coordinates of image pixel points in the rectangular coordinate system, then:
c(x,y)=r(x,y)+n(x,y) (1)
now, a template is needed to be found to determine the correlation between each element of c (x, y) and r (x, y), so that n (x, y) is eliminated effectively;
the gray value corresponding to the pixel point x, y in the c (x, y) image is represented by c (i), and then there is
<math> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>I</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>Y</mi> </munderover> <munderover> <mi>&Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>X</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>x</mi> <mo>,</mo> <mi>y</mi> <mo>)</mo> </mrow> <mo>+</mo> <mi>&gamma;</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>2</mn> <mo>)</mo> </mrow> </mrow> </math>
The image denoising method comprises the following steps of obtaining an image point X, obtaining an image point Y, obtaining a gray level pixel in the image point X, obtaining a gray level pixel in the image point Y, obtaining an image point Y by using a pixel I, obtaining a gray level pixel in the image point X, obtaining a gray level pixel in the image point Y, and obtaining a gray level pixel in the image point X, obtaining a gray level pixel in the image point Y, wherein I is belonged to (1, 2.. I), X is belong;
(ii) random noise model conversion
The main reason for the image degradation of the X-ray imaging system is the system random noise, which appears as horizontal or vertical stripes on the X-ray scanning image, and studies show that the distribution of the noise generated by the generation of X-rays and the interaction with the substance is considered as a state discrete, time continuous markov process, which satisfies the poisson random process both in time and space, and if the independent increment process Δ c (t) and the probability distribution of the increment obey the poisson distribution, the following are provided:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>&ap;</mo> <mfrac> <msup> <mi>&lambda;</mi> <mi>k</mi> </msup> <mrow> <mi>k</mi> <mo>!</mo> </mrow> </mfrac> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>&lambda;</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>3</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein K is the number of times of occurrence of a random variable increment Δ c (t), K belongs to (1, 2.. K), and when K is larger, it is very inconvenient in practical application that the error is very complicated to calculate according to a poisson distribution formula, so that a stipling (Stirling) approximation formula is adopted for a noise image to convert poisson noise into white gaussian noise;
the stipling approximation formula holds that when k is large, k! Approximated by equation (4):
<math> <mrow> <mi>k</mi> <mo>!</mo> <mo>&ap;</mo> <msqrt> <mn>2</mn> <mi>&pi;k</mi> </msqrt> <msup> <mi>k</mi> <mi>k</mi> </msup> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>k</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>4</mn> <mo>)</mo> </mrow> </mrow> </math>
at this time, the noise is converted from poisson distribution to gaussian distribution, and then the X-ray noise distribution expression is:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <msqrt> <mn>2</mn> <mi>&pi;h</mi> </msqrt> </mfrac> <msup> <mi>e</mi> <mrow> <mo>[</mo> <mo>-</mo> <mfrac> <msup> <mrow> <mo>(</mo> <mi>h</mi> <mo>-</mo> <mi>k</mi> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mrow> <mn>2</mn> <mi>h</mi> </mrow> </mfrac> <mo>]</mo> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>5</mn> <mo>)</mo> </mrow> </mrow> </math>
the original image conforms to a gaussian white noise model, whose mathematical expectation E is given by equation (6):
<math> <mrow> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>=</mo> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>+</mo> <msup> <mrow> <mn>2</mn> <mi>&sigma;</mi> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein,
Figure BDA0000130219160000095
is the Gaussian weighted Euclidean distance of the neighborhood where the pixel i, j is located, and a > 0 is the standardThe noise variance is sigma, and the size of the sigma determines the size of a fuzzy noise elimination window;
noise level estimation
The noise level has a close relationship with the module window size and the filter parameters, so that the noise level in an image needs to be estimated to achieve a good denoising effect. For white Gaussian noise, the mean value is 0, and only the standard deviation parameter of the white Gaussian noise needs to be estimated;
there are many gaussian noise estimation methods, and two methods, image block-based and filter-based, are commonly used. Dividing an image into a plurality of small blocks based on an image block method, calculating respective variances of the small blocks, and taking the mean value of a plurality of minimum variances as an estimation result; the filter-based method first smoothes the image once, and then calculates the difference between the original image and the smoothed image, thereby estimating the noise level from the difference image. According to the method, an image is divided into a plurality of subblocks by using a block dividing method, each subblock is filtered by using a parallel filtering method, and then the maximum noise level in the subblocks is found by using a particle swarm optimization algorithm to serve as an overall noise level estimation result;
theoretical analysis and experimental results of Buades research in recent years indicate that the NL-Means algorithm is superior to common image denoising algorithms in subjective and objective performance, such as Gaussian filtering, anisotropic filtering, total error minimization, neighborhood filtering and the like, weight of the NL-Means algorithm is obtained according to the similarity of gray distribution of the whole area around a pixel, and the NL-Means algorithm has strong capacity of keeping image spatial resolution while reducing image noise;
(iii) fuzzy noise filtering template window
In order to improve the calculation efficiency, two windows are selected for parallel operation, two window sizes are set, one is the pixel neighborhood window size A multiplied by A, the other is the window size B multiplied by B of the pixel neighborhood window search range, namely the neighborhood size of a selected pixel in the area with the size of B multiplied by B is A multiplied by A, an Adaptive Non Local averaging (ANL-means) algorithm is executed, the B multiplied by B window slides in the area with the size of A multiplied by A, and the contribution weight of the central pixel gray level of the area is determined according to the similarity of the areas.
2) Bivariate fuzzy adaptive non-local average filtering algorithm
The most core problem in the FANL means algorithm is to use gaussian additive noise level to find the relevant local reconstruction weight matrix that minimizes the reconstruction error, however, the algorithm is operated for local image blocks, researchers all use variables related to euclidean distance to define the weight matrix, and the magnitude of influence is measured by the distance, which makes the algorithm sensitive to the noise in the sample, and the convergence speed of the algorithm is not fast enough. The bivariate fuzzy self-adaptive non-local average filtering algorithm is established on the basis of fuzzy denoising window selection, each small image block is subjected to non-local average filtering denoising processing, a pair of optimized filtering parameters are obtained in each module, the particle swarm optimization algorithm is utilized to achieve updating operation of the optimal parameters, and accordingly optimization solving of the target is achieved. Therefore, the invention uses the particle swarm optimization algorithm to search the weight value which minimizes the dimension reduction reconstruction error of the characteristic vector of the X-ray scanning image from the optimal parameter of the filter, thereby obtaining the effective denoising method of the X-ray scanning image.
According to the invention, ANL means filtering processing is carried out in an image subblock, an individual of a particle swarm optimization algorithm is constructed according to a related program of a sample point and a near point of the sample point, then the individual of the particle swarm finds out a global optimal speed in an optimization process, a global optimal position is determined, and finally a most relevant near local reconstruction weight matrix is obtained, so that irrelevant redundant information is effectively removed, and effective noise elimination of X-rays is realized;
first, bivariate non-local average filtering
Let c (X, y) be an observation image, i.e., an X-ray inspection image, n be a mean of 0 and a variance of σ2The input image r (x, y) is mapped into the observation space by a Non Local means (NL means) algorithm, and (x, y) defines a two-dimensional bounded regionRegion, (x, y) is E.R2,xi,yiAnd neighborhood point xj,yjCorrelation value NL (c (x)) betweeni,yi) Is determined from equation (6):
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> </mfrac> <mo>&Integral;</mo> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </mrow> </msup> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mi>dxdy</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein the variables are (x, y),
Figure BDA0000130219160000102
is a Gaussian convolution kernel with standard deviation a, h is a filtering parameter, which is mainly determined by the noise standard deviation of the image, D (x)i,yi) For NL means transform coefficients, it is found from the gray values of the relative positions of the coordinates (x, y):
<math> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>=</mo> <msup> <mrow> <mo>&Integral;</mo> <mi>e</mi> </mrow> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>t</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>t</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </msup> <msup> <mi>x</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <msup> <mi>y</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mi>di</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>7</mn> <mo>)</mo> </mrow> </mrow> </math>
for a digital X-ray scanning image, which is expressed as C (I) in a discrete domain, a pixel point I belongs to (X, y), C ═ C (I), I belongs to I }, and I is a pixel set in the image, a pixel point NL means algorithm calculates a correlation value NL (C (I)) between the pixel point I and a neighborhood according to a form that a most relevant neighbor local reconstruction weight matrix is converted into a formula (8) and is expressed by a relevant neighbor local reconstruction weight w (I, j) and a gray value C (j) of a neighboring point thereof:
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mo>=</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>s</mi> <mo>&Element;</mo> <mi>I</mi> </mrow> </munder> <mi>w</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>,</mo> <mi>j</mi> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <mi>j</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>8</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein, in the formula (2), the point (x)i,yi) The gray value of (d) is c (i), and the change correction coefficient gamma is converted by c (x, y), and the adjacent point (x, y) is adjacent to the gray valuej,yj) I is the total number of pixels of the X-ray detection image, X is the width value of c (X, Y), and Y is the height value of c (X, Y);
wherein, I { (1, 1), (1, 2) · I.. I } { (1, 2) }i,yi) (X, Y) }, where the associated neighbor local reconstruction weight w (i, j) is expressed as:
w ( i , j ) = 1 Z ( i ) e | | c ( NL ( x i , , y i ) c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 9 )
Z ( i ) = e - | | c ( NL ( x i , , y i ) - c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 10 )
wherein, the related near neighbor local reconstruction weight w (i, s) between the pixel point i and the near point j is constructed in the relation of the vertical type (9), Z (i) is a weight weighting transformation coefficient,the gray level-based Gaussian weighted Euclidean distance of two neighborhoods where points i and j are located, a weight value w (i, s) is mainly determined by parameters a and h, a is the standard deviation of a standard Gaussian convolution kernel, h is a filtering parameter of a bivariate NL means, if a is larger, the weight value is smaller, and the pixel x is indicatedi,yiThe further away from the central pixel, the size of a is determined by the window of the selected pixel neighborhoodDetermining the size A multiplied by A; with the increase of the filtering parameter h, the artificial artifact is gradually weakened, but the spatial resolution is also reduced, and the filtering parameter h is determined by the standard deviation of the noise;
(ii) particle swarm optimization
Setting the obtained local optimal parameter in the p-th sub-module as apAnd hpFor local optimal solution vectors, each particle can estimate an adaptive value of the position of the particle through a certain rule by using a particle swarm optimization algorithm; each particle can remember its own currently found local best position zpNamely, it is a p h p , Local position of the particle is zpq,zp∈zpq={zp1,zp2....,zpq..zpQ},zpqFor the position of the particles in the local population, Q is the number of particles contained in the population, and in addition, the best position found by all individuals in the population, called globally optimal z, is kept in mindgI.e. by a h , Selecting the best of the population a h Solution vector;
The particle swarm optimization algorithm indicates that all particles have a speed to determine their direction and distance, called local optimal speed, vpRepresents; the particles search in the solution space following the current optimal particle, and in each iteration, the particles update the position and velocity according to the following equation:
zp+1=zp+vp+1 (11)
vp+1=w1vp+g1(spq-zp)+g2(sgq-zp) (12)
where Q is the dimension of the target search space, P represents the number of individuals in the population, and s is calculatedpCurrent position adaptation value, vpIs the flight velocity, s, of the particle pp∈(sp1,sp2,spq,...spQ) For the optimum position, s, of the particles searched so farpqThe position through which the particles pass in the population, spIs a velocity vpThe optimal position searched in time; sg=(sg1+sg1+...sgq+...sgQ) Optimum position sum, s, searched for the entire particle swarm so fargqBest position currently recorded for the particle swarm, g1And g2For a self-learning factor, w1Is the inertial weight;
third, the evaluation function of the degree of suitability
The fitness evaluation function is a mark for measuring the quality of an individual and has the function of finding out the overall optimal parameters a and h in the block sub-graph module. According to the invention, according to the particularity of an industrial X-ray scanning image noise model as an individual model, the adopted fitness evaluation function is as follows:
<math> <mrow> <mi>f</mi> <mrow> <mo>(</mo> <mi>u</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>p</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>P</mi> </munderover> <msup> <mrow> <mo>|</mo> <mo>|</mo> <msub> <mi>v</mi> <mi>p</mi> </msub> <mo>-</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>d</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>D</mi> </munderover> <msub> <mi>u</mi> <mi>pq</mi> </msub> <msup> <msub> <mi>z</mi> <mi>pq</mi> </msub> <mo>&prime;</mo> </msup> <mo>|</mo> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>13</mn> <mo>)</mo> </mrow> </mrow> </math>
in the formula upqExpressing the qth individual of the p generation in the particle swarm, and D expressing the number of individuals in the swarm, wherein the optimization method comprises the following specific steps:
firstly, initializing a population: selecting a threshold value epsilon and a maximum number of iterations umaxThe initial iteration number u is 0 and the particle position range is zmin~zmaxParticle velocity range vmax~vmin
Measuring individuals in the population: measuring the adaptation value u for each particlepqSelecting the optimal adaptation value of the group at this time to compare with the optimal adaptation value of the historical group to obtain the current optimal adaptation value u of the grouppAnd u isp∈{upq|up1,up2,...upq,...upQAnd access the value z of the corresponding positiong∈{zpq|zp1,zp2,...zpq,...zpQ}; each particle is obtained by comparing the sizes of self adaptive values historicallyThe optimal adaptive value u up to the presentg∈{ugq|ug1,ug2,...ugq,...ugQAnd access the corresponding position zg∈{zgq|zg1,zg2,...zgq,...zgQ};
③ evaluation of population UpAnd keeping the optimal solution;
particle swarm operation: if U is presentpIf the value is more than epsilon, executing in sequence, otherwise, ending the circulation;
v is updated according to the rulep,zp
Sixthly, changing evolution algebra: adding 1 to the evolution algebra, e.g. the maximum evolution algebra P has not yet been metmaxThe algorithm goes to step two of this section to continue.
The invention carries out denoising research aiming at the characteristics of narrow gray scale interval, fuzzy defect edge, much image noise, sometimes submerged defect characteristics and the like of an X-ray scanning image in the nondestructive testing process of electric field industrial equipment, respectively takes horizontal quantum noise, vertical quantum noise, random noise and noise generated by over-enhancement processing as examples for research, and inputs scanning images of various formats such as BMP, JPG, PNG and the like with any size. Firstly, a user provides self-selection parameters (target images) according to the requirement of a denoising index, if the user does not provide the self-selection parameters, the system automatically judges the self-selection parameters and converts quantum noise of the input images into Gaussian noise, then, the high-stage noise is subjected to level division, different windows are set by using a fuzzy control rule according to the level distribution of a noise model, different filter parameters are set in each sub-window, the global optimal filter parameters are selected by using a parallel particle swarm optimization algorithm, then, the FANL denoising algorithm is carried out on the whole X-ray scanning image, and the denoising performance of the system is evaluated by using Minimum Mean Square Error (MMSE), Peak Signal Noise Ratio (PSNR) and time t used for denoising. The system structure block diagram is shown in fig. 2, and the specific implementation method is as follows:
1. noise level modeling and template window size selection
The main reason for image degradation in X-ray imaging systems is systematic random noise. Studies have shown that X-ray generation and interaction with matter satisfy the poisson stochastic process both temporally and spatially. For a fast X-ray imaging system, due to the short exposure time, the quantum noise generated by the X-ray is more prominent, which seriously affects the quality of the image. Therefore, the input X-ray scan image is added with the mean value μ based on the original image because the noise model is unknown0Is 0, initial variance σ0A low noise level of 0.02 is Gaussian white noise, where μ0,σ0In order to add an initial value of Gaussian noise, the initial value is a constant value, at the moment, an image function model of X-ray scanning after the Gaussian uniform noise is added is approximated by using a stipuling formula (4), Poisson noise is converted into the Gaussian white noise, and then the variance sigma of the total Gaussian white noise of the converted image is solved, and the performance of the system is influenced by the value of the sigma.
According to the selection principle of a fuzzy noise filtering template window, the local optimal parameters of an image subjected to gaussian noise processing on a detected X-ray image need to be calculated in a fuzzy blocking parallel mode, so that two windows need to be set, the size of a pixel neighborhood window is A multiplied by A, the size of a window B multiplied by B of a neighborhood window search range is B multiplied by B, and a common image with large noise is generally selected to be A equal to 7 and B equal to 23, and the noise reduction can be basically met by selecting A equal to 3 and B equal to 7 for a low-noise image. Therefore, the noise level is used to set the size of the template window for non-local average noise cancellation, and the parameter (u) is added for the input noise0,σ0) The model of post-conversion noise of white gaussian noise is divided into five levels according to the difference of high-term noise level sigma in the converted image function, namely, five domain intervals of low noise sigma < 0.2, low noise 0.2 < sigma < 0.5, medium noise 0.5 < sigma < 0.8, high noise 0.8 < sigma < 1 and high noise sigma > 1, different processing template windows are set for different noises, filtering parameters are adaptively adjusted in each template window, and the type levels of noise fuzzy windows at different levels are shown in fig. 3.
2. Local optimal parameter selection in template window
(1) Local parameter a
The weighted value w (i, j) of the pixel point i and the adjacent pixel point j in the non-local average filtering is mainly determined by parameters a and h, wherein a is a standard Gaussian convolution kernel, h is a filtering parameter of bivariate NL means, the larger the Gaussian convolution kernel a is, the smaller the weighted value is, and the pixel x is shown to bei,yiThe farther away from the central pixel, the size of a is determined by the size of the window of the selected pixel neighborhood, a x a; the value of a has a certain relation with the smoothness of the image, when the value of a is large, more noise points are included, but points which are different from the current pixel value in the image are included, so that the larger the value of a is, the better the value of a is, and the range of the size of a neighborhood window is usually 1-10 times; and simultaneously considering the influence of different noise levels, taking 10-15 times of the noise standard deviation sigma as a reference value, and considering all pixel points of which the weighted absolute difference with the current pixel does not exceed a sigma. Therefore, when the selected optimum parameter does not satisfy the above condition, the selected local optimum parameter value is discarded.
(2) Local parameter h
The study shows that the filter parameter h and the noise variance sigma2Has approximately linear proportional relation and is influenced by the variance of the noise image, and in order not to lose information except the noise, when the weighted distance between two pixels is larger than a threshold value hβWhen (β is the cut-off condition set by the filter), the weight w (i, j) should be close to zero.
When the distribution of pixel points in the image after the noise processing is carried out accords with Gaussian distribution, the noise weight function w (i, j) accords with a typical Gaussian function with the mean value of 0 and the standard deviation of h/2, therefore, the distribution of the weight w (i, j) is adjusted by changing the value of h, the w (i, j) meets the characteristic of the Gaussian distribution, points which have the same gray level with the current pixel point and the adjacent pixel thereof have some differences with the current pixel value after the Gaussian noise (sigma) is superposed, the differences determine the Gaussian weighted Euclidean distance value based on the gray level between the two points i and j, and the pixels with a certain proportion fall in the range that the weighted absolute difference value of the pixel value considered at present does not exceed the noise standard deviation by beta. And neglecting the percentage of noise pixels when setting the neglected weight sum and calculating the weighted distance, estimating the sum of all weights when the weight distance is greater than a certain multiple of the standard deviation, setting the neglected weight sum, and solving the multiple value. Assuming now that the weighted absolute difference of pixel values does not exceed the multiple of the noise standard deviation by β, the non-negligible distance should satisfy:
<math> <mrow> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>NL</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>NL</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>&le;</mo> <mfrac> <mi>&beta;h</mi> <msqrt> <mn>2</mn> </msqrt> </mfrac> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>14</mn> <mo>)</mo> </mrow> </mrow> </math>
then the approximate relationship between the filter parameters and the noise level is obtained as:
<math> <mrow> <mi>h</mi> <mo>=</mo> <msqrt> <mn>2</mn> </msqrt> <msup> <mi>&beta;&sigma;</mi> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>15</mn> <mo>)</mo> </mrow> </mrow> </math>
the number of X-ray image gray levels is 256, and therefore, the h value is estimated using the following equation:
<math> <mrow> <mi>h</mi> <mo>=</mo> <mo>[</mo> <msqrt> <mn>2</mn> </msqrt> <mi>&beta;</mi> <mo>+</mo> <mfrac> <mrow> <mi>max</mi> <mrow> <mo>(</mo> <mi>O</mi> <mrow> <mo>(</mo> <msub> <mi>&sigma;</mi> <mi>c</mi> </msub> <mo>-</mo> <msub> <mi>&sigma;</mi> <mn>0</mn> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mrow> <mn>10</mn> </mfrac> <mo>]</mo> <msup> <mi>&sigma;</mi> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>16</mn> <mo>)</mo> </mrow> </mrow> </math>
σcto detect the mean standard deviation, σ, of the image0To refer to the standard deviation threshold, an approximately optimal effect is achieved when the noise image is filtered using the parameters in equation (16). Too small an h parameter value may leave much noise to be accounted for; if the h parameter value is too large, some image differences beyond the noise range can be smoothed, so that the image is too smooth, and the edge and other detailed information is lost. For an X-ray scanned image with 256 levels of gray scale, less than σ0Has less influence on the h value, and when the noise level is higher than sigma0The time has a large influence on h.
3. Filtering parameter solution vector selection based on particle swarm optimization
When the noise elimination processing is carried out on the X-ray image, firstly, the whole image is partitioned, and then the local optimal parameter solution vector of each sub-block is solved by using an ANL means algorithm. Because the noise model obtained by the X-ray machine is unknown, the number of the blocks of different X-ray images is different, and the local optimal parameters in each image sub-block are different, so that a particle swarm optimization algorithm is adopted to search a global optimal parameter solution vector in the X-ray scanned image.
The method extracts characteristic information in X-ray scanning image sub-blocks after Gaussian noise model conversion according to the correlation of gray values of all pixel points, wherein the size of a neighborhood window is A multiplied by A, the size of a window in a search range is B multiplied by B, at the moment, not only are adjacent points related, but also certain correlation exists among non-adjacent points in a set range, a weight value w (i, j) is obtained according to the correlation among the pixel points i, j, and the local optimal parameter a of each sub-block is calculated in each sub-blocki,hiAnd then, solving the global optimal parameters a and h by utilizing a particle swarm optimization algorithm.
The input X-ray image is divided into P sub-blocks, certain correlation exists between every two sub-blocks in consideration of correlation among pixels, and therefore each sub-block is regarded as a sample point c of the optimal parameter space to be selectedpCalculating each sample point (feature vector) cpCalculating the distance between the point and other P-1 sample points, sorting the distances, and selecting the first k and cpThe nearest point is taken as its neighboring point.
Calculating local reconstruction weight matrix of each sample point from neighboring points of the sample point a p h p . And (4) reconstructing the feature vector by using the neighboring point of each feature vector, and solving a neighboring local reconstruction weight matrix which minimizes the reconstruction error.
The reconstruction fitting error function is defined as follows:
<math> <mrow> <mi>f</mi> <mrow> <mo>(</mo> <mi>u</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>p</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>P</mi> </munderover> <msup> <mrow> <mo>|</mo> <mo>|</mo> <msub> <mi>v</mi> <mi>p</mi> </msub> <mo>-</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>d</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>D</mi> </munderover> <msub> <mi>u</mi> <mi>pq</mi> </msub> <msup> <msub> <mi>z</mi> <mi>pq</mi> </msub> <mo>&prime;</mo> </msup> <mo>|</mo> <mo>|</mo> </mrow> <mn>2</mn> </msup> </mrow> </math>
wherein, cq(q ═ 1, 2,. k) is cpQ neighboring points in the sample, upqIs cpAnd cqThe weight value in between.
When the following two constraint conditions are met, a local reconstruction weight matrix is obtained by minimizing an error function, namely an optimal W matrix is constructed by the adjacent points of the sample points, so that the error function value is minimum.
1) Each data point cqCan only be represented by its associated point if cqNot the point of correlation, then upq=0;
2) The sum of each row of the weight matrix is 1, i.e. the normalized constraint is satisfied
Figure BDA0000130219160000163
In the process of solving the optimal U matrix, U is an error function formed by reconstruction fitting error function solution vectors, in the invention, a sample point and a reconstruction weight vector set of a relevant point are used as initial particles of a particle swarm algorithm, then an individual in the particle swarm finds a global optimal position and an optimal speed in the process of optimizing, and finally a neighboring local reconstruction weight matrix U is obtained. Wherein u ispqRepresents the qth individual of the P-th generation in the population, and P represents the number of individuals in the population. The specific steps of the algorithm optimization are shown as follows, and the algorithm flow is shown in fig. 1.
In the formula upqThe q-th individual of the p-th generation in the particle swarm is shown, D represents the number of individuals in the swarm, the specific steps of the optimization of the algorithm are shown as follows, and the algorithm flow is shown in figure 1.
1) Initializing a population: selecting a threshold value epsilon and a maximum number of iterations umaxThe initial iteration number u is 0 and the particle position range is zmin~zmaxParticle velocity range vmax~vmin
2) Measurements were performed on individuals in the population: measuring the adaptation value u for each particlepqSelecting the optimal adaptation value of the group at this time to compare with the optimal adaptation value of the historical group to obtain the current optimal adaptation value u of the grouppAnd u isp∈{upq|up1,up2,...upq,...upQAnd access the value z of the corresponding positiong∈{zpq|zp1,zp2,...zpq,...zpQ}; each particle obtains the current optimal adaptive value u by comparing the sizes of the historical adaptive valuesg∈{ugq|ug1,ug2,...ugq,...ugQAnd access the corresponding position zg∈{zgq|zg1,zg2,...zgq,...zgQ}。
3) Evaluation population UpAnd keeping the optimal solution;
4) particle swarm operation: if U is presentpIf the value is more than epsilon, executing in sequence, otherwise, ending the circulation;
5) according to the rule, v is updatedp,zp
6) Changing evolution algebra: adding 1 to the evolution algebra, e.g. the maximum evolution algebra P has not yet been metmaxThe algorithm goes to step 2) and continues.
According to the steps, an optimal neighbor local reconstruction weight matrix U is obtained, and in order to keep the weight U (P) obtained in the previous step unchanged, the constraint conditions executed in the step 2) of the algorithm flow are as follows:
1) location update operation: z is a radical ofp+1=zp+vp+1
2) Speed updating operation: v. ofp+1=w1vp+g1(spq-zp)+g2(sgq-zp)
Wherein q is as large as { q ∈ [ { q ]1,q2... Q }, where Q is the dimension of the target search space and P is the number of data points in the sample, s is calculatedpCurrent position adaptation value, vpIs the flight velocity, s, of the particle pp∈(sp1,sp2,spq,...spQ) For the optimum position, s, of the particles searched so farpqThe position through which the particles pass in the population, spIs a velocity vpThe optimal position searched in time; sg=(sg1+sg1+...sgq+...sgQ) Optimum position sum, s, searched for the entire particle swarm so fargqBest position currently recorded for the particle swarm, g1And g2For a self-learning factor, w1Is the inertial weight. Therefore, the vector corresponding to the minimum Q eigenvalues of f (u) in the minimized fitting error function is the column vector composition matrix [ a ]p,hp]TThen the column vector of U is the vector representation of the Q-dimensional space.
4. Similarity measure
In the invention, quantum noise in an input industrial X-ray scanning image is converted into Gaussian noise, and then the converted image with the Gaussian noise is subjected to fast denoising by using a FANL algorithm. Therefore, the similarity measurement is carried out on the detected industrial X-ray detection image with uncertain quantum noise and the X-ray image with Gaussian noise converted by the noise model with low noise level, and the method adopts the following similarity measurement method:
(1) mutual information measurement
Mutual information is used as a similarity measure function for measuring the registration of the two images, and when the value of the mutual information is larger, the two amplitude images are more similar.
Assuming that the detected industrial X-ray detection image with uncertain quantum noise is image CR, the converted X-ray image with Gaussian noise is image C, and the sub-atlas formed by selecting neighborhood window blocks is C1,C2..Ca..CAAnd C is divided into C according to the search neighborhood window1,C2..Cb.CBCR and C are arbitrary real numbers, and the edge probability density of CR and C is PCR(cr) and PC(c) Their joint probability distribution is then denoted PAB(a, b) the degree of correlation between the two signals is represented by the cross-correlation information, and then
<math> <mrow> <mi>I</mi> <mrow> <mo>(</mo> <mi>CR</mi> <mo>,</mo> <mi>C</mi> <mo>)</mo> </mrow> <mo>=</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>cr</mi> <mo>,</mo> <mi>c</mi> </mrow> </munder> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> <mi>log</mi> <mfrac> <mrow> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> </mrow> <mrow> <msub> <mi>P</mi> <mi>CR</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>)</mo> </mrow> <msub> <mi>P</mi> <mi>C</mi> </msub> <mrow> <mo>(</mo> <mi>c</mi> <mo>)</mo> </mrow> </mrow> </mfrac> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>17</mn> <mo>)</mo> </mrow> </mrow> </math>
The cross-correlation has a close relationship with the entropy, and equation (17) is written in the form of equation (18):
I(CR,C)=H(CR,C)=H(CR)+H(C)-H(CR,C)=H(C)H(C/CR) (18)
h (A) and H (B) are the entropy of the two images respectively. The entropy of an image CR, which is related to the previous pixels, is expressed as follows:
<math> <mrow> <mi>H</mi> <mrow> <mo>(</mo> <mi>CR</mi> <mo>)</mo> </mrow> <mo>=</mo> <mo>-</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>n</mi> </munderover> <mi>pi</mi> <mi>log</mi> <mi>pi</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>19</mn> <mo>)</mo> </mrow> </mrow> </math>
i e (1, 2.. n) represents the number of pixels contained in the signal a, and if H (CR, C) represents the joint entropy of the images CR, C, and H (CR/C), H (C/CR) represents the conditional entropy of the images, respectively, then:
<math> <mrow> <mi>H</mi> <mrow> <mo>(</mo> <mi>CR</mi> <mo>|</mo> <mi>C</mi> <mo>)</mo> </mrow> <mo>=</mo> <mo>-</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>cr</mi> <mo>,</mo> <mi>c</mi> </mrow> </munder> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> <mi>log</mi> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>|</mo> <mi>c</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>20</mn> <mo>)</mo> </mrow> </mrow> </math>
<math> <mrow> <mi>H</mi> <mrow> <mo>(</mo> <mi>CR</mi> <mo>,</mo> <mi>C</mi> <mo>)</mo> </mrow> <mo>=</mo> <mo>-</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>cr</mi> <mo>,</mo> <mi>c</mi> </mrow> </munder> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> <mi>log</mi> <msub> <mi>P</mi> <mi>CRC</mi> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>21</mn> <mo>)</mo> </mrow> </mrow> </math>
let m (e) be the gray value of the original detected image at point s, e be the pixel point in the image, and Γ (T (e)) be the gray value of the original image after the original image dry-sound model conversion and after Γ transformation at point eThe gray scale value is set between 0-255, similarly, the gray scale value range of gamma (e) and m (T (e)) is 0-255, when C moves on CR, the overlapped part forms a two-dimensional histogram, and the number of the gray scale pair (gamma (e) formed by two graphs and m (T (e)) is hα(Γ m), the probability of the joint distribution of the two correlated images CR and C is then
Figure BDA0000130219160000191
Probability of edge distribution
Figure BDA0000130219160000192
And
Figure BDA0000130219160000193
the cross-correlation function is then:
<math> <mrow> <mi>I</mi> <mrow> <mo>(</mo> <mo>&PartialD;</mo> <mo>)</mo> </mrow> <mo>=</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>cr</mi> <mo>,</mo> <mi>c</mi> </mrow> </munder> <msub> <mi>P</mi> <mrow> <mi>CRC</mi> <mo>,</mo> <mo>&PartialD;</mo> </mrow> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> <msub> <mi>log</mi> <mn>2</mn> </msub> <mfrac> <mrow> <msub> <mi>P</mi> <mrow> <mi>CRC</mi> <mo>,</mo> <mo>&PartialD;</mo> </mrow> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>,</mo> <mi>c</mi> <mo>)</mo> </mrow> </mrow> <mrow> <msub> <mi>P</mi> <mrow> <mi>CR</mi> <mo>,</mo> <mo>&PartialD;</mo> </mrow> </msub> <mrow> <mo>(</mo> <mi>cr</mi> <mo>)</mo> </mrow> <msub> <mi>P</mi> <mi>C</mi> </msub> <mrow> <mo>(</mo> <mi>c</mi> <mo>)</mo> </mrow> </mrow> </mfrac> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>22</mn> <mo>)</mo> </mrow> </mrow> </math>
optimal mutual information parameter
Figure BDA0000130219160000195
Is provided with
<math> <mrow> <msup> <mo>&PartialD;</mo> <mo>*</mo> </msup> <mo>=</mo> <mi>arc</mi> <mi>max</mi> <mi>I</mi> <mrow> <mo>(</mo> <mi>&alpha;</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>23</mn> <mo>)</mo> </mrow> </mrow> </math>
Respectively solving neighborhood windows C1,C2..Ca..CAAnd search window C1,C2..Cb.CBOptimal mutual information parameter of
Figure BDA0000130219160000197
And
Figure BDA0000130219160000198
then the optimum value <math> <mrow> <msup> <msub> <mo>&PartialD;</mo> <mi>o</mi> </msub> <mo>*</mo> </msup> <mo>=</mo> <mi>max</mi> <mo>{</mo> <msubsup> <mo>&PartialD;</mo> <mi>a</mi> <mo>*</mo> </msubsup> <mo>,</mo> <msubsup> <mo>&PartialD;</mo> <mi>b</mi> <mo>*</mo> </msubsup> <mo>}</mo> <mo>.</mo> </mrow> </math>
(2) Cosine distance metric
In order to examine the correlation degree between the pixel positions of the two-amplitude images, the correlation relation on the image position is found out by using a method of an intersection cosine distance method of a histogram.
Assuming that F and Q are histograms of image C and CR image containing w points, the intersection distance l between them is represented by:
<math> <mrow> <mi>l</mi> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>w</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>N</mi> </munderover> <mi>min</mi> <mrow> <mo>(</mo> <msub> <mi>F</mi> <mi>w</mi> </msub> <mo>,</mo> <msub> <mi>Q</mi> <mi>w</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>24</mn> <mo>)</mo> </mrow> </mrow> </math>
the intersection of the histograms refers to the number of pixels that are common to both histograms at each point. Sometimes, this value is also normalized by dividing by the number of all pixels in one of the histograms, so that its value lies in the range of values of [0, 1], then:
<math> <mrow> <mi>l</mi> <mrow> <mo>(</mo> <mi>F</mi> <mo>,</mo> <mi>Q</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>w</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>N</mi> </munderover> <mi>min</mi> <mrow> <mo>(</mo> <msub> <mi>F</mi> <mi>w</mi> </msub> <mo>,</mo> <msub> <mi>Q</mi> <mi>w</mi> </msub> <mo>)</mo> </mrow> <mo>/</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>w</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>N</mi> </munderover> <msub> <mi>Q</mi> <mi>w</mi> </msub> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>25</mn> <mo>)</mo> </mrow> </mrow> </math>
the cosine distance is obtained as follows:
l(F,Q)=FT*Q/(||F||*||Q||) (26)
wherein, F and Q respectively represent the feature vector of the image in the query image and the database, and | x | represents the vector norm. The calculated similarity measure is between 0, 1, the larger the value, the more similar the image.
For combined feature images, the similarity measure is defined as a weighted sum of the individual feature similarity measures. The formula is as follows:
<math> <mrow> <mi>l</mi> <mrow> <mo>(</mo> <mi>F</mi> <mo>,</mo> <mi>Q</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>w</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>m</mi> </munderover> <msub> <mi>u</mi> <mi>w</mi> </msub> <mo>*</mo> <msub> <mi>l</mi> <mi>w</mi> </msub> <mrow> <mo>(</mo> <mi>F</mi> <mo>,</mo> <mi>Q</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>27</mn> <mo>)</mo> </mrow> </mrow> </math>
is represented by m feature combinationsWherein u iswThe weight coefficient representing the w-th feature, which represents the importance of the w-th feature, is generally taken to be each uwIs equal to Sw(F, Q) represents a similarity measure function value of the w-th feature.
5. Performance evaluation of algorithms
The invention adopts the commonly used minimum mean square error MMSE (minimum Means Square error), peak signal-to-noise ratio PSNR and response time t in the denoising performance evaluation to objectively evaluate the denoising performance.
And evaluating the change degree of the denoised image data by MMSE, wherein the smaller the value of MMSE is, the more accurate the denoising effect is. The noise model of the original X-ray detection image is quantum noise, and the mean square error of the noise in the Gaussian noise model obtained by converting the quantum noise is sigma0After the image is denoised by the method of the invention, the information entropy of each point pixel of the new image after denoising can be known, the pixel entropy of the denoised image is compared with the pixel information entropy of each point of the original X-ray scanning image, and the mean square error sigma of the whole is calculated1Then MMSE is min { sigma ═ σ0,σ1And the MMSE reflects the average noise elimination level of each point of the denoised image. In order to illustrate the influence of a larger difference value in an image on a denoising effect, the PSNR is introduced as another objective standard for evaluating the denoising effect of the image and is used for measuring the change condition between a maximum value point and noise in the image, the known detection result shows that an X-ray scanning image is CR, the CR is converted by a noise model to obtain an image C, and the image R is obtained after the noise is removed by the C*Ideally, the desired noise-free image is R, and the PSNR is defined as follows:
<math> <mrow> <mi>PSNR</mi> <mo>=</mo> <mn>10</mn> <mo>&times;</mo> <mi>log</mi> <mrow> <mo>(</mo> <mfrac> <msup> <mn>255</mn> <mn>2</mn> </msup> <mi>MSE</mi> </mfrac> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>28</mn> <mo>)</mo> </mrow> </mrow> </math>
<math> <mrow> <mi>MMSE</mi> <mo>=</mo> <mi>min</mi> <mo>{</mo> <mo>|</mo> <mfrac> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>n</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>N</mi> </munderover> <mrow> <mo>(</mo> <msup> <mrow> <mo>(</mo> <msup> <mi>R</mi> <mi>x</mi> </msup> <mo>)</mo> </mrow> <mi>n</mi> </msup> <mo>-</mo> <msup> <mi>R</mi> <mi>n</mi> </msup> <mo>)</mo> </mrow> </mrow> <mi>N</mi> </mfrac> <mo>|</mo> <mo>}</mo> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>29</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein N is the image size, N is a pixel point in the image, and N belongs to N to represent the number of pixels contained in the image. The PSNR and MMSE indicate performance indexes of the effect of the denoising processing system, and in practice, acceptable PSNR and MMSE thresholds are set according to user requirements.
Response time is also a neglected index in measuring performance indexes of a denoising system, and all modules are used for parallel calculation after blocking, so that the processing time is superior to that of the traditional NL means denoising algorithm, but in consideration of the precision requirement, the position information of pixel points n in an image is described by using x (n) and y (n), and the denoising condition of a specified area can be processed more accurately.
When the traditional non-local average filtering denoising algorithm is applied to process complex images, the calculation amount is large, the processing speed is low, and the problem is more prominent particularly when large images are processed; in addition, the conventional non-local average filtering method may introduce artificial artifacts in the smooth region of the image, the image becomes blurred, and the spatial resolution is affected. The fuzzy bivariate non-local average filtering denoising algorithm provided by the invention blocks the complex image by a blocking mode, and then performs adaptive parameter parallel operation on the sub-blocks, thereby reducing the complexity of the image, saving the calculation time and achieving better denoising performance.

Claims (1)

1. A bivariate non-local average filtering X-ray image denoising method is characterized by comprising the following steps:
1) selection method of fuzzy noise-canceling window
The non-local average filtering algorithm has a premise assumption: the local space where the sampling data is located is linear, namely each sampling point has a similar relation with its adjacent points and is linearly represented by a weight contribution value;
the algorithm fully utilizes the redundant relation among pixels in a low-dimensional space, sets the weight in each neighborhood according to the similarity of gray distribution, namely, the embedded mapping window minimizes irrelevant pixels under the condition that the local part is linear, and reconstructs an original image;
let c (X, y) be the X-ray scanning image function, r (X, y) be the ideal image function, n (X, y) be the noise image function, and X, y be the coordinates of image pixel points in the rectangular coordinate system, then:
c(x,y)=r(x,y)+n(x,y) (1)
now, a template is needed to be found to determine the correlation between each element of c (x, y) and r (x, y), so that n (x, y) is eliminated effectively;
the gray value corresponding to the pixel point x, y in the c (x, y) image is represented by c (i), and then there is
<math> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>I</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>Y</mi> </munderover> <munderover> <mi>&Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>X</mi> </munderover> <mi>c</mi> <mrow> <mo>(</mo> <mi>x</mi> <mo>,</mo> <mi>y</mi> <mo>)</mo> </mrow> <mo>+</mo> <mi>&gamma;</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>2</mn> <mo>)</mo> </mrow> </mrow> </math>
The image denoising method comprises the steps that I, X, Y and c (X, Y) are the size of an image, I is a gray pixel in an image point X and Y, I belongs to (1, 2.. I), X belongs to (1, 2.. X), Y belongs to (1, 2.. Y) c (I) is a gray value of the ith point in an X-ray scanning image, c (X, Y) reflects gray information of points X and Y in the image, and gamma is an image gray correction factor, so that the local contrast of the X-ray scanning image is adjusted by adjusting the gamma value of each point, and the gray distribution of the denoised image is appropriate;
(ii) random noise model conversion
The main reason for the image degradation of the X-ray imaging system is the system random noise, which appears as horizontal or vertical stripes on the X-ray scanning image, the noise generated by the generation of X-rays and the interaction with the substance, the distribution of which is the state discrete, time continuous markov process, which satisfies the poisson random process both in time and space, if the independent increment process Δ c (t), the probability distribution of the increment obeys the poisson distribution, then:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>&ap;</mo> <mfrac> <msup> <mi>&lambda;</mi> <mi>k</mi> </msup> <mrow> <mi>k</mi> <mo>!</mo> </mrow> </mfrac> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>&lambda;</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>3</mn> <mo>)</mo> </mrow> </mrow> </math>
k is the number of times of occurrence of random variable increment delta c (t), K belongs to (1, 2.. K), and when K is larger, the error is calculated according to a Poisson distribution formula, so that the practical application that the error is very complicated is inconvenient, therefore, a Sterling (Stirling) approximate formula is adopted for a noise image, and the Poisson noise is converted into white Gaussian noise;
the stipling approximation formula holds that when k is large, k! Approximated by equation (4):
<math> <mrow> <mi>k</mi> <mo>!</mo> <mo>&ap;</mo> <msqrt> <mn>2</mn> <mi>&pi;k</mi> </msqrt> <msup> <mi>k</mi> <mi>k</mi> </msup> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mi>k</mi> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>4</mn> <mo>)</mo> </mrow> </mrow> </math>
at this time, the noise is converted from poisson distribution to gaussian distribution, and then the X-ray noise distribution expression is:
<math> <mrow> <mi>p</mi> <mrow> <mo>(</mo> <mi>k</mi> <mo>)</mo> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <msqrt> <mn>2</mn> <mi>&pi;h</mi> </msqrt> </mfrac> <msup> <mi>e</mi> <mrow> <mo>[</mo> <mo>-</mo> <mfrac> <msup> <mrow> <mo>(</mo> <mi>h</mi> <mo>-</mo> <mi>k</mi> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mrow> <mn>2</mn> <mi>h</mi> </mrow> </mfrac> <mo>]</mo> </mrow> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>5</mn> <mo>)</mo> </mrow> </mrow> </math>
the original image conforms to a gaussian white noise model, whose mathematical expectation E is given by equation (6):
<math> <mrow> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>=</mo> <mi>E</mi> <msubsup> <mrow> <mo>|</mo> <mo>|</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>r</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> <mo>|</mo> </mrow> <mrow> <mn>2</mn> <mi>a</mi> </mrow> <mn>2</mn> </msubsup> <mo>+</mo> <msup> <mrow> <mn>2</mn> <mi>&sigma;</mi> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein,
Figure FDA0000130219150000025
the method comprises the steps that the Gaussian weighted Euclidean distance of a neighborhood where pixels i and j are located is used, a is larger than 0 and is a standard Gaussian convolution kernel, the noise variance is sigma, and the size of the sigma determines the size of a fuzzy denoising window;
noise level estimation
The method comprises the steps of firstly dividing an image into a plurality of subblocks by using a partitioning method, filtering each subblock by using a parallel filtering method, and finding out the maximum noise level in the subblocks by using a particle swarm optimization algorithm to serve as an overall noise level estimation result;
(iii) fuzzy noise filtering template window
Setting two window sizes, wherein one is a pixel neighborhood window size A multiplied by A, and the other is a window size B multiplied by B of a pixel neighborhood window searching range, namely the neighborhood size of a selected pixel in a region with the size of B multiplied by B is A multiplied by B, executing an Adaptive Non local averaging (ANL-means) algorithm, sliding the B multiplied by B window in the region with the size of A multiplied by A, and determining the contribution weight of the central pixel gray level of the region according to the similarity of the region;
2) bivariate fuzzy adaptive non-local average filtering algorithm
The method uses a particle swarm optimization algorithm to search a weight value which enables the characteristic vector dimension reduction reconstruction error of the X-ray scanning image to be minimum from the optimal parameter of a filter, thereby obtaining an effective denoising method of the X-ray scanning image;
according to the invention, ANL means filtering processing is carried out in an image subblock, an individual of a particle swarm optimization algorithm is constructed according to a related program of a sample point and a near point of the sample point, then the individual of the particle swarm finds out a global optimal speed in an optimization process, a global optimal position is determined, and finally a most relevant near local reconstruction weight matrix is obtained, so that irrelevant redundant information is effectively removed, and effective noise elimination of X-rays is realized;
first, bivariate non-local average filtering
Let c (X, y) be an observation image, i.e., an X-ray inspection image, n be a mean of 0 and a variance of σ2The input image R (x, y) is mapped into the observation space through a Non Local means (NL means) algorithm, wherein (x, y) defines a two-dimensional bounded region, and (x, y) belongs to R2,xi,yiAnd neighborhood point xj,yjCorrelation value NL (c (x)) betweeni,yi) Is determined from equation (6):
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> <mo>=</mo> <mfrac> <mn>1</mn> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> </mrow> </mfrac> <mo>&Integral;</mo> <msup> <mi>e</mi> <mrow> <mo>-</mo> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </mrow> </msup> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>j</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>j</mi> </msub> <mo>)</mo> </mrow> <mi>dxdy</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein the variables are (x, y),
Figure FDA0000130219150000032
is a Gaussian convolution kernel with standard deviation a, h is a filtering parameter, which is mainly determined by the noise standard deviation of the image, D (x)i,yi) For NL means transform coefficients, it is found from the gray values of the relative positions of the coordinates (x, y):
<math> <mrow> <mi>D</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mo>=</mo> <msup> <mrow> <mo>&Integral;</mo> <mi>e</mi> </mrow> <mfrac> <mrow> <mo>(</mo> <msub> <mi>G</mi> <mi>a</mi> </msub> <mo>*</mo> <mrow> <mo>(</mo> <msup> <mrow> <mo>|</mo> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>i</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>i</mi> </msub> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <msub> <mi>x</mi> <mi>t</mi> </msub> <mo>,</mo> <msub> <mi>y</mi> <mi>t</mi> </msub> <mo>)</mo> </mrow> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> </mrow> <mrow> <mo>(</mo> <mn>0</mn> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <msup> <mi>h</mi> <mn>2</mn> </msup> </mfrac> </msup> <msup> <mi>x</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <msup> <mi>y</mi> <mo>&prime;</mo> </msup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mi>di</mi> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>7</mn> <mo>)</mo> </mrow> </mrow> </math>
for a digital X-ray scanning image, which is expressed as C (I) in a discrete domain, a pixel point I belongs to (X, y), C ═ C (I), I belongs to I }, and I is a pixel set in the image, a pixel point NL means algorithm calculates a correlation value NL (C (I)) between the pixel point I and a neighborhood according to a form that a most relevant neighbor local reconstruction weight matrix is converted into a formula (8) and is expressed by a relevant neighbor local reconstruction weight w (I, j) and a gray value C (j) of a neighboring point thereof:
<math> <mrow> <mi>NL</mi> <mrow> <mo>(</mo> <mi>c</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mo>=</mo> <munder> <mi>&Sigma;</mi> <mrow> <mi>s</mi> <mo>&Element;</mo> <mi>I</mi> </mrow> </munder> <mi>w</mi> <mrow> <mo>(</mo> <mi>i</mi> <mo>,</mo> <mi>j</mi> <mo>)</mo> </mrow> <mi>c</mi> <mrow> <mo>(</mo> <mi>j</mi> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>8</mn> <mo>)</mo> </mrow> </mrow> </math>
wherein, in the formula (2), the point (x)i,yi) The gray value of (d) is c (i), and the change correction coefficient gamma is converted by c (x, y), and the adjacent point (x, y) is adjacent to the gray valuej,yj) I is the total number of pixels of the X-ray detection image, X is the width value of c (X, Y), and Y is the height value of c (X, Y);
wherein, I { (1, 1), (1, 2) · I.. I } { (1, 2) }i,yi) (X, Y) }, where the associated neighbor local reconstruction weight w (i, j) is expressed as:
w ( i , j ) = 1 Z ( i ) e | | c ( NL ( x i , , y i ) c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 9 )
Z ( i ) = e - | | c ( NL ( x i , , y i ) - c ( NL ( x s , y s ) ) | | 2 a 2 / h 2 - - - ( 10 )
wherein, the related near neighbor local reconstruction weight w (i, s) between the pixel point i and the near point j is constructed in the relation of the vertical type (9), Z (i) is a weight weighting transformation coefficient,
Figure FDA0000130219150000044
the gray level-based Gaussian weighted Euclidean distance of two neighborhoods where points i and j are located, a weight value w (i, s) is mainly determined by parameters a and h, a is the standard deviation of a standard Gaussian convolution kernel, h is a filtering parameter of a bivariate NL means, if a is larger, the weight value is smaller, and the pixel x is indicatedi,yiThe farther away from the central pixel, the size of a is determined by the size of the window of the selected pixel neighborhood, a x a; with the increase of the filtering parameter h, the artificial artifact is gradually weakened, but the spatial resolution is also reduced, and the filtering parameter h is determined by the standard deviation of the noise; (ii) particle swarm optimization
Setting the obtained local optimal parameter in the p-th sub-module as apAnd hpFor local optimal solution vectors, each particle can estimate an adaptive value of the position of the particle through a certain rule by using a particle swarm optimization algorithm; each particle can remember its own currently found local best position zpNamely, it is a p h p , Local position of the particle is zpq,zp∈zpq={zp1,zp2....,zpq..zpQ},zpqFor the position of the particles in the local population, Q is the number of particles contained in the population, and in addition, the best position found by all individuals in the population, called globally optimal z, is kept in mindgI.e. by a h , Selecting the best of the population a h Solving the vector;
the particle swarm optimization algorithm indicates that all particles have a speed to determine their direction and distance, called local optimal speed, vpRepresents; the particles search in the solution space following the current optimal particle, and in each iteration, the particles update the position and velocity according to the following equation:
zp+1=zp+vp+1 (11)
vp+1=w1vp+g1(spq-zp)+g2(sgq-zp) (12)
where Q is the dimension of the target search space, P represents the number of individuals in the population, and s is calculatedpCurrent position adaptation value, vpIs the flight velocity, s, of the particle pp∈(sp1,sp2,spq,...spQ) For the optimum position, s, of the particles searched so farpqThe position through which the particles pass in the population, spIs a velocity vpThe optimal position searched in time; sg=(sg1+sg1+...sgq+...sgQ) Optimum position sum, s, searched for the entire particle swarm so fargqBest position currently recorded for the particle swarm, g1And g2For a self-learning factor, w1Is the inertial weight;
third, the evaluation function of the degree of suitability
The fitness evaluation function is a mark for measuring the quality of an individual and has the function of finding out the integral optimal parameters a and h in the block sub-graph module; according to the uncertainty of the industrial X-ray scanning image noise model as the particularity of the individual model, the adopted fitness evaluation function is as follows:
<math> <mrow> <mi>f</mi> <mrow> <mo>(</mo> <mi>u</mi> <mo>)</mo> </mrow> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>p</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>P</mi> </munderover> <msup> <mrow> <mo>|</mo> <mo>|</mo> <msub> <mi>v</mi> <mi>p</mi> </msub> <mo>-</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>d</mi> <mo>=</mo> <mn>1</mn> </mrow> <mi>D</mi> </munderover> <msub> <mi>u</mi> <mi>pq</mi> </msub> <msup> <msub> <mi>z</mi> <mi>pq</mi> </msub> <mo>&prime;</mo> </msup> <mo>|</mo> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>13</mn> <mo>)</mo> </mrow> </mrow> </math>
in the formula upqExpressing the qth individual of the p generation in the particle swarm, and D expressing the number of individuals in the swarm, wherein the optimization method comprises the following specific steps:
firstly, initializing a population: selecting a threshold value epsilon and a maximum number of iterations umaxThe initial iteration number u is 0 and the particle position range is zmin~zmaxParticle velocity range vmax~vmin
Measuring individuals in the population: measuring the adaptation value u for each particlepqSelecting the optimal adaptation value of the group at this time to compare with the optimal adaptation value of the historical group to obtain the current optimal adaptation value u of the grouppAnd u isp∈{upq|up1,up2,...upq,...upQAnd access the value z of the corresponding positiong∈{zpq|zp1,zp2,...zpq,...zpQ}; each particle obtains the current optimal adaptive value u by comparing the sizes of the historical adaptive valuesg∈{ugq|ug1,ug2,...ugq,...ugQAnd access the corresponding position zg∈{zgq|zg1,zg2,...zgq,...zgQ};
③ evaluation of population UpAnd keeping the optimal solution;
particle swarm operation: if U is presentpIf the value is more than epsilon, executing in sequence, otherwise, ending the circulation;
v is updated according to the rulep,zp
Sixthly, changing evolution algebra: adding 1 to the evolution algebra, e.g. the maximum evolution algebra P has not yet been metmaxThe algorithm goes to step two of this section to continue.
CN201210007379.XA 2012-01-11 2012-01-11 Bivariate nonlocal average filtering de-noising method for X-ray image Active CN102609904B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210007379.XA CN102609904B (en) 2012-01-11 2012-01-11 Bivariate nonlocal average filtering de-noising method for X-ray image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210007379.XA CN102609904B (en) 2012-01-11 2012-01-11 Bivariate nonlocal average filtering de-noising method for X-ray image

Publications (2)

Publication Number Publication Date
CN102609904A true CN102609904A (en) 2012-07-25
CN102609904B CN102609904B (en) 2014-04-30

Family

ID=46527250

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210007379.XA Active CN102609904B (en) 2012-01-11 2012-01-11 Bivariate nonlocal average filtering de-noising method for X-ray image

Country Status (1)

Country Link
CN (1) CN102609904B (en)

Cited By (30)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103500441A (en) * 2013-09-29 2014-01-08 华南理工大学 Noise modeling and de-noising method for micro-focus X-ray image
CN104077746A (en) * 2013-03-29 2014-10-01 富士通株式会社 Gray level image processing method and device
CN104346787A (en) * 2014-11-25 2015-02-11 成都卫士通信息产业股份有限公司 Non-local mean image denoising algorithm
CN104657958A (en) * 2015-03-18 2015-05-27 西安科技大学 Infrared image stripe noise elimination method
CN105046654A (en) * 2015-06-23 2015-11-11 华中科技大学 Electrocardiosignal adaptive nonlocal means filtering method based on particle swarm optimization
CN105049846A (en) * 2015-08-14 2015-11-11 广东中星电子有限公司 Image and video encoding and decoding methods and equipment
CN105205828A (en) * 2015-10-20 2015-12-30 江南大学 Warp knitted fabric flaw detection method based on optimal Gabor filter
CN105335947A (en) * 2014-05-26 2016-02-17 富士通株式会社 Image de-noising method and image de-noising apparatus
CN107067419A (en) * 2017-04-16 2017-08-18 江西理工大学 The method for registering images of application enhancements gravitation search
CN107492079A (en) * 2017-08-28 2017-12-19 维沃移动通信有限公司 A kind of image mill skin method and mobile terminal
CN108022220A (en) * 2017-12-06 2018-05-11 西南科技大学 A kind of ultrasound pattern speckle noise minimizing technology
CN108389162A (en) * 2018-01-09 2018-08-10 浙江大学 A kind of image border holding filtering method based on adaptive neighborhood shape
CN108604302A (en) * 2016-02-01 2018-09-28 德克萨斯仪器股份有限公司 Adaptive bilateral (BL) for computer vision is filtered
CN108765350A (en) * 2018-05-31 2018-11-06 北京空间机电研究所 One kind is towards aerospace optical remote sensing image quantization filtering method
CN108830594A (en) * 2018-06-22 2018-11-16 李秀全 Multi-mode electronic fare payment system
CN109583309A (en) * 2018-10-31 2019-04-05 浙江清华柔性电子技术研究院 Signal de-noising method, apparatus, computer equipment and storage medium
CN109767435A (en) * 2019-01-07 2019-05-17 哈尔滨工程大学 It is a kind of based on the alzheimer's disease brain network characterization extracting method for continuing same conditioning technology
CN109903254A (en) * 2019-03-04 2019-06-18 中国科学院长春光学精密机械与物理研究所 Based on the improved bilateral filtering method of Poisson's kernel
CN110097518A (en) * 2019-04-28 2019-08-06 东软医疗系统股份有限公司 Image de-noising method, device and terminal device
CN110514567A (en) * 2019-08-28 2019-11-29 哈尔滨工业大学 Gas source searching method based on comentropy
CN111012370A (en) * 2019-12-25 2020-04-17 四川大学华西医院 AI-based X-ray imaging analysis method and device and readable storage medium
CN111063423A (en) * 2019-12-16 2020-04-24 哈尔滨工程大学 Method for extracting specific structure of brain network of Alzheimer disease and mild cognitive impairment
CN111340741A (en) * 2020-01-03 2020-06-26 中北大学 Particle swarm optimization gray level image enhancement method based on quaternion and L1 norm
CN111507919A (en) * 2020-04-16 2020-08-07 北京深测科技有限公司 Denoising processing method for three-dimensional point cloud data
CN112767536A (en) * 2021-01-05 2021-05-07 中国科学院上海微系统与信息技术研究所 Three-dimensional reconstruction method, device and equipment of object and storage medium
CN113724158A (en) * 2021-08-13 2021-11-30 浙江大学 Noise reduction method for dynamic contrast enhanced magnetic resonance imaging
CN117665788A (en) * 2024-02-01 2024-03-08 湖南科技大学 Noise processing method based on microwave measurement data
CN117765107A (en) * 2023-11-20 2024-03-26 河北港口集团有限公司秦皇岛中西医结合医院 Imaging quality optimization method and system for CT scanning of coronary artery disease
CN117893527A (en) * 2024-03-07 2024-04-16 江苏亿都智能特种装备有限公司 New energy storage box surface defect detection method
US12020122B1 (en) 2022-12-15 2024-06-25 International Business Machines Corporation Mitigating errors in measurements from a quantum system by defining regions of trust

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101102399A (en) * 2007-07-26 2008-01-09 上海交通大学 Real time digital image processing and enhancing method with noise removal function
CN102184533A (en) * 2011-06-10 2011-09-14 西安电子科技大学 Non-local-restriction-based total variation image deblurring method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101102399A (en) * 2007-07-26 2008-01-09 上海交通大学 Real time digital image processing and enhancing method with noise removal function
CN102184533A (en) * 2011-06-10 2011-09-14 西安电子科技大学 Non-local-restriction-based total variation image deblurring method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
LI JIN: "Industrial X-Ray Image Enhancement Algorithm based on Adaptive Histogram and Wavelet", 《2011 6TH INTERNATIONAL FORUM ON STRATEGIC TECHNOLOGY》 *
侯润石: "用于焊缝检测的X射线实时图像序列时空域滤波", 《清华大学学报(自然科学版)》 *

Cited By (50)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104077746A (en) * 2013-03-29 2014-10-01 富士通株式会社 Gray level image processing method and device
CN104077746B (en) * 2013-03-29 2017-03-01 富士通株式会社 Gray level image processing method and its device
CN103500441A (en) * 2013-09-29 2014-01-08 华南理工大学 Noise modeling and de-noising method for micro-focus X-ray image
CN105335947A (en) * 2014-05-26 2016-02-17 富士通株式会社 Image de-noising method and image de-noising apparatus
CN105335947B (en) * 2014-05-26 2019-03-01 富士通株式会社 Image de-noising method and image denoising device
CN104346787A (en) * 2014-11-25 2015-02-11 成都卫士通信息产业股份有限公司 Non-local mean image denoising algorithm
CN104657958A (en) * 2015-03-18 2015-05-27 西安科技大学 Infrared image stripe noise elimination method
CN104657958B (en) * 2015-03-18 2017-09-29 西安科技大学 A kind of infrared image fringes noise removing method
CN105046654B (en) * 2015-06-23 2017-11-10 华中科技大学 A kind of adaptive non-local mean noise-reduction method of electrocardiosignal based on particle group optimizing
CN105046654A (en) * 2015-06-23 2015-11-11 华中科技大学 Electrocardiosignal adaptive nonlocal means filtering method based on particle swarm optimization
CN105049846A (en) * 2015-08-14 2015-11-11 广东中星电子有限公司 Image and video encoding and decoding methods and equipment
CN105205828A (en) * 2015-10-20 2015-12-30 江南大学 Warp knitted fabric flaw detection method based on optimal Gabor filter
CN105205828B (en) * 2015-10-20 2019-03-19 江南大学 Knitted fabric flaw detection method based on Optimal Gabor Filters
CN108604302A (en) * 2016-02-01 2018-09-28 德克萨斯仪器股份有限公司 Adaptive bilateral (BL) for computer vision is filtered
CN108604302B (en) * 2016-02-01 2022-06-28 德克萨斯仪器股份有限公司 Adaptive Bilateral (BL) filtering for computer vision
CN107067419A (en) * 2017-04-16 2017-08-18 江西理工大学 The method for registering images of application enhancements gravitation search
CN107492079A (en) * 2017-08-28 2017-12-19 维沃移动通信有限公司 A kind of image mill skin method and mobile terminal
CN108022220A (en) * 2017-12-06 2018-05-11 西南科技大学 A kind of ultrasound pattern speckle noise minimizing technology
CN108022220B (en) * 2017-12-06 2021-04-20 西南科技大学 Ultrasonic image speckle noise removing method
CN108389162A (en) * 2018-01-09 2018-08-10 浙江大学 A kind of image border holding filtering method based on adaptive neighborhood shape
CN108765350A (en) * 2018-05-31 2018-11-06 北京空间机电研究所 One kind is towards aerospace optical remote sensing image quantization filtering method
CN108765350B (en) * 2018-05-31 2022-03-04 北京空间机电研究所 Aerospace-oriented optical remote sensing image quantization filtering method
CN108830594A (en) * 2018-06-22 2018-11-16 李秀全 Multi-mode electronic fare payment system
CN108830594B (en) * 2018-06-22 2019-05-07 山东高速信联支付有限公司 Multi-mode electronic fare payment system
CN109583309A (en) * 2018-10-31 2019-04-05 浙江清华柔性电子技术研究院 Signal de-noising method, apparatus, computer equipment and storage medium
CN109583309B (en) * 2018-10-31 2021-05-04 浙江清华柔性电子技术研究院 Signal noise reduction method and device, computer equipment and storage medium
CN109767435B (en) * 2019-01-07 2022-04-19 哈尔滨工程大学 Alzheimer brain network feature extraction method based on continuous coherent technology
CN109767435A (en) * 2019-01-07 2019-05-17 哈尔滨工程大学 It is a kind of based on the alzheimer's disease brain network characterization extracting method for continuing same conditioning technology
CN109903254B (en) * 2019-03-04 2020-08-18 中国科学院长春光学精密机械与物理研究所 Improved bilateral filtering method based on Poisson nucleus
CN109903254A (en) * 2019-03-04 2019-06-18 中国科学院长春光学精密机械与物理研究所 Based on the improved bilateral filtering method of Poisson's kernel
CN110097518A (en) * 2019-04-28 2019-08-06 东软医疗系统股份有限公司 Image de-noising method, device and terminal device
CN110097518B (en) * 2019-04-28 2022-12-27 东软医疗系统股份有限公司 Image denoising method and device and terminal equipment
CN110514567A (en) * 2019-08-28 2019-11-29 哈尔滨工业大学 Gas source searching method based on comentropy
CN110514567B (en) * 2019-08-28 2021-10-29 哈尔滨工业大学 Gas source searching method based on information entropy
CN111063423B (en) * 2019-12-16 2022-05-20 哈尔滨工程大学 Method for extracting specific structure of brain network of Alzheimer disease and mild cognitive impairment
CN111063423A (en) * 2019-12-16 2020-04-24 哈尔滨工程大学 Method for extracting specific structure of brain network of Alzheimer disease and mild cognitive impairment
CN111012370A (en) * 2019-12-25 2020-04-17 四川大学华西医院 AI-based X-ray imaging analysis method and device and readable storage medium
CN111340741B (en) * 2020-01-03 2023-05-09 中北大学 Particle swarm optimization gray image enhancement method based on quaternion and L1 norm
CN111340741A (en) * 2020-01-03 2020-06-26 中北大学 Particle swarm optimization gray level image enhancement method based on quaternion and L1 norm
CN111507919A (en) * 2020-04-16 2020-08-07 北京深测科技有限公司 Denoising processing method for three-dimensional point cloud data
CN111507919B (en) * 2020-04-16 2023-07-14 北京深测科技有限公司 Denoising processing method for three-dimensional point cloud data
CN112767536A (en) * 2021-01-05 2021-05-07 中国科学院上海微系统与信息技术研究所 Three-dimensional reconstruction method, device and equipment of object and storage medium
CN113724158A (en) * 2021-08-13 2021-11-30 浙江大学 Noise reduction method for dynamic contrast enhanced magnetic resonance imaging
CN113724158B (en) * 2021-08-13 2024-01-02 浙江大学 Noise reduction method for dynamic contrast enhanced magnetic resonance imaging
US12020122B1 (en) 2022-12-15 2024-06-25 International Business Machines Corporation Mitigating errors in measurements from a quantum system by defining regions of trust
CN117765107A (en) * 2023-11-20 2024-03-26 河北港口集团有限公司秦皇岛中西医结合医院 Imaging quality optimization method and system for CT scanning of coronary artery disease
CN117665788A (en) * 2024-02-01 2024-03-08 湖南科技大学 Noise processing method based on microwave measurement data
CN117665788B (en) * 2024-02-01 2024-04-05 湖南科技大学 Noise processing method based on microwave measurement data
CN117893527A (en) * 2024-03-07 2024-04-16 江苏亿都智能特种装备有限公司 New energy storage box surface defect detection method
CN117893527B (en) * 2024-03-07 2024-05-28 江苏亿都智能特种装备有限公司 New energy storage box surface defect detection method

Also Published As

Publication number Publication date
CN102609904B (en) 2014-04-30

Similar Documents

Publication Publication Date Title
CN102609904A (en) Bivariate nonlocal average filtering de-noising method for X-ray image
Mafi et al. A comprehensive survey on impulse and Gaussian denoising filters for digital images
CN111047663B (en) Method for reconstructing electrical tomography artifact inhibition image
CN103236046B (en) Based on the fractional order adaptive coherent spot filtering method of image aspects fuzzy membership
CN106991661B (en) Non-local mean denoising method fusing KL (karhunen-Loeve) transformation and grey correlation degree
CN109191418B (en) Remote sensing image change detection method based on feature learning of contraction self-encoder
CN111783583B (en) SAR image speckle suppression method based on non-local mean algorithm
CN106157330B (en) Visual tracking method based on target joint appearance model
CN109859242B (en) Target tracking method for prediction adaptive learning
CN112418149A (en) Abnormal behavior detection method based on deep convolutional neural network
CN114820401A (en) Method for enhancing marine backlight infrared image by combining histogram transformation and edge information
CN115409872A (en) Underwater camera image optimization method
CN113506212B (en) Improved hyperspectral image super-resolution reconstruction method based on POCS
Liu et al. Image super-resolution based on adaptive joint distribution modeling
Garcin et al. Wavelet shrinkage of a noisy dynamical system with non-linear noise impact
CN115601301B (en) Fish phenotype characteristic measurement method, system, electronic equipment and storage medium
CN100583153C (en) Posteriori probability image tracing method based on background suppression
Ferzo et al. Image Denoising Techniques Using Unsupervised Machine Learning and Deep Learning Algorithms: A Review
CN114926524B (en) Method for improving measuring accuracy of effective shielding area of infrared smoke screen
CN112686814B (en) Affine low-rank based image denoising method
CN112927169A (en) Remote sensing image denoising method based on wavelet transformation and improved weighted nuclear norm minimization
CN111091569B (en) Industrial CT image segmentation method with self-adaptive local parameters
CN114926408B (en) Method for measuring infrared shielding effect of smoke screen
CN115067920B (en) Electrical impedance tomography method with high resolution and capable of enhancing edge characteristics of reconstructed image
CN116228915B (en) Image reconstruction method, system and equipment based on region judgment

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant