Bidirectional traffic flow identification method and device based on target detection and tracking algorithm

By applying a two-way traffic identification method based on target detection and tracking algorithms in road traffic management, the problem of difficulty in accurately identifying two-way traffic in the existing technology is solved, and efficient and real-time traffic identification and statistics are achieved.

CN119445832AActive Publication Date: 2025-02-14GUANGZHOU DESAY SV INTELLIGENT TRANSPORTATION TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202411392269.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-30
Publication Date
2025-02-14
Estimated Expiration
2044-09-30

AI Technical Summary

Technical Problem

The prior art is difficult to accurately and efficiently identify road bidirectional traffic flow, and the existing one-way traffic flow recognition methods are sensitive to noise and outliers, or the vehicle recognition accuracy and efficiency are low.

Method used

A two-way traffic recognition method based on target detection and tracking algorithm is adopted to analyze the road section images and obtain vehicle object information through the target detection model, and a tracking algorithm model is used to track the vehicle to determine its passing status, thereby calculating the traffic result.

Benefits of technology

It improves the accuracy and efficiency of two-way traffic identification, can detect and count road traffic in real time and accurately, and reduces the sensitivity to noise and outliers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119445832A_ABST
    Figure CN119445832A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of traffic flow detection, and discloses a bidirectional traffic flow identification method and device based on a target detection and tracking algorithm, and the method comprises the steps: a current road image comprises one or more target vehicle objects; inputting the current road section image into a target detection model for analysis to obtain object information of a target vehicle object, and inputting the object information into a tracking algorithm model for analysis to obtain a tracking serial number of the target vehicle object; determining a passing state result of each target vehicle object according to the object information of each target vehicle object, the tracking sequence number and the traffic data set; and determining a traffic flow result according to the traffic state results of the identified vehicle objects in the traffic data set, all the identified vehicle objects including the target vehicle object. Therefore, the accuracy, reliability, determination efficiency and determination convenience of the determined traffic flow result can be improved, so that the traffic flow recognition accuracy, efficiency and timeliness of the target road section are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle flow detection, and in particular to a method and device for identifying bidirectional vehicle flow based on target detection and tracking algorithms. Background Art

[0002] With the acceleration of urbanization and the continuous improvement of transportation infrastructure, road traffic flow has increased dramatically, which has put forward higher requirements for traffic management and planning. Among them, vehicle flow identification, as an important link in traffic management, plays an important role in alleviating traffic congestion, optimizing the allocation of road resources and ensuring traffic safety.

[0003] At present, the road traffic flow identification method is mostly to provide one-way traffic flow data, which cannot accurately reflect the two-way traffic conditions of the road. In addition, the existing one-way traffic flow data determination method is generally based on the long short-term memory network (LSTM) traffic flow prediction method or the millimeter wave radar based traffic flow detection method. Among them, the traffic flow prediction method based on the long short-term memory network is used to capture the time dependency in the traffic flow data to realize the prediction of traffic flow. It is sensitive to noise and outliers, and the traffic flow data is difficult to label. It needs to rely on a large amount of training data and cannot realize the real-time detection of traffic flow. The traffic flow detection method based on the millimeter wave radar uses the millimeter wave radar to detect the vehicle speed and other information to realize the detection of traffic flow. However, the millimeter wave radar has a high requirement for the reflectivity of the target object, and the vehicle recognition accuracy and efficiency are low. Therefore, it is particularly important to provide a new two-way traffic flow identification method to improve the recognition accuracy and efficiency of two-way traffic flow. Summary of the invention

[0004] The present invention provides a two-way vehicle flow recognition method and device based on target detection and tracking algorithm, which can improve the recognition accuracy and recognition efficiency of two-way vehicle flow.

[0005] In order to solve the above technical problems, the first aspect of the present invention discloses a method for identifying bidirectional vehicle flow based on a target detection and tracking algorithm, the method comprising:

[0006] Determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects;

[0007] Inputting the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, and inputting the object information of each target vehicle object into a converged tracking algorithm model for analysis to obtain a tracking sequence number of each target vehicle object;

[0008] Determine the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section;

[0009] The traffic flow result of the target road section within the target time is determined according to the traffic status result of each identified vehicle object in the traffic data set, and all the identified vehicle objects include the target vehicle object.

[0010] As an optional implementation, in the first aspect of the present invention, the object information of the target vehicle object at least includes positioning frame coordinate information, confidence information and object category information of the target vehicle object;

[0011] And, determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section includes:

[0012] Determine the tracking number of each identified vehicle object in the traffic data set according to the determined traffic data set corresponding to the target road section;

[0013] For each of the target vehicle objects, judging whether the target vehicle object meets a preset identification condition according to the tracking numbers of all the identified vehicle objects and the tracking number of the target vehicle object;

[0014] When it is determined that the target vehicle object meets the identified condition, the traffic status result of the target vehicle object is determined according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information;

[0015] When it is determined that the target vehicle object does not meet the identified conditions, the corresponding element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number corresponding to the target vehicle object, and the set basic traffic status result, and the traffic status result of the target vehicle object is determined.

[0016] As an optional implementation, in the first aspect of the present invention, the determining of the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information includes:

[0017] Determine a first ordinate value according to the determined current center point coordinate information corresponding to the target vehicle object, determine a second ordinate value according to the previous center point coordinate information corresponding to the target vehicle object, and determine a reference ordinate value according to the preset vehicle flow reference line coordinate information;

[0018] Determine the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value; the traffic state type includes one of an up state type, a down state type and other state types;

[0019] Determine the traffic status result of the target vehicle object according to the traffic status type;

[0020] And, determining the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value includes:

[0021] When the first ordinate value is greater than the second ordinate value and the first ordinate value is greater than the reference ordinate value, determining that the traffic state type of the target vehicle object is a down state type;

[0022] When the first ordinate value is smaller than the second ordinate value and the first ordinate value is smaller than the reference ordinate value, it is determined that the traffic state type of the target vehicle object is an upward state type.

[0023] As an optional implementation, in the first aspect of the present invention, determining the traffic flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set includes:

[0024] When the traffic flow identification requirement type of the target road section is a two-way traffic flow identification type, according to the determined target traffic state information requiring two-way traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set, a first target object that meets a preset traffic state matching condition is determined from all the identified vehicle objects; the number of first vehicles corresponding to all the first target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the first number of vehicles;

[0025] When the traffic flow identification requirement type of the target road section is an exclusive category traffic flow identification type, based on the determined target vehicle category that requires targeted traffic flow identification and the object category information of each identified vehicle object in the traffic data set, a second target object that meets the preset vehicle category matching condition is determined from all the identified vehicle objects; the number of second vehicles corresponding to all the second target objects is calculated; and based on the second number of vehicles, the traffic flow result of the target road section within the target time is determined.

[0026] As an optional implementation, in the first aspect of the present invention, before determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, the method further includes:

[0027] According to the current road section image, determining whether the target road section meets a preset data set establishment condition;

[0028] When it is determined that the target road section meets the data set establishment conditions, a traffic data set is established; according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, corresponding element addition and data update operations are performed on the traffic data set;

[0029] When it is determined that the target road section does not meet the data set establishment conditions, the operation of determining the traffic status result of each target vehicle object based on the object information and tracking number of each target vehicle object and the traffic data set corresponding to the target road section is performed.

[0030] As an optional implementation manner, in the first aspect of the present invention, judging whether the target road section meets a preset data set establishment condition according to the current road section image includes:

[0031] According to the historical tracking image information of the target road section, determining whether the current road section image meets the preset first frame tracking image condition;

[0032] When it is determined that the current road section image meets the first frame tracking image condition, determining that the target road section meets the preset data set establishment condition;

[0033] When it is determined that the current road section image does not meet the first frame tracking image condition, determining that the target road section does not meet the preset data set establishment condition;

[0034] And, performing corresponding element addition and data update operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, including:

[0035] Determine the center point coordinate information of each target vehicle object according to the positioning frame coordinate information included in the object information of each target vehicle object;

[0036] According to the center point coordinate information corresponding to each target vehicle object, the tracking sequence number and the object category information included in the object information, and the set basic traffic status result, corresponding element addition and data update operations are performed on the traffic data set.

[0037] As an optional implementation, in the first aspect of the present invention, before determining the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information, the method further includes:

[0038] Determine the current center point coordinate information of the target vehicle object according to the positioning frame coordinate information of the target vehicle object, and determine the previous center point coordinate information of the target vehicle object according to the traffic data set;

[0039] And, after determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, the method further includes:

[0040] According to the determined current center point coordinate information, tracking sequence number, traffic status result and object category information included in the object information corresponding to each of the target vehicle objects, a corresponding data update operation is performed on the traffic data set.

[0041] The second aspect of the present invention discloses a two-way vehicle flow recognition device based on a target detection and tracking algorithm, the device comprising:

[0042] An image determination module, used to determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects;

[0043] A vehicle tracking module, used for inputting the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, and inputting the object information of each target vehicle object into a converged tracking algorithm model for analysis to obtain a tracking sequence number of each target vehicle object;

[0044] A state determination module, used to determine the traffic state result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section;

[0045] The vehicle flow determination module is used to determine the vehicle flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set, and all the identified vehicle objects include the target vehicle object.

[0046] As an optional implementation, in the second aspect of the present invention, the object information of the target vehicle object at least includes positioning frame coordinate information, confidence information and object category information of the target vehicle object;

[0047] And, the state determination module determines the traffic state result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, specifically including:

[0048] Determine the tracking number of each identified vehicle object in the traffic data set according to the determined traffic data set corresponding to the target road section;

[0049] For each of the target vehicle objects, judging whether the target vehicle object meets a preset identification condition according to the tracking numbers of all the identified vehicle objects and the tracking number of the target vehicle object;

[0050] When it is determined that the target vehicle object meets the identified condition, the traffic status result of the target vehicle object is determined according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information;

[0051] When it is determined that the target vehicle object does not meet the identified conditions, the corresponding element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number corresponding to the target vehicle object, and the set basic traffic status result, and the traffic status result of the target vehicle object is determined.

[0052] As an optional implementation, in the second aspect of the present invention, the state determination module determines the traffic state result of the target vehicle object according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information, specifically including:

[0053] Determine a first ordinate value according to the determined current center point coordinate information corresponding to the target vehicle object, determine a second ordinate value according to the previous center point coordinate information corresponding to the target vehicle object, and determine a reference ordinate value according to the preset vehicle flow reference line coordinate information;

[0054] Determine the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value; the traffic state type includes one of an up state type, a down state type and other state types;

[0055] Determine the traffic status result of the target vehicle object according to the traffic status type;

[0056] And, the state determination module determines the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value, specifically including:

[0057] When the first ordinate value is greater than the second ordinate value and the first ordinate value is greater than the reference ordinate value, determining that the traffic state type of the target vehicle object is a down state type;

[0058] When the first ordinate value is smaller than the second ordinate value and the first ordinate value is smaller than the reference ordinate value, it is determined that the traffic state type of the target vehicle object is an upward state type.

[0059] As an optional implementation, in the second aspect of the present invention, the vehicle flow determination module determines the vehicle flow result of the target road section within the target time according to the traffic state result of each identified vehicle object in the traffic data set in a manner specifically including:

[0060] When the traffic flow identification requirement type of the target road section is a two-way traffic flow identification type, according to the determined target traffic state information requiring two-way traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set, a first target object that meets a preset traffic state matching condition is determined from all the identified vehicle objects; the number of first vehicles corresponding to all the first target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the first number of vehicles;

[0061] When the traffic flow identification requirement type of the target road section is an exclusive category traffic flow identification type, based on the determined target vehicle category that requires targeted traffic flow identification and the object category information of each identified vehicle object in the traffic data set, a second target object that meets the preset vehicle category matching condition is determined from all the identified vehicle objects; the number of second vehicles corresponding to all the second target objects is calculated; and based on the second number of vehicles, the traffic flow result of the target road section within the target time is determined.

[0062] As an optional implementation, in the second aspect of the present invention, the device further includes:

[0063] A judgment module is used to judge whether the target road section meets the preset data set establishment conditions according to the current road section image before the state determination module determines the traffic state result of each target vehicle object according to the object information and tracking number of each target vehicle object and the traffic data set corresponding to the target road section; when it is judged that the target road section does not meet the data set establishment conditions, the state determination module performs the operation of determining the traffic state result of each target vehicle object according to the object information and tracking number of each target vehicle object and the traffic data set corresponding to the target road section;

[0064] A set establishment module, used to establish a traffic data set when the determination module determines that the target road section meets the data set establishment condition;

[0065] The first set data updating module is used to perform corresponding element addition and data updating operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result.

[0066] As an optional implementation, in the second aspect of the present invention, the judgment module judges whether the target road section meets the preset data set establishment condition according to the current road section image in a manner specifically including:

[0067] According to the historical tracking image information of the target road section, determining whether the current road section image meets the preset first frame tracking image condition;

[0068] When it is determined that the current road section image meets the first frame tracking image condition, determining that the target road section meets the preset data set establishment condition;

[0069] When it is determined that the current road section image does not meet the first frame tracking image condition, determining that the target road section does not meet the preset data set establishment condition;

[0070] And, the first set data updating module performs corresponding element addition and data updating operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, specifically including:

[0071] Determine the center point coordinate information of each target vehicle object according to the positioning frame coordinate information included in the object information of each target vehicle object;

[0072] According to the center point coordinate information corresponding to each target vehicle object, the tracking sequence number and the object category information included in the object information, and the set basic traffic status result, corresponding element addition and data update operations are performed on the traffic data set.

[0073] As an optional implementation, in the second aspect of the present invention, the device further includes:

[0074] A coordinate determination module, used to determine the current center point coordinate information of the target vehicle object according to the positioning frame coordinate information of the target vehicle object, and determine the previous center point coordinate information of the target vehicle object according to the traffic data set, before the state determination module determines the traffic state result of the target vehicle object according to the current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object determined and the preset vehicle flow baseline coordinate information;

[0075] The second set data updating module is used to perform corresponding data updating operations on the traffic data set after the state determination module determines the traffic state result of each target vehicle object based on the object information and tracking number of each target vehicle object and the traffic data set corresponding to the determined target road section, based on the current center point coordinate information, tracking number, traffic state result and object category information included in the object information corresponding to each target vehicle object.

[0076] The third aspect of the present invention discloses another bidirectional vehicle flow recognition device based on target detection and tracking algorithm, the device comprising:

[0077] A memory storing executable program code;

[0078] a processor coupled to the memory;

[0079] The processor calls the executable program code stored in the memory to execute the two-way vehicle flow recognition method based on target detection and tracking algorithm disclosed in the first aspect of the present invention.

[0080] The fourth aspect of the present invention discloses a computer storage medium, which stores computer instructions. When the computer instructions are called, they are used to execute the two-way vehicle flow identification method based on target detection and tracking algorithm disclosed in the first aspect of the present invention.

[0081] Compared with the prior art, the embodiments of the present invention have the following beneficial effects:

[0082] In an embodiment of the present invention, a current road section image of a target road section for which traffic flow identification is required is determined, wherein the current road section image includes one or more target vehicle objects; the current road section image is input into a converged target detection model for analysis to obtain object information of each target vehicle object, and the object information of each target vehicle object is input into a converged tracking algorithm model for analysis to obtain a tracking number of each target vehicle object; based on the object information and tracking number of each target vehicle object and the determined traffic data set corresponding to the target road section, a traffic status result of each target vehicle object is determined; based on the traffic status result of each identified vehicle object in the traffic data set, a traffic flow result of the target road section within a target time is determined, wherein all the identified vehicle objects include the target vehicle object. It can be seen that the present invention can obtain the object information and tracking number of the target vehicle object through the target detection model and the tracking algorithm model, determine the traffic status result of the target vehicle object according to the object information and the tracking number, and then determine the traffic flow result of the target section within the target time, which is conducive to improving the comprehensiveness and rationality of the two-way traffic flow identification method, and then is conducive to improving the accuracy and reliability of the determined traffic flow results, and is also conducive to improving the determination efficiency and convenience of the traffic flow results, thereby helping to improve the accuracy, efficiency and timeliness of traffic flow identification on the target section, and further conducive to realizing real-time and low-cost detection of traffic flow on the section. BRIEF DESCRIPTION OF THE DRAWINGS

[0083] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0084] Figure 1 It is a flow chart of a two-way vehicle flow recognition method based on target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0085] Figure 2 It is a flow chart of another method for identifying bidirectional vehicle flow based on target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0086] Figure 3 It is a structural schematic diagram of a two-way vehicle flow recognition device based on a target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0087] Figure 4 It is a structural schematic diagram of another bidirectional vehicle flow recognition device based on target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0088] Figure 5 It is a structural schematic diagram of another bidirectional vehicle flow recognition device based on target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0089] Figure 6 It is a scene schematic diagram of a two-way vehicle flow recognition method based on a target detection and tracking algorithm disclosed in an embodiment of the present invention;

[0090] Figure 7 It is a flow chart of another method for identifying bidirectional vehicle flow based on target detection and tracking algorithm disclosed in an embodiment of the present invention. DETAILED DESCRIPTION

[0091] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0092] The terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish different objects rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, device, product or end including a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units inherent to these processes, methods, products or ends.

[0093] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present invention. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0094] The present invention discloses a two-way vehicle flow identification method and device based on target detection and tracking algorithm, which can obtain the object information and tracking sequence number of the target vehicle object through the target detection model and tracking algorithm model, determine the traffic state result of the target vehicle object according to the object information and tracking sequence number, and then determine the vehicle flow result of the target road section within the target time, which is conducive to improving the comprehensiveness and rationality of the two-way vehicle flow identification method, and then is conducive to improving the accuracy and reliability of the determined vehicle flow result, and is also conducive to improving the determination efficiency and convenience of the vehicle flow result, so as to improve the accuracy, efficiency and timeliness of the vehicle flow identification of the target road section, and further is conducive to realizing the real-time detection and low-cost detection of the vehicle flow of the road section. The following are detailed descriptions.

[0095] Embodiment 1

[0096] See also Figure 1 , Figure 1 is a flow chart of a two-way vehicle flow identification method based on target detection and tracking algorithm disclosed in an embodiment of the present invention. Figure 1 The described method may be applied to a bidirectional vehicle flow identification device, wherein the device may include a server, wherein the server includes a local server or a cloud server, which is not limited in the embodiment of the present invention. Figure 1 As shown, the two-way vehicle flow recognition method based on target detection and tracking algorithm includes the following operations:

[0097] 101. Determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects.

[0098] Optionally, the preliminary preparation of this solution may include but is not limited to training a target detection model based on the yolov5 target detection algorithm, and the detection objects are common motor vehicles on the road, such as cars, trucks, tank trucks, trailers, etc.; based on the on-site debugging of the camera, the vehicle flow baseline flow_line of the image is set, and the vertical coordinate of the vehicle flow baseline is recorded as flow_line_y, such as Figure 1 As shown; further, the position setting of the vehicle baseline can avoid obstructions as much as possible, such as traffic lights, telephone poles, green belts, etc., which are not limited in the embodiments of the present invention.

[0099] Optionally, the object type of the target vehicle object may include, but is not limited to, one or more of a car type, a truck type, a tanker type, a trailer type, a non-motor vehicle type, and other motor vehicle types, and is not limited in this embodiment of the present invention.

[0100] Optionally, the target vehicle object may include one or more vehicles, which is not limited in this embodiment of the present invention.

[0101] 102. Input the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, where the object information of the target vehicle object at least includes positioning frame coordinate information, confidence information, and object category information of the target vehicle object.

[0102] Optionally, the current road section image is input into a converged target detection model for analysis to obtain object information of each target vehicle object. For example: the target detection model is used to perform inference detection on each target vehicle object in the current road section image to obtain the positioning frame coordinate information, confidence information and object category information of the target vehicle object, which is not limited in the embodiments of the present invention.

[0103] Optionally, the target vehicle object may be understood as a motor vehicle object or a pedestrian object in the current road section image, etc., which is not limited in the embodiment of the present invention.

[0104] Optionally, the target detection model may be determined by first starting a target detection algorithm, and then calling the target detection model through the target detection algorithm, which is not limited in the embodiment of the present invention.

[0105] Optionally, the coordinate information of the positioning frame of the target vehicle object may include, but is not limited to, the coordinates of the upper left vertex (x l ,y l ) and the coordinates of the lower right vertex (x r ,y r ), which is not limited in the embodiments of the present invention.

[0106] Optionally, the object category information of the target vehicle object may be understood as the target category class_id of the target vehicle object, which is not limited in the embodiment of the present invention.

[0107] Optionally, the target detection model may be a yolov5 model or other models capable of realizing the target vehicle object detection function, which is not limited in the embodiment of the present invention.

[0108] Optional object category information, for example: large motor vehicles, small motor vehicles, non-motor vehicles, pedestrians, etc., is not limited in the embodiment of the present invention.

[0109] 103. Input the object information of each target vehicle object into the converged tracking algorithm model for analysis to obtain the tracking sequence number of each target vehicle object.

[0110] Optionally, the object information of each target vehicle object is input into a convergent tracking algorithm model for analysis to obtain a tracking number for each target vehicle object. For example, for each target vehicle object, the positioning frame coordinate information, confidence information and object category information of the target vehicle object are input into a convergent tracking algorithm model for analysis to obtain a tracking number for each target vehicle object. This embodiment of the present invention is not limited to this.

[0111] Further optionally, the tracking number of the target vehicle object may be understood as the tracking number track_id of the target vehicle object, which is not limited in the embodiment of the present invention.

[0112] Optionally, for the tracking number of the target vehicle object, an example is given: the tracking algorithm model will record the information of all target vehicle objects detected in the previous image (such as the positioning box coordinate information, confidence information, object category information and tracking number assigned to each target vehicle object of the target vehicle object), and use the target vehicle object information detected in the current image to match the target vehicle object information detected in the previous image. The tracking number of the target vehicle object that can be matched remains unchanged; for example, the current image detects a car A through the target detection algorithm, and it is also detected in the previous image matched through the tracking algorithm model, and the "tracking number" is 0, then the "tracking number" of the car A detected in the current image is 0, and this is not limited in the embodiments of the present invention.

[0113] Optionally, the tracking algorithm model may be a tracking algorithm API interface of ByteTrack, or other models capable of implementing the vehicle object tracking function, which is not limited in the embodiment of the present invention.

[0114] 104. Determine the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section.

[0115] Optionally, the traffic data set can be understood as a VehicleTrafficInfo queue; further, the traffic data set is used to record the traffic data of each detected vehicle object, such as the tracking number, object category, vehicle center point coordinates, vehicle traffic status results, etc. of a certain vehicle object, which is not limited in the embodiment of the present invention.

[0116] Optionally, the traffic status result can be represented by state=1, state=2, state=0, etc.; further, when the target vehicle object passes through the vehicle baseline and is in the downlink direction, its traffic status result is determined to be state=1, when the target vehicle object passes through the vehicle baseline and is in the uplink direction, its traffic status result is determined to be state=2, and when the target vehicle object is in other situations, its traffic status result is determined to be state=0, which is not limited in the embodiments of the present invention.

[0117] 105. Determine the traffic flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set, and all identified vehicle objects include the target vehicle object.

[0118] Further optionally, after determining the traffic flow result of the target road section within the target time, a data clearing operation may be performed on the traffic data set, which is not limited in the embodiment of the present invention.

[0119] Optionally, the detection results of the current frame and the previous frame image are matched through a tracking algorithm model. If the target match is successful, the tracking number remains unchanged, that is, within the same target time, a target vehicle object corresponds to an exclusive tracking number, which is not limited in the embodiment of the present invention.

[0120] Optionally, the above method determines the traffic flow result of the target road section within the target time based on the traffic status result of each identified vehicle object in the traffic data set. For example: the traffic status result of each element in the traffic data set (each element corresponds to a vehicle object) is judged to count the up and down traffic flow of all categories of motor vehicles within a unit time (such as 1 minute, etc.). The traffic flow of a single category of motor vehicles can also be counted according to the object category, which is not limited in the embodiments of the present invention.

[0121] Optionally, all identified vehicle objects in the traffic data set may include but are not limited to all target vehicle objects, which is not limited in this embodiment of the present invention.

[0122] Optionally, the difference between the identified vehicle object in the traffic data set and the target vehicle object in the aforementioned step can be understood as follows: when the tracking number of the target vehicle object does not exist in the traffic data set, a traffic data element representing the target vehicle object is added to the traffic data set and the object information and traffic status result of the target vehicle object are recorded based on the traffic data element. At this time, the target vehicle object is determined to be an identified vehicle object in the traffic data set; that is, when the tracking number of the target vehicle object does not exist in the traffic data set, it is determined that the identified vehicle objects in the traffic data set do not include the target vehicle object; when the tracking number of the target vehicle object exists in the traffic data set, it is determined that the identified vehicle objects in the traffic data set include the target vehicle object, which is not limited in the embodiments of the present invention.

[0123] Optional, such as Figure 7 As shown, the vehicle flow statistics method of this scheme can be specifically as follows: preliminary preparation, which can specifically include training the target detection model, on-site debugging of the camera, setting the vehicle flow baseline, etc.; further, collecting the current section image of the target section; further, inputting the current section image into the target detection model for analysis to obtain the object information of the target vehicle object, and the object information can specifically include the information on the left side of the positioning box, the confidence information and the object category information; further, inputting the object information of the target vehicle object into the tracking algorithm model for analysis to obtain the tracking sequence number of the target vehicle object; further, judging whether the current section image is the first frame input to the model image, if it is the first frame, then according to The tracking result information constructs a traffic data set, and performs subsequent operations based on the constructed traffic data set; if it is not the first frame, the uplink and downlink states of the target vehicle object are determined through the current tracking result corresponding to the current road section image and the determined traffic data set, and the traffic data set is updated. The tracking result information may include object information and tracking sequence number; further, it is determined whether the current moment has reached the preset traffic flow identification statistical time. If the traffic flow identification statistical time has been reached, the motor vehicle traffic flow results of the target road section within unit time are statistically calculated; if the traffic flow identification statistical time has not been reached, the road section image collection and identification of the target road section continue, which is not limited in the embodiments of the present invention.

[0124] It can be seen that the two-way traffic flow identification method based on target detection and tracking algorithm described in the embodiment of the present invention can obtain the object information and tracking number of the target vehicle object through the target detection model and the tracking algorithm model, determine the traffic status result of the target vehicle object according to the object information and tracking number, and then determine the traffic flow result of the target section within the target time, which is conducive to improving the comprehensiveness and rationality of the two-way traffic flow identification method, and then help to improve the accuracy and reliability of the determined traffic flow results, and also help to improve the determination efficiency and convenience of the traffic flow results, so as to improve the accuracy, efficiency and timeliness of traffic flow identification of the target section, and further help to realize real-time and low-cost detection of traffic flow on the section.

[0125] In an optional embodiment, the above-mentioned determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section may include:

[0126] Determine a tracking sequence number of each identified vehicle object in the traffic data set according to the determined traffic data set corresponding to the target road section;

[0127] For each target vehicle object, judging whether the target vehicle object meets a preset identification condition according to the tracking numbers of all identified vehicle objects and the tracking number of the target vehicle object;

[0128] When it is determined that the target vehicle object meets the identification conditions, the traffic status result of the target vehicle object is determined according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information;

[0129] When it is determined that the target vehicle object does not meet the identified conditions, the corresponding element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number corresponding to the target vehicle object, and the set basic traffic status result, and the traffic status result of the target vehicle object is determined.

[0130] Optionally, the above-mentioned determination of the traffic status result of the target vehicle object can refer to but is not limited to the above-mentioned specific operation steps for determining the traffic status result of each target vehicle object based on the object information and tracking number of each target vehicle object and the traffic data set corresponding to the determined target road section, and the embodiment of the present invention is not limited thereto.

[0131] Further optionally, judging whether the target vehicle object satisfies a preset identification condition based on the tracking numbers of all identified vehicle objects and the tracking number of the target vehicle object may include:

[0132] Determining whether the tracking serial numbers of all identified vehicle objects include the tracking serial number of the target vehicle object;

[0133] When it is determined that the tracking serial numbers of all the identified vehicle objects include the tracking serial number of the target vehicle object, determining that the target vehicle object meets the preset identified condition;

[0134] When it is determined that the tracking serial numbers of all the identified vehicle objects do not include the tracking serial number of the target vehicle object, it is determined that the target vehicle object does not meet the preset identification condition.

[0135] Optionally, the current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object can be understood as: the current center point coordinate information is the center point coordinate information of the target vehicle object obtained through the currently input road section image (current frame); the previous center point coordinate information is the center point coordinate information of the target vehicle object obtained through the last input road section image (previous frame), which is not limited in the embodiment of the present invention.

[0136] Further optionally, the above-mentioned method judges whether the target vehicle object meets the preset identification condition based on the tracking numbers of all identified vehicle objects and the tracking number of the target vehicle object. For example: using the current tracking result information and the traffic data set corresponding to the previous frame of the road section image, it is judged whether the tracking number of the target vehicle object (current) is consistent with the tracking number in the traffic data set (previous frame). If they are consistent, it is determined that the target vehicle object meets the identification condition; if they are inconsistent, it is determined that the target vehicle object does not meet the identification condition. The embodiment of the present invention is not limited to this.

[0137] Optionally, the above-mentioned element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number, and the set basic traffic status result corresponding to the target vehicle object. For example: a new exclusive traffic data element for the target vehicle object is added to the traffic data set to record the center point coordinate information, object category information and tracking number, and traffic status result information of the target vehicle object. Further, the center point coordinate information is determined by the positioning frame coordinate information; further, a new exclusive traffic data element for the target vehicle object is added. For example: whenever a new target vehicle object appears, a VehicleTrafficInfo variable is added to the traffic data set, and an element is added to the traffic data set to represent the target vehicle object. The embodiment of the present invention is not limited to this.

[0138] Optionally, the set basic traffic state result can be understood as the traffic state result defaulting to state=0, which is used to indicate that it has not yet been determined whether the target vehicle object is going up or down, and the embodiment of the present invention does not limit this.

[0139] It can be seen that this optional embodiment can match the corresponding traffic status result determination operations according to the results of the identified conditions of the target vehicle object, which is conducive to improving the comprehensiveness, integrity and rationality of the traffic status result determination method, and thus is conducive to improving the diversity and flexibility of the traffic status result determination method, so as to improve the accuracy and reliability of the determined traffic status results, and also to improve the execution accuracy and execution rationality of the traffic status determination operation. In addition, it also provides a method for adding elements to the traffic data set and updating data, which is conducive to improving the comprehensiveness and rationality of the method for adding elements to the traffic data set and updating data, and thus is conducive to improving the data update accuracy, timeliness and efficiency of the traffic data set, so as to improve the data accuracy and completeness of the traffic data set, and further to improve the accuracy and reliability of the traffic status results and traffic flow results subsequently determined based on the traffic data set.

[0140] In another optional embodiment, the above-mentioned determining the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information may include:

[0141] Determine a first ordinate value according to the determined current center point coordinate information corresponding to the target vehicle object, determine a second ordinate value according to the previous center point coordinate information corresponding to the target vehicle object, and determine a reference ordinate value according to the preset vehicle flow reference line coordinate information;

[0142] Determine the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value; the traffic state type includes one of an upward state type, a downward state type and other state types;

[0143] According to the traffic state type, the traffic state result of the target vehicle object is determined.

[0144] Optionally, the traffic state type includes an upward state type, which can be understood as the target vehicle object passing through the vehicle baseline and being in an upward state, which is not limited in the embodiment of the present invention.

[0145] Optionally, the traffic status type includes a downlink status type, which can be understood as the target vehicle object passing through the vehicle baseline and being in a downlink status, which is not limited in the embodiment of the present invention.

[0146] Further optionally, the above-mentioned determining the traffic state result of the target vehicle object according to the traffic state type may include:

[0147] When the traffic state type includes an up state type, determining the traffic state result of the target vehicle object is state=2;

[0148] When the traffic state type includes a downlink state type, determining the traffic state result of the target vehicle object is state=1;

[0149] When the traffic state type includes other state types, the traffic state result of the target vehicle object is determined to be state=0.

[0150] Optionally, when it is not determined that the target vehicle object is an uplink state type or a downlink state type, the default traffic state result is state=0, that is, the traffic state type is other state types; when it is determined that the target vehicle object is not an uplink state type or a downlink state type, the traffic state result is determined to be state=0, which is not limited in this embodiment of the present invention.

[0151] It can be seen that this optional embodiment can determine the corresponding vertical coordinate value through the current center point coordinate information, the previous center point coordinate information and the vehicle flow baseline coordinate information, and then determine the traffic state type of the target vehicle object, and determine the traffic state result according to the traffic state type, which is conducive to improving the comprehensiveness and rationality of the traffic state result determination method, and then is conducive to improving the diversity, pertinence and rationality of the determination parameters used to determine the traffic state results, so as to improve the accuracy and reliability of the determined traffic state results.

[0152] In yet another optional embodiment, the determining of the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value may include:

[0153] When the first ordinate value is greater than the second ordinate value and the first ordinate value is greater than the reference ordinate value, determining that the traffic state type of the target vehicle object is a down state type;

[0154] When the first ordinate value is less than the second ordinate value and the first ordinate value is less than the reference ordinate value, it is determined that the traffic state type of the target vehicle object is an upward state type.

[0155] It can be seen that this optional embodiment can determine the traffic state type of the target vehicle object through the comparison relationship between the first ordinate value and the second ordinate value and the comparison relationship between the first ordinate value and the reference ordinate value, which is beneficial to improving the comprehensiveness, integrity and rationality of the traffic state type determination method, and further helps to improve the accuracy and reliability of the determined traffic state type.

[0156] In yet another optional embodiment, the above-mentioned determining the traffic flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set may include:

[0157] When the traffic flow identification requirement type of the target road section is a two-way traffic flow identification type, according to the determined target traffic state information requiring two-way traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set, a first target object that meets the preset traffic state matching condition is determined from all identified vehicle objects; the number of first vehicles corresponding to all first target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the number of first vehicles;

[0158] When the traffic flow identification requirement type of the target road section is an exclusive category traffic flow identification type, according to the determined target vehicle category that requires targeted traffic flow identification and the object category information of each identified vehicle object in the traffic data set, a second target object that meets the preset vehicle category matching condition is determined from all identified vehicle objects; the number of second vehicles corresponding to all second target objects is calculated; and based on the number of second vehicles, the traffic flow result of the target road section within the target time is determined.

[0159] Optionally, the target traffic state information required for two-way traffic flow identification may be understood as traffic state results of state=1 and state=2, which is not limited in the embodiment of the present invention.

[0160] Further optionally, the above-mentioned determining the first target object satisfying the preset traffic state matching condition from all the identified vehicle objects may include:

[0161] A target identified vehicle object whose traffic state result is state=1 or state=2 is determined from all identified vehicle objects as a first target object that meets a preset traffic state matching condition.

[0162] Optionally, the object category information may be represented by class_id=0 for a small car and class_id=1 for a large car, or may be represented by other forms, which are not limited in the embodiment of the present invention.

[0163] Further optionally, the above-mentioned determining the second target object satisfying the preset vehicle category matching condition from all the identified vehicle objects may include:

[0164] A target identified vehicle object whose vehicle category matches the target vehicle category is determined from all identified vehicle objects as a second target object that meets a preset vehicle category matching condition.

[0165] Further optionally, a method for statistically analyzing the traffic flow of a single vehicle category is illustrated by way of example: all identified vehicle objects are screened for traffic status conditions, and further, the identified vehicle objects that meet the traffic status conditions are screened for vehicle category conditions to obtain traffic flow statistics results for a single vehicle category, which is not limited in the embodiments of the present invention.

[0166] Further optional, it may also include:

[0167] When the traffic flow identification requirement type of the target road section is the category and direction traffic flow identification type, a third target object that meets the preset specific direction traffic state matching condition is determined from all identified vehicle objects according to the determined second target traffic state information that requires specific direction traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set; a fourth target object that meets the preset second vehicle category matching condition is determined from all third target objects according to the determined target vehicle category that requires targeted traffic flow identification and the object category information of each third target object; the number of third vehicles corresponding to all fourth target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the number of third vehicles.

[0168] It can be seen that this optional embodiment can match the corresponding traffic flow result determination method for the two-way traffic flow identification type and the exclusive category traffic flow identification type respectively, which is conducive to improving the comprehensiveness, integrity and rationality of the traffic flow result determination method, and further conducive to improving the pertinence, diversity and flexibility of the traffic flow result determination method, thereby helping to improve the accuracy and reliability of the determined traffic flow results.

[0169] In another optional embodiment, before determining the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information, the method may further include the following operations:

[0170] According to the positioning frame coordinate information of the target vehicle object, the current center point coordinate information of the target vehicle object is determined, and according to the traffic data set, the previous center point coordinate information of the target vehicle object is determined.

[0171] Further optionally, the determining the current center point coordinate information of the target vehicle object according to the positioning frame coordinate information of the target vehicle object may include:

[0172] According to the positioning frame coordinate information of the target vehicle object, determine the upper left horizontal coordinate value, the upper left vertical coordinate value, the lower right horizontal coordinate value and the lower right vertical coordinate value of the positioning frame of the target vehicle object;

[0173] Calculate a first difference (absolute value) between the upper left horizontal coordinate value and the lower right horizontal coordinate value, calculate a first average value corresponding to the first difference, calculate a first addition value corresponding to the upper left horizontal coordinate value and the first average value, and determine the first addition value as the horizontal coordinate value of the current center point;

[0174] Calculate the second difference (absolute value) corresponding to the upper left ordinate value and the lower right ordinate value, calculate the second average value corresponding to the second difference, calculate the second added value corresponding to the upper left ordinate value and the second average value, and determine the second added value as the ordinate value of the current center point;

[0175] The current center point coordinate information of the target vehicle object is determined according to the current center point horizontal coordinate value and the current center point vertical coordinate value.

[0176] Optionally, the horizontal coordinate value of the current center point of the target vehicle object can be obtained by the following formula: c =x l +(x r -x l ) / 2, which is not limited in the embodiments of the present invention.

[0177] Optionally, the current center point ordinate value of the target vehicle object can be obtained by the following formula: c =y l +(y r -y l ) / 2, which is not limited in the embodiments of the present invention.

[0178] Optionally, the traffic data set will record the center point coordinate information of the identified vehicle objects. Therefore, when the identified vehicle objects in the traffic data set include the target vehicle object, the center point coordinate information of the target vehicle object based on the previous frame of the road section image can be directly obtained from the traffic data set, and then the previous center point coordinate information of the target vehicle object can be determined; in addition, the positioning frame coordinate information of the target vehicle object based on the previous frame of the road section image can be determined through the traffic data set, and the previous center point coordinate information of the target vehicle object can be further determined by referring to but not limited to the above-mentioned method for determining the current center point coordinate information of the target vehicle object, which is not limited to the embodiments of the present invention.

[0179] It can be seen that this optional embodiment can provide a method for determining the current center point coordinate information and the previous center point coordinate information, which is conducive to improving the comprehensiveness and rationality of the method for determining the current center point coordinate information and the previous center point coordinate information, and further helps to improve the accuracy and reliability of the determined current center point coordinate information and the previous center point coordinate information.

[0180] Embodiment 2

[0181] See also Figure 2 , Figure 2 is a flow chart of another method for identifying bidirectional vehicle flow based on target detection and tracking algorithm disclosed in an embodiment of the present invention. Figure 2 The described method may be applied to a bidirectional vehicle flow identification device, wherein the device may include a server, wherein the server includes a local server or a cloud server, which is not limited in the embodiment of the present invention. Figure 2 As shown, the two-way vehicle flow recognition method based on target detection and tracking algorithm includes the following operations:

[0182] 201. Determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects.

[0183] 202. Input the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, and input the object information of each target vehicle object into a converged tracking algorithm model for analysis to obtain a tracking sequence number of each target vehicle object.

[0184] 203. According to the current road section image, determine whether the target road section meets the preset data set establishment conditions. When the judgment result is yes, execute step 204; when the judgment result is no, execute step 205.

[0185] 204. Establish a traffic data set, and perform corresponding element addition and data update operations on the traffic data set according to the object information and tracking number of each target vehicle object and the set basic traffic status result.

[0186] Optionally, a traffic data set is established. For example, an array variable named VehicleTrafficInfo is established to record the traffic data of each detected vehicle object (such as object category information, tracking sequence number, center point coordinate information, traffic status results, etc.); further, "VehicleTrafficInfo" can be understood as a variable defined in this solution, a method of using a C++ program, and this variable contains multiple variables (i.e. corresponding to different vehicle objects and specific traffic data of vehicle objects), which is not limited in the embodiments of the present invention.

[0187] 205. Determine the traffic status result of each target vehicle object based on the object information and tracking number of each target vehicle object and the determined traffic data set corresponding to the target road section; determine the traffic flow result of the target road section within the target time based on the traffic status result of each identified vehicle object in the traffic data set, and all identified vehicle objects include the target vehicle object.

[0188] In the embodiment of the present invention, for other descriptions of step 201 to step 205, please refer to other detailed descriptions of step 101 to step 105 in embodiment 1, and the embodiment of the present invention will not be repeated here.

[0189] It can be seen that the embodiment of the present invention can obtain the object information and tracking number of the target vehicle object through the target detection model and the tracking algorithm model, determine the traffic state result of the target vehicle object according to the object information and the tracking number, and then determine the traffic flow result of the target section within the target time, which is conducive to improving the comprehensiveness and rationality of the two-way traffic flow identification method, and thus is conducive to improving the accuracy and reliability of the determined traffic flow result, and is also conducive to improving the determination efficiency and convenience of the traffic flow result, so as to improve the accuracy, efficiency and timeliness of the traffic flow identification of the target section, and further facilitate the realization of real-time and low-cost detection of the traffic flow of the section; and, it can also determine whether the target section meets the data set establishment conditions, and match the corresponding operations according to the results of the data set establishment conditions, which is conducive to improving the comprehensiveness and integrity of the two-way traffic flow identification method. In addition, it also provides a traffic data set establishment, element addition and data update method, which is conducive to improving the comprehensiveness and rationality of the traffic data set processing method, and thus is conducive to improving the accuracy, timeliness and rationality of the establishment of the traffic data set, and is conducive to improving the accuracy, timeliness and rationality of the element addition and data update of the traffic data set, so as to improve the applicability and data integrity and effectiveness of the traffic data set.

[0190] In an optional embodiment, judging whether the target road section meets the preset data set establishment condition according to the current road section image may include:

[0191] According to the historical tracking image information of the target road section, determine whether the current road section image meets the preset first frame tracking image condition;

[0192] When it is determined that the current road section image meets the first frame tracking image condition, determining that the target road section meets the preset data set establishment condition;

[0193] When it is determined that the current road section image does not meet the first frame tracking image condition, it is determined that the target road section does not meet the preset data set establishment condition.

[0194] Optionally, the historical tracking image information of the target road section may be the historical tracking image information of the target road section within a set time period, or may be all historical tracking image information of the target road section since the road section image acquisition was started in the past, which is not limited in the embodiment of the present invention.

[0195] Further optionally, judging whether the current road section image meets the preset first frame tracking image condition according to the historical tracking image information of the target road section may include:

[0196] According to the historical tracking image information of the target road section, determining whether the current road section image is the first frame image;

[0197] When it is determined that the current road section image is the first frame image, determining that the current road section image meets a preset first frame tracking image condition;

[0198] When it is determined that the current road section image is not the first frame image, it is determined that the current road section image does not meet the preset first frame tracking image condition.

[0199] It can be seen that this optional embodiment can determine the results of satisfying the data set establishment conditions based on the results of satisfying the conditions of the first frame tracking image of the current road section image, which is beneficial to improving the comprehensiveness, integrity and rationality of the method of determining the results of satisfying the data set establishment conditions, and further helps to improve the accuracy and reliability of the determined results of satisfying the data set establishment conditions.

[0200] In another optional embodiment, the above-mentioned performing corresponding element addition and data update operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result may include:

[0201] Determine the center point coordinate information of each target vehicle object according to the positioning frame coordinate information included in the object information of each target vehicle object;

[0202] According to the center point coordinate information corresponding to each target vehicle object, the tracking sequence number and the object category information included in the object information, and the set basic traffic status results, the corresponding element addition and data update operations are performed on the traffic data set.

[0203] It can be seen that this optional embodiment can provide a method for adding elements to a traffic data set and updating data in response to the situation where the target vehicle object has not been recorded in the traffic data set history, and perform corresponding element addition and data update operations on the traffic data set according to the center point coordinate information, tracking sequence number and object category information, and basic traffic status results. This is beneficial to improving the comprehensiveness, rationality and integrity of the method for adding elements to a traffic data set and updating data, as well as improving the flexibility and pertinence of the method for adding elements to a traffic data set and updating data, and thus is beneficial to improving the accuracy and timeliness of the method for adding elements to a traffic data set and updating data.

[0204] In another optional embodiment, after determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, the method may further include the following operations:

[0205] According to the current center point coordinate information, tracking sequence number, traffic status result and object category information included in the object information corresponding to each determined target vehicle object, a corresponding data update operation is performed on the traffic data set.

[0206] Optionally, the above-mentioned corresponding data update operation on the traffic data set may be to directly add the current center point coordinate information, tracking number, traffic status result and object category information included in the object information corresponding to each determined target vehicle object to the corresponding position of the traffic data set, or to replace the corresponding data originally stored in the traffic data set with the current center point coordinate information, tracking number, traffic status result and object category information included in the object information corresponding to each determined target vehicle object, and the embodiment of the present invention is not limited to this.

[0207] It can be seen that this optional embodiment can provide a data update method for the traffic data set according to the situation of the target vehicle object that has been historically recorded in the traffic data set, which is beneficial to improving the pertinence, flexibility and accuracy of the data update method for the traffic data set, and further beneficial to improving the execution accuracy and reliability of the data update operation of the traffic data set, thereby helping to improve the data accuracy of the traffic data set.

[0208] Embodiment 3

[0209] See also Figure 3 , Figure 3 : is a schematic diagram of the structure of a two-way vehicle flow recognition device based on target detection and tracking algorithm disclosed in an embodiment of the present invention. Figure 3 The described device may include a server, wherein the server includes a local server or a cloud server, which is not limited in the embodiment of the present invention. Figure 3 As shown, the two-way vehicle flow recognition device based on target detection and tracking algorithm may include:

[0210] The image determination module 301 is used to determine the current road section image of the target road section that needs to be subjected to vehicle flow recognition, wherein the current road section image includes one or more target vehicle objects.

[0211] The vehicle tracking module 302 is used to input the current road section image into the converged target detection model for analysis to obtain the object information of each target vehicle object, and input the object information of each target vehicle object into the converged tracking algorithm model for analysis to obtain the tracking sequence number of each target vehicle object.

[0212] The state determination module 303 is used to determine the traffic state result of each target vehicle object according to the object information and tracking number of each target vehicle object and the traffic data set corresponding to the determined target road section.

[0213] The vehicle flow determination module 304 is used to determine the vehicle flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set, and all identified vehicle objects include the target vehicle object.

[0214] It can be seen that implementation Figure 3 The described two-way traffic flow identification device based on target detection and tracking algorithm can obtain the object information and tracking number of the target vehicle object through the target detection model and tracking algorithm model, determine the traffic status result of the target vehicle object according to the object information and tracking number, and then determine the traffic flow result of the target section within the target time, which is conducive to improving the comprehensiveness and rationality of the two-way traffic flow identification method, and then help to improve the accuracy and reliability of the determined traffic flow results, and also help to improve the determination efficiency and convenience of the traffic flow results, so as to improve the accuracy, efficiency and timeliness of traffic flow identification of the target section, and further help to realize real-time and low-cost detection of traffic flow on the section.

[0215] In an optional embodiment, the object information of the target vehicle object includes at least positioning frame coordinate information, confidence information and object category information of the target vehicle object.

[0216] And, the state determination module 303 determines the traffic state result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, specifically including:

[0217] Determine a tracking sequence number of each identified vehicle object in the traffic data set according to the determined traffic data set corresponding to the target road section;

[0218] For each target vehicle object, judging whether the target vehicle object meets a preset identification condition according to the tracking numbers of all identified vehicle objects and the tracking number of the target vehicle object;

[0219] When it is determined that the target vehicle object meets the identification conditions, the traffic status result of the target vehicle object is determined according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information;

[0220] When it is determined that the target vehicle object does not meet the identified conditions, the corresponding element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number corresponding to the target vehicle object, and the set basic traffic status result, and the traffic status result of the target vehicle object is determined.

[0221] It can be seen that implementation Figure 4 The described device can match the corresponding traffic status result determination operations according to the results of the identified conditions of the target vehicle object, which is conducive to improving the comprehensiveness, integrity and rationality of the traffic status result determination method, and thus is conducive to improving the diversity and flexibility of the traffic status result determination method, thereby helping to improve the accuracy and reliability of the determined traffic status results, and is also conducive to improving the execution accuracy and execution rationality of the traffic status determination operation. In addition, it also provides a method for adding elements to a traffic data set and updating data, which is conducive to improving the comprehensiveness and rationality of the method for adding elements to a traffic data set and updating data, and thus is conducive to improving the data update accuracy, timeliness and efficiency of the traffic data set, thereby helping to improve the data accuracy and completeness of the traffic data set, and further helping to improve the accuracy and reliability of the traffic status results and traffic flow results subsequently determined based on the traffic data set.

[0222] In another optional embodiment, the state determination module 303 determines the traffic state result of the target vehicle object according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information, specifically including:

[0223] Determine a first ordinate value according to the determined current center point coordinate information corresponding to the target vehicle object, determine a second ordinate value according to the previous center point coordinate information corresponding to the target vehicle object, and determine a reference ordinate value according to the preset vehicle flow reference line coordinate information;

[0224] Determine the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value; the traffic state type includes one of an upward state type, a downward state type and other state types;

[0225] According to the traffic state type, the traffic state result of the target vehicle object is determined.

[0226] It can be seen that implementation Figure 4The described device can also determine the corresponding vertical coordinate values ​​through the current center point coordinate information, the previous center point coordinate information and the vehicle flow baseline coordinate information, and then determine the traffic state type of the target vehicle object, and determine the traffic state result according to the traffic state type, which is conducive to improving the comprehensiveness and rationality of the traffic state result determination method, and then is conducive to improving the diversity, pertinence and rationality of the determination parameters used to determine the traffic state results, thereby helping to improve the accuracy and reliability of the determined traffic state results.

[0227] In another optional embodiment, the state determination module 303 determines the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value in a manner that specifically includes:

[0228] When the first ordinate value is greater than the second ordinate value and the first ordinate value is greater than the reference ordinate value, determining that the traffic state type of the target vehicle object is a down state type;

[0229] When the first ordinate value is less than the second ordinate value and the first ordinate value is less than the reference ordinate value, it is determined that the traffic state type of the target vehicle object is an upward state type.

[0230] It can be seen that implementation Figure 4 The described device can also determine the traffic state type of the target vehicle object by comparing the size relationship between the first ordinate value and the second ordinate value and the size relationship between the first ordinate value and the reference ordinate value, which is beneficial to improving the comprehensiveness, integrity and rationality of the traffic state type determination method, and further helps to improve the accuracy and reliability of the determined traffic state type.

[0231] In another optional embodiment, the vehicle flow determination module 304 determines the vehicle flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set in a manner specifically including:

[0232] When the traffic flow identification requirement type of the target road section is a two-way traffic flow identification type, according to the determined target traffic state information requiring two-way traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set, a first target object that meets the preset traffic state matching condition is determined from all identified vehicle objects; the number of first vehicles corresponding to all first target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the number of first vehicles;

[0233] When the traffic flow identification requirement type of the target road section is an exclusive category traffic flow identification type, according to the determined target vehicle category that requires targeted traffic flow identification and the object category information of each identified vehicle object in the traffic data set, a second target object that meets the preset vehicle category matching condition is determined from all identified vehicle objects; the number of second vehicles corresponding to all second target objects is calculated; and based on the number of second vehicles, the traffic flow result of the target road section within the target time is determined.

[0234] It can be seen that implementation Figure 4 The described device can also match corresponding traffic flow result determination methods for two-way traffic flow identification types and exclusive category traffic flow identification types, which is conducive to improving the comprehensiveness, integrity and rationality of the traffic flow result determination method, and further helps to improve the pertinence, diversity and flexibility of the traffic flow result determination method, thereby helping to improve the accuracy and reliability of the determined traffic flow results.

[0235] In yet another optional embodiment, Figure 4 As shown, the device may also include:

[0236] The judgment module 305 is used to judge whether the target road section meets the preset data set establishment conditions according to the current road section image before the state determination module 303 determines the traffic state result of each target vehicle object according to the object information and tracking number of each target vehicle object and the traffic data set corresponding to the determined target road section; when it is judged that the target road section does not meet the data set establishment conditions, the state determination module 303 performs the operation of determining the traffic state result of each target vehicle object according to the object information and tracking number of each target vehicle object and the traffic data set corresponding to the determined target road section.

[0237] The set establishing module 306 is used to establish a traffic data set when the judging module 305 determines that the target road section meets the data set establishing conditions.

[0238] The first set data updating module 307 is used to perform corresponding element addition and data updating operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result.

[0239] It can be seen that implementation Figure 4The described device can also determine whether the target road section meets the data set establishment conditions, and match the corresponding operations according to the results of whether the data set establishment conditions are met, which is conducive to improving the comprehensiveness and integrity of the two-way traffic flow identification method. In addition, it also provides traffic data set establishment, element addition and data update methods, which is conducive to improving the comprehensiveness and rationality of the traffic data set processing method, and thus is conducive to improving the accuracy, timeliness and rationality of traffic data set establishment, as well as the accuracy, timeliness and rationality of element addition and data update of traffic data sets, thereby helping to improve the applicability of traffic data sets and data integrity and effectiveness.

[0240] In another optional embodiment, the determination module 305 determines whether the target road section meets the preset data set establishment condition according to the current road section image in the following manner:

[0241] According to the historical tracking image information of the target road section, determine whether the current road section image meets the preset first frame tracking image condition;

[0242] When it is determined that the current road section image meets the first frame tracking image condition, determining that the target road section meets the preset data set establishment condition;

[0243] When it is determined that the current road section image does not meet the first frame tracking image condition, it is determined that the target road section does not meet the preset data set establishment condition.

[0244] It can be seen that implementation Figure 4 The described device can also determine whether the data set establishment conditions are satisfied based on the results of the first frame tracking image conditions of the current road section image, which is conducive to improving the comprehensiveness, integrity and rationality of the method for determining the data set establishment conditions are satisfied, and further helps to improve the accuracy and reliability of the determined data set establishment conditions are satisfied.

[0245] In another optional embodiment, the first set data updating module 307 performs corresponding element addition and data update operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, specifically including:

[0246] Determine the center point coordinate information of each target vehicle object according to the positioning frame coordinate information included in the object information of each target vehicle object;

[0247] According to the center point coordinate information corresponding to each target vehicle object, the tracking sequence number and the object category information included in the object information, and the set basic traffic status results, the corresponding element addition and data update operations are performed on the traffic data set.

[0248] It can be seen that implementation Figure 4The described device can also provide a method for adding elements to a traffic data set and updating data in response to the situation where the target vehicle object has not been historically recorded in the traffic data set, and perform corresponding element addition and data update operations on the traffic data set based on the center point coordinate information, tracking sequence number and object category information, and basic traffic status results, which is beneficial to improving the comprehensiveness, rationality and integrity of the method for adding elements to a traffic data set and updating data, as well as improving the flexibility and pertinence of the method for adding elements to a traffic data set and updating data, thereby helping to improve the accuracy and timeliness of the method for adding elements to a traffic data set and updating data.

[0249] In yet another optional embodiment, Figure 4 As shown, the device may also include:

[0250] The coordinate determination module 308 is used to determine the current center point coordinate information of the target vehicle object according to the positioning frame coordinate information of the target vehicle object, and determine the previous center point coordinate information of the target vehicle object according to the traffic data set before the state determination module 303 determines the traffic state result of the target vehicle object according to the current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset traffic flow baseline coordinate information.

[0251] It can be seen that implementation Figure 4 The described device can also provide a method for determining the current center point coordinate information and the previous center point coordinate information, which is conducive to improving the comprehensiveness and rationality of the method for determining the current center point coordinate information and the previous center point coordinate information, and further helps to improve the accuracy and reliability of the determined current center point coordinate information and the previous center point coordinate information.

[0252] In yet another optional embodiment, Figure 4 As shown, the device may also include:

[0253] The second set data updating module 309 is used to perform corresponding data updating operations on the traffic data set according to the current center point coordinate information, tracking number, traffic status result and object category information included in the object information corresponding to each target vehicle object determined by the state determination module 303, after the traffic data set corresponding to the determined target road section is determined by the state determination module 303.

[0254] It can be seen that implementation Figure 4The described device can also provide a data update method for the traffic data set based on the situation of the target vehicle object that has been historically recorded in the traffic data set, which is beneficial to improving the pertinence, flexibility and accuracy of the data update method for the traffic data set, and further beneficial to improving the execution accuracy and reliability of the data update operation of the traffic data set, thereby helping to improve the data accuracy of the traffic data set.

[0255] Embodiment 4

[0256] See also Figure 5 , Figure 5 is a schematic diagram of the structure of another bidirectional vehicle flow recognition device based on target detection and tracking algorithm disclosed in an embodiment of the present invention. Figure 5 The described device may include a server, wherein the server includes a local server or a cloud server, which is not limited in the embodiment of the present invention. Figure 5 As shown, the device may include:

[0257] A memory 401 storing executable program codes;

[0258] a processor 402 coupled to the memory 401;

[0259] Furthermore, it may also include an input interface 403 and an output interface 404 coupled to the processor 402;

[0260] The processor 402 calls the executable program code stored in the memory 401 to execute the steps of the two-way vehicle flow recognition method based on the target detection and tracking algorithm described in the first or second embodiment.

[0261] Embodiment 5

[0262] An embodiment of the present invention discloses a computer storage medium storing a computer program for electronic data exchange, wherein the computer program enables a computer to execute the steps of the two-way vehicle flow identification method based on target detection and tracking algorithm described in Embodiment 1 or Embodiment 2.

[0263] Embodiment 6

[0264] An embodiment of the present invention discloses a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to enable a computer to execute the steps of the two-way vehicle flow identification method based on target detection and tracking algorithm described in Example 1 or Example 2.

[0265] The device embodiments described above are only illustrative, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, i.e., they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative work.

[0266] Through the specific description of the above embodiments, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on such an understanding, the above technical solution can be essentially or partly contributed to the prior art in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, and the storage medium includes a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable rewritable read-only memory (EEPROM), a compact disc (CD-ROM) or other optical disc storage, a magnetic disk storage, a magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.

[0267] Finally, it should be noted that the method and device for identifying two-way vehicle flow based on target detection and tracking algorithm disclosed in the embodiment of the present invention only disclose the preferred embodiment of the present invention, which is only used to illustrate the technical solution of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments can still be modified, or some of the technical features therein can be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. A two-way vehicle flow recognition method based on target detection and tracking algorithm, characterized in that: The method comprises: Determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects; Inputting the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, and inputting the object information of each target vehicle object into a converged tracking algorithm model for analysis to obtain a tracking sequence number of each target vehicle object; Determine the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section; The traffic flow result of the target road section within the target time is determined according to the traffic status result of each identified vehicle object in the traffic data set, and all the identified vehicle objects include the target vehicle object.

2. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to claim 1 is characterized in that: The object information of the target vehicle object at least includes positioning frame coordinate information, confidence information and object category information of the target vehicle object; And, determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section includes: Determine, according to the determined traffic data set corresponding to the target road section, a tracking number of each identified vehicle object in the traffic data set; For each of the target vehicle objects, judging whether the target vehicle object meets a preset identification condition according to the tracking numbers of all the identified vehicle objects and the tracking number of the target vehicle object; When it is determined that the target vehicle object meets the identified condition, the traffic status result of the target vehicle object is determined according to the current center point coordinate information and the previous center point coordinate information corresponding to the determined target vehicle object and the preset vehicle flow baseline coordinate information; When it is determined that the target vehicle object does not meet the identified conditions, the corresponding element addition and data update operations are performed on the traffic data set according to the positioning frame information, object category information and tracking number corresponding to the target vehicle object, and the set basic traffic status result, and the traffic status result of the target vehicle object is determined.

3. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to claim 2 is characterized in that: The method of determining the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information includes: Determine a first ordinate value according to the determined current center point coordinate information corresponding to the target vehicle object, determine a second ordinate value according to the previous center point coordinate information corresponding to the target vehicle object, and determine a reference ordinate value according to the preset vehicle flow reference line coordinate information; Determine the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value; the traffic state type includes one of an up state type, a down state type and other state types; Determine the traffic status result of the target vehicle object according to the traffic status type; And, determining the traffic state type of the target vehicle object according to the first ordinate value, the second ordinate value and the reference ordinate value includes: When the first ordinate value is greater than the second ordinate value and the first ordinate value is greater than the reference ordinate value, determining that the traffic state type of the target vehicle object is a down state type; When the first ordinate value is smaller than the second ordinate value and the first ordinate value is smaller than the reference ordinate value, it is determined that the traffic state type of the target vehicle object is an upward state type.

4. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to claim 2 is characterized in that: The determining of the traffic flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set includes: When the traffic flow identification requirement type of the target road section is a two-way traffic flow identification type, according to the determined target traffic state information requiring two-way traffic flow identification and the traffic state result of each identified vehicle object in the traffic data set, a first target object that meets a preset traffic state matching condition is determined from all the identified vehicle objects; the number of first vehicles corresponding to all the first target objects is calculated; and the traffic flow result of the target road section within the target time is determined according to the first number of vehicles; When the traffic flow identification requirement type of the target road section is an exclusive category traffic flow identification type, based on the determined target vehicle category that requires targeted traffic flow identification and the object category information of each identified vehicle object in the traffic data set, a second target object that meets the preset vehicle category matching condition is determined from all the identified vehicle objects; the number of second vehicles corresponding to all the second target objects is calculated; and based on the second number of vehicles, the traffic flow result of the target road section within the target time is determined.

5. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to any one of claims 2 to 4, characterized in that: Before determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, the method further includes: According to the current road section image, determining whether the target road section meets a preset data set establishment condition; When it is determined that the target road section meets the data set establishment conditions, a traffic data set is established; according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, corresponding element addition and data update operations are performed on the traffic data set; When it is determined that the target road section does not meet the data set establishment conditions, the operation of determining the traffic status result of each target vehicle object based on the object information and tracking number of each target vehicle object and the traffic data set corresponding to the target road section is performed.

6. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to claim 5 is characterized in that: The determining, based on the current road section image, whether the target road section satisfies a preset data set establishment condition includes: According to the historical tracking image information of the target road section, determining whether the current road section image meets the preset first frame tracking image condition; When it is determined that the current road section image meets the first frame tracking image condition, determining that the target road section meets the preset data set establishment condition; When it is determined that the current road section image does not meet the first frame tracking image condition, determining that the target road section does not meet the preset data set establishment condition; And, performing corresponding element addition and data update operations on the traffic data set according to the object information and tracking sequence number of each target vehicle object and the set basic traffic status result, including: Determine the center point coordinate information of each target vehicle object according to the positioning frame coordinate information included in the object information of each target vehicle object; According to the center point coordinate information corresponding to each target vehicle object, the tracking sequence number and the object category information included in the object information, and the set basic traffic status result, corresponding element addition and data update operations are performed on the traffic data set.

7. The method for identifying bidirectional vehicle flow based on target detection and tracking algorithm according to any one of claims 2 to 4, characterized in that: Before determining the traffic status result of the target vehicle object according to the determined current center point coordinate information and the previous center point coordinate information corresponding to the target vehicle object and the preset vehicle flow baseline coordinate information, the method further includes: Determine the current center point coordinate information of the target vehicle object according to the positioning frame coordinate information of the target vehicle object, and determine the previous center point coordinate information of the target vehicle object according to the traffic data set; And, after determining the traffic status result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section, the method further includes: According to the determined current center point coordinate information, tracking sequence number, traffic status result and object category information included in the object information corresponding to each of the target vehicle objects, a corresponding data update operation is performed on the traffic data set.

8. A two-way vehicle flow recognition device based on target detection and tracking algorithm, characterized in that: The device comprises: An image determination module, used to determine a current road section image of a target road section for which vehicle flow identification is required, wherein the current road section image includes one or more target vehicle objects; A vehicle tracking module, used for inputting the current road section image into a converged target detection model for analysis to obtain object information of each target vehicle object, and inputting the object information of each target vehicle object into a converged tracking algorithm model for analysis to obtain a tracking sequence number of each target vehicle object; A state determination module, used to determine the traffic state result of each target vehicle object according to the object information and tracking sequence number of each target vehicle object and the determined traffic data set corresponding to the target road section; The vehicle flow determination module is used to determine the vehicle flow result of the target road section within the target time according to the traffic status result of each identified vehicle object in the traffic data set, and all the identified vehicle objects include the target vehicle object.

9. A two-way vehicle flow recognition device based on target detection and tracking algorithm, characterized in that: The device comprises: A memory storing executable program code; a processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the two-way vehicle flow identification method based on target detection and tracking algorithm as described in any one of claims 1-7.

10. A computer storage medium, characterized in that: The computer storage medium stores computer instructions, and when the computer instructions are called, they are used to execute the two-way vehicle flow identification method based on target detection and tracking algorithm as described in any one of claims 1-7.

Citation Information

Patent Citations

  • Traffic video intelligent analysis method based on target detection and tracking

    CN110472496A

  • Road vehicle tracking method and system based on attention mechanism and multi-target tracking

    CN114627447A

  • Underground mine car traffic control device and method based on road section flow control

    CN118447674A

  • Apparatus and method for determining traffic flow by lane

    KR102499023B1