A kind of Traffic State Detection Method and device
Technical field
The present embodiments relate to technical field of vehicle, particularly relate to a kind of Traffic State Detection Method and device.
Background technology
Along with the development of science and technology, vehicle is increasingly becoming the walking-replacing tool of people, but increasing of vehicle fleet size causes friendship
Logical blocks up.
The scheme of existing detection traffic congestion state generally uses geographic satellite equipment to collect data, calculates the road of vehicle
Running time, draws condition of road surface.But, such scheme is the most relatively costly, and the data volume in processing procedure is very big, also
The precision that can cause detection is inadequate.
During realizing the embodiment of the present invention, inventor finds that prior art at least exists following defect: existing side
In case, detection congestion status is relatively costly, and data processing amount is big, and the precision detected is the highest.
Summary of the invention
The purpose of the embodiment of the present invention is to provide a kind of Traffic State Detection Method and device, to solve prior art
In, detection congestion status is relatively costly, and data processing amount is big, and the problem that the precision that detects is the highest.
First aspect, a possible embodiment of the embodiment of the present invention provides a kind of Traffic State Detection Method, bag
Include: obtain velocity information and the positional information of vehicle;According to the velocity information of vehicle, determine that speed is less than the target of threshold speed
Vehicle;According to the positional information of target vehicle, target vehicle is classified, obtain one or more target road section;To each
Target road section carries out jamming analysis, determines the traffic behavior of each target road section according to the result of jamming analysis.
Second aspect, a possible embodiment of the embodiment of the present invention provides a kind of traffic condition detection device, bag
Include: acquisition module, for obtaining velocity information and the positional information of vehicle;Speed divides module, for the speed according to vehicle
Information, determines that speed is less than the target vehicle of threshold speed;Position divides module, for the positional information according to target vehicle,
Target vehicle is classified, obtains one or more target road section;State determining module, for carrying out each target road section
Jamming analysis, determines the traffic behavior of each target road section according to the result of jamming analysis.
The embodiment of the present invention, by obtaining velocity information and the positional information of vehicle, according to the velocity information of vehicle, determines
Target vehicle, less than the target vehicle of threshold speed, according to the positional information of target vehicle, is classified, is obtained one by speed
Or multiple target road section, each target road section is carried out jamming analysis, determines each target road section according to the result of jamming analysis
Traffic behavior.Using the speed of vehicle and position as the object judging traffic congestion, by twice division, first carry out by speed
Dividing, reduce the quantity judging congested link vehicle, the result opsition dependent again divided further according to speed divides, and decreases judgement
The quantity of congested link, by progressively reducing the scope of detection object, not only reduces cost and the data of detection traffic behavior
Treating capacity, also improves the precision of detection.
Accompanying drawing explanation
Fig. 1 is the flow chart of steps of a kind of Traffic State Detection Method that the embodiment of the present invention one provides;
Fig. 2 is the flow chart of steps of a kind of Traffic State Detection Method that the embodiment of the present invention two provides;
Fig. 3 is the structured flowchart of a kind of traffic condition detection device that the embodiment of the present invention three provides;
Fig. 4 is the structured flowchart of a kind of traffic condition detection device that the embodiment of the present invention four provides;
Fig. 5 is the structured flowchart of a kind of traffic condition detection equipment that the embodiment of the present invention five provides.
Detailed description of the invention
(label identical in some accompanying drawings represent identical element) and embodiment below in conjunction with the accompanying drawings, implements the present invention
The detailed description of the invention of example is described in further detail.Following example are used for illustrating the embodiment of the present invention, but are not limited to
The scope of the embodiment of the present invention.
It will be understood by those skilled in the art that terms such as " first ", " second " in the embodiment of the present invention is only used for difference
Different step, equipment or module etc., neither represent any particular technology implication, also do not indicate that the inevitable logic between them is suitable
Sequence.
Server during the Traffic State Detection Method that the embodiment of the present invention provides can be networked by car performs, it is also possible to by
Performing with the vehicle arrangement processing function, this is not especially limited by the embodiment of the present invention, for making the embodiment of the present invention describe
Unified, the embodiment of the present invention all car is networked in server as executive agent.
Embodiment one
With reference to Fig. 1, it is shown that the flow chart of steps of a kind of Traffic State Detection Method that the embodiment of the present invention one provides.
The Traffic State Detection Method of the present embodiment specifically may include steps of:
Step 102, the velocity information obtaining vehicle and positional information.
Server in car networking obtains the velocity information of vehicle and positional information, velocity information and positional information can be by
Vehicle actively sends to server, also has and is obtained according to GPS information by server;Wherein, the note in vehicle is included in car networking
Volume vehicle.It addition, CAN (the Controller Area that the velocity information of vehicle can also be reported according to vehicle by server
Network, controller local area network) bus data acquisition.
Step 104, velocity information according to vehicle, determine that speed is less than the target vehicle of threshold speed.
Velocity information according to vehicle and threshold speed, classify vehicle, determines that car speed is less than threshold speed
Vehicle, and using car speed less than the vehicle of threshold speed as target vehicle.
Step 106, positional information according to target vehicle, classify to target vehicle, obtain one or more target
Section.
Speed less than threshold speed vehicle by include many target vehicles (wherein, many include two and two with
On), according to the positional information of target vehicle, according to preset position mode classification, target vehicle is carried out position classification, determine
Section, target vehicle place, i.e. can get multiple target road section according to multiple sections at target vehicle place.Wherein, a kind of feasible
Position mode classification may include that adjacent target vehicle distances is divided into less than the vehicle of certain distance threshold value be in same
The vehicle of position, e.g., distance threshold is 1.5 meters.
Step 108, each target road section is carried out jamming analysis, determine each target road section according to the result of jamming analysis
Traffic behavior.
After target road section determines, each target road section is carried out jamming analysis.Wherein, jamming analysis can include but not
It is limited to: determine whether to belong to traffic congestion according to the quantity of target vehicle in each target road section, or according in each mesh section
View data determine whether to belong to traffic congestion.After jamming analysis determines which target road section belongs to traffic congestion, at general
Traffic behavior in the target road section of traffic congestion changes to congestion status.
The embodiment of the present invention, by obtaining velocity information and the positional information of vehicle, according to the velocity information of vehicle, determines
Target vehicle, less than the target vehicle of threshold speed, according to the positional information of target vehicle, is classified, is obtained one by speed
Or multiple target road section, each target road section is carried out jamming analysis, determines each target road section according to the result of jamming analysis
Traffic behavior.Using the speed of vehicle and position as the object judging traffic congestion, by twice division, first carry out by speed
Dividing, reduce the quantity judging congested link vehicle, the result opsition dependent again divided further according to speed divides, and decreases judgement
The quantity of congested link, by progressively reducing the scope of detection object, not only reduces cost and the data of detection traffic behavior
Treating capacity the most progressively reduces the scope of monitoring object, not only reduces the cost of detection traffic behavior, also improves detection
Precision.
Embodiment two
With reference to Fig. 2, it is shown that the flow chart of steps of a kind of Traffic State Detection Method that the embodiment of the present invention two provides, tool
Body may include steps of:
Step 202, the velocity information obtaining vehicle and positional information.
The traffic behavior at multiple crossings in one road can only be detected by the embodiment of the present invention, it is also possible to the most right
The traffic behavior of a plurality of road detects, and for simplicity of description, the embodiment of the present invention is with to the multiple crossings in a road
Traffic condition detection as a example by be introduced.
Server in car networking obtains velocity information and the positional information of vehicle, and vehicle can pass through CAN
(Controller Area Network, controller local area network) bus obtains the velocity information of vehicle, obtains car by GPS
Positional information.Again velocity information and the positional information of vehicle are sent to the server in car networking.Or, in car networking
Server can obtain the velocity information of vehicle and positional information in car networking by GPS information.
Step 204, velocity information according to vehicle, cluster the speed of vehicle, it is thus achieved that multiple speed are grouped.
Step 206, by speed less than threshold speed speed packet in vehicle, be defined as target vehicle.
In the embodiment of the present invention, vehicle is classified, in reality by velocity information and positional information according to vehicle respectively
In application, those skilled in the art can use the mode classification that any one is suitable, and this is not made specifically by the embodiment of the present invention
Limit, in the present embodiment, use the mode clustered velocity information and positional information respectively to vehicle to cluster.Wherein, poly-
The set of physics or abstract object, based on similarity, is grouped into the multiple classes being made up of the object being similar to by alanysis.Tool
The cluster process of body can be realized by multiple feasible pattern, e.g., can use K-MEANS algorithm, K-MEDOIDS algorithm or
CLARANS algorithm realizes.Following condition is met: (1) each packet is including at least one by the packet obtained after cluster
Data record;(2) each data record belongs to and only belongs to a packet.
In embodiments of the present invention for reducing the complexity calculated, increase the precision of detection, use first to velocity information
Cluster, then the mode that positional information is clustered.
According to the velocity information of vehicle in car networking, the velocity information of vehicle is carried out cluster analysis, by the speed of vehicle
Information is divided into the packet of multiple speed, and wherein, the packet of multiple speed can include 0-1m/s, 1-2m/s, 2-5m/s etc..
Preset a threshold speed in embodiments of the present invention, such as 5m/s, car speed is less than threshold speed
Vehicle in speed packet is defined as target vehicle, and wherein, target vehicle includes many.
Step 208, positional information according to target vehicle, cluster the position of target vehicle.
Step 210, according to cluster result, obtain one or more target road section.
According to the positional information of car networking internal object vehicle, the positional information of target vehicle is carried out cluster analysis, wherein,
Cluster analysis can include that adjacent target vehicle distances is divided into, less than the vehicle of certain distance threshold value, the car being in same position
, such as 1.5 meters, the position of target vehicle is divided into one or more region, according to obtain according to the result of cluster analysis
Region determine correspondence one or more target road section, e.g., road A, have 20 sections of A1-A20, through analyze section A4, A5,
A6 is target road section.
In the optional mode of one of the embodiment of the present invention, can be using the data of vehicle in target road section as judging traffic
The object of state, specifically may include that setting one amount threshold, after determining one or more target road section, obtains each mesh
The quantity of target vehicle in mark section, by the quantity of target vehicle in each target road section is compared with amount threshold,
When the quantity of target vehicle is less than amount threshold, it is determined that this target road section is not belonging to traffic congestion;Number when target vehicle
When amount is more than amount threshold, it is determined that this target road section belongs to traffic congestion.Such as, amount threshold can be 20.
In embodiments of the present invention, i.e. can determine whether whether this target road section is sent out by the quantity of target vehicle in target road section
Raw traffic congestion, but for allowing to more accurately judge whether this target road section gets congestion, by obtaining in current goal section
Road conditions view data determine whether the traffic behavior of this target road section, specifically can refer to step 212-step 218.
Wherein it is desired to explanation is that step 212-step 218 is optional step, as above, in actual applications, it is also possible to
Determine the traffic behavior of target road section otherwise.
Step 212, target vehicle in each target road section send data acquisition instruction.
In a kind of alternative of the embodiment of the present invention, for increasing the precision of detection, by the picture number of target road section
According to as judging whether this target road section belongs to the object of traffic congestion, the server in car networking is in each target road section
Target vehicle sends data acquisition instruction, and wherein, data acquisition instruction uploads the road conditions image of collection for indicating target vehicle
Data.
The road conditions view data that step 214, reception target vehicle are uploaded.
Target vehicle instructs to take pictures target vehicle front road conditions according to data acquisition and obtains the image of front road conditions
Data, and the view data of acquisition rear road conditions that rear road conditions are taken pictures;The view data of front road conditions that will obtain
Upload with the view data of the rear road conditions server in vehicle net, so that server receives the road conditions figure that target vehicle is uploaded
As data.
It should be noted that in the alternative dispensing means of the embodiment of the present invention, it is also possible on the road of the both sides of road
Installing photographic head on mark post or red street lamp road sign bar, be open to traffic the server controls photographic head in networking, claps and takes current goal section
View data, such as panoramic picture etc., and then determine the traffic behavior of target road section according to this panoramic picture.
Step 216, judge whether at least one target road section gets congestion according to the road conditions view data of each target road section,
When judging that at least one target road section gets congestion, then perform step 218, otherwise process ends.
In embodiments of the present invention according to the label of target road section, successively the road conditions view data of each target road section is entered
Row is analyzed, it is determined that when whether at least one target road section gets congestion, and performs step 218;If target road section is A4, A5, A6, the most right
Target road section A4 is analyzed, and obtains the road conditions view data that in target road section A4, all target vehicles are uploaded, determines target road
Section A4 is in the target vehicle of original position and be in the target vehicle of end position, according to the target vehicle of original position and
The position of the target vehicle of end position determines the traffic congestion distance of target road section A4, such as 100m, more successively from the mesh of original position
The road conditions analysis of image data that mark vehicle is uploaded, determines whether target road section A4 has vehicle accident to occur.
Predetermined standard of blocking up can also be set in embodiments of the present invention, such as target road section distance gathering around for non-less than 10m
Stifled section (may be for waiting road green light), and for example, generation vehicle accident for congested link in target road section.
Step 218, the traffic behavior of the target road section got congestion is set as congestion status.
The traffic behavior determining the target road section that traffic congestion occurs is set as congestion status, in the embodiment of the present invention
In a kind of optional mode, the information being in the target road section of congestion status is sent to the vehicle in car networking, to point out user
Make the adjustment of corresponding drive route.
The embodiment of the present invention is by obtaining velocity information and the positional information of vehicle, according to the velocity information of vehicle, to car
Speed cluster, it is thus achieved that multiple speed be grouped, by speed less than threshold speed speed packet in vehicle, be defined as
Target vehicle, according to the positional information of target vehicle, clusters the position of target vehicle, according to cluster result, obtains one
Individual or multiple target road section, the target vehicle in each target road section sends data acquisition instruction, receives target vehicle and uploads
Road conditions view data, judge whether each target road section gets congestion according to the road conditions view data of each target road section, will
The traffic behavior of the target road section got congestion is set as congestion status.Using the speed of vehicle and position as judging traffic congestion
Object, by twice division, first divide by speed, reduce the quantity judging congested link vehicle, further according to speed
The result opsition dependent again divided divides, and decreases the quantity judging congested link, by progressively reducing the scope of detection object, no
Only reduce cost and the data processing amount of detection traffic behavior, also improve the precision of detection.
It will be understood by those skilled in the art that in the said method of embodiment of the present invention detailed description of the invention, each step
Sequence number size be not meant to the priority of execution sequence, the execution sequence of each step should determine with its function and internal logic,
And the implementation process of embodiment of the present invention detailed description of the invention should not constituted any restriction.
Embodiment three
With reference to Fig. 3, it is shown that the structured flowchart of a kind of traffic condition detection device that the embodiment of the present invention three provides;Specifically
Can include such as lower module:
Acquisition module 302, for obtaining velocity information and the positional information of vehicle.
Speed divides module 304, for the velocity information according to vehicle, determines that speed is less than the target carriage of threshold speed
?.
Position divides module 306, for the positional information according to target vehicle, classifies target vehicle, obtains one
Individual or multiple target road section.
State determining module 308, for each target road section is carried out jamming analysis, determines according to the result of jamming analysis
The traffic behavior of each target road section.
The embodiment of the present invention, by obtaining velocity information and the positional information of vehicle, according to the velocity information of vehicle, determines
Target vehicle, less than the target vehicle of threshold speed, according to the positional information of target vehicle, is classified, is obtained one by speed
Or multiple target road section, each target road section is carried out jamming analysis, determines each target road section according to the result of jamming analysis
Traffic behavior.Using the speed of vehicle and position as the object judging traffic congestion, by twice division, first carry out by speed
Dividing, reduce the quantity judging congested link vehicle, the result opsition dependent again divided further according to speed divides, and decreases judgement
The quantity of congested link, by progressively reducing the scope of detection object, not only reduces cost and the data of detection traffic behavior
Treating capacity, also improves the precision of detection.
Embodiment four
With reference to Fig. 4, it is shown that the structured flowchart of a kind of traffic condition detection device that the embodiment of the present invention four provides, specifically
Can include such as lower module:
Acquisition module 302, for obtaining velocity information and the positional information of vehicle.
Speed divides module 304, for the velocity information according to vehicle, clusters the speed of vehicle, it is thus achieved that multiple
Speed is grouped;By speed less than the vehicle in the speed packet of threshold speed, it is defined as target vehicle.
Position divides module 306, for the positional information according to target vehicle, clusters the position of target vehicle;
According to cluster result, obtain one or more target road section.
State determining module 308, including: instruction sends submodule 3082, for the target carriage in each target road section
Sending data acquisition instruction, wherein, data acquisition instruction uploads the road conditions view data of collection for indicating target vehicle;Connect
Receive submodule 3084, for receiving the road conditions view data that target vehicle is uploaded;Judge submodule 3086, for according to each mesh
The road conditions view data in mark section judges whether at least one target road section gets congestion;State sets submodule 3088, for working as
Judge when at least one target road section gets congestion, then the traffic behavior of the target road section got congestion to be set as congestion status.
Wherein, receive submodule 3084, for receiving vehicle front road conditions view data and the vehicle that target vehicle is uploaded
Rear road conditions view data.
The Vehicle Detection device of the embodiment of the present invention is by obtaining velocity information and the positional information of vehicle, according to vehicle
Velocity information, clusters the speed of vehicle, it is thus achieved that multiple speed are grouped, by speed less than in the speed packet of threshold speed
Vehicle, be defined as target vehicle, according to the positional information of target vehicle, the position of target vehicle clustered, according to poly-
Class result, obtains one or more target road section, and the target vehicle in each target road section sends data acquisition instruction, receives
Whether the road conditions view data that target vehicle is uploaded, judge each target road section according to the road conditions view data of each target road section
Get congestion, the traffic behavior of the target road section got congestion is set as congestion status.Using the speed of vehicle and position as
Judge the object of traffic congestion, by twice division, first divide by speed, reduce the number judging congested link vehicle
Amount, the result opsition dependent again divided further according to speed divides, and decreases the quantity judging congested link, by progressively reducing detection
The scope of object, not only reduces cost and the data processing amount of detection traffic behavior, also improves the precision of detection.
Embodiment five
The embodiment of the present invention five additionally provides a kind of traffic condition detection equipment 500, and the embodiment of the present invention is not to traffic
Implementing of condition detecting device 500 limits.As it is shown in figure 5, this traffic condition detection equipment 500 may include that
Processor (processor) 502, communication interface (Communications Interface) 504, memorizer
(memory) 506 and communication bus 508.Wherein:
Processor 502, communication interface 504 and memorizer 506 complete mutual communication by communication bus 508.
Communication interface 504, for the communication between vehicle and server.
Processor 502, is used for the program that performs 510, specifically can perform the correlation step in said method embodiment.
Specifically, program 510 can include program code, and program code includes computer-managed instruction.
Processor 502 is probably a central processor CPU, or specific integrated circuit ASIC (Application
Specific Integrated Circuit), or it is configured to implement the one or more integrated electricity of the embodiment of the present invention
Road.
Memorizer 506, is used for program of depositing 510.Memorizer 506 may comprise high-speed RAM memorizer, it is also possible to also includes
Nonvolatile memory (non-volatile memory), for example, at least one disk memory.Program 510 specifically can be used
Following operation is performed: obtain velocity information and the positional information of vehicle in making processor 502;According to the velocity information of vehicle,
Determine that speed is less than the target vehicle of threshold speed;According to the positional information of target vehicle, target vehicle is classified, obtain
One or more target road section;Each target road section is carried out jamming analysis, determines each target according to the result of jamming analysis
The traffic behavior in section.
In the optional embodiment of one, program 510 is additionally operable to so that the processor 502 mesh in each target road section
Mark vehicle sends data acquisition instruction, and wherein, data acquisition instruction uploads the road conditions picture number of collection for indicating target vehicle
According to;Receive the road conditions view data that target vehicle is uploaded;Road conditions view data according to each target road section judges at least one mesh
Whether mark section gets congestion;When judging that at least one target road section gets congestion, then the friendship of target road section that will get congestion
Logical state is set as congestion status.
In the optional embodiment of one, program 510 is additionally operable to so that processor 502 receives the car that target vehicle is uploaded
Front road conditions view data and rear view of vehicle road conditions view data.
In the optional embodiment of one, program 510 is additionally operable to so that processor 502 is believed according to the position of target vehicle
Breath, clusters the position of target vehicle;According to cluster result, obtain one or more target road section.
In the optional embodiment of one, program 510 is additionally operable to so that processor 502 is according to the velocity information of vehicle,
The speed of vehicle is clustered, it is thus achieved that multiple speed are grouped;By speed less than the vehicle in the speed packet of threshold speed, really
It is set to target vehicle.
Should be understood that the equipment 500 provided according to embodiments of the present invention can realize the corresponding of each method in Fig. 1 to Fig. 2
Flow process, for sake of simplicity, do not repeat them here, the associated description in said method embodiment is also applied for the present embodiment.
In program 510, each step implements correspondence in the corresponding steps and module that may refer in above-described embodiment
Describe, be not repeated herein.Those skilled in the art is it can be understood that arrive, and for convenience and simplicity of description, above-mentioned retouches
The equipment stated and the specific works process of module, the corresponding process being referred in preceding method embodiment describes, at this no longer
Repeat.
The Vehicle Detection device of the embodiment of the present invention is by obtaining velocity information and the positional information of vehicle, according to vehicle
Velocity information, clusters the speed of vehicle, it is thus achieved that multiple speed are grouped, by speed less than in the speed packet of threshold speed
Vehicle, be defined as target vehicle, according to the positional information of target vehicle, the position of target vehicle clustered, according to poly-
Class result, obtains one or more target road section, and the target vehicle in each target road section sends data acquisition instruction, receives
Whether the road conditions view data that target vehicle is uploaded, judge each target road section according to the road conditions view data of each target road section
Get congestion, the traffic behavior of the target road section got congestion is set as congestion status.Using the speed of vehicle and position as
Judge the object of traffic congestion, by twice division, first divide by speed, reduce the number judging congested link vehicle
Amount, the result opsition dependent again divided further according to speed divides, and decreases the quantity judging congested link, by progressively reducing detection
The scope of object, not only reduces cost and the data processing amount of detection traffic behavior, also improves the precision of detection.
Those of ordinary skill in the art are it is to be appreciated that combine the list of each example that the embodiments described herein describes
Unit and method step, it is possible to being implemented in combination in of electronic hardware or computer software and electronic hardware.These functions are actually
Perform with hardware or software mode, depend on application-specific and the design constraint of technical scheme.Professional and technical personnel
Each specifically should being used for can be used different methods to realize described function, but this realization is it is not considered that exceed
The scope of the embodiment of the present invention.
If function is using the form realization of SFU software functional unit and as independent production marketing or use, can store
In a computer read/write memory medium.Based on such understanding, the technical scheme of the embodiment of the present invention substantially or
Say that the part of part or this technical scheme contributing prior art can embody with the form of software product, should
Computer software product is stored in a storage medium, including some instructions with so that a computer equipment (can be
Personal computer, server, or the network equipment etc.) perform embodiment of the present invention method all or part of step.And it is aforementioned
Storage medium include: USB flash disk, portable hard drive, read only memory (ROM, Read-Only Memory), random access memory
The various media that can store program code such as (RAM, Random Access Memory), magnetic disc or CD.
Embodiment of above is merely to illustrate the embodiment of the present invention, and not restriction to the embodiment of the present invention, relevant skill
The those of ordinary skill in art field, in the case of without departing from the spirit and scope of the embodiment of the present invention, it is also possible to make various
Change and modification, the technical scheme of the most all equivalents falls within the category of the embodiment of the present invention, the patent of the embodiment of the present invention
Protection domain should be defined by the claims.