CN110516549A - A kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram - Google Patents
A kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram Download PDFInfo
- Publication number
- CN110516549A CN110516549A CN201910677409.XA CN201910677409A CN110516549A CN 110516549 A CN110516549 A CN 110516549A CN 201910677409 A CN201910677409 A CN 201910677409A CN 110516549 A CN110516549 A CN 110516549A
- Authority
- CN
- China
- Prior art keywords
- vehicle
- pixel
- time
- road
- domain diagram
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/40—Scenes; Scene-specific elements in video content
- G06V20/41—Higher-level, semantic clustering, classification or understanding of video scenes, e.g. detection, labelling or Markovian modelling of sport events or news items
- G06V20/42—Higher-level, semantic clustering, classification or understanding of video scenes, e.g. detection, labelling or Markovian modelling of sport events or news items of sport video content
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/50—Context or environment of the image
- G06V20/56—Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
- G06V20/58—Recognition of moving objects or obstacles, e.g. vehicles or pedestrians; Recognition of traffic objects, e.g. traffic signs, traffic lights or roads
- G06V20/584—Recognition of moving objects or obstacles, e.g. vehicles or pedestrians; Recognition of traffic objects, e.g. traffic signs, traffic lights or roads of vehicle lights or traffic lights
-
- G—PHYSICS
- G08—SIGNALLING
- G08G—TRAFFIC CONTROL SYSTEMS
- G08G1/00—Traffic control systems for road vehicles
- G08G1/01—Detecting movement of traffic to be counted or controlled
- G08G1/0104—Measuring and analyzing of parameters relative to traffic conditions
- G08G1/0125—Traffic data processing
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Theoretical Computer Science (AREA)
- Chemical & Material Sciences (AREA)
- Analytical Chemistry (AREA)
- Computational Linguistics (AREA)
- Software Systems (AREA)
- Traffic Control Systems (AREA)
- Image Processing (AREA)
Abstract
The present invention relates to a kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram, the following steps are included: looking down the pixel sampling line for being arranged perpendicular to ground and being orthogonal to vehicle pass-through direction in video flowing in trackside traffic monitoring, the one-dimensional sampled pixel array in video successive frame is merged into rectangle time-domain diagram;By rectangle time-domain diagram boil down to gray-scale image, binarization of gray value is carried out to image by the threshold value of setting, longitudinal accumulation vector is constructed based on binaryzation time-domain diagram;Add up vector based on longitudinal pixel and carry out vehicle and road Identification, carries out road denoising, shadow elimination and vehicle alignment;Longitudinal pixel is added up into vector and is converted into vehicle pulse sequence timing diagram, carries out traffic flow parameter calculating.Compared with prior art, the present invention calculates simple, also can be carried out the acquisition of multi-lane traffic flow parameter when congestion, bad weather, night insufficient light in lane, method accuracy rate is high and has universality.
Description
Technical field
The present invention relates to the magnitudes of traffic flow to obtain field, more particularly, to a kind of traffic flow parameter based on binaryzation time-domain diagram
Acquisition methods.
Background technique
Video is monitored based on road traffic, vehicle count, vehicle classification, time headway, time occupancy are carried out to vehicle
The vehicle flowrate correlation of calculating etc. obtains, and plays an important role in traffic administration and intelligent transport system field.Vehicle flowrate
Related data is referred to as traffic flow parameter, is the basic foundation of intelligent transportation system work.
Currently, traffic management department largely deploys road section traffic volume monitoring device, by obtaining to traffic flow parameter
Round-the-clock video monitoring information provided by each section monitoring device can be efficiently used and excavate, to massive video data processing
After analysis, it is converted into intelligible effective telecommunication flow information.In intelligent transportation system, traffic flow parameter is obtained as its basis
Functional requirement needs to use contemporary data communication, video processing, data analysis and the technological synthesis such as excavation, completes high-precision
Vehicle identification and automobile speedestimate have systematically to improve traffic transportation efficiency and ensuring traffic safety and provide infrastructural support
Application prospect with development potential.
Traditional traffic flow parameter based on non-computer vision obtains, such as induction coil, infrared ray, hardware investment and
Maintenance cost is high, and road pavement is needed to construct, also easy to damage.Video monitoring for traffic control system provide it is intuitive it is practical,
The strong traffic real time monitoring means of interactivity.But in the existing acquisition methods based on video monitoring, however it remains ask below
Topic: 1, it is most of not account for that reasonable camera view and pixel sampling line how is arranged, it cannot achieve in lane jam situation
Under nonredundancy multilane flow obtain;2, the friendship being limited only under the bright and clear ecotopias such as noiseless, fine
Through-flow parameter obtains, and almost without the influence for considering the environmental factors such as rainy weather, insufficient light in actual conditions, actually makes
Limited with middle accuracy rate, method does not have universality.
Summary of the invention
When being based on binaryzation it is an object of the present invention to overcome the above-mentioned drawbacks of the prior art and provide one kind
The traffic flow parameter acquisition methods of domain figure.
The purpose of the present invention can be achieved through the following technical solutions:
A kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram, comprising the following steps:
S1. it is looked down in trackside traffic monitoring and is arranged perpendicular to ground and is orthogonal to the pixel in vehicle pass-through direction in video flowing
Line is sampled, the one-dimensional sampled pixel array in video successive frame is merged into rectangle time-domain diagram;
S2. by rectangle time-domain diagram boil down to gray-scale image, binarization of gray value is carried out to image by the threshold value of setting,
Longitudinal accumulation vector is constructed based on binaryzation time-domain diagram;
S3. vector is added up based on longitudinal pixel and carries out vehicle and road Identification, construct systematic data de-noising and shadow
Removing method carries out road denoising, shadow elimination and vehicle alignment;
S4. longitudinal pixel is added up into vector and is converted into vehicle pulse sequence timing diagram, carry out traffic flow parameter calculating, including
Vehicle flowrate, time headway and time occupancy.
Further, it is specifically included in the step S1:
S11. the Traffic Surveillance Video looked down from lane eminence is chosen, is chosen in camera perspective closest to ground and is hung down
Plane P that is straight and being orthogonal to vehicular movement direction, selects the friendship of plane P and ground in the pixel network of video frame I (x, y, t)
Line is as pixel sampling line ls, lsBoth ends are concordant with the two sides in lane, and wherein x indicates the abscissa of pixel in present frame, y table
Show that the ordinate of pixel in present frame, t indicate to obtain the present frame corresponding timestamp in video;
S12. it is based on video frame sample frequency, obtains sampling line l in each framesOn one-dimensional pixel;
S13. the one-dimensional pixel array obtained in each frame is denoted as an isochronous surface St(t, l), l represent lsUpper each picture
The coordinate value (x, y) of element will synthesize time-domain diagram D (t, y) along time axis connection from the one-dimensional pixel array of successive frame, time domain
Figure X direction indicates that, by the corresponding timestamp of pixel array on each isochronous surface of sequential video frame, y direction indicates that arrangement is each
The pixel of one-dimensional array.
Further, it is based on video frame sample frequency, obtains sampling line l in each framesOn one-dimensional pixel, the one-dimensional picture
Plain d (x, 0) is made of vehicle target object v (x, 0), road r (x, 0), shadow s (x, 0) and noise n (x, 0).
Further, it is specifically included in the step S2:
S21. gray-scale image is converted by time-domain diagram, adaptive gray threshold is determined using maximum variance between clusters
T realizes that inter-class variance g is minimized, and the difference of the foreground and background of gray-scale image maximizes, when threshold value T takes g to minimize pair
The image grayscale answered;Inter-class variance g calculation expression is as follows:
ω1+ω2=1
N1+N2=M*N
G=ω1*ω2*(μ1-μ2)2
In formula, ω1And ω2Indicate the pixel accounting in entire image of background and prospect, μ1And μ2For background and prospect
Average gray value, image is dimensioned to M × N, and number of pixels of the gray value of pixel less than threshold value T is N in image1, as
Number of pixels of the plain gray scale greater than threshold value T is N2;
S22. road background and Vehicle Object are distinguished by binaryzation, gray-scale image is handled as bianry image D '
(t, y), if D ' (t, y) grey scale pixel value src (t, y) is higher than adaptive gray threshold T and is set as the corresponding gray scale of white most
Big value maxVal, is labeled as Vehicle Object, is denoted as 1;It is otherwise provided as the corresponding minimum gray value of black, is labeled as road gap
Object is denoted as 0;The binaryzation value of image each point pixel is as follows:
S23. binaryzation time-domain diagram is converted into the accumulative vector of longitudinal pixel, gray level in each column pixel array in acquisition image
For the number of pixels of white, x-axis is the corresponding timestamp t of each frame time slice, and y-axis is that every frame white pixel occurs
Number ∑ S (xi), the vehicle width that physical significance is recorded for the isochronous surface.
Further, it is specifically included in the step S3:
S31. road denoising is carried out, i.e., removal lane line, surface mark line, trolley wire, video watermark and road surface are miscellaneous
The interference of the road noise of object;Control traffic surveillance videos mark road data in time-domain diagram matrix, vertical based on road
The cumulative distribution function for adding up vector to pixel chooses road threshold value H according to the road of video acquisition, weather conditionr, according to
Threshold value HrTwo groups are divided the image into, threshold value H will be less thanrColumn is zeroed, and is labeled as road gap object;
S32. shadow elimination is carried out, adding up vector with longitudinal pixel is analysis object, calculates longitudinal pixel and adds up in vector
Longitudinal span | y | maximum location of pixels is mapped as vehicle width Wvehicle;By vehicle width WvehicleLess than threshold value HsVehicle
Object is interfered as caused by car light, vehicle shadow, is zeroed by thresholding, is converted road gap object for shadow;
S32. vehicle alignment is carried out, is calculated according to natural driving behavior with the data distribution of headstock distance THW under scene of speeding
Cumulative distribution function, when convoy spacing timestamp t span is less than HfWhen, assert that the convoy spacing is vehicle itself, completes vehicle
Calibration, calculation expression are;
Hf=Frame*Hv
In formula, THW indicates headstock distance, | s1-s2| indicate the spacing of two vehicles, v1Indicate rear car speed, HvTo take 2% point
Digit is to reject threshold value, HfFor frame number threshold value, Frame is traffic surveillance videos frame number per second.
Further, it is specifically included in the step S4:
Add up the Vehicle Object and road gap object that vector analysis obtains according to longitudinal pixel, between Vehicle Object and road
Gap cross arrangement, with Vehicle Object viTimestamp length be pulse widthUsing the mean breadth of Vehicle Object as pulse height
DegreeGenerate vehicle pulse sequence timing diagram P (vi);
Pulse diagram horizontal axis represents the time;Pulse represents Vehicle Object, burst length (i.e. pulse width) indicate that vehicle is logical
The duration of over-sampling line reflects car speed, pulse heightReflect vehicle width;Pulse spacingWhen representing headstock
Away from THW;
Large car and compact car classification are carried out based on pulse height extreme value, with HpFor threshold value, pulse extreme value is more than HpIt is classified as
Otherwise large car is compact car.
Further, in the step S4, the calculation expression of vehicle flowrate Q are as follows:
In formula, T0Indicate the unit time, n indicates to pass through the vehicular traffic number in a certain section of road, n (P0) represent in vehicle
Unit time T in pulse sequence timing diagram0Interior umber of pulse.
Further, in the step S4, time headway htCalculation expression are as follows:
In formula,Indicate the burst length, n indicates to pass through the vehicular traffic number in a certain section of road.
Further, in the step S4, time occupancy RtCalculation expression are as follows:
In formula, T0Indicate the unit time,Indicate pulse width.
Compared with prior art, the invention has the following advantages that
1, a large amount of long video dimension-reduction treatment is two-dimensional time-domain diagram by the present invention, can greatly simplify traffic flow parameter
Acquisition process is also beneficial to carry out target retrieval in a large amount of long monitor video;Meanwhile the present invention is based on existing video prisons
It controls data and carries out calculating, have the characteristics that inexpensive, high-precision.
2, pixel sampling line is arranged in the present invention in video streaming, and the one-dimensional pixel array acquired in successive frame is merged into square
Shape time-domain diagram carries out binary conversion treatment after converting gray-scale image by maximum variance between clusters for rectangle time-domain diagram, comes
Distinguish road gap object and Vehicle Object;Longitudinal pixel is calculated based on binaryzation time-domain diagram and adds up vector, in different weather
And under illumination, systematic data de-noising and shadow removing method are constructed to overcome the influence of bad weather and insufficient light, it is right
Longitudinal pixel adds up vector progress analytical calculation and generates vehicle pulse sequence timing diagram even if when the congestion of lane
It can be carried out the higher traffic flow parameter of accuracy to obtain, meet the requirement of traffic flow parameter acquisition methods in practical application.
Detailed description of the invention
Fig. 1 is flow diagram of the invention.
Fig. 2 is that the present invention is based on the sample figures that traffic flow parameter acquisition is carried out under a variety of weather and light environment;
Fig. 3 be based under the conditions of " daytime-is fine " rectangle time-domain diagram and its processing after longitudinal pixel for generating add up vector
With vehicle pulse sequence timing diagram.
Fig. 4 be based under the conditions of " rain on daytime-" rectangle time-domain diagram and its processing after longitudinal pixel for generating add up vector
With vehicle pulse sequence timing diagram.
Fig. 5 be based under the conditions of " daytime-is cloudy " rectangle time-domain diagram and its processing after longitudinal pixel for generating add up to
Amount and vehicle pulse sequence timing diagram.
Fig. 6 be based under the conditions of " night-snow " rectangle time-domain diagram and its processing after longitudinal pixel for generating add up vector
With vehicle pulse sequence timing diagram.
Fig. 7 be based under the conditions of " night-is fine " rectangle time-domain diagram and its processing after longitudinal pixel for generating add up vector
With vehicle pulse sequence timing diagram.
Specific embodiment
The present invention is described in detail with specific embodiment below in conjunction with the accompanying drawings.The present embodiment is with technical solution of the present invention
Premised on implemented, the detailed implementation method and specific operation process are given, but protection scope of the present invention is not limited to
Following embodiments.
As shown in Figure 1, present embodiments providing a kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram, specifically
The following steps are included:
Step S1. looks down to be arranged in video flowing in trackside traffic monitoring perpendicular to ground and is orthogonal to vehicle pass-through direction
One-dimensional sampled pixel array in video successive frame is merged into rectangle time-domain diagram by pixel sampling line.
Step S2. determines threshold by rectangle time-domain diagram boil down to gray-scale image, by maximum variance between clusters (OUST)
Binarization of gray value is carried out to image after value, longitudinal accumulation vector is constructed based on binaryzation time-domain diagram.
Step S3., which is based on longitudinal pixel, to be added up vector and carries out vehicle and road Identification, construct systematic data de-noising and
Shadow removing method carries out road denoising, shadow elimination and vehicle alignment.
Longitudinal pixel is added up vector and is converted into vehicle pulse sequence timing diagram by step S4., carries out common reflection traffic
The parameter for flowing feature calculates, including vehicle flowrate, time headway and time occupancy.
One, the specific of step S1 is unfolded as follows:
Step S11, choose the Traffic Surveillance Video looked down from lane eminence, chosen in camera perspective closest to ground
Face is vertical and is orthogonal to the plane P in vehicular movement direction, and plane P and ground are selected in the pixel network of video frame I (x, y, t)
Intersection as pixel sampling line ls, lsBoth ends are concordant with the two sides in lane.
Step S12, it is based on video frame sample frequency, obtains sampling line l in each framesOn one-dimensional pixel.One-dimensional pixel d
(x, 0) is made of vehicle target object v (x, 0), road r (x, 0), shadow s (x, 0), noise n (x, 0), emphasis in subsequent algorithm
Extract and identify these different objects.The expression of one-dimensional pixel are as follows:
D (x, 0)=v (x, 0)+r (x, 0)+s (x, 0)+n (x, 0).
Step S13, the pixel sampling line l that will be obtained in each frame I (x, y, t)sOn one-dimensional pixel array be denoted as one
Isochronous surface St(t, l), l represent lsThe coordinate value (x, y) of upper each pixel, by from the one-dimensional pixel array of successive frame along when
Between axis connection synthesis time-domain diagram D (t, y), time-domain diagram X direction indicates by pixel array pair on each isochronous surface of sequential video frame
The timestamp t answered, y direction arrange the pixel of each one-dimensional array, and grey scale pixel value is denoted as src (t, y), St(t, l) is calculated
Expression formula is as follows:
Two, the specific of step S2 is unfolded as follows:
Step S21, gray-scale image is converted by time-domain diagram, is determined using maximum variance between clusters (OTSU) adaptive
Gray threshold T, realize that inter-class variance g is minimized, the difference of the foreground and background of gray-scale image maximizes, and threshold value T takes g
Corresponding image grayscale when minimum.With ω1And ω2Indicate the pixel accounting in entire image of background and prospect, μ1And μ2
For the average gray value of background and prospect, image is dimensioned to M × N, and the gray value of pixel is less than the pixel of threshold value T in image
Number is N1, number of pixels of the pixel grey scale greater than threshold value T is N2.The expression formula of inter-class variance g is as follows:
ω1+ω2=1
N1+N2=M*N
G=ω1*ω2*(μ1-μ2)2
Step S22, road background and Vehicle Object are distinguished by binaryzation.Gray-scale image is handled as bianry image
I ' (t, y), if I ' (t, y) grey scale pixel value src (t, y) is higher than adaptive gray threshold T and is set as the corresponding gray scale of white
Maximum value maxVal (takes 8 maximum gradation values 255), is labeled as Vehicle Object (being denoted as 1);It is otherwise provided as the corresponding ash of black
It spends minimum value (value 0) and is labeled as road gap object (being denoted as 0).
Step S23, longitudinal pixel is converted by binaryzation time-domain diagram and add up vector, obtain in image in each column pixel array
Gray level is the pixel aggregate-value of white, is indicated with vector t [n], and x-axis is corresponding the timestamp t, y of each frame time slice
Axis is the number ∑ S (i) that every frame white pixel occurs, and is denoted as ti, vehicle width that physical significance is recorded for the isochronous surface.
The calculation expression of vector t [n] is as follows:
T [n]=[t1, t2, t3…ti…tn]
ti=∑ S (i).
Three, the specific of step S3 is unfolded as follows:
Step S31, road denoising is carried out, i.e. removal lane line, surface mark line, trolley wire, video watermark and road
The interference of the road noises such as face sundries.Control traffic surveillance videos mark road data in time-domain diagram matrix, are based on road
Road longitudinal direction pixel adds up the cumulative distribution function (Cumulative Distribution Function, CDF) of vector, according to view
The different conditions such as road, the weather of frequency acquisition, taking longitudinal pixel to add up 2% quantile of vector is road threshold value Hr, according to threshold value Hr
Two groups are divided the image into, threshold value H will be less thanrColumn is zeroed, and is labeled as road gap object.
Step S32, shadow elimination is carried out, the light due to caused by car light, vehicle shadow is avoided to interfere.It is tired with longitudinal pixel
Counting vector is analysis object, calculates longitudinal pixel and adds up longitudinal span in vector | y | it is wide to be mapped as vehicle for maximum location of pixels
Spend Wvehicle.By vehicle width WvehicleLess than threshold value HsThe Vehicle Object of (value 100) causes as car light, vehicle shadow etc.
Interference, be zeroed by thresholding, convert road gap object for shadow.
Step S33, vehicle alignment is carried out, the excessively close Vehicle Object in two gaps is merged by scalping method, is corrected due to vehicle
Body local color is close with road color, is identified as the erroneous judgement of road in time-domain diagram binaryzation.According to existing literature, headstock
When to be less than 1s away from (Time Headway, THW) be short distance follow the bus, THW calculation formula is as follows:
Hf=Frame*Hv
Wherein, | S1-S2| refer to the spacing of adjacent two vehicle, v1Indicate rear car speed.According to natural driving behavior with speeding under scene
The data distribution of THW calculates cumulative distribution function, takes 2% quantile to reject threshold value Hv(value 0.5s), HfFor corresponding frame number
(12) monitor video number of pictures per second 25, the threshold value are taken as threshold value, Frame is traffic surveillance videos frame number per second.When between vehicle
It is less than H every timestamp t spanfWhen, assert that the convoy spacing is vehicle itself, completes vehicle alignment.
Four, the specific of step S3 is unfolded as follows:
Step S41, vehicle pulse sequence timing diagram is generated.Based on the vehicle obtained according to the accumulative vector analysis of longitudinal pixel
Object and road gap object, Vehicle Object and the cross arrangement of road gap, with Vehicle Object viTimestamp length be pulse
WidthUsing the mean breadth of Vehicle Object as pulse heightGenerate vehicle pulse sequence timing diagram P (vi).Pulse diagram
Horizontal axis represents the time;Pulse represents Vehicle Object, burst length (i.e. pulse width) indicate vehicle by sampling line when
It is long, reflect car speed, pulse heightReflect vehicle width;Pulse spacingRepresent time headway THW.Based on arteries and veins
Degree of leaping high extreme value (i.e. vehicle width maximum value) carries out large car and compact car classification, with Hp(value 400) is threshold value, pulse pole
Value is more than HpIt is classified as large car, is otherwise compact car.
Step S42, the Common Parameters of reflection traffic flow character: vehicle flowrate Q, time headway h are calculatedtOccupy with the lane time
Rate Rt。
(1) vehicle flowrate Q is obtained in unit time T0It is interior, by the vehicular traffic number n in a certain section of road, calculate public
Formula is as follows:
Wherein, n (P0) represent the unit time T in vehicle pulse sequence timing diagram0Interior umber of pulse.
(2) time headway ht, pass through certain to continuously drive the headstock of the adjacent two cars in front and back in same lane, same direction
Time interval at one, calculation formula are as follows:
Wherein,Indicate the burst length, n indicates to pass through the vehicular traffic number in a certain section of road.Ti-1Indicate previous
The headstock of vehicle passes through the time of pixel sampling line, TiIndicate that the headstock of latter vehicle passes through the time of pixel sampling line.
(3) time occupancy Rt, refer to certain time interval T0Interior, rolling stock passes through a certain section required time aggregate-valueWith observation time T0Ratio, calculation formula is as follows:
Wherein, T0Indicate the unit time,Indicate pulse width.
Fig. 2 is that the present invention is based on the sample figure that traffic flow parameter acquisition is carried out under a variety of weather and light environment, light feelings
Condition is divided into day and night, and weather condition is divided into fine, rain, cloudy, snow.
Fig. 3 is the present invention one and is based on carrying out the pixel sampling line on each timestamp of video frame under the conditions of " daytime-is fine "
Rectangle time-domain diagram made of merging after interception, longitudinal pixel after image binaryzation add up vector, and accumulative to longitudinal pixel
The vehicle pulse sequence timing diagram that vector generates after being handled.
Fig. 4 is the present invention one and is based on carrying out the pixel sampling line on each timestamp of video frame under the conditions of " rain on daytime-"
Rectangle time-domain diagram made of merging after interception, longitudinal pixel after image binaryzation add up vector, and accumulative to longitudinal pixel
The vehicle pulse sequence timing diagram that vector generates after being handled.
Fig. 5 be the present invention one based under the conditions of " daytime-is cloudy " to the pixel sampling line on each timestamp of video frame into
Rectangle time-domain diagram made of merging after row interception, longitudinal pixel after image binaryzation add up vector, and tired to longitudinal pixel
The vehicle pulse sequence timing diagram that meter vector generates after being handled.
Fig. 6 is the present invention one and is based on carrying out the pixel sampling line on each timestamp of video frame under the conditions of " night-snow "
Rectangle time-domain diagram made of merging after interception, longitudinal pixel after image binaryzation add up vector, and accumulative to longitudinal pixel
The vehicle pulse sequence timing diagram that vector generates after being handled.
Fig. 7 is the present invention one and is based on carrying out the pixel sampling line on each timestamp of video frame under the conditions of " night-is fine "
Rectangle time-domain diagram made of merging after interception, longitudinal pixel after image binaryzation add up vector, and accumulative to longitudinal pixel
The vehicle pulse sequence timing diagram that vector generates after being handled.
Wherein, it is the corresponding timestamp t of each frame time slice that longitudinal pixel, which adds up the x-axis of vector, and y-axis is that every frame is white
The number ∑ S (x that color pixel occursi), the vehicle width that physical significance is recorded for the isochronous surface, top line segment is threshold in figure
Value Hr, lower section line segment is threshold value Hs, in step S3 road denoising and shadow eliminate, avoid the dry of bad weather and light
It disturbs;X-axis represents the time in vehicle pulse sequence timing diagram;Pulse represents Vehicle Object.
As shown, the systematic data de-noising and shadow that the present invention constructs are eliminated under different weather and illumination
A large amount of long video dimension-reduction treatment can be accurate clear two-dimensional time-domain diagram, longitudinal pixel by rectangle time-domain diagram acquired in method
After accumulative vector carries out road denoising according to step S3, shadow is eliminated and vehicle alignment, resulting vehicle pulse sequence timing diagram
Even if still being able to accurately reflect vehicle number when the interference of bad weather, insufficient light and street lamp and being used to calculate common
Reflect the parameter of traffic flow character, including vehicle flowrate, time headway and time occupancy, even if larger etc. in lane traffic flow
Also it can be carried out the higher traffic flow parameter of accuracy in the case of (such as Fig. 7) to obtain, be able to satisfy traffic flow parameter in practical application and obtain
Take the requirement of method.
The preferred embodiment of the present invention has been described in detail above.It should be appreciated that those skilled in the art without
It needs creative work according to the present invention can conceive and makes many modifications and variations.Therefore, all technologies in the art
Personnel are available by logical analysis, reasoning, or a limited experiment on the basis of existing technology under this invention's idea
Technical solution, all should be within the scope of protection determined by the claims.
Claims (9)
1. a kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram, which comprises the following steps:
S1. it is looked down in trackside traffic monitoring and is arranged perpendicular to ground and is orthogonal to the pixel sampling in vehicle pass-through direction in video flowing
One-dimensional sampled pixel array in video successive frame is merged into rectangle time-domain diagram by line;
S2. by rectangle time-domain diagram boil down to gray-scale image, binarization of gray value is carried out to image by the threshold value of setting, is based on
Binaryzation time-domain diagram constructs longitudinal accumulation vector;
S3. vector is added up based on longitudinal pixel and carries out vehicle and road Identification, constructed systematic data de-noising and shadow is eliminated
Method carries out road denoising, shadow elimination and vehicle alignment;
S4. longitudinal pixel is added up into vector and is converted into vehicle pulse sequence timing diagram, carry out traffic flow parameter calculating, including wagon flow
Amount, time headway and time occupancy.
2. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
It is specifically included in step S1:
S11. choose the Traffic Surveillance Video looked down from lane eminence, choose in camera perspective closest to perpendicular to the ground and
It is orthogonal to the plane P in vehicular movement direction, plane P and the intersection on ground is selected to make in the pixel network of video frame I (x, y, t)
For pixel sampling line ls, lsBoth ends are concordant with the two sides in lane, and wherein x indicates the abscissa of pixel in present frame, and y expression is worked as
The ordinate of pixel in previous frame, t indicate to obtain the present frame corresponding timestamp in video;
S12. it is based on video frame sample frequency, obtains sampling line l in each framesOn one-dimensional pixel;
S13. the one-dimensional pixel array obtained in each frame is denoted as an isochronous surface St(t, l), l represent lsUpper each pixel
Coordinate value (x, y) will synthesize time-domain diagram D (t, y) along time axis connection from the one-dimensional pixel array of successive frame, and time-domain diagram is horizontal
Axis direction indicates that, by the corresponding timestamp of pixel array on each isochronous surface of sequential video frame, y direction indicates that arrangement is each one-dimensional
The pixel of array.
3. the traffic flow parameter acquisition methods according to claim 2 based on binaryzation time-domain diagram, which is characterized in that be based on
Video frame sample frequency obtains sampling line l in each framesOn one-dimensional pixel, one-dimensional pixel d (x, 0) is by vehicle target pair
As v (x, 0), road r (x, 0), shadow s (x, 0) and noise n (x, 0) are formed.
4. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
It is specifically included in step S2:
S21. gray-scale image is converted by time-domain diagram, adaptive gray threshold T is determined using maximum variance between clusters, it is real
Existing inter-class variance g is minimized, and the difference of the foreground and background of gray-scale image maximizes, and threshold value T is corresponding when g being taken to minimize
Image grayscale;Inter-class variance g calculation expression is as follows:
ω1+ω2=1
N1+N2=M*N
G=ω1*ω2*(μ1-μ2)2
In formula, ω1And ω2Indicate the pixel accounting in entire image of background and prospect, μ1And μ2For the flat of background and prospect
Equal gray value, image are dimensioned to M × N, and number of pixels of the gray value of pixel less than threshold value T is N in image1, pixel ash
Number of pixels of the degree greater than threshold value T is N2;
S22. road background and Vehicle Object are distinguished by binaryzation, gray-scale image are handled as bianry image D ' (t, y),
If D ' (t, y) grey scale pixel value src (t, y), which is higher than adaptive gray threshold T, is set as the corresponding gray scale maximum value of white
MaxVal is labeled as Vehicle Object, is denoted as 1;It is otherwise provided as the corresponding minimum gray value of black, is labeled as road gap pair
As being denoted as 0;
S23. binaryzation time-domain diagram is converted into the accumulative vector of longitudinal pixel, and gray level is white in each column pixel array in acquisition image
The number of pixels of color, x-axis are the corresponding timestamp t of each frame time slice, and y-axis is the number ∑ that every frame white pixel occurs
S(xi), the vehicle width that physical significance is recorded for the isochronous surface.
5. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
It is specifically included in step S3:
S31. road denoising is carried out, that is, removes lane line, surface mark line, trolley wire, video watermark and road debris
The interference of road noise;Control traffic surveillance videos mark road data in time-domain diagram matrix, are based on road longitudinal direction picture
The cumulative distribution function of the accumulative vector of element chooses road threshold value H according to the road of video acquisition, weather conditionr, according to threshold value Hr
Two groups are divided the image into, threshold value H will be less thanrColumn is zeroed, and is labeled as road gap object;
S32. shadow elimination is carried out, adding up vector with longitudinal pixel is analysis object, and the longitudinal pixel of calculating adds up longitudinal in vector
Span | y | maximum location of pixels is mapped as vehicle width Wvehicle;By vehicle width WvehicleLess than threshold value HsVehicle pair
As being interfered as caused by car light, vehicle shadow, it is zeroed by thresholding, converts road gap object for shadow;
S32. vehicle alignment is carried out, calculates accumulation with the data distribution of headstock distance THW under scene of speeding according to natural driving behavior
Distribution function, when convoy spacing timestamp t span is less than HfWhen, assert that the convoy spacing is vehicle itself, complete vehicle alignment,
Its calculation expression is;
Hf=Frame*Hv
In formula, THW indicates headstock distance, | s1-s2| indicate the spacing of two vehicles, v1Indicate rear car speed, HvTo take 2% quantile to be
Reject threshold value, HfFor frame number threshold value, Frame is traffic surveillance videos frame number per second.
6. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
It is specifically included in step S4:
Add up the Vehicle Object and road gap object that vector analysis obtains according to longitudinal pixel, Vehicle Object and road gap are handed over
Fork arrangement, with Vehicle Object viTimestamp length be pulse widthUsing the mean breadth of Vehicle Object as pulse heightGenerate vehicle pulse sequence timing diagram P (vi);
Pulse diagram horizontal axis represents the time;Pulse represents Vehicle Object, burst length (i.e. pulse width) indicate vehicle by adopting
The duration of line-transect reflects car speed, pulse heightReflect vehicle width;Pulse spacingRepresent time headway
THW;
Large car and compact car classification are carried out based on pulse height extreme value, with HpFor threshold value, pulse extreme value is more than HpIt is classified as large size
Otherwise vehicle is compact car.
7. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
In step S4, the calculation expression of vehicle flowrate Q are as follows:
In formula, T0Indicate the unit time, n indicates to pass through the vehicular traffic number in a certain section of road, n (P0) represent in vehicle pulse
Unit time T in sequence timing diagram0Interior umber of pulse.
8. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
In step S4, time headway htCalculation expression are as follows:
In formula,Indicate the burst length, n indicates to pass through the vehicular traffic number in a certain section of road.
9. the traffic flow parameter acquisition methods according to claim 1 based on binaryzation time-domain diagram, which is characterized in that described
In step S4, time occupancy RtCalculation expression are as follows:
In formula, T0Indicate the unit time,Indicate pulse width.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910677409.XA CN110516549B (en) | 2019-07-25 | 2019-07-25 | Traffic flow parameter obtaining method based on binary time domain diagram |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910677409.XA CN110516549B (en) | 2019-07-25 | 2019-07-25 | Traffic flow parameter obtaining method based on binary time domain diagram |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110516549A true CN110516549A (en) | 2019-11-29 |
CN110516549B CN110516549B (en) | 2021-11-09 |
Family
ID=68623598
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910677409.XA Active CN110516549B (en) | 2019-07-25 | 2019-07-25 | Traffic flow parameter obtaining method based on binary time domain diagram |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110516549B (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101042805A (en) * | 2007-03-09 | 2007-09-26 | 吉林大学 | Control method for single crossing mixed traffic signal |
CN103236162A (en) * | 2013-04-11 | 2013-08-07 | 江苏大学 | Signalized intersection traffic capacity analyzing method based on based on video analysis |
CN103383816A (en) * | 2013-07-01 | 2013-11-06 | 青岛海信网络科技股份有限公司 | Method and device for controlling traffic signals of multipurpose electronic police mixed traffic flow detection |
CN108198415A (en) * | 2017-12-28 | 2018-06-22 | 同济大学 | A kind of city expressway accident forecast method based on deep learning |
CN109919883A (en) * | 2018-12-03 | 2019-06-21 | 南京三宝科技股份有限公司 | A kind of traffic video data capture method based on gradation conversion |
-
2019
- 2019-07-25 CN CN201910677409.XA patent/CN110516549B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101042805A (en) * | 2007-03-09 | 2007-09-26 | 吉林大学 | Control method for single crossing mixed traffic signal |
CN103236162A (en) * | 2013-04-11 | 2013-08-07 | 江苏大学 | Signalized intersection traffic capacity analyzing method based on based on video analysis |
CN103383816A (en) * | 2013-07-01 | 2013-11-06 | 青岛海信网络科技股份有限公司 | Method and device for controlling traffic signals of multipurpose electronic police mixed traffic flow detection |
CN108198415A (en) * | 2017-12-28 | 2018-06-22 | 同济大学 | A kind of city expressway accident forecast method based on deep learning |
CN109919883A (en) * | 2018-12-03 | 2019-06-21 | 南京三宝科技股份有限公司 | A kind of traffic video data capture method based on gradation conversion |
Non-Patent Citations (7)
Title |
---|
MARKÉTA DUBSKÁ等: "Fully Automatic Roadside Camera Calibration for Traffic Surveillance", 《IEEE T R A N S A C T I O N S O N INTELLIGENT TRANSPORTATION SYSTEMS》 * |
NILUTHPOL CHOWDHURY MITHUN等: "Detection and Classification of Vehicles From Video Using Multiple Time-Spatial Images", 《IEEE TRANSACTIONS ON INTELLIGENT TRANSPORTATION SYSTEMS》 * |
RONGJIE YU等: "Exploring crash mechanisms with microscopic traffic flow variables: A hybrid approach with latent class logit and path analysis models", 《ACCIDENT ANALYSIS AND PREVENTION》 * |
RUIMIN KE等: "Real-Time Traffic Flow Parameter Estimation From UAV Video Based on Ensemble Classifier and Optical Flow", 《IEEE TRANSACTIONS ON INTELLIGENT TRANSPORTATION SYSTEMS》 * |
ZHIQIANG HUANG等: "Utilizing Latent Class Logit Model to Predict Crash Risk", 《2017 IEEE/ACIS 16TH INTERNATIONAL CONFERENCE ON COMPUTER AND》 * |
章强: "基于视频检测技术的道路交通参数监测***", 《中国优秀博硕士学位论文全文数据库(硕士) 信息科技辑》 * |
范五一: "视频交通流参数检测技术研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》 * |
Also Published As
Publication number | Publication date |
---|---|
CN110516549B (en) | 2021-11-09 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Chen et al. | Lidar-video driving dataset: Learning driving policies effectively | |
CN107845264A (en) | A kind of volume of traffic acquisition system and method based on video monitoring | |
Nemade | Automatic traffic surveillance using video tracking | |
CN106934374B (en) | Method and system for identifying traffic signboard in haze scene | |
CN102819764A (en) | Method for counting pedestrian flow from multiple views under complex scene of traffic junction | |
Pan et al. | Traffic surveillance system for vehicle flow detection | |
CN102426785B (en) | Traffic flow information perception method based on contour and local characteristic point and system thereof | |
JPH07505966A (en) | object monitoring system | |
CN102496281B (en) | Vehicle red-light violation detection method based on combination of tracking and virtual loop | |
US20210312801A1 (en) | Traffic monitoring using distributed fiber optic sensing | |
CN108921076B (en) | Pavement crack disease self-adaptive constant false alarm detection method based on image | |
CN102054169B (en) | License plate positioning method | |
CN108717540A (en) | The method and device of pedestrian and vehicle are distinguished based on 2D laser radars | |
CN107274678B (en) | A kind of night vehicle flowrate and model recognizing method based on Kinect | |
CN103839415A (en) | Traffic flow and occupation ratio information acquisition method based on road surface image feature identification | |
CN103268470A (en) | Method for counting video objects in real time based on any scene | |
Chen et al. | Traffic congestion classification for nighttime surveillance videos | |
CN208271388U (en) | A kind of volume of traffic acquisition system based on video monitoring | |
Yuliandoko et al. | Automatic vehicle counting using Raspberry pi and background subtractions method in the sidoarjo toll road | |
Shafie et al. | Smart video surveillance system for vehicle detection and traffic flow control | |
Mossi et al. | Real-time traffic analysis at night-time | |
CN110516549A (en) | A kind of traffic flow parameter acquisition methods based on binaryzation time-domain diagram | |
CN104318783A (en) | Method for analyzing night traffic flow through car lamp detection | |
Al-Kadi et al. | Road scene analysis for determination of road traffic density | |
Zhou et al. | Video driven traffic modelling |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |