The content of the invention
The problem that the present invention is solved is to provide a kind of Atmospheric Degraded Image based on multiscale analysis with estimation of Depth to be strengthened
Method, can realize degradation compensation and obtain enhanced image, imaging effect is good to image direct estimation.
To solve the above problems, embodiments provide a kind of air based on multiscale analysis with estimation of Depth and move back
Change image enchancing method, including:Obtain the air light value of image;Obtain rough transmission rate matrix in image;Using linear extendible
Method optimize the rough transmission rate matrix, obtain fine transmission rate matrix;Based on the air light value and fine transmissivity
Matrix, original observation figure is optimized for tentatively going back artwork;Multiple dimensioned framework based on supreme down-sampling is to tentatively also artwork is realized
The enhancing of image detail.
Optionally, the method for obtaining the air light value of image includes:By analyzing the edge weights letter in original observation figure
Breath, builds matrix of edge, finds the pixel of maximum intensity from the edge and near zone more than threshold value, and the value of the pixel is made
To select the decision sex factor of air light value.
Optionally, for the matrix of edge of any position isWherein μ is defined as follows It is the local variance of blurred picture,It is then the local variance of noise;η (i, j) is defined asThe local variance of noise byTo estimate, andIt is the sharpening result of fuzzy graphLocal variance, and s is the flat of a N × N
Sliding operator.
Optionally, in the non-sky areas of original observation figure, rough transmission rate matrix is
In the sky areas of original observation figure, rough transmission rate matrix is
Optionally, the method for optimizing the rough transmission rate matrix includes:Optimize formula T using linear extendiblet=Ag+B,
Successively rough transmission rate matrix is optimized by the way of local window, TtFor fine transmission rate matrix, g is original observation
Figure, for n-th local window wn, have P is window wnCertain interior
Individual pixel, NwFor pixel quantity, μnWith σnFor the average and variance of pixel in window, ε is the constant for preventing morbid state,It is T in window
Average in mouthful.
Also include, to parameter AnWith BnAsk for averagely, finely transmiting rate matrix
Wherein NpiIt is the quantity of all windows comprising pixel p, pi
Refer to all windows comprising pixel p.
Also include, it is described tentatively to go back artworkG is original observation figure, and A is air light value, TtFor
Fine transmission rate matrix, T0For constant.
Also include, realize that based on the multiple dimensioned framework of supreme down-sampling the enhanced concrete steps of image detail include:It is flat
It is sliding tentatively to go back artwork;Based on the different degrees of many details scalogram pictures of smooth structure;After with multi-resolution decomposition image, to difference
Subgraph on yardstick realizes image enhaucament with different weights.
Compared with prior art, the technical program has advantages below:
The inventive method is directed to Atmospheric Degraded Image, and the rough transmission rate matrix of construction, with reference to filtering technique is pointed to, is realized saturating
The thinning and optimizing and fine estimating depth information of rate matrix are penetrated, and jointing edge matrix analysis obtains air light value, according to degeneration
Construction of A Model realizes the recovery of Atmospheric Degraded Image;And then strengthened using realization under the multiple dimensioned framework of supreme down-sampling.At this
In inventive method, as long as width input observed image, you can rapid acquisition preferably strengthen result.The inventive method can be applicable to
Remotely sensed image, traffic monitoring imaging etc., quickly realize the enhancing of Atmospheric Degraded Image.
Specific embodiment
Below in conjunction with the accompanying drawings, by specific embodiment, clear, complete description is carried out to technical scheme.
Fig. 1 is refer to, is that the Atmospheric Degraded Image based on multiscale analysis with estimation of Depth of the embodiment of the present invention strengthens
Method, including:
Step S101, obtains the air light value of image;
Step S102, obtains rough transmission rate matrix in image;
Step S103, optimizes the rough transmission rate matrix using the method for linear extendible, obtains fine transmission rate matrix;
Original observation figure, based on the air light value and fine transmission rate matrix, is optimized for preliminary reduction by step S104
Figure;
Step S105, the multiple dimensioned framework based on supreme down-sampling realize the enhancing of image detail to preliminary also artwork.
Specifically, execution step S101, obtains the air light value of image.
The original observed image g of setting air, needs the preliminary also artwork for obtaining to be f.Due to image atmospheric degradation model
For g (i, j)=f (i, j) e-βd(i,j)+A(1-e-βd(i,j)), A is air light value(The intensity of ambient light), β dissipating for atmospheric particles
Coefficient is penetrated, d (i, j) is the scenery depth of pixel (i, j) corresponding position.E generally in above-mentioned formula-βd(i,j)It is referred to as transmissivity T,
Then the transmissivity at (i, j) place can be represented with T (i, j).
In the prior art, the intensity level of most bright spot in image is considered as air light value A often.Due to practical application field
The complexity of scenery in conjunction, the maximum pixel of brightness are probably such as white building of some scenery etc., therefore in this case most
Bright values may not elect air light value as.
The present invention builds matrix of edge, from the side more than threshold value by analyzing the edge weights information in original observation figure g
Edge and near zone find the pixel of maximum intensity, and by the decision sex factor of the value of the pixel alternatively air light value A.
The value of matrix of edge M is determined by the signal and noise of local.M is calculated in local window N × N, for appointing
Value M (x, y) at meaning position has
μ values are used for the scope of the numerical value for determining M, and μ is defined as follows
Above formula It is the local variance of blurred picture,It is then the office of noise
Portion's variance.Max_n (A) represents n-th maximum in A, be employed herein front 10 maximums averagely replacing individually most
Big value is overcoming randomness.
η (i, j) is defined as
The local variance of noise byTo estimate, andIt is the sharpening result of fuzzy graphOffice
Portion's variance, and s is the smoothing operator of a N × N,
Analyze as described above, and M (x, y) ∈ (0,1).
After to sum up obtaining edge weights matrix, for M>th(Threshold value)Region triple channel launch maximum searching,
Front 5 maximums it is average as air light value, obtain A, contain corresponding to R(red), G(Green), B(blue)Three
Value.
Execution step S102, obtains rough transmission rate matrix in image.
In embodiments of the present invention, transmissivity is estimated using dark channel prior.
In the regional area of most non-skies, certain some pixel always has at least one Color Channel with very low
Value.Then, it is represented by with mathematic(al) representation:
Wherein p represents certain pixel, and Ω represents the neighborhood centered on p, pmRepresent the r or g or b passages in color.
According to dark channel prior, for non-sky areas in original observation figure, fdarkIntensity always very low and convergence
In 0, that is, there is fdark(i,j)→0.With reference to atmospheric degradation model formation, the solution mode of transmissivity T can be obtained:
And as dark channel prior cannot process the related region of sky, however, the imaging to sky has but been also tended to greatly
The shadow that gas is degenerated.Therefore, sky areas are met simultaneously in order that solving, introduce a self adaptation constant k (0<K≤1), make
Obtain the mist that result of calculation can targetedly retain a part of remote scenery --- overcome the impact of sky areas:
Then rough transmission rate matrix is obtained, while according to T (i, j)=e-βd(i,j)Formula can learn depth from side
The estimation of information.
Execution step S103, optimizes the rough transmission rate matrix using the method for linear extendible, obtains fine transmissivity
Matrix.
As the rough transmission rate matrix obtained in step S102 is relative coarseness, side of the present invention using linear extendible
Method optimizes the matrix so that air restores more effectively fruit.Assume that the transmission rate matrix that optimization is refined is Tt, then thinning process can
Sketch and be:
Tt=Ag+B
Wherein A and B is figure parameters.To ensure optimization quality, the present invention is optimized successively using local window w(Window is big
Little M × M).For n-th window wn, have
Above in formula, p is window wnCertain interior pixel (acute pyogenic infection of finger tip wnInterior any pixel), NwFor pixel quantity, μnWith
σnFor the average and variance of pixel in window, ε is the constant for preventing morbid state,It is averages of the T in window.For certain pixel
P, is included in many window w, in different windows, its parameter AnWith BnIt is different, needs are asked for averagely, then pixel p
The refinement transmissivity at place is:
In above formula, NpiIt is all windows comprising p
Quantity, pi (pi=1,2 ..., Npi) refer to all windows comprising p.
Fine transmission rate matrix T can then be obtainedt, realize fine estimation of Depth.
Execution step S104, based on the air light value and fine transmission rate matrix, original observation figure is optimized for tentatively
Also artwork.
According to image atmospheric degradation model g (i, j)=f (i, j) e-βd(i,j)+A(1-e-βd(i,j)), can simply obtain recovery
Model is:
To prevent ill appearance, constant T is introduced0, tentatively also artwork f is rewritable is:
Wherein g is original observation figure, and A is air light value, TtFor fine transmission rate matrix, T0For constant.
Execution step S105, the multiple dimensioned framework based on supreme down-sampling realize the increasing of image detail to preliminary also artwork
By force.
Compared to primary radiation, the contrast of Atmospheric Degraded Image declines a lot, and loss in detail is more serious, needs
Strengthen and realize the compensation of details.The present invention realizes strengthening using multiple dimensioned framework.General multiple dimensioned construction can be involved
The problem of upper down-sampling, is easily lost the information of signal in sampling process.Here, build nothing using exponential smoothing to adopt up and down
The multiple dimensioned framework of sample, by the relative adjustment of in front and back's parameter, realizes the enhancing of image detail.
In the present embodiment, Fig. 2 is refer to, the enhanced of image detail is realized based on the multiple dimensioned framework of supreme down-sampling
Concrete steps include:
Step S201, smooths;
Step S202, based on the different degrees of many details scalogram pictures of smooth structure;
Step S203, with multi-resolution decomposition image after, to the subgraph on different scale with different weights, realize figure
Image intensifying.
Specifically, first tentatively also artwork is smoothed.In order to pass through to control the number of image non-zero gradient, realize
Smoothed image retains the purpose at edge, the thinking of gradient minimisation is applied to image smoothing, the smoothing operator S in the present embodiment
Structure on close to I, can smoothed image as far as possible except the edge of those high-contrasts.The solving equation design of S is as follows:
Wherein C (S)=# p | ▽ Sp≠ 0 }, andλ is the Regularization factor.Final above formula is simple
It is written as:S=L (I, λ).When λ increases, the S of output becomes smoother, and its typical span is [0.001,0.1], thus adjusts
Section λ, can obtain the image of different smoothness.
For artwork f is tentatively gone back, using S=L (f, λ), tentatively also artwork can be smoothed to some extent, after
And build many details scalogram pictures.Assume that this is decomposed into (n+1) level level, including 1 basal layer SnWith n levels of detail (di~
dn), referred to as subgraph.The smoothed image of i-stage yardstick is as follows:
Si=L (f, λi)
λiRepresent the regularization parameter of i level scale levels, and λi> λi-1。SnIt is considered as basal layer, levels of detail is determined
Justice is:
di=Si-1-Si
Here S0=f.Original image is exactly resolved into basal layer and levels of detail by the multi-resolution decomposition:
Image on down-sampling is not related to based on smooth many details Scale Decompositions due to this, therefore final result is not received
It is limited to bandwidth.
After with multi-resolution decomposition image, to the subgraph on different scale with different weights, the rule of synthesis is such as
Under:
U=α1d1+α2d2+...+αndn+αn+1Sn
U is the result of final synthesis, αk(k=1,2 ... n+1) is the weight of different scale images.Using appropriate αk, can
The proportion of different level of detail images is adjusted, final composograph effect can be caused more preferably, realization strengthens and prominent details.
Generally, n very littles, n<5 is enough.One big α1The details of final image will be strengthened.One big αnResult will be caused
More smooth.The effect of remaining parameter obeys following rule:K is the closer to 1, then a big αkAbility to strengthening details is big
In smooth ability, on the contrary it is then contrary.αkGenerally between [0,1].
Enhancing result U of the original observed image g of air is obtained finally.
Refer to Fig. 3 and Fig. 4, Fig. 3 is original observation figure, and Fig. 4 is through Atmospheric Degraded Image Enhancement Method process
Clear figure afterwards, can clearly see the processing variation of image from two figures, and effect of optimization is obvious.
Although the present invention is disclosed as above with preferred embodiment, which is not for limiting the present invention, any this area
Technical staff without departing from the spirit and scope of the present invention, may be by the methods and techniques content of the disclosure above to this
Bright technical scheme makes possible variation and modification, therefore, every content without departing from technical solution of the present invention, according to the present invention
Technical spirit any simple modification, equivalent variations and modification that above example is made, belong to technical solution of the present invention
Protection domain.