A kind of image interfusion method based on guiding filteringTechnical field
The invention belongs to technical field of image processing, be specifically related to a kind of image interfusion method based on guiding filtering.
Background technology
In view of visible images resolution is higher, the detailed information such as edge, texture is abundanter, but is easily subject to the impact of the external environments such as weather; Infrared image adaptive faculty is comparatively strong, can penetrate general smog, can continuous firing round the clock, but gradation of image is determined by temperature, and details is less, and the sense of reality is strong, therefore both is mutually merged and is supplemented, can reach good visual effect.At present, relevant Image Fusion has following two kinds: 1. pixel method of weighted mean: interested image-region is composed larger weights to obtain advantage display.The advantage of the method is that computation complexity is low, is easy to real-time process, and shortcoming is that weighted criterion is difficult to determine, causes syncretizing effect otherness very large.2. multi-Resolution Image Fusion method: by picture breakdown on different frequency bands, then merges each frequency range data according to certain fusion rule, finally the reconstruct of each frequency range is obtained fused image.These class methods typically have: laplacian pyramid method, Wavelet Transform etc.Advantage is to select different fusion rules according to image different frequency range characteristic, specific aim is stronger, and shortcoming lacks relevance between different frequency range pixel, causes merging reconstructed image too " stiff ", visual effect is not good, and computation complexity is also higher in addition.
Summary of the invention
The invention provides a kind of image interfusion method based on guiding filtering, be intended to solve existing visible ray and infrared image fusion method computation complexity is high, merge the not good problem of visual effect.
Image interfusion method of the present invention comprises the steps:
1) to original infrared image Iicarry out maximal value filtering, filter resultcan be expressed as:
Wherein, Ωrx () represents that centre coordinate is x, radius is the image-region of R;
2) guiding filtering algorithm pair is adopteddo further filtering process, output image
Wherein, GuidedFilter () represents guiding filtering algorithm, and r represents filter radius, and ε represents regularization parameter;
3) by imagedirectly be superimposed upon primary visible light image Ivon, obtain image If:
4) to image Ifcarry out Gamma correction, obtain final fused images I 'f:
Wherein, γ represents correction coefficient, and p represents the figure place of view data.
Described guiding filtering algorithm comprises the steps:
1) to original infrared image Iiandcarry out mean filter, obtain averageand try to achieve original infrared image Iiautocorrelation valueand and imagecross correlation valuenamely
2) according to averageautocorrelation valuewith cross correlation valueand averagetry to achieve varianceand covariancenamely
3) then according to step 2) to result of calculation carry out following computing, finally obtain merging rear output imagemeana=fmean(a),meanb=fmean(b),
The invention has the beneficial effects as follows: the present invention fully takes into account visible images and infrared image advantage separately, namely visible images details is enriched, and infrared image can to the highlighted display of some interested targets.All retain visible light part when doing image co-registration, infrared part then instruction filtering extracts highlight information for this reason.Merge owing to the present invention is based on Pixel-level, and just subregion improves grey level, can't occur the phenomenon of syncretizing effect " not nature ", algorithm computation complexity is lower in addition, is easy to real-time process.
Accompanying drawing explanation
Fig. 1 is the fusion method FB(flow block) of the present embodiment;
Fig. 2 is the design sketch of the present embodiment, and wherein, (a) figure is primary visible light image, and (b) figure is original infrared image, and (c) figure is result after merging.
Embodiment
Below in conjunction with accompanying drawing, technical scheme of the present invention is described in further detail.
The image interfusion method based on guiding filtering in the present embodiment, first carries out maximal value filtering acquisition highlight information wherein to infrared image; Then use original infrared image to do guiding filtering (GuidedFilter) process as guide image (GuidanceImage) to highlighted part, result is directly superimposed upon can by light image; Finally superimposed image is carried out Gamma correction (GammaCorrection) and namely finally merged output to adjust pixel grayscale, concrete steps are as follows:
1) to original infrared image Iicarry out maximal value filtering, filter resultcan be expressed as:
Wherein, Ωrx () represents that centre coordinate is x, radius is the image-region of R;
2) guiding filtering algorithm pair is adopteddo further filtering process, output image
Wherein, GuidedFilter () represents guiding filtering algorithm, and r represents filter radius, and ε represents regularization parameter;
3) by imagedirectly be superimposed upon primary visible light image Ivon, obtain image If:
4) to image Ifcarry out Gamma correction, obtain final fused images I 'f:
Wherein, γ represents correction coefficient, and p represents the figure place of view data.
Directiveness filtering algorithm implementation procedure is as follows:
Wherein, fmeanrepresent that filter radius is the mean filter of r, mean, corr, var and cov represent average, correlation, variance and covariance respectively.
In the present embodiment, visible ray used and infrared image are 8, the gray level image of 360 × 270, as shown in (a) figure in accompanying drawing 2 He (b) figure.
According to above-mentioned implementation step, (1) formula is first utilized to do maximal value filtering process to original infrared image, wherein radius R=7; Then (2) formula is utilized to try to achieve guiding filter result, wherein filter radius r=30, regularization parameter ε=10-3; Finally, use (3) formula by filtering image and primary visible light imaging importing, stack result is passed through again (4), and namely formula Gamma correction obtains final fusion output, wherein correction coefficient γ=0.8, image figure place n=8.
(c) figure in accompanying drawing 2 is final syncretizing effect, compares with infrared image with primary visible light, has both remained the detailed information of visible images, again highlighted for the interesting target in infrared image display, and has good visual effect.