A real-time vehicle flow statistics method for T-CPS smart traffic scenarios
By using multi-angle and multi-category vehicle picture data sets and improved PP-YOLOE and BYTETracker models, the problem of detection accuracy and slow speed of vehicle flow statistics methods in intelligent transportation is solved, and efficient and efficient detection of multi-angle and multi-category vehicles is achieved. Accurate detection.
Patent Information
- Application Number
- CN202410265644.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-08
- Publication Date
- 2025-01-21
- Estimated Expiration
- 2044-03-08
AI Technical Summary
The existing vehicle flow statistics methods in intelligent transportation have problems such as small data set size, single shooting angle, same vehicle category labeling, poor generalization of the model, and slow detection accuracy and speed.
Using a representative multi-angle and multi-category vehicle picture data set, combined with the improved PP-YOLOE model and BYTETracker target tracking model, through the feature fusion network of the spatial attention mechanism, accurate detection and tracking of multi-angle and multi-category vehicles are achieved. .
It improves the accuracy and speed of vehicle target detection, enhances the accuracy and efficiency of vehicle traffic statistics, and is suitable for multi-angle and multi-category vehicle detection.
Smart Images

Figure CN118230560B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent transportation technology, and in particular to a real-time vehicle flow statistics method for a T-CPS intelligent transportation scenario. Background Art
[0002] With the continuous advancement of urbanization, the number of motor vehicles has continued to increase, and urban traffic congestion has become increasingly serious. At the same time, traffic intersections often have problems such as long waiting times for vehicles in a certain direction. In order to alleviate traffic congestion and improve traffic operation efficiency, it is necessary to dynamically adjust the operation mode of traffic. For this reason, it is necessary to conduct accurate and efficient statistical analysis of traffic data. Among them, it is necessary to conduct statistical analysis of vehicle flow in traffic data to improve the intelligence of traffic.
[0003] However, the current vehicle flow statistics methods used in intelligent transportation still have the following defects:
[0004] 1. The previous vehicle target detection model had a small data set size, a single shooting angle, and the same vehicle category labeling, which resulted in the defect of weak generalization of the trained model. When terminal devices with other shooting angles were deployed, the accuracy would be reduced, and it would be impossible to distinguish more detailed vehicle categories.
[0005] 2. The previous vehicle target detection model had poor feature extraction and feature fusion capabilities, slow reasoning speed, and classified different vehicle types into the same category, resulting in inaccurate detection of vehicle positions and vehicle categories;
[0006] 3. At the same time, due to the inaccurate vehicle detection position and category, in the target tracking process, all the detection targets are carried out together with the prediction results, which requires reliance on multiple target information features, resulting in inaccurate matching and tracking results and slow running speed. Summary of the invention
[0007] The purpose of the present invention is to overcome the above-mentioned defects in the prior art and provide a real-time vehicle flow statistics method for T-CPS smart traffic scenarios, which solves the following problems:
[0008] First, it integrates a representative multi-angle and multi-category vehicle image dataset, which enables multi-angle and multi-category vehicle detection on the terminal camera (that is, no matter where the terminal camera is deployed, it is adapted to the BYTETracker model and can maintain a good accuracy rate), solving the problem of inaccurate vehicle position and vehicle frame detection, making vehicle flow statistics more accurate;
[0009] Second: An improved PP-YOLOE model was adopted, the improved SK module was integrated into the PP-YOLOE network, and a feature fusion network with a spatial attention mechanism was used to solve the problem of insufficient detection capability of the target detection network, thereby improving the accuracy and speed of vehicle target detection, thereby improving the speed of vehicle flow statistics.
[0010] Third: The BYTETracker target tracking model is used in combination with the more accurate multi-classification model pp-yoloe model. The detection results are divided into high-score frames and low-score frames according to the confidence level, and matched with the results predicted by the Kalman filter respectively, thereby improving the accuracy and stability of target tracking. At the same time, due to this high-precision matching, the matching process does not need to add additional vehicle feature information, thereby improving the reasoning speed. At the same time, since no deep learning method is used, no additional retraining process is required.
[0011] To achieve the above object, the present invention provides a real-time vehicle flow statistics method for T-CPS smart traffic scenario, comprising the following steps:
[0012] S1: Create a vehicle image dataset with multiple angles, which includes the UA-DETRAC dataset and the VisDrone-DET dataset;
[0013] S2: Build the PP-YOLOE model, integrate the SK module into the feature fusion network of the PP-YOLOE model, and use the vehicle image dataset in step S1 for training;
[0014] S3: embed the trained PP-YOLOE model of step S2 into the BYTETracker model to track the target vehicle and number the corresponding target vehicle;
[0015] S4: Acquire mobile terminal video, set the area of interest, set the virtual detection line, and use the BYTETracker model of step S3 to implement vehicle flow statistics.
[0016] Preferably, the specific steps of step S1 are as follows:
[0017] S11: Split the VisDrone-DET dataset images;
[0018] S12: The segmented dataset is merged with the UA-DETRAC dataset and divided into a training set and a validation set according to a certain ratio;
[0019] S13: Convert the xml format of the data set fused together in S12 into the COCO data set format, and finally merge the duplicate labels to complete the data set format conversion to obtain a vehicle image data set from multiple angles for training.
[0020] Preferably, the specific steps of step S11 are as follows: the VisDrone-DET dataset image is segmented with a sliding window of size 640*640 and step length 200, and the segmented VisDrone-DET dataset image is scaled according to ratios of 0.5:1, 1:1, and 1:1.5, respectively, wherein when the intersection and intersection ratio of the target box and the segmented VisDrone-DET dataset image is greater than 0.8, the target box is added to the segmented image annotation.
[0021] Preferably, the step of integrating the SK module into the feature fusion network of the PP-YOLOE model in step S2 is: replacing the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model with the SK module operation.
[0022] Preferably, the specific steps of step S2 are as follows:
[0023] S21: The FPN-PAN network of the PP-YOLOE model extracts features from the input 640*640 size vehicle image dataset and obtains feature maps of 160*160, 80*80 and 40*40 sizes;
[0024] S22: The FPN network of the PP-YOLOE model performs interpolation and upsampling operations on the high-dimensional feature map, and adds and fuses it with the low-dimensional feature map, so that the semantic information is transferred from the high dimension to the low dimension, and a feature map is generated that integrates the semantic information of the vehicle target at multiple scales;
[0025] S23: The PAN network of the PP-YOLOE model transfers the semantic information from low dimension to high dimension again, performs multiple downsampling and additive fusion, and generates a feature map that integrates vehicle target position information at multiple scales.
[0026] Preferably, in step S22 and step S23, the SK module is used to replace the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model, and the specific operation of the SK module is: concatenating the high-dimensional and low-dimensional feature maps, extracting different position attention feature maps by maximum pooling and mean pooling, and obtaining a normalized position attention feature map through convolution layer and activation function mapping;
[0027] Preferably, S31: using the trained PP-YOLOE module as the target vehicle detection module of the BYTETracker model, the BYTETracker model also includes a vehicle position prediction module and a vehicle feature matching module;
[0028] S32: The target vehicle detection module uses the trained PP-YOLOE model to detect the video frame image of the mobile terminal video, infers the location information and confidence of each vehicle in the video frame at the current moment, and divides the detection frame into a high-scoring frame and a low-scoring frame according to the confidence level;
[0029] S33: The vehicle position prediction module uses the Kalman filter algorithm to predict the position information of the vehicle at the next moment, wherein, when the vehicle moves, the speed and position information of the vehicle in the current frame are predicted based on the speed and position information of the vehicle in the previous frame, and the position coordinates (x', y') of the vehicle are: x'=x+w / 2, y'=y+h / 2, wherein (x, y, w, h) is the vehicle frame information identified by the target vehicle detection module, (x, y) is the coordinates of the upper left corner of the vehicle frame, and (w, h) are the width and height of the vehicle frame respectively;
[0030] S34: The target vehicle feature matching of the vehicle feature matching module first uses the trained PP-YOLOE model to infer the position information and confidence of each vehicle in the current video frame, divides the detection frame into high-score frames and low-score frames according to the confidence level, and then uses the Kalman filter algorithm to predict the vehicle position information of the current frame through the tracking trajectory vehicle position information of the previous 30 frames, and then uses the Hungarian matching algorithm to perform feature matching on the detected vehicle position information and the vehicle position information predicted and tracked by the Kalman filter algorithm.
[0031] Preferably, the specific steps of the target vehicle feature matching in step S34 are as follows: first process the high-score detection frame, and match the high-score frame with the previous tracking trajectory; then use the low-score frame and the tracking trajectory that does not match the high-score frame for matching; finally, assign the remaining high-score frames that do not match the tracking trajectory a new tracking trajectory and tracking identifier, and the tracking trajectory that does not match any detection frame will continue to use Kalman filtering to predict its position, and retain it for 30 frames, and continue to retain it when it matches the target.
[0032] Preferably, the specific steps of step S4 are as follows:
[0033] S41: Acquire a real-time video frame image captured by a mobile terminal;
[0034] S42: Detecting the vehicle in the video frame image through the target vehicle detection module;
[0035] S43: Acquire the next frame of the real-time video captured by the mobile terminal;
[0036] S44: by using the vehicle feature matching module, associating similar detection frames to obtain tracking trajectories, and assigning corresponding identifiers to each target;
[0037] S45: Setting the region of interest and the virtual detection line, and counting the vehicle targets passing through the detection line in a continuous frame image.
[0038] S46: loop the above steps S41-S45 to implement traffic statistics.
[0039] As preferably, the following steps are also included:
[0040] S5: The vehicle flow statistics results of the BYTETracker model are visualized through the vehicle flow statistics visualization system.
[0041] Compared with the prior art, the present invention has the following beneficial effects:
[0042] 1. With a fused multi-angle and multi-category vehicle image dataset, multi-angle and multi-category vehicle detection can be realized on the terminal camera (that is, no matter where the terminal camera is deployed, it is adapted to the BYTETracker model and can maintain a good accuracy rate), thereby reducing the detection error of vehicle position and vehicle frame information, thereby improving the accuracy of vehicle flow detection.
[0043] 2. The camera view image is processed by adopting an improved PP-YOLOE network (i.e., integrating the SK module into the feature fusion network FPN-PAN structure of the PP-YOLOE model), so that the vehicle flow statistics method of the present invention is suitable for multi-angle vehicle target acquisition and spatial position calculation processing, thereby effectively improving the accuracy and detection speed of vehicle target detection, thereby improving the vehicle flow statistics speed.
[0044] 3. The improved SK module introduces the spatial attention mechanism, which enables the feature fusion network of the PP-YOLOE model to dynamically obtain receptive fields of different sizes according to different vehicle categories, thereby improving the accuracy of vehicle detection.
[0045] 4. Since the PP-YOLOE model has been trained, after the trained PP-YOLOE model is embedded in the BYTETracker model, there is no need for additional training for vehicle target tracking; at the same time, since the calculation of Reid features is omitted, the inference speed of vehicle target tracking is improved; in addition, since the detected targets are processed separately according to high-resolution frames and low-resolution frames, the false detection rate of low-resolution frame generated representations and trajectories is reduced, thereby increasing the reliability of vehicle flow statistics. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0047] Figure 1 It is a flow chart of a real-time vehicle flow statistics method for T-CPS smart traffic scenario of the present invention;
[0048] Figure 2 It is a schematic diagram of the model structure of the improved PP-YOLOE network of the present invention;
[0049] Figure 3 It is a structural schematic diagram of the SK module in the improved PP-YOLOE model feature fusion network of the present invention;
[0050] Figure 4 It is a vehicle flow statistics reasoning flow chart based on PP-YOLOE model and BYTETracker model of the present invention;
[0051] Figure 5 is a schematic diagram of a designed virtual detection line of the present invention;
[0052] Figure 6 This is a diagram showing the vehicle detection and tracking effect of the present invention;
[0053] Figure 7 It is a visualization effect diagram of the present invention. DETAILED DESCRIPTION
[0054] The technical scheme in this embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in this embodiment of the present invention. Obviously, the described embodiment is one embodiment of the present invention, not all embodiments of the present invention. Based on this embodiment of the present invention, all other embodiments of the present invention obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0055] like Figure 1-7 As shown, the present invention provides a real-time vehicle flow statistics method for T-CPS smart traffic scenario, comprising the following steps:
[0056] S1: Create a vehicle image dataset with multiple angles, which includes the UA-DETRAC dataset and the VisDrone-DET dataset;
[0057] The specific steps of step S1 are as follows:
[0058] S11: Segment the high-resolution VisDrone-DET dataset image, and the specific steps are: segment the VisDrone-DET dataset image with a sliding window size of 640*640 and a step size of 200, and scale the segmented VisDrone-DET dataset image according to the ratios of 0.5:1, 1:1, and 1:1.5 in sequence, wherein when the intersection and union ratio of the target box and the segmented VisDrone-DET dataset image is greater than 0.8, the target box is added to the segmented image annotation (about the segmented image annotation data of the training set, because some targets will be at the edge of the image after segmentation);
[0059] S12: The segmented data set is merged with the UA-DETRAC data set and divided into a training set and a validation set according to a certain ratio; further, the two can be divided into a training set and a test set according to a ratio of 8:2;
[0060] S13: This real-time vehicle flow statistics method is implemented based on the PaddleDetection open source framework. The dataset format generally used is the COCO dataset format. Therefore, the dataset fused with S12 is first converted from xml format to COCO dataset format, and finally the repeated labels of the two datasets are merged to complete the dataset format conversion, and a vehicle image dataset of multiple angles for training is obtained;
[0061] S2: Build an improved PP-YOLOE model, integrate the SK module into the feature fusion network of the PP-YOLOE model, and use the vehicle image dataset in step S1 for training;
[0062] Among them, the improved PP-YOLOE model is based on the original PP-YOLOE model, and improves the feature fusion network FPN-PAN structure. Its structure includes an input end, a feature extraction network, a feature fusion network and a classification detection head. The improvement lies in: integrating the SK module into the feature fusion network FPN-PAN structure of the PP-YOLOE model, that is, replacing the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model with the SK module operation;
[0063] Among them, Figure 2 As shown, the specific steps of step S2 are as follows:
[0064] S21: The FPN-PAN structure in the PP-YOLOE model first extracts features from the input 640*640 size vehicle image dataset to obtain feature maps of 160*160, 80*80 and 40*40 sizes;
[0065] S22: The FPN network of the PP-YOLOE model performs a bilinear interpolation upsampling operation on the high-dimensional feature map and adds and fuses it with the low-dimensional feature map, so that the semantic information is transferred from the high dimension to the low dimension, and a feature map is generated that integrates the semantic information of the vehicle target at multiple scales;
[0066] S23: The PAN network of the PP-YOLOE model transfers the semantic information from low dimension to high dimension again, performs multiple downsampling and addition fusion, and generates a feature map that integrates vehicle target position information at multiple scales.
[0067] As well as Figure 3 As shown, in step S22 and step S23, the SK module is used to replace the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model. The specific operation of the SK module is: concatenating the high-dimensional and low-dimensional feature maps, extracting different position attention feature maps by maximum pooling and mean pooling, and obtaining a normalized position attention feature map after convolution layer and activation function mapping. The function of the SK module is to obtain a feature map that integrates high-dimensional and low-dimensional features, so that different targets can obtain features from contextual information of different receptive fields;
[0068] S3: embed the trained PP-YOLOE model of step S2 into the BYTETracker model to track the target vehicle and number the corresponding target vehicle (the vehicle tracking operation is naturally synchronized with the vehicle numbering operation, that is, after tracking the vehicle, the corresponding number ID is assigned to the vehicle);
[0069] S31: using the trained improved PP-YOLOE module as the target vehicle detection module of the BYTETracker model, the BYTETracker model also includes a vehicle position prediction module and a vehicle feature matching module;
[0070] S32: The target vehicle detection module uses the trained improved PP-YOLOE model to detect the video frame image of the mobile terminal video (the video frame image detection method is the same as the image processing method of the vehicle image dataset, please refer to step S2 for details), and infers the location information and confidence of each vehicle in the video frame at the current moment, and divides the detection frame into high-scoring frame and low-scoring frame according to the confidence level;
[0071] S33: The vehicle position prediction module uses the Kalman filter algorithm to predict the position information of the vehicle at the next moment, wherein, when the vehicle moves, the speed and position information of the vehicle in the current frame are predicted based on the speed and position information of the vehicle in the previous frame, and the position coordinates (x', y') of the vehicle are: x'=x+w / 2, y'=y+h / 2, wherein (x, y, w, h) is the vehicle frame information identified by the target vehicle detection module, (x, y) is the coordinates of the upper left corner of the vehicle frame, and (w, h) are the width and height of the vehicle frame respectively;
[0072] S34: The target vehicle feature matching of the vehicle feature matching module, first the position information and confidence of each vehicle in the current moment video frame inferred by the trained PP-YOLOE model, the detection frame is divided into a high-scoring frame and a low-scoring frame according to the confidence level, and then the vehicle position information of the current frame is predicted by the tracking track vehicle position information of the previous 30 frames using the Kalman filter algorithm, the detection frame of the vehicle position prediction is divided into a high-scoring frame and a low-scoring frame according to the confidence level, and the detected vehicle position information and the vehicle position information obtained by the Kalman filter algorithm prediction tracking are respectively matched by the Hungarian matching algorithm. Thereby, the target vehicle trajectory (or position information) is tracked, and the corresponding target vehicle is numbered, and the detected target and the target of the previous frame can be matched and the same number id will be given.
[0073] Among them, the specific steps of target vehicle feature matching in step S34 are: first process the high-score detection frame, and match the high-score frame with the previous tracking trajectory. The accuracy in this case is very high; then use the low-score frame and the tracking trajectory that does not match the high-score frame for matching. In this case, the target that can be clearly detected in the previous frame but is severely obscured in the current frame can still be tracked; finally, the remaining high-score frames that do not match the tracking trajectory are assigned a new tracking trajectory and tracking identifier. Finally, the tracking trajectory that does not match any detection frame will continue to use Kalman filtering to predict its position, and retain it for 30 frames, and continue to retain it when it matches the target.
[0074] S4: Deploy the BYTETracker model in step S3 on the corresponding hardware device in the T-CPS smart transportation scenario. Please run and infer the process as follows Figure 4 As shown, in the T-CPS intelligent transportation scene, the mobile terminal video is obtained, the area of interest is set, the virtual detection line is set, and the BYTETracker model of step S3 is used to realize vehicle flow statistics;
[0075] The specific steps of step S4 are as follows:
[0076] S41: Acquire a real-time video frame image captured by a mobile terminal;
[0077] S42: Detecting the vehicle in the video frame image through the target vehicle detection module;
[0078] S43: Acquire the next frame of the real-time video captured by the mobile terminal;
[0079] S44: by using the vehicle feature matching module, associating similar detection frames to obtain tracking trajectories, and assigning corresponding identifiers to each target;
[0080] S45: Setting the region of interest and the virtual detection line, and counting the vehicle targets passing through the detection line in a continuous frame image.
[0081] S46: loop the above steps S41-S45 to implement traffic statistics.
[0082] A real-time vehicle flow statistics method for T-CPS smart traffic scenario of the present invention also includes the following steps:
[0083] S5: The vehicle flow statistics results of the BYTETracker model are visualized through the vehicle flow statistics visualization system.
[0084] Therefore, the present invention proposes a real-time vehicle flow statistics method for the T-CPS smart transportation scenario. Vehicle images are captured by mobile terminals on urban roads (mobile terminal videos are suitable for the real-time vehicle flow statistics method regardless of where they are deployed, and can achieve good detection effects). The BYTETracker model embedded with the improved PP-YOLOE model is used to perform target detection and tracking, and real-time statistics are performed on information such as the number of vehicles and vehicle speeds, so as to provide decision support for the T-CPS system and traffic management departments.
[0085] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A real-time vehicle flow statistics method for T-CPS smart traffic scenario, characterized in that: The steps include: S1: Create a vehicle image dataset with multiple angles, which includes the UA-DETRAC dataset and the VisDrone-DET dataset; S2: Build the PP-YOLOE model, integrate the SK module into the feature fusion network of the PP-YOLOE model, and use the vehicle image dataset in step S1 for training; In step S2, the steps of integrating the SK module into the feature fusion network of the PP-YOLOE model are as follows: replacing the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model with the SK module operation; The specific steps of step S2 are as follows: S21: The FPN-PAN network of the PP-YOLOE model extracts features from the input 640*640 size vehicle image dataset and obtains feature maps of 160*160, 80*80 and 40*40 sizes; S22: The FPN network of the PP-YOLOE model performs interpolation and upsampling operations on the high-dimensional feature map, and adds and fuses it with the low-dimensional feature map, so that the semantic information is transferred from the high dimension to the low dimension, and a feature map is generated that integrates the semantic information of the vehicle target at multiple scales; S23: The PAN network of the PP-YOLOE model transfers the semantic information from low dimension to high dimension again, performs multiple downsampling and addition fusion, and generates a feature map that integrates vehicle target position information at multiple scales. In the step S22 and step S23, the SK module is used to replace the addition fusion operation in the FPN-PAN structure in the PP-YOLOE model. The specific operation of the SK module is: concatenating the high-dimensional and low-dimensional feature maps, extracting different position attention feature maps by maximum pooling and mean pooling, and obtaining a normalized position attention feature map through convolution layer and activation function mapping; S3: embed the trained PP-YOLOE model of step S2 into the BYTETracker model to track the target vehicle and number the corresponding target vehicle; The specific steps of step S3 are as follows: S31: Using the trained PP-YOLOE module as the target vehicle detection module of the BYTETracker model, the BYTETracker model also includes a vehicle position prediction module and a vehicle feature matching module; S32: The target vehicle detection module uses the trained PP-YOLOE model to detect the video frame image of the mobile terminal video, infers the location information and confidence of each vehicle in the video frame at the current moment, and divides the detection frame into a high-scoring frame and a low-scoring frame according to the confidence level; S33: The vehicle position prediction module uses the Kalman filter algorithm to predict the position information of the vehicle at the next moment, wherein, when the vehicle moves, the speed and position information of the vehicle in the current frame are predicted based on the speed and position information of the vehicle in the previous frame, and the position coordinates (x', y') of the vehicle are: x'=x+w / 2, y'=y+h / 2, wherein (x, y, w, h) is the vehicle frame information identified by the target vehicle detection module, (x, y) is the coordinates of the upper left corner of the vehicle frame, and (w, h) are the width and height of the vehicle frame respectively; S34: The target vehicle feature matching of the vehicle feature matching module is firstly to use the position information and confidence of each vehicle in the current video frame inferred by the trained PP-YOLOE model, and to divide the detection frame into high-score frame and low-score frame according to the confidence level. Then, the Kalman filter algorithm is used to predict the vehicle position information of the current frame through the tracking trajectory vehicle position information of the previous 30 frames, and the detected vehicle position information is respectively matched with the vehicle position information predicted and tracked by the Kalman filter algorithm using the Hungarian matching algorithm for feature matching; The specific steps of the target vehicle feature matching in step S34 are as follows: first process the high-score detection frame, and match the high-score frame with the previous tracking track; then use the low-score frame and the tracking track that does not match the high-score frame for matching; finally, assign a new tracking track and tracking identifier to the remaining high-score frame that does not match the tracking track, and continue to use Kalman filtering to predict the position of the tracking track that does not match any detection frame, and retain it for 30 frames, and continue to retain it when it matches the target; S4: Acquire mobile terminal video, set the area of interest, set the virtual detection line, and use the BYTETracker model of step S3 to implement vehicle flow statistics.
2. According to claim 1, a real-time vehicle flow statistics method for T-CPS intelligent transportation scenario is characterized in that: The specific steps of step S1 are as follows: S11: Split the VisDrone-DET dataset images; S12: The segmented dataset is merged with the UA-DETRAC dataset and divided into a training set and a validation set according to a certain ratio; S13: Convert the xml format of the data set fused together in S12 into the COCO data set format, and finally merge the duplicate labels to complete the data set format conversion to obtain a vehicle image data set from multiple angles for training.
3. According to claim 2, a real-time vehicle flow statistics method for T-CPS intelligent transportation scenario is characterized in that: The specific steps of step S11 are as follows: the VisDrone-DET dataset image is segmented with a sliding window of size 640*640 and step length 200, and the segmented VisDrone-DET dataset image is scaled according to the ratios of 0.5:1, 1:1, and 1:1.5 respectively, wherein when the intersection-over-intersection ratio of the target box and the segmented VisDrone-DET dataset image is greater than 0.8, the target box is added to the segmented image annotation.
4. According to claim 1, a real-time vehicle flow statistics method for T-CPS intelligent transportation scenario is characterized in that: The specific steps of step S4 are as follows: S41: Acquire a real-time video frame image captured by a mobile terminal; S42: Detecting the vehicle in the video frame image through the target vehicle detection module; S43: Acquire the next frame of the real-time video captured by the mobile terminal; S44: by using the vehicle feature matching module, associating similar detection frames to obtain tracking trajectories, and assigning corresponding identifiers to each target; S45: Setting the region of interest and the virtual detection line, and counting the vehicle targets passing through the detection line in a continuous frame image. S46: loop the above steps S41-S45 to implement traffic statistics.
5. According to claim 1, a real-time vehicle flow statistics method for T-CPS intelligent transportation scenario is characterized in that: The following steps are also included: S5: The vehicle flow statistics results of the BYTETracker model are visualized through the vehicle flow statistics visualization system.
Citation Information
Patent Citations
Multi-target tracking method, system and device based on YOLOv5 and improved interpolation algorithm and readable storage medium
CN117593339A
Object tracking device of road monitoring video and method
JP2021128761A