Disclosure of Invention
In order to solve the problem that the true value jitter of a training sample causes the fitting error true value of a track prediction model during training, the invention provides a method for denoising the training sample to improve the stability of the track prediction model.
In order to achieve the above object, an embodiment of the present invention provides a track prediction denoising method based on a deep learning model, which is characterized by including:
acquiring training samples from the trajectory prediction training sample set;
acquiring tracking track data from a training sample;
analyzing the tracking track data to obtain all track points corresponding to the track truth value;
calculating the Euclidean distance between the starting point and the end point of the tracking track;
traversing all track points, calculating Euclidean distances of adjacent track points and summing;
and calculating a jitter value according to the Euclidean distance between the starting point and the end point and the sum of the Euclidean distances of adjacent track points, and deleting the training samples of which the jitter value is greater than a jitter threshold value from the track prediction training sample set.
In order to achieve the above object, an embodiment of the present invention further provides a track prediction denoising device based on a deep learning model, which is characterized by including:
the training sample extraction module is used for acquiring training samples from the track prediction training sample set;
the tracking track data extraction module is used for acquiring tracking track data from the training sample;
the track analysis module is used for analyzing the tracking track data to obtain all track points corresponding to the track true value;
the first calculation module is used for calculating the Euclidean distance between the starting point and the end point of the tracking track;
the second calculation module is used for traversing all track points, calculating Euclidean distances of adjacent track points and summing the Euclidean distances;
the third calculation module is used for calculating a jitter value according to the sum of the Euclidean distance between the starting point and the end point and the Euclidean distance between adjacent track points;
the comparison module is used for comparing the jitter value with a jitter threshold value;
and the filtering module is used for deleting the training samples with the jitter values larger than the jitter threshold value from the track prediction training sample set.
In order to achieve the above object, an embodiment of the present invention further provides an apparatus, which includes a memory, a processor, and a program stored in the memory and executable on the processor, where the program implements the steps of the track prediction denoising method based on a deep learning model when executed by the processor.
In order to achieve the above object, an embodiment of the present invention further provides a storage medium, where the storage medium stores at least one program, and the at least one program is executable by at least one processor to implement the steps of the track prediction denoising method based on the deep learning model.
The invention has the beneficial effects that:
the track prediction denoising method based on the deep learning model can effectively clean the training data and screen out high-quality training samples, thereby reducing model prediction problems caused by the quality problems of the training samples and improving the accuracy and stability of track prediction.
Detailed Description
Embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. It should be understood that the drawings and embodiments of the present application are for illustration purposes only and are not intended to limit the scope of the present application.
Example 1
The embodiment provides a track prediction denoising method based on a deep learning model, as shown in fig. 1, including:
step 101, obtaining training samples from a training sample set of a track prediction model based on deep learning. The training samples consisted primarily of the following data: the method comprises the steps that historical x second tracks of a vehicle to be predicted and obstacles around the vehicle to be predicted, map elements around the vehicle to be predicted and future y second tracks of the vehicle to be predicted, wherein the historical x second tracks of the vehicle to be predicted and the obstacles around the vehicle to be predicted and the map elements around the vehicle to be predicted are used as input of a track prediction model, and the future y second tracks of the vehicle to be predicted are used as true values of the track prediction model to be output.
Through an interface get _ agent _ IDs (), the tracking track IDs of all training samples in the database can be obtained, and the tracking track IDs correspond to the training samples one to one, so that the corresponding training samples are obtained.
Step 102, tracking track data, namely the future y-second track data of the vehicle to be predicted, is obtained from the training sample.
By inputting the tracking track ID to the interface get _ track _ by _ ID (), the tracking track data corresponding to the training sample can be returned from the database.
And 103, analyzing all track points corresponding to the track truth value from the tracking track data of the training sample by using the conventional analysis method.
Step 104, calculating the euclidean distance between the start point and the end point of the tracking track, and recording as traj _ len.
And 105, traversing all track points of the training sample, calculating Euclidean distances of every two adjacent track points, summing the Euclidean distances, and recording the Euclidean distances as perimeter.
And 106, calculating a jitter value score according to the sum of the Euclidean distance between the starting point and the end point and the Euclidean distance between adjacent track points, and deleting the training samples with jitter values larger than a jitter threshold value from the track prediction training sample set.
And 107, acquiring the next training sample, and repeating the steps 101-106 until all the training samples are traversed.
Wherein score = perimeter/traj _ len, for a smooth trajectory, the jitter value should be close to 1, and the jitter value is too large, which indicates that the predicted trajectory is abnormal, and the quality of the corresponding training sample is low. The setting of the jitter threshold can be set reasonably according to the expected target of the trajectory tracking. The training samples with jitter values larger than the jitter threshold value are deleted from the track prediction training sample set, namely the training samples with low quality and track true value jitter are deleted, and the training sample set is subjected to noise removal and cleaning, so that a model cannot be subjected to false true value fitting during training, model prediction problems caused by the quality problems of the training samples are reduced, and the accuracy and the stability of track prediction are improved.
The track prediction denoising method based on the deep learning model is mainly applied to a behavior or track prediction module in an automatic driving technology, and a prediction model developed based on the deep learning technology on the front edge often needs a specific form of input. Particularly in the model training stage, correctly available training and testing samples can be obtained for dynamically and continuously expanded self-collected data, and the predicted trajectory quality of the prediction model can be better improved from the data side.
Example 2
The present embodiment provides a trajectory prediction denoising method based on a deep learning model, including steps 101 to 107 of embodiment 1, as shown in fig. 2, after cleaning a training sample in step 107 and deleting the training sample having a trajectory true value and a trajectory jitter value, the method further includes:
and step 108, acquiring tracking track data for each residual training sample in the track prediction training sample set, analyzing to obtain all track points corresponding to the track true value, traversing all track points, and calculating the curvature of each track point and the curvature variation of adjacent track points.
And the curvature calculation of each track point determines a circle by taking every adjacent 3 track points as a group for calculation, and the curvature difference of every two adjacent track points is subtracted to obtain an absolute value so as to obtain the curvature variation.
And step 109, screening out training samples with track point curvature absolute values larger than a curvature threshold value or with abrupt changes in track point curvature.
Step 109 specifically includes: and setting a curvature threshold and a curvature variation threshold, comparing the curvature absolute value of the track point with the curvature threshold, comparing the curvature variation of the adjacent track point with the curvature variation threshold, and judging that the curvature of the track point has a sudden change when the curvature variation of the adjacent track point is greater than the curvature variation threshold. When the curvature absolute value of a certain track point is larger than the curvature threshold, or the curvature variation of two adjacent track points is larger than the curvature variation threshold, namely, the curvature of the track point has sudden change, the prediction effect of the track prediction model can be influenced. In the embodiment, the training samples with the screened true track value and the overlarge curvature or mutation are put into the training sample set to be repaired for repair, so that the model prediction problem caused by the quality problem of the training samples can be further reduced, and the accuracy and the stability of track prediction are improved. The curvature threshold and the curvature change amount threshold can be reasonably set according to the expected target of the track tracking.
Example 3
The embodiment provides a track prediction denoising device based on a deep learning model, as shown in fig. 3, including a training sample extraction module 1, a tracking track data extraction module 2, a track analysis module 3, a first calculation module 4, a second calculation module 5, a third calculation module 6, a comparison module 7, and a filtering module 8. The training sample extraction module 1 obtains training samples from a track prediction training sample set and inputs the training samples into the tracking track data extraction module 2, the tracking track data extraction module 2 obtains tracking track data from the training samples and inputs the tracking track data into the track analysis module 3, and the track analysis module 3 analyzes the tracking track data by using the prior art to obtain all track points corresponding to a track true value. The first calculation module 4 reads the start point and end point data of the tracking track, and calculates the euclidean distance between the start point and the end point. The second calculation module 5 traverses all the trace points, calculates the euclidean distance between every two adjacent trace points and sums the calculated euclidean distances. The third calculation module 6 inputs the euclidean distance between the starting point and the end point and the sum of the euclidean distances between adjacent track points, and calculates the jitter value by using the following formula: score = perimeter/traj _ len, where score represents the jitter value, traj _ len represents the euclidean distance of the starting point from the end point, and perimeter represents the sum of the euclidean distances of adjacent track points. The comparison module 7 inputs the calculated jitter value, compares the calculated jitter value with a jitter threshold value, and inputs the comparison result into the filtering module 8. When the true track jitter value of a training sample is greater than the jitter threshold, the filtering module 8 obtains the corresponding training sample according to the tracking track ID of the training sample, and deletes the training sample whose jitter value is greater than the jitter threshold from the track prediction training sample set.
Example 4
The embodiment provides a track prediction denoising device based on a deep learning model, which includes a training sample extraction module 1, a tracking track data extraction module 2, a track analysis module 3, a first calculation module 4, a second calculation module 5, a third calculation module 6, a comparison module 7, and a filtering module 8 in embodiment 3, as shown in fig. 4, and further includes a fourth calculation module 9, a fifth calculation module 10, and a screening module 11. After the training samples with shaking track truth values are cleaned by the filtering module 8, the multiplexing training sample extracting module 1 of the embodiment intensively obtains training samples from the rest training samples, the multiplexing tracking track data extracting module 2 obtains tracking track data of the training samples, the multiplexing track analyzing module 3 analyzes the training samples to obtain all track points corresponding to the track truth values, then the fourth calculating module traverses all track points and calculates curvatures of the track points, the fifth calculating module 10 traverses all track points and subtracts the curvatures of adjacent track points to obtain absolute values to obtain curvature variation of the adjacent track points, and finally the screening module 11 screens out the training samples with overlarge track point curvature absolute values or with sudden changes in track point curvature, and puts the training samples into a training sample set to be repaired for repair, so that the model prediction problem caused by the self quality problem of the training samples can be further reduced, and the accuracy and the stability of track prediction are improved.
As shown in fig. 5, the screening module 11 includes a first comparing unit 1101 for comparing the curvature absolute value of the trace point with a curvature threshold; the second comparing unit 1102 is configured to compare the curvature variation of the adjacent track points with a curvature variation threshold, and determine that the curvature of the track points has a sudden change when the curvature variation of the adjacent track points is greater than the curvature variation threshold; the first comparison unit 1101 and the second comparison unit 1102 output comparison results to the screening unit 1103, the screening unit 1103 extracts training samples with track point curvature absolute values larger than a curvature threshold value or with abrupt changes in track point curvature, and the training samples are put into a training sample set to be repaired for repair.
Example 5
The present embodiment provides an apparatus, which includes a memory, a processor, and a program stored on the memory and executable on the processor, and when the program is executed by the processor, the program implements the steps of the trajectory prediction denoising method based on the deep learning model in the foregoing embodiments.
Example 6
The present embodiment provides a storage medium storing at least one program, which is executable by at least one processor, to implement the steps of the trajectory prediction denoising method based on the deep learning model in the above embodiments.
Those of ordinary skill in the art will understand that: although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art will recognize that changes may be made in the form and details of the embodiments without departing from the spirit and scope of the invention. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application.