CN105096271A - Method for detecting traffic image in hazy weather based on improved gradient similarity kernel - Google Patents

Method for detecting traffic image in hazy weather based on improved gradient similarity kernel Download PDF

Info

Publication number
CN105096271A
CN105096271A CN201510505156.XA CN201510505156A CN105096271A CN 105096271 A CN105096271 A CN 105096271A CN 201510505156 A CN201510505156 A CN 201510505156A CN 105096271 A CN105096271 A CN 105096271A
Authority
CN
China
Prior art keywords
traffic image
image
color space
haze weather
omega
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
CN201510505156.XA
Other languages
Chinese (zh)
Other versions
CN105096271B (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.)
Xi'an Huizhi Information Technology Co.,Ltd.
Original Assignee
Changan University
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 Changan University filed Critical Changan University
Priority to CN201510505156.XA priority Critical patent/CN105096271B/en
Publication of CN105096271A publication Critical patent/CN105096271A/en
Application granted granted Critical
Publication of CN105096271B publication Critical patent/CN105096271B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Processing (AREA)
  • Image Analysis (AREA)

Abstract

The invention discloses a method for detecting a traffic image in a hazy weather based on an improved gradient similarity kernel. The method comprises the steps of firstly, acquiring the traffic image in the hazy weather; secondly, converting the traffic image obtained in step 1 from an RGB color space to a Lab color space; thirdly, filtering the traffic image obtained in step 2 in the Lab color space; and finally, converting the traffic image processed in step 3 from the Lab color space to the RGB color space, and outputting the processed traffic image in the hazy weather. The method achieves the filtering effect on the image in the hazy weather, and effectively keeps the edge information of the image, so the method is particularly important for subsequent traffic image processing and information extraction.

Description

Based on traffic image detection method under the haze weather of improvement gradient similarity core
Technical field
The invention belongs to technical field of image processing, be specifically related to a kind of based on traffic image detection method under the haze weather of improvement gradient similarity core.
Background technology
Digital Image Processing refers to and converts picture signal to digital signal and utilize the process that computing machine processes it.The object of early stage image procossing improves the quality of image, to obtain the bulk information in image.The common method of image procossing has image enhaucament, recovery, coding, compression etc.
In recent years, along with the development of image processing field, Image Acquisition information is utilized to become a kind of important means.In traffic, image processing techniques is widely used, as road environment monitoring, vehicle peccancy identification.No matter be at road traffic safety or in the intelligent transportation system developed, all play more and more important effect.But under physical environment, can there is much noise due to factors such as weather in the traffic image of acquisition, is difficult to obtain accurate information according to this low-quality image.
At present, digital picture smoothing processing has a lot of method, and spatial domain is smoothly comparatively conventional in Digital Image Processing and effective method.Through the development of decades, there is the algorithm of a lot of comparative maturity in airspace filter, as mean filter, medium filtering, Wiener filtering.But in itself, spatial domain filter algorithms all belongs to low-pass filtering, some useful high-frequency informations due to the missing image after low-pass filtering, image detail is caused to be lost, although filtered image eliminates noise, making edge fog, is very disadvantageous to follow-up image procossing, so the research of various denoising method is actual is the balance carried out between denoising and reserved high-frequency information.
For the problems referred to above, 1998, C.Tomasi and R.Manduchi proposed a kind of non-iterative simple strategy, is called bilateral filtering.It not only takes the strategy of traditional filtering method, considers spatial positional information, also adds the impact of codomain similarity, and therefore, in the region that image change is mild, in neighborhood, pixel brightness value is more or less the same, and bilateral filtering is converted into gauss low frequency filter; In the region that image change is violent, wave filter utilizes the brightness value of the pixel that brightness value near marginal point is close on average to substitute former brightness value.Therefore, bilateral filtering not only can removal of images noise but also remain image edge information.Although bilateral filtering has above-mentioned advantage, there is inefficiency in it, the shortcoming that filter effect is not good.
Summary of the invention
The object of the present invention is to provide a kind of based on traffic image detection method under the haze weather of improvement gradient similarity core, to overcome the defect that above-mentioned prior art exists, the present invention had both met the filter effect of haze weather situation hypograph, effectively maintain again the marginal information of image, to follow-up traffic image process and information extraction particularly important.
For achieving the above object, the present invention adopts following technical scheme:
Based on traffic image detection method under the haze weather of improvement gradient similarity core, comprise the following steps:
Step 1: traffic image under acquisition haze weather;
Step 2: the traffic image of RGB color space step 1 obtained is transformed into Lab color space;
Step 3: filtering process is carried out to the traffic image of the Lab color space that step 2 obtains;
Step 4: the traffic image of the Lab color space after step 3 being processed is transformed into RGB color space, traffic image under the haze weather after output processing.
Further, in step 2, traffic image under the haze weather of RGB color space is transformed into Lab color space, traffic image changes L, a, b tri-components into by R, G, B color component, wherein L represents the brightness of image, a represents the scope from redness to green, and b represents the scope from yellow to blueness.
Further, the filter transfer function that in step 3, filtering process adopts is:
u ′ ( i , j ) = 1 C s , r Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j ) u ( m , n )
In formula, u ' (i, j) is filtered image slices vegetarian refreshments, u (m, n) be the pixel in filter window, the square area that ω is radius centered by filtered pixel of the traffic image of the Lab color space that step 2 obtains taken from by this filter window, w d(m, n, i, j) is the space proximity factor, w r(m, n, i, j) is the pixel coordinate figure of the codomain similarity factor, the traffic image of the Lab color space that (i, j) obtains for step 2, and (m, n) is the coordinate figure of the pixel in filter window, and ω is filter window radius, C s,rfor normalization coefficient, and C s , r = Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j ) .
Further, the space proximity factor w in filter transfer function dcomputing method be:
w d ( i , j , m , n ) = e - | i - m | 2 + | j - n | 2 2 σ d 2
In formula, (m, n) is the coordinate of pixel in filter window, the pixel coordinate figure of the traffic image of the Lab color space that (i, j) obtains for step 2, σ dfor Gauss's variance.
Further, the codomain similarity factor w in filter transfer function rcomputing method be:
w r = exp ( - ( g L ) 2 + ( g a ) 2 + ( g b ) 2 2 σ r 2 )
In formula, σ rfor gaussian coefficient, g l, g aand g bbe respectively the Grad of L, a, b.
Further, g l, g aand g bcomputing method be:
g L = ( ∂ u L ∂ x L ) 2 + ( ∂ u L ∂ y L ) 2 ∂ u L ∂ x L × ∂ u L ∂ y L g a = ( ∂ u a ∂ x a ) 2 + ( ∂ u a ∂ y a ) 2 ∂ u a ∂ x a × ∂ u a ∂ y a g b = ( ∂ u b ∂ x b ) 2 + ( ∂ u b ∂ y b ) 2 ∂ u b ∂ x b × ∂ u b ∂ y b
In formula, with that the L component image that obtains of step 2 is to x respectively lask partial derivative and to y lask partial derivative, with that a component image is to x respectively aask partial derivative and to y aask partial derivative, with that b component image is to x respectively bask partial derivative and to y bask partial derivative, g l, g aand g bbe respectively the Grad of L, a, b.
Further, Gauss's variances sigma d=3, gaussian coefficient σ r=0.1, filter window radius ω=5.
Compared with prior art, the present invention has following useful technique effect:
The present invention adopts the gradient of neighbor brightness value to construct gradient similarity core, gradient method is widely used in traditional images rim detection, because gradient edge is more responsive, adopt gradient method more effectively can detect the image border in concrete direction, and result in by force image denoising effect decline because gradient Edge detected is crossed, simple gradient bilateral filtering method filter effect difference loses the essential meaning of wave filter, therefore the present invention improves gradient calculation formula, gradient edge Detection results is weakened in conjunction with gradient formula itself, not only edge keeps better image after filtering process but also filter effect is better.The present invention is weighted on average by the gradient similarity core of geometry adjacency core and improvement to image neighborhood pixels, thus realize filtering, both the filter effect of haze weather situation hypograph had been met, effectively maintain again the marginal information of image, to follow-up traffic image process and information extraction particularly important.
Accompanying drawing explanation
Fig. 1 is schematic flow sheet of the present invention;
Fig. 2 is that the present invention and other filtering method contrast traffic image denoising effect under haze weather, wherein, (a) original Noise image, (b) mean filter image, (c) traditional bilateral filtering image, (d) gradient bilateral filtering image, (e) bilateral filtering image of the present invention;
Fig. 3 is the partial enlargement of Fig. 2, wherein, and (a) original Noise image, (b) mean filter image, c () is traditional bilateral filtering image, (d) gradient bilateral filtering image, (e) bilateral filtering image of the present invention.
Embodiment
Below in conjunction with accompanying drawing, the present invention is described in further detail:
See Fig. 1, based on traffic image detection method under the haze weather of improvement gradient similarity core, comprise the following steps:
Traffic image under step 1, acquisition haze weather.
Utilize image capture device, the traffic image degraded under obtaining haze weather.
Step 2, the image of RGB color space is transformed into Lab color space, image is L, a, b tri-components by R, G, B color transition, and wherein L represents the brightness of image, and a represents the scope from redness to green, and b represents the scope from yellow to blueness.
Step 3, through step 1 and step 2, we obtain the traffic image under pretreated haze weather, because the image that in reality, we collect all contains noise, this is extremely disadvantageous to the useful information that we obtain in image, and noise also has certain interference to further image procossing, therefore filtering process is carried out to the image obtained and be extremely necessary.
Traditional filtering has medium filtering, mean filter etc.Medium filtering and mean filter are all general do not add averaging of differentiation or intermediate value to the pixel in filter window when processing a certain pixel.As can be seen from the principle of bilateral filtering we just, two-sided filter can be thought to be made up of two functions, and a function is the coefficient being determined wave filter by geometric space distance, and another determines the coefficient of wave filter by pixel value difference.
We arrange windows radius size is 5, computer memory proximity factor w d, formula is as follows
w d ( i , j , m , n ) = e - | i - m | 2 + | j - n | 2 2 σ d 2
In formula, (m, n) is the coordinate of pixel in filter window, and (i, j) is the coordinate inputting filtered pixel.Formula essence is Gaussian function computing formula, σ dfor Gauss's variance.
From above Gaussian function, along with the distance of the pixel in window to the filtered pixel of input increases, space proximity factor w dreduce, namely neighbor pixel is larger on filtering impact.
The difference that the pixel that step 4, filtering in step 3 take into account geometric space different distance affects pixel to be processed.In order to keep the boundary information of image, we also will consider the impact of pixel value difference between adjacent pixels point, because gradient edge is very responsive, our modified hydrothermal process selects a kind of Grad of improvement to calculate pixel similarity coefficient.Traditional gradient calculation formula is as follows:
G = G x 2 + G y 2
Wherein G xand G ybe the partial derivative to X and Y respectively, do not consider the impact of the derivative of himself, therefore, we carry out improving to traditional gradient formula, and can to obtain new gradient formula as follows:
g = ( ∂ u ∂ x ) 2 + ( ∂ u ∂ y ) 2 ∂ u ∂ x × ∂ u ∂ y
In formula, that image asks partial derivative to x, be that image asks partial derivative to y, g is the Grad exported.
In step 5, step 4, we obtain new gradient formula, and we can obtain Lab space Grad g to use new gradient calculation formula l, g aand g bgray scale difference value when Grad is larger between neighbor is larger, then can judge that this pixel is as edge pixel point, now, the filter effect of formula edge pixel needs to weaken, then we introduce codomain coefficient of similarity, and when Grad is larger, codomain coefficient of similarity reduces, and function filter effect suitably reduces with Retain edge information.
Codomain similarity factor w is calculated according to the Grad that Lab space is improved ras follows:
w r = exp ( - ( g L ) 2 + ( g a ) 2 + ( g b ) 2 2 σ r 2 )
In formula, σ rfor codomain similarity because the gaussian coefficient of subformula keeps effect, g for adjusting edge l, g aand g bbe respectively the gradient calculation value adopting and improve L, a, b that gradient formula calculates.
Step 6, general space proximity factor w dwith the codomain similarity factor w improved robtain filter transfer function, carry out filtering process.Marginal point is determined whether by the Grad calculating neighbor, and then adjustment codomain similarity factor w rsize, make function edge and non-edge have different filter effects.Namely weaken filter effect at boundary, reach the object keeping edge.
Filter transfer function:
u ′ ( i , j ) = 1 C s , r Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j ) u ( m , n )
In formula, u (m, n) is the pixel in filter window, w dfor the space proximity factor, w rfor the codomain similarity factor.The pixel coordinate figure that (i, j) is filtered image, (m, n) is the coordinate figure of the pixel in filter window, and ω is filter window radius.
Normalization coefficient:
C s , r = Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j )
Horizontal traversing graph, as pixel, carries out filtering process to image.To formula basic parameter assignment, σ in this example d=3, σ r=0.1, filter window ω=5.
Step 7, the image of Lab color space is transformed into RGB color space, traffic image under the haze weather after output processing.
Can more intuitively to treatment effect by the partial enlarged drawing of Fig. 3, Fig. 3 (a) is grandfather tape noise image, is difficult to carry out follow-up mist elimination process in visual picture with much noise; Fig. 3 (b) adopts radius to be the mean filter of the filter window of 5, and can find out, mean filter soft edge, loss in detail, filter effect is poor; The bilateral filter result of tradition is as Fig. 3 (c), and same employing radius is the filter window of 5, although it is poor to maintain image part edge details filter effect; Fig. 3 (d) is gradient bilateral filtering result, and filter effect strengthens to some extent; Adopt filtering method effect of the present invention as Fig. 3 (e), filter effect has greatly improved relative to traditional bilateral filtering, and edge keeps better.
In sum, filtering method of the present invention is for traffic image denoising under haze weather, and denoising effect is good, and edge keeps better, to the effective ideal of traffic picture processing under haze weather, the further process of image and Obtaining Accurate image information are had great significance.

Claims (7)

1., based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, comprise the following steps:
Step 1: traffic image under acquisition haze weather;
Step 2: the traffic image of RGB color space step 1 obtained is transformed into Lab color space;
Step 3: filtering process is carried out to the traffic image of the Lab color space that step 2 obtains;
Step 4: the traffic image of the Lab color space after step 3 being processed is transformed into RGB color space, traffic image under the haze weather after output processing.
2. according to claim 1 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, in step 2, traffic image under the haze weather of RGB color space is transformed into Lab color space, traffic image changes L, a, b tri-components into by R, G, B color component, wherein L represents the brightness of image, a represents the scope from redness to green, and b represents the scope from yellow to blueness.
3. according to claim 1 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, the filter transfer function that in step 3, filtering process adopts is:
u ′ ( i , j ) = 1 C s , r Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j ) u ( m , n )
In formula, u ' (i, j) is filtered image slices vegetarian refreshments, u (m, n) be the pixel in filter window, the square area that ω is radius centered by filtered pixel of the traffic image of the Lab color space that step 2 obtains taken from by this filter window, w d(m, n, i, j) is the space proximity factor, w r(m, n, i, j) is the pixel coordinate figure of the codomain similarity factor, the traffic image of the Lab color space that (i, j) obtains for step 2, and (m, n) is the coordinate figure of the pixel in filter window, and ω is filter window radius, C s,rfor normalization coefficient, and C s , r = Σ m = i - ω i + ω Σ n = j - ω j + ω w d ( m , n , i , j ) w r ( m , n , i , j ) .
4. according to claim 3 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, the space proximity factor w in filter transfer function dcomputing method be:
w d ( i , j , m , n ) = e - | i - m | 2 + | j - n | 2 2 σ d 2
In formula, (m, n) is the coordinate of pixel in filter window, the pixel coordinate figure of the traffic image of the Lab color space that (i, j) obtains for step 2, σ dfor Gauss's variance.
5. according to claim 4 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, the codomain similarity factor w in filter transfer function rcomputing method be:
w r = exp ( - ( g L ) 2 + ( g a ) 2 + ( g b ) 2 2 σ r 2 )
In formula, σ rfor gaussian coefficient, g l, g aand g bbe respectively the Grad of L, a, b.
6. according to claim 5 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, g l, g aand g bcomputing method be:
g L = ( ∂ u L ∂ x L ) 2 + ( ∂ u L ∂ y L ) 2 ∂ u L ∂ x L × ∂ u L ∂ y L g a = ( ∂ u a ∂ x a ) 2 + ( ∂ u a ∂ y a ) 2 ∂ u a ∂ x a × ∂ u a ∂ y a g b = ( ∂ u b ∂ x b ) 2 + ( ∂ u b ∂ y b ) 2 ∂ u b ∂ x b × ∂ u b ∂ y b
In formula, with that the L component image that obtains of step 2 is to x respectively lask partial derivative and to y lask partial derivative, with that a component image is to x respectively aask partial derivative and to y aask partial derivative, with that b component image is to x respectively bask partial derivative and to y bask partial derivative, g l, g aand g bbe respectively the Grad of L, a, b.
7. according to claim 5 based on traffic image detection method under the haze weather of improvement gradient similarity core, it is characterized in that, Gauss's variances sigma d=3, gaussian coefficient σ r=0.1, filter window radius ω=5.
CN201510505156.XA 2015-08-17 2015-08-17 Based on traffic image detection method under the haze weather for improving gradient similarity core Active CN105096271B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510505156.XA CN105096271B (en) 2015-08-17 2015-08-17 Based on traffic image detection method under the haze weather for improving gradient similarity core

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510505156.XA CN105096271B (en) 2015-08-17 2015-08-17 Based on traffic image detection method under the haze weather for improving gradient similarity core

Publications (2)

Publication Number Publication Date
CN105096271A true CN105096271A (en) 2015-11-25
CN105096271B CN105096271B (en) 2017-08-25

Family

ID=54576622

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510505156.XA Active CN105096271B (en) 2015-08-17 2015-08-17 Based on traffic image detection method under the haze weather for improving gradient similarity core

Country Status (1)

Country Link
CN (1) CN105096271B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2568438A2 (en) * 2011-09-08 2013-03-13 Fujitsu Limited Image defogging method and system
CN103996178A (en) * 2014-05-30 2014-08-20 天津大学 Sand and dust weather color image enhancing method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2568438A2 (en) * 2011-09-08 2013-03-13 Fujitsu Limited Image defogging method and system
CN103996178A (en) * 2014-05-30 2014-08-20 天津大学 Sand and dust weather color image enhancing method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
KAIMING HE ET AL: "Single image haze removal using dark channel prior", 《2009 IEEE CONFERENCE ON COMPUTER VISION AND PATTERN RECOGNITION》 *
蒋辉: "梯度双边滤波的图像去噪", 《计算机工程与应用HTTP://WWW.CNKI.NET/KCMS/DOI/10.3778/J.ISSN.1002-8331.1402-0317.HTML》 *

Also Published As

Publication number Publication date
CN105096271B (en) 2017-08-25

Similar Documents

Publication Publication Date Title
CN107330376B (en) Lane line identification method and system
CN103413276B (en) A kind of degree of depth Enhancement Method based on grain distribution feature
CN100474337C (en) Noise-possessing movement fuzzy image restoration method based on radial basis nerve network
CN102479383B (en) Method and device for removing salt and pepper noise
CN103049906B (en) A kind of image depth extracting method
CN102855617B (en) Method and system for processing adaptive images
CN107895375B (en) Complex road route extraction method based on visual multi-features
CN102982304B (en) Utilize polarized light image to detect the method and system of vehicle location
CN103440644B (en) A kind of multi-scale image weak edge detection method based on minimum description length
CN106778551B (en) Method for identifying highway section and urban road lane line
CN110414385B (en) Lane line detection method and system based on homography transformation and characteristic window
Krishnan et al. A survey on different edge detection techniques for image segmentation
CN104200437A (en) Image defogging method
CN104463814B (en) Image enhancement method based on local texture directionality
CN112528868B (en) Illegal line pressing judgment method based on improved Canny edge detection algorithm
CN110245600B (en) Unmanned aerial vehicle road detection method for self-adaptive initial quick stroke width
CN101968885A (en) Method for detecting remote sensing image change based on edge and grayscale
CN105719275A (en) Parallel combination image defect segmentation method
CN105184743A (en) Image enhancement method based on non-linear guiding filtering
CN105787912B (en) Classification-based step type edge sub-pixel positioning method
CN104424641A (en) Detection method for image fuzzy tampering
CN105894474A (en) Non-linear image enhancement method, and edge detection method using the same
CN101739667B (en) Non-downsampling contourlet transformation-based method for enhancing remote sensing image road
Cheng An improved Canny edge detection algorithm
CN107784639A (en) A kind of polygon filtering and noise reduction method of unmanned aerial vehicle remote sensing image improvement

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20210128

Address after: Room 508, block a, Rongcheng cloud Valley, 57 Keji 3rd road, Zhangba Street office, high tech Zone, Xi'an City, Shaanxi Province, 710075

Patentee after: Xi'an Huizhi Information Technology Co.,Ltd.

Address before: 710064 No. 33, South Second Ring Road, Shaanxi, Xi'an

Patentee before: CHANG'AN University

TR01 Transfer of patent right