Trajectory point processing method and vehicle
By improving the multidimensional tree structure and dynamic search radius method, the problem of inaccurate removal of duplicate points in traditional trajectory point processing is solved, achieving efficient and accurate trajectory point deduplication in multiple densities and scenarios, thus improving data processing efficiency and accuracy.
Patent Information
- Application Number
- CN202610415340.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-03-31
- Publication Date
- 2026-07-31
AI Technical Summary
Traditional trajectory point processing methods cannot accurately remove duplicate points in multi-density and multi-scenario environments, leading to increased data storage overhead, transmission latency, and reduced algorithm accuracy.
An improved multidimensional tree structure is adopted, which combines spatial coordinates and timestamps to divide trajectory points and dynamically adjust the search radius. Redundant trajectory points are quickly retrieved and eliminated through the multidimensional tree structure.
It enables accurate removal of redundant trajectory points in multiple densities and scenarios, reducing data storage overhead and improving transmission efficiency and algorithm accuracy.
Smart Images

Figure CN122489531A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the fields of vehicle and data processing technology, and more specifically, to a trajectory point processing method and a vehicle. Background Technology
[0002] In target tracking and trajectory prediction systems, the high-frequency acquisition characteristics of sensors and the need for multi-source data fusion result in the presence of "repeated points" or "redundant points" in trajectory data, thus requiring deduplication of trajectory points.
[0003] Traditional grid-based methods suffer from poor adaptability, making it difficult to balance accuracy and efficiency. Nearest neighbor search methods based on fixed radii are parameter-sensitive and have poor generalization ability. Traditional solutions all rely on a single spatial dimension to determine duplicate points, resulting in incomplete deduplication logic and an inability to accurately remove duplicate points across multiple densities and scenarios.
[0004] There is currently no good solution to the above problems. Summary of the Invention
[0005] This application provides a trajectory point processing method and vehicle to at least solve the technical problem that traditional solutions, which rely solely on a single spatial dimension to determine duplicate points, cannot accurately eliminate duplicate points in multiple densities and scenarios.
[0006] According to one aspect of the embodiments of this application, a trajectory point processing method is provided, comprising: obtaining a set of predicted trajectory points of a vehicle, wherein the trajectory points in the set of predicted trajectory points carry spatial coordinates, timestamps, and motion state labels; constructing a multidimensional tree structure corresponding to the set of predicted trajectory points based on the spatial coordinates and timestamps, wherein the odd-numbered levels of the multidimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, and the even-numbered levels of the multidimensional tree structure are divided based on timestamps; determining the search radius corresponding to the trajectory points based on the motion state labels and the multidimensional tree structure; determining a set of points to be removed from the set of predicted trajectory points based on the search radius and the multidimensional tree structure; and removing the trajectory points from the set of points to be removed from the set of predicted trajectory points to obtain a target set of predicted trajectory points.
[0007] Further, obtaining the vehicle's predicted trajectory point set includes: obtaining an initial predicted trajectory point set for the vehicle; removing a first predicted trajectory point from the initial predicted trajectory point set to obtain a first predicted trajectory point set, wherein the spatial coordinates of the first predicted trajectory point are outside the target boundary; removing a second predicted trajectory point from the first predicted trajectory point set to obtain a second predicted trajectory point set, wherein the timestamp of the second predicted trajectory point is less than the timestamp of the previous predicted trajectory point; and marking the predicted trajectory points in the second predicted trajectory point set with motion state labels according to a preset speed threshold to obtain a predicted trajectory point set, wherein the motion state labels are used to represent the motion mode corresponding to the predicted trajectory point.
[0008] Furthermore, constructing the multidimensional tree structure corresponding to the predicted trajectory point set based on spatial coordinates and timestamps includes: dividing the predicted trajectory point set according to the median of the horizontal coordinates in the spatial coordinates to obtain the division result, wherein the division result includes a left child set and a right child set, where the horizontal coordinates of the predicted trajectory points in the left child set are less than or equal to the median, and the horizontal coordinates of the predicted trajectory points in the right child set are greater than the median; generating a root node based on the division result, wherein the root node is located at an odd level; starting from the root node, dividing the left child set and the right child set of the next level in sequence to generate corresponding nodes, until a multidimensional tree structure is constructed, wherein odd levels are divided alternately according to the median of the horizontal coordinates or the median of the vertical coordinates in the spatial coordinates, and even levels are divided according to the timestamp, and the nodes in the multidimensional tree structure carry the corresponding child set, division dimension, median, and standard deviation of the point set.
[0009] Furthermore, determining the search radius corresponding to the trajectory point based on the motion state label and the multidimensional tree structure includes: adjusting the number of nearest neighbors corresponding to the trajectory point based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure; performing a nearest neighbor search on the trajectory point in the multidimensional tree structure based on the number of nearest neighbors and the priority search rule to obtain a set of nearest neighbors, wherein the priority search rule is used to search within the set of sub-points whose timestamps meet the search requirements; determining the Euclidean distance between the trajectory point and the target nearest neighbor based on the set of nearest neighbors, wherein the target nearest neighbor is the nearest neighbor farthest from the trajectory point in the set of nearest neighbors; and determining the search radius corresponding to the trajectory point based on the motion state label and the Euclidean distance.
[0010] Furthermore, based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure, the number of nearest neighbor points corresponding to the trajectory point is adjusted as follows: if the standard deviation of the point set is less than the preset density threshold, the number of nearest neighbor points is increased; if the standard deviation of the point set is greater than or equal to the preset density threshold, the number of nearest neighbor points is decreased.
[0011] Furthermore, determining the search radius corresponding to the trajectory point based on the motion state label and Euclidean distance includes: adjusting the motion state correction factor corresponding to the trajectory point based on the motion state label; and determining the search radius corresponding to the predicted trajectory point based on the global scaling factor, the motion state correction factor, and the Euclidean distance.
[0012] Furthermore, adjusting the motion state correction factor corresponding to the trajectory point based on the motion state label includes: increasing the motion state correction factor if the motion state label is a stationary label or a first velocity label; and decreasing the motion state correction factor if the motion state label is a second velocity label, wherein the velocity corresponding to the second velocity label is higher than the velocity corresponding to the first velocity label.
[0013] Further, based on the search radius and the multidimensional tree structure, the set of points to be eliminated in the predicted trajectory point set is determined as follows: A spatial range search is performed in the multidimensional tree structure with the trajectory point as the center and the search radius corresponding to the trajectory point as the radius, to obtain a spatial candidate point set; erroneous trajectory points are eliminated from the spatial candidate point set to obtain a spatiotemporal candidate point set, wherein the difference between the timestamp of the erroneous trajectory point and the timestamp of the trajectory point is greater than a preset time threshold; if the spatiotemporal candidate point set contains a single trajectory point, the trajectory point is marked as a representative point; or, if the spatiotemporal candidate point set contains multiple trajectory points, the trajectory point with the earliest timestamp among the multiple trajectory points is marked as a representative point; or, if the timestamps of multiple trajectory points are the same, the trajectory point whose motion state label is consistent with the motion state label of the previous trajectory point among the multiple trajectory points is marked as a representative point; the trajectory points in the spatiotemporal candidate point set other than the representative points are summarized to obtain the set of points to be eliminated.
[0014] Furthermore, any trajectory point in the multidimensional tree structure carries an expiration date label, which indicates the retention period of any trajectory point. The method also includes: inserting a new trajectory point into a target node in the multidimensional tree structure during vehicle operation; if the number of trajectory points corresponding to the target node is greater than a preset threshold, splitting the target node, wherein the number of trajectory points is the number of trajectory points contained in the child point set corresponding to the target node; and / or deleting the target trajectory point from the multidimensional tree structure according to a preset time interval and the expiration date label, and deleting invalid nodes from the multidimensional tree structure, wherein the difference between the timestamp of the target trajectory point and the current time is greater than the retention period corresponding to the target trajectory point, and the child point set corresponding to the invalid node is empty.
[0015] According to another aspect of the embodiments of this application, a trajectory point processing apparatus is also provided, comprising: an acquisition module, configured to acquire a set of predicted trajectory points of a vehicle, wherein the trajectory points in the set of predicted trajectory points carry spatial coordinates, timestamps, and motion state labels; a construction module, configured to construct a multi-dimensional tree structure corresponding to the set of predicted trajectory points based on the spatial coordinates and timestamps, wherein the odd-numbered levels of the multi-dimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, and the even-numbered levels of the multi-dimensional tree structure are divided based on the timestamps; a first determination module, configured to determine the search radius corresponding to the trajectory points based on the motion state labels and the multi-dimensional tree structure; a second determination module, configured to determine a set of points to be removed from the set of predicted trajectory points based on the search radius and the multi-dimensional tree structure; and a removal module, configured to remove the trajectory points from the set of points to be removed from the set of predicted trajectory points to obtain a target set of predicted trajectory points.
[0016] According to another aspect of the embodiments of this application, a vehicle is also provided, including: a memory storing an executable program; and a processor for running the program, wherein the program executes the methods in various embodiments of this application when it runs.
[0017] According to another aspect of the embodiments of this application, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored executable program, wherein, when the executable program is running, it controls the device where the computer-readable storage medium is located to perform the methods of various embodiments of this application.
[0018] According to another aspect of the embodiments of this application, a computer program product is also provided, including a computer program that, when executed by a processor, implements the methods of various embodiments of this application.
[0019] According to another aspect of the embodiments of this application, a computer program product is also provided, including a non-volatile computer-readable storage medium storing a computer program that, when executed by a processor, implements the methods in various embodiments of this application.
[0020] According to another aspect of the embodiments of this application, a computer program is also provided, which, when executed by a processor, implements the methods of the various embodiments of this application.
[0021] In this embodiment, a trajectory point processing method is employed to obtain a set of predicted trajectory points for a vehicle. Each trajectory point in the predicted trajectory point set carries spatial coordinates, a timestamp, and a motion state label. A multi-dimensional tree structure corresponding to the predicted trajectory point set is constructed based on the spatial coordinates and timestamps. Odd-numbered levels of the multi-dimensional tree structure are partitioned based on alternating horizontal and vertical coordinates of the spatial coordinates, while even-numbered levels are partitioned based on the timestamps. The search radius corresponding to each trajectory point is determined based on the motion state label and the multi-dimensional tree structure. A set of points to be removed from the predicted trajectory point set is determined based on the search radius and the multi-dimensional tree structure. Trajectories from the set of points to be removed are removed from the predicted trajectory point set to obtain the target predicted trajectory point set. This achieves the goal of dynamically adapting to trajectory data with different densities and motion states, thereby realizing the technical effect of accurately removing spatiotemporally redundant trajectory points. This solves the technical problem of traditional solutions that rely solely on a single spatial dimension to determine duplicate points, failing to accurately remove duplicate points in multi-density and multi-scenario scenarios. Attached Figure Description
[0022] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0023] Figure 1 This is a flowchart of a trajectory point processing method according to an embodiment of this application;
[0024] Figure 2 This is a flowchart of a trajectory point processing technology solution according to an embodiment of this application;
[0025] Figure 3 This is a flowchart of trajectory point preprocessing and improved multidimensional tree construction according to an embodiment of this application;
[0026] Figure 4 This is a flowchart of an adaptive radius calculation according to an embodiment of this application;
[0027] Figure 5 This is a flowchart of a spatiotemporal joint repetition point search and marking according to an embodiment of this application;
[0028] Figure 6 This is a flowchart of a duplicate point removal and multidimensional tree dynamic update according to an embodiment of this application;
[0029] Figure 7 This is a structural block diagram of a trajectory point processing device according to an embodiment of this application. Detailed Implementation
[0030] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0031] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0032] In traditional target tracking and trajectory prediction systems, the high-frequency acquisition characteristics of sensors and the need for multi-source data fusion result in the prevalence of "repeated points" or "redundant points" in trajectory data. These points are extremely close in spatial coordinates and have very short timestamp intervals. In certain specific scenarios, they cannot reflect the actual changes in the target's motion state. However, a large number of trajectory points significantly increases data storage overhead; for example, millions of trajectory points require more than 50% additional storage space. They also reduce transmission efficiency, such as increasing data transmission latency by about 30% in vehicle-to-everything (V2X) scenarios, and interfere with the accuracy of subsequent trajectory clustering, target behavior analysis, and path planning algorithms. For example, they can cause problems in path planning, affecting the driver's experience.
[0033] In traditional schemes, trajectory point deduplication methods can be divided into the following two categories:
[0034] 1. Grid-based deduplication method: The core logic is to divide the target motion space into uniform grid cells, treat all trajectory points falling within the same grid cell as duplicate points, and retain only the first acquisition point, the geometric center of the point set, or the middle point of the timestamp, etc. The advantage of this method is its low computational complexity, making it suitable for scenarios with high real-time requirements but low data accuracy requirements. It can be applied to roughly remove obviously duplicate data points using grid filtering methods before inserting trajectory point data into a multidimensional tree.
[0035] 2. Fixed-radius nearest neighbor search deduplication method: This method presets a uniform search radius for all trajectory points. Using spatial indexing structures such as multidimensional trees and ball trees, it performs a "nearest neighbor search within the radius" for each trajectory point. If other trajectory points exist in the search results, these are considered duplicates and removed. Compared to grid-based deduplication, it offers higher accuracy and is suitable for scenarios with high trajectory accuracy requirements, such as autonomous driving and drone navigation, for example, deduplicating vehicle trajectories collected by LiDAR.
[0036] However, traditional solutions have their own shortcomings and deficiencies. Although the above methods can achieve basic deduplication in specific scenarios, they still have the following insurmountable defects in complex practical applications.
[0037] Mesh-based methods suffer from poor adaptability, making it difficult to balance accuracy and efficiency. First, while mesh size is a core parameter determining the method's performance, it lacks adaptive adjustment capabilities. If the mesh size is too large, spatially adjacent trajectory points belonging to different motion states may be misclassified as duplicates, such as continuous trajectory points generated by a target vehicle changing lanes. This can lead to the loss of important trajectory points in the predicted trajectory and the mistaken straightening of the trajectory. Conversely, if the mesh size is too small, it cannot effectively merge duplicate points in dense areas, such as multiple trajectory points collected when the vehicle is stationary, resulting in low deduplication efficiency and increased mesh storage and traversal overhead. Second, mesh-based methods cannot adapt to irregular motion spaces. For example, in non-rectangular areas such as curves, intersections, and forks, uniform mesh segmentation can lead to "boundary fragmentation," causing continuous trajectory points of the same target to be misclassified as non-duplicate points due to crossing mesh boundaries, further reducing deduplication accuracy.
[0038] Nearest neighbor search methods based on fixed radii are parameter-sensitive and have poor generalization ability. First, fixed radii rely on prior knowledge, resulting in high parameter adjustment costs: the search radius needs to be manually adjusted according to the specific scenario (such as target speed, sensor accuracy, and environmental density). For example, for low-speed vehicles (e.g., 5 km / h), a search radius of 1.0m can effectively remove duplicates, but for high-speed vehicles (e.g., 100 km / h), the same search radius will misclassify consecutive valid trajectory points (e.g., the vehicle travels approximately 2.8m within 100ms, and the distance between adjacent trajectory points is 2.8m) as non-repeating points, leading to deduplication failure. If the radius is adjusted to 3.0m for high-speed scenarios, it will over-merge trajectory points in low-speed scenarios, such as misclassifying consecutive trajectory points when the vehicle is turning as duplicates. In actual assisted driving systems, different radius parameters need to be configured for different scenarios, increasing system complexity and maintenance costs. Second, it cannot handle multi-density trajectory regions, as the same trajectory dataset often contains "sparse areas" and "dense areas". For example, when assisted driving vehicles are driving on highways or elevated roads, the target trajectory points are sparse, while when driving in urban or rural areas, the target trajectory points are dense. A fixed radius cannot simultaneously adapt to both types of areas. If the search radius is small, valid trajectory points in sparse areas will be misjudged as duplicate points, and duplicate points in dense areas cannot be completely eliminated.
[0039] The common drawback of both methods is the lack of a temporal dimension for determination, resulting in relatively simple deduplication logic. Traditional solutions only determine duplicate points based on the spatial dimension, ignoring timestamp information. For example, if a vehicle passes the same parking spot twice within a certain time period, it will be misjudged as a duplicate point; conversely, two trajectory points with the same timestamp and extremely close spatial distance may be misjudged as non-duplicate points if the parameters are improperly set, such as an excessively large grid size or an excessively small radius. The lack of a temporal dimension leads to incomplete deduplication logic, making it impossible to accurately distinguish between spatiotemporally repeated points and spatiotemporally independent points.
[0040] This application relates to the fields of vehicle and data processing technology, specifically focusing on trajectory data optimization in three core application areas: computer vision, autonomous driving, and target tracking and trajectory prediction. More specifically, this application provides a trajectory point processing method based on an improved multidimensional tree search strategy for target trajectory point data collected by various types of sensors (LiDAR providing high-precision spatial coordinates, millimeter-wave radar resisting severe weather interference, and cameras capturing semantic information) or generated through iterative prediction using algorithms such as Long Short-Term Memory (LSTM) networks and Transformers.
[0041] It can efficiently and accurately remove duplicate or redundant trajectory points caused by redundant sensor acquisition and algorithm jitter in both spatiotemporal dimensions. It is suitable for scenarios with extremely high requirements for trajectory data accuracy and real-time performance, such as autonomous driving parking path planning, intelligent transportation vehicle-road cooperative target tracking, drone low-altitude inspection trajectory optimization, and robot indoor motion control. It is especially suitable for complex application environments with asynchronous fusion of multiple sensors and centralized generation of high-density trajectory points.
[0042] According to an embodiment of this application, a method embodiment for trajectory point processing is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0043] This embodiment provides a trajectory point processing method. Figure 1 This is a flowchart of a trajectory point processing method according to an embodiment of this application, such as... Figure 1 As shown, the process includes the following steps:
[0044] Step S11: Obtain the predicted trajectory point set of the vehicle, wherein the trajectory points in the predicted trajectory point set carry spatial coordinates, timestamps and motion state labels.
[0045] In this embodiment of the application, a set of predicted trajectory points for the vehicle is first obtained. The trajectory points in the set of predicted trajectory points carry spatial coordinates, timestamps, and motion state labels to describe the future motion path of the target vehicle.
[0046] As can be seen, the trajectory point processing system acquires a set of trajectory points containing spatial coordinates, timestamps, and motion state labels, which serve as the input data source for subsequent deduplication. Each trajectory point contains three-dimensional features: spatial coordinates, timestamps, and motion state labels, such as uniform speed, acceleration, and stillness.
[0047] For example, an autonomous vehicle predicts its own trajectory within the next second and outputs 10 points. Each point, such as (x=15.2m, y=3.1m, z=0m, t=1680001234ms, s=uniform speed), indicates that the point is located at spatial coordinates (15.2, 3.1) and is in a uniform speed state at time 1680001234 milliseconds.
[0048] This provides a data foundation for subsequent adaptive judgments to be based on real motion characteristics.
[0049] Step S12: Construct a multidimensional tree structure corresponding to the predicted trajectory point set based on spatial coordinates and timestamps. The odd-numbered levels of the multidimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, while the even-numbered levels of the multidimensional tree structure are divided based on timestamps.
[0050] In this embodiment of the application, the trajectory point processing constructs a multidimensional tree structure corresponding to the predicted trajectory point set based on spatial coordinates and timestamps. The odd-numbered levels of the multidimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, while the even-numbered levels of the multidimensional tree structure are divided based on timestamps. The multidimensional tree structure is used to efficiently organize and retrieve trajectory points with spatiotemporal attributes.
[0051] As can be seen, the trajectory point processing system constructs a multi-dimensional tree structure based on the spatial coordinates and timestamps of the trajectory points. This structure alternates between x and y coordinates for odd-numbered layers and timestamps for even-numbered layers, thus achieving ordered indexing in both spatial and temporal dimensions.
[0052] For example, the root node (level 1) can be divided according to the median of the x-coordinate, its child nodes (level 2) according to the median of the timestamp, and the next level (level 3) according to the median of the y-coordinate, and so on, to form a spatiotemporally hierarchical tree index.
[0053] This improves the efficiency of retrieving spatiotemporally nearby points during subsequent nearest neighbor searches and avoids misjudgments caused by ignoring time information in pure spatial indexes.
[0054] Step S13: Determine the search radius corresponding to the trajectory point based on the motion state label and the multidimensional tree structure.
[0055] In this embodiment, the trajectory point processing system determines the search radius corresponding to each trajectory point based on the motion state label and the multidimensional tree structure. The search radius refers to the spatial distance threshold centered on each trajectory point, used to define potential repeating points within its neighborhood. This value is dynamically calculated based on local point density and motion state, rather than being fixed.
[0056] It can be seen that the trajectory point processing system combines the motion state label of the trajectory point with the corresponding node in the multidimensional tree structure to adaptively calculate the exclusive search radius of each trajectory point, which is used for subsequent spatiotemporal joint deduplication judgment.
[0057] For example, if a trajectory point is located in a dense intersection area and is in a "low speed" state, the search radius is 0.66m based on the smaller k-nearest neighbor distance multiplied by the magnification factor; if it is located in a sparse area of a highway section and is in a "uniform speed" state, the corresponding radius is 2.16m.
[0058] This allows the search radius to adapt to changes in scene density and motion characteristics, avoiding misjudgment problems under different road conditions with a fixed radius.
[0059] Step S14: Determine the set of points to be removed from the predicted trajectory point set based on the search radius and the multidimensional tree structure.
[0060] In this embodiment, the trajectory point processing system determines the set of points to be eliminated from the predicted trajectory point set based on the search radius and the multidimensional tree structure. The set of points to be eliminated refers to the set of other trajectory points that are spatially and temporally too close to the current trajectory point and are deemed redundant or duplicated, given a given search radius and time threshold constraints.
[0061] As can be seen, the trajectory point processing system uses a multi-dimensional tree structure to quickly retrieve the time neighbors of each trajectory point within the adaptive search radius, and combines a preset time window to filter out points that meet the repetition condition in both spatial and temporal dimensions, thus forming a set of points to be removed.
[0062] For example, five spatially adjacent points are found within a radius of 0.66m centered on a low-speed driving trajectory point. Three of these points have a timestamp difference of ≤150ms and are marked as points to be removed, while the two points with time differences exceeding the limit are retained.
[0063] Therefore, by combining spatiotemporal screening, duplicate points caused by sensor redundancy or algorithm jitter can be effectively identified and marked, thereby improving the purity of trajectory data.
[0064] Step S15: Remove the trajectory points from the set of points to be removed from the set of predicted trajectory points to obtain the set of target predicted trajectory points.
[0065] In this embodiment, the trajectory point processing system removes trajectory points from the set of points to be eliminated from the predicted trajectory point set to obtain the target predicted trajectory point set. The target predicted trajectory point set refers to the subset of trajectory points retained after deduplication, free from spatiotemporal redundancy, used for subsequent path planning or behavior analysis, and possessing higher accuracy and consistency.
[0066] As can be seen, the trajectory point processing system removes points marked as to be eliminated from the original predicted trajectory point set, retaining only trajectory points with good uniqueness, thus forming a simplified target predicted trajectory point set.
[0067] For example, the original set contains 100 points. After detection, 23 points were marked as duplicates. After removal, a set of 77 retained points is obtained, which has a more sparse and reasonable spatial distribution and does not affect the temporal continuity.
[0068] Therefore, without losing the integrity of the trajectory, redundant data is effectively reduced, improving the processing efficiency and reliability of subsequent algorithms.
[0069] In summary, the trajectory point processing method of this application first obtains the predicted trajectory point set of the vehicle, providing a data foundation for subsequent adaptive judgment based on real motion characteristics. Secondly, it constructs a multi-dimensional tree structure corresponding to the predicted trajectory point set based on spatial coordinates and timestamps, improving the retrieval efficiency of spatiotemporally nearby points during subsequent nearest neighbor search and avoiding misjudgments caused by ignoring temporal information in pure spatial indexing. Then, based on motion state labels and the multi-dimensional tree structure, it determines the search radius corresponding to the trajectory points, enabling the search radius to adaptively change with scene density and motion characteristics, avoiding misjudgments under different road conditions with a fixed radius. Subsequently, based on the search radius and the multi-dimensional tree structure, it determines the set of points to be removed from the predicted trajectory point set. Through spatiotemporal joint filtering, it effectively identifies and marks duplicate points caused by sensor redundancy or algorithm jitter, improving the purity of trajectory data. Finally, it removes trajectory points from the set of points to be removed from the predicted trajectory point set to obtain the target predicted trajectory point set. This effectively reduces redundant data without sacrificing trajectory integrity, improving the processing efficiency and reliability of subsequent algorithms.
[0070] The above steps of this application obtain a set of predicted trajectory points for the vehicle, wherein each trajectory point in the predicted trajectory point set carries spatial coordinates, a timestamp, and a motion state label; a multi-dimensional tree structure corresponding to the predicted trajectory point set is constructed based on the spatial coordinates and timestamps, wherein odd-numbered levels of the multi-dimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, and even-numbered levels of the multi-dimensional tree structure are divided based on the timestamps; the search radius corresponding to the trajectory point is determined based on the motion state label and the multi-dimensional tree structure; the set of points to be removed from the predicted trajectory point set is determined based on the search radius and the multi-dimensional tree structure; and the trajectory points in the set of points to be removed are removed from the predicted trajectory point set to obtain the target predicted trajectory point set. This achieves the technical effect of accurately removing spatiotemporally redundant trajectory points, thereby solving the technical problem that traditional solutions, which rely solely on a single spatial dimension to determine duplicate points, cannot accurately remove duplicate points in multi-density and multi-scenario scenarios.
[0071] Optionally, in step S11, obtaining the predicted trajectory point set of the vehicle may include the following execution steps:
[0072] Step S111: Obtain the initial predicted trajectory point set for the vehicle.
[0073] Step S112: Remove the first predicted trajectory point from the initial predicted trajectory point set to obtain the first predicted trajectory point set, wherein the spatial coordinates of the first predicted trajectory point are outside the target boundary.
[0074] Step S113: Remove the second predicted trajectory point from the first predicted trajectory point set to obtain the second predicted trajectory point set, wherein the timestamp of the second predicted trajectory point is less than the timestamp of the previous predicted trajectory point.
[0075] Step S114: According to the preset speed threshold, mark the predicted trajectory points in the second predicted trajectory point set with motion state labels to obtain the predicted trajectory point set, wherein the motion state labels are used to represent the motion mode corresponding to the predicted trajectory points.
[0076] In this embodiment of the application, the trajectory point processing system first obtains the initial predicted trajectory point set of the vehicle. The initial predicted trajectory point set refers to the directly obtained, unprocessed sequence of raw trajectory points, containing the spatial coordinates, timestamp, and motion state information of each point.
[0077] As can be seen, the trajectory point processing system reads the output results from the vehicle's prediction model to obtain the original trajectory point set containing spatial location, timestamp, and motion state, which serves as the input basis for subsequent processing.
[0078] For example, the vehicle predicts its own motion path within the next second and outputs a sequence of 20 points, such as (x=10.1m, y=2.5m, t=1680001000ms, s=uniform speed). Each point is directly generated by the model without removing redundancy.
[0079] This provides complete raw data support for trajectory deduplication, ensuring that subsequent processing is based on the actual prediction results and avoiding information loss.
[0080] Secondly, the trajectory point processing system removes the first predicted trajectory point from the initial predicted trajectory point set to obtain the first predicted trajectory point set. The spatial coordinates of the first predicted trajectory point are outside the target boundary. The first predicted trajectory point refers to the target trajectory point whose spatial coordinates exceed the boundary of the preset road or drivable area, which is an abnormal output that is physically unreachable.
[0081] As can be seen, the trajectory point processing system filters out points located outside the boundary in the initial predicted trajectory points based on the definition of the vehicle's drivable boundary, and retains all trajectory points located within the legal area to form the first predicted trajectory point set.
[0082] For example, a predicted point has coordinates (x=-3.2m, y=5.1m), while the lane boundary is x≥0. This point is identified as an out-of-bounds point and removed. The remaining 19 points are all located within the lane, forming the first predicted trajectory point set.
[0083] This eliminates unreasonable prediction points and improves the physical feasibility and security of trajectory data.
[0084] Then, the trajectory point processing system removes the second predicted trajectory point from the first predicted trajectory point set to obtain the second predicted trajectory point set. The timestamp of the second predicted trajectory point is less than the timestamp of the previous predicted trajectory point. The second predicted trajectory point refers to an abnormal trajectory point whose timestamp is reversed (i.e., the time of the later point is earlier than the time of the previous point), which violates the principle of physical time continuity.
[0085] As can be seen, the trajectory point processing system traverses the first predicted trajectory point set, detects and removes points whose timestamps do not satisfy the monotonically increasing relationship, and ensures that the remaining trajectory points are arranged in chronological order to form the second predicted trajectory point set.
[0086] For example, a point in the sequence has a timestamp of 1680001050ms, and the next point has a timestamp of 1680001030ms. The latter point has the reversed time and is identified as the second predicted trajectory point and is removed. The remaining points maintain the ascending time order.
[0087] This eliminates time-disruption points, ensuring the rationality of the trajectory timing and the stability of subsequent processing.
[0088] Finally, the trajectory point processing system labels the predicted trajectory points in the second predicted trajectory point set with motion state tags according to a preset speed threshold, thus obtaining the predicted trajectory point set. The motion state tags represent the motion mode corresponding to each predicted trajectory point. Specifically, the motion state tags are category identifiers based on the speed changes between adjacent trajectory points, used to characterize the target's current motion mode, including stationary, low-speed, uniform speed, or high-speed.
[0089] As can be seen, the trajectory point processing system calculates the velocity difference between each point in the second predicted trajectory point set and the previous point, classifies them into corresponding motion state labels according to a preset velocity threshold, and generates a final predicted trajectory point set with labels.
[0090] For example, if the velocity difference between a certain trajectory point and the previous point is 0.2 m / s, which is below the low-speed threshold of 1.5 m / s, it is marked as stationary. If the velocity difference between another point and the previous point is 8.5 m / s, which exceeds the high-speed threshold of 25 m / s, it is marked as high-speed.
[0091] This provides motion feature basis for subsequent adaptive radius calculation, improving the adaptability of deduplication logic to real driving behavior.
[0092] Optionally, in step S12, constructing the multidimensional tree structure corresponding to the predicted trajectory point set based on spatial coordinates and timestamps may include the following execution steps:
[0093] Step S121: Divide the set of predicted trajectory points according to the median of the horizontal coordinates in the spatial coordinates to obtain the division result. The division result includes a left child set and a right child set. The horizontal coordinates of the predicted trajectory points in the left child set are less than or equal to the median, and the horizontal coordinates of the predicted trajectory points in the right child set are greater than the median.
[0094] Step S122: Generate a root node based on the partitioning result, wherein the root node is located at an odd level.
[0095] Step S123: Starting from the root node, the left and right child sets of the next level are partitioned sequentially to generate corresponding nodes until a multidimensional tree structure is constructed. Odd-numbered levels are partitioned alternately based on the median of the horizontal or vertical coordinates in the spatial coordinate system, while even-numbered levels are partitioned based on the timestamp. Each node in the multidimensional tree structure carries the corresponding child set, partition dimension, median, and standard deviation of the point set.
[0096] In this embodiment of the application, firstly, the trajectory point processing system divides the predicted trajectory point set according to the median of the horizontal coordinates in the spatial coordinates to obtain the division result. The division result includes a left child point set and a right child point set. The horizontal coordinates of the predicted trajectory points in the left child point set are less than or equal to the median, and the horizontal coordinates of the predicted trajectory points in the right child point set are greater than the median.
[0097] The horizontal coordinate refers to the coordinate of the trajectory point in the horizontal plane in the direction perpendicular to the vehicle's direction of travel (such as the y-coordinate).
[0098] As can be seen, the trajectory point processing system calculates the median based on the lateral coordinates of all points in the predicted trajectory point set, and divides the point set into two: those with lateral coordinates less than or equal to the median are assigned to the left subset, and those with lateral coordinates greater than the median are assigned to the right subset.
[0099] For example, the horizontal coordinates of the predicted trajectory point set are [1.2, 3.5, 2.1, 4.8, 2.9], the median is 2.9, the left child point set contains [1.2, 2.1, 2.9], and the right child point set contains [3.5, 4.8].
[0100] This enables efficient binary organization of space, providing a structural foundation for multidimensional tree construction and improving the efficiency of subsequent searches.
[0101] Then, the trajectory point processing system generates a root node based on the partitioning result. The root node is located at an odd level and is the starting node of the multidimensional tree, used to initiate spatial recursive partitioning.
[0102] As can be seen, based on the partitioning results, the trajectory point processing system creates a root node and binds the left child point set, the right child point set, and the median of the horizontal coordinates as the first-level node of the multidimensional tree.
[0103] For example, after partitioning, the left child set contains 3 points and the right child set contains 2 points, with a horizontal median of 2.9m. A root node is generated and the partitioning dimension is marked as the x-axis, with a level of 1 (odd level).
[0104] Thus, the initial root node of the tree structure is established, providing structural support for subsequent recursive construction and spatiotemporal joint search.
[0105] Finally, starting from the root node, the trajectory point processing system sequentially divides the left and right child point sets of the next level, generating corresponding nodes, until a multidimensional tree structure is constructed. Odd-numbered levels are divided alternately based on the median of the horizontal or vertical coordinates in the spatial coordinate system, while even-numbered levels are divided based on the timestamp. Each node in the multidimensional tree structure carries the corresponding child point set, the division dimension, the median, and the standard deviation of the point set.
[0106] As can be seen, the trajectory point processing system starts from the root node and recursively performs partitioning on each layer of sub-points: odd-numbered layers are partitioned according to the median of the horizontal or vertical coordinates, and even-numbered layers are partitioned according to the median of the timestamp, continuing until all point sets are organized into a tree structure. Each node records its own sub-point set, partitioning dimension, median, and standard deviation.
[0107] For example, after the root node (level 1, x-axis) is partitioned, its left child node (level 2) is partitioned by the median of the timestamp, and the next level (level 3) partitions the subsets by the median of the y-coordinate, forming an alternating structure of x→t→y, with each node having a set of points and standard deviation.
[0108] Therefore, by alternating between spatiotemporal partitioning, search efficiency is improved, providing a structural basis for adaptive radius calculation and spatiotemporal joint deduplication.
[0109] Optionally, in step S13, determining the search radius corresponding to the trajectory point based on the motion state label and the multidimensional tree structure may include the following steps:
[0110] Step S131: Adjust the number of nearest neighbors corresponding to the trajectory point based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure.
[0111] Step S132: In the multidimensional tree structure, perform a nearest neighbor search on the trajectory points according to the number of nearest neighbors and the priority search rule to obtain a set of nearest neighbors. The priority search rule is used to search the set of sub-points whose timestamps meet the search requirements.
[0112] Step S133: Determine the Euclidean distance between the trajectory point and the target nearest neighbor based on the nearest neighbor set, where the target nearest neighbor is the nearest neighbor point in the nearest neighbor set that is farthest from the trajectory point.
[0113] Step S134: Determine the search radius corresponding to the trajectory point based on the motion state label and Euclidean distance.
[0114] In this embodiment, the trajectory point processing system first adjusts the number of nearest neighbor points corresponding to a trajectory point based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure. The standard deviation of the point set reflects the spatial density of the trajectory points within a node; a smaller standard deviation indicates a more clustered distribution of points, and is used to assess local density to dynamically adjust the nearest neighbor search scale.
[0115] The number of nearest neighbors corresponding to a trajectory point refers to the number of nearest neighbors retrieved for that trajectory point in the nearest neighbor search, which is used as the basis for determining the adaptive radius.
[0116] As can be seen, the trajectory point processing system increases the number of neighboring points to cover denser areas based on the standard deviation of the point set of the multidimensional tree node to which the trajectory point belongs. Conversely, it decreases the number of neighboring points to avoid over-searching of sparse areas when the standard deviation is small.
[0117] For example, if the standard deviation of the node where a trajectory point is located is 0.5m (dense), then its k value is set to 8; if the standard deviation of the node is 1.5m (sparse), then the number of neighboring points is set to 3.
[0118] This allows the number of nearest neighbors to be adaptively adjusted according to local density, improving the rationality of radius calculation and the accuracy of subsequent deduplication.
[0119] Secondly, in the multidimensional tree structure, the trajectory point processing system performs nearest neighbor search on the trajectory points according to the number of nearest neighbor points and the priority search rule to obtain the nearest neighbor point set. The priority search rule is used to search the sub-point set whose timestamps meet the search requirements. In the multidimensional tree search process, the priority search rule prioritizes traversing the subtree branches whose timestamps are close to the target point to accelerate the spatiotemporal joint matching efficiency.
[0120] Nearest neighbor search finds the k nearest points to the target point based on a specified number of nearest neighbor points; the nearest neighbor set is the set of the k trajectory points in the search results that are spatially closest to the target point.
[0121] It can be seen that the trajectory point processing system performs nearest neighbor search in the improved multidimensional tree according to the priority search rule (prioritizing the retrieval of child nodes with similar timestamps) to obtain the set of nearest neighbors of the target trajectory point.
[0122] For example, if the target point timestamp is 1050ms, the search will first enter the subtree with the median timestamp in the range of 1000–1100ms, and finally find 8 nearest spatial points in this area to form a set of nearest neighbors.
[0123] Therefore, while ensuring the accuracy of spatial proximity, prioritizing points that are temporally similar improves search efficiency and reduces invalid calculations.
[0124] Then, the trajectory point processing system determines the Euclidean distance between the trajectory point and the target nearest neighbor based on the nearest neighbor set, where the target nearest neighbor is the nearest neighbor point farthest from the trajectory point in the nearest neighbor set.
[0125] Euclidean distance is a measure of the straight-line distance between two points in space, calculated by taking the square root of the sum of the squares of their coordinate differences; the target nearest neighbor is the point in the nearest neighbor set that has the largest spatial distance from the current trajectory point.
[0126] As can be seen, the trajectory point processing system selects the point farthest from the current trajectory point from the set of nearest neighbors, calculates the Euclidean distance between that point and the trajectory point, and uses it as the benchmark value for the adaptive radius.
[0127] For example, among the eight nearest neighbors of a certain trajectory point, the farthest point is 0.54m away from it in space. This value is the determined target nearest neighbor distance.
[0128] Therefore, by using the distance between the farthest and nearest neighbors in a local area as a benchmark, the point density is naturally reflected, allowing the radius to adaptively match the actual distribution and providing a reasonable basis for the dynamic radius.
[0129] Finally, the trajectory point processing system determines the search radius corresponding to the trajectory point based on the motion state label and Euclidean distance.
[0130] It can be seen that the trajectory point processing system combines the motion state label of the trajectory point with the Euclidean distance of the target's nearest neighbor points to adjust the search radius. The slower the motion, the larger the radius, and the faster the motion, the smaller the radius.
[0131] For example, if the motion state of a point is "low speed" and the Euclidean distance is 0.54m, the calculated search radius is 0.71m; if it is "high speed", the radius is 0.52m.
[0132] This allows the search radius to be dynamically adjusted according to the motion state, improving the deduplication accuracy under different motion state labels.
[0133] Optionally, in step S131, adjusting the number of nearest neighbors corresponding to a trajectory point based on the standard deviation of the point set corresponding to a node in the multidimensional tree structure may include the following steps:
[0134] Step S1311: If the standard deviation of the point set is less than the preset density threshold, increase the number of nearest neighbor points.
[0135] Step S1312: If the standard deviation of the point set is greater than or equal to the preset density threshold, reduce the number of nearest neighbor points.
[0136] In this embodiment, firstly, if the standard deviation of the point set is less than a preset density threshold, the trajectory point processing system increases the number of nearest neighbor points. The preset density threshold is a pre-defined critical value for the standard deviation of the point set, used to distinguish between sparse and dense regions in the spatial distribution of trajectory points.
[0137] It can be seen that when the standard deviation of the coordinates of the trajectory points within a certain multidimensional tree node is less than the preset density threshold, it indicates that the point density in that area is high. Therefore, the number of points in the nearest neighbor search should be increased to ensure that enough potential duplicate points are covered.
[0138] For example, if the preset density threshold is set to 0.8m and the standard deviation of a certain node set is 0.6m, the system increases the number of neighboring search points from 3 to 8 to more fully search the neighboring points of the dense area.
[0139] Therefore, the search range is increased in high-density areas to avoid missing duplicate points due to insufficient neighbor points.
[0140] Secondly, if the standard deviation of the point set is greater than or equal to the preset density threshold, the trajectory point processing system reduces the number of nearest neighbor points.
[0141] It can be seen that when the standard deviation of the coordinates of the trajectory points within a certain multidimensional tree node is greater than or equal to the preset density threshold, it indicates that the points in that area are sparsely distributed. Therefore, the number of points for nearest neighbor search should be reduced to reduce computational redundancy and avoid misjudgment.
[0142] For example, if the preset density threshold is 0.8m and the standard deviation of a certain node set is 1.2m, the system reduces the number of neighboring points searched from 8 to 3, and only searches a small number of neighboring points to match the features of sparse regions.
[0143] Therefore, unnecessary searches are reduced in low-density areas, query efficiency is improved, and the erroneous removal of valid points due to excessively large neighborhoods is prevented.
[0144] Optionally, in step S134, determining the search radius corresponding to the trajectory point based on the motion state label and Euclidean distance may include the following steps:
[0145] Step S1341: Adjust the motion state correction factor corresponding to the trajectory point according to the motion state label.
[0146] Step S1342: Determine the search radius corresponding to the predicted trajectory point based on the global scaling factor, motion state correction factor, and Euclidean distance.
[0147] In this embodiment, the trajectory point processing system first adjusts the motion state correction factor corresponding to the trajectory point based on the motion state label. The motion state correction factor is a weighting coefficient that dynamically adjusts the search radius based on the motion state of the trajectory point (e.g., stationary, low speed, high speed).
[0148] It can be seen that the trajectory point processing system assigns a larger correction factor to stationary or low-speed points to expand the search radius, and assigns a smaller correction factor to high-speed points to shrink the search radius, based on the motion state label of the trajectory points.
[0149] For example, for trajectory points with a motion state of "stationary" or "low speed", the correction factor can be 1.1 to increase the search radius by 10% to merge dense redundant points caused by sensor jitter; for trajectory points with a motion state of "high speed", the correction factor can be 0.8 to reduce the search radius by 20% to avoid misjudging continuous trajectory points with real forward motion as repeated points.
[0150] This allows the search radius to match the target's motion characteristics, improving the accuracy of merging redundant points when stationary and retaining effective points when moving at high speeds.
[0151] Secondly, the trajectory point processing system determines the search radius corresponding to the predicted trajectory point based on the global scaling factor, motion state correction factor, and Euclidean distance. Among them, the global scaling factor is a benchmark coefficient that uniformly adjusts the search radius of all trajectory points, used to fine-tune the deduplication sensitivity, and does not change with the scene or density.
[0152] Specifically, the global scaling factor can be set to 1.2, which will uniformly increase the adaptive radius of all trajectory points by 20% on the basis of the original calculation. This is to adapt to the real vehicle environment where the LiDAR point cloud density is relatively high and the noise is slightly large, and the deduplication coverage capability can be improved without readjusting the density threshold or motion state weight.
[0153] It can be seen that the trajectory point processing system multiplies the motion state correction factor by the k nearest neighbor distance, and then multiplies it by the global scaling factor to obtain the final adaptive search radius, thereby achieving uniform calibration of the radius scale.
[0154] For example, if the nearest neighbor distance is 0.5m, the motion state correction factor is 1.1, and the global scaling factor is 1.2, then the search radius is 0.5×1.1×1.2=0.66m.
[0155] Therefore, the deduplication intensity can be adjusted as a whole through a single parameter, simplifying the parameter tuning process and improving the transferability of the method in different scenarios.
[0156] Optionally, in step S1341, adjusting the motion state correction factor corresponding to the trajectory point based on the motion state label may include the following steps:
[0157] Step S13411: If the motion state label is a stationary label or a first velocity label, increase the motion state correction factor.
[0158] Step S13412: If the motion state label is the second speed label, reduce the motion state correction factor, wherein the speed corresponding to the second speed label is higher than the speed corresponding to the first speed label.
[0159] In this embodiment, firstly, if the motion state label is a stationary label or a first speed label, the trajectory point processing system increases the motion state correction factor. The stationary label indicates that the target speed corresponding to the trajectory point is close to zero, typically when the vehicle is completely stationary. The first speed label indicates that the target speed is below a preset low-speed threshold, indicating slow movement or idling.
[0160] It can be seen that when the motion state label of a trajectory point is a stationary label or a first velocity label, it indicates that the point is in a low-motion or stationary scene. At this time, the trajectory point processing system increases the motion state correction factor to expand the search radius and enhance the ability to merge dense and redundant points.
[0161] For example, if a trajectory point has a speed of 0.2 m / s and is labeled "stationary", the correction factor is increased from the default 1.0 to 1.1; another point has a speed of 1.5 m / s and is labeled "first speed", and the correction factor is also increased to 1.1 to match its low-speed characteristics.
[0162] This helps to merge repetitive points generated by sensor noise in scenarios where vehicles are parked or moving slowly.
[0163] Secondly, if the motion state label is the second velocity label, the trajectory point processing system reduces the motion state correction factor, where the velocity corresponding to the second velocity label is higher than the velocity corresponding to the first velocity label. The second velocity label represents the high-speed threshold corresponding to the trajectory point.
[0164] It can be seen that when the motion state label of the trajectory point is the second velocity label, because of its fast motion speed and large distance between trajectory points, the trajectory point processing system reduces the motion state correction factor to reduce the search radius and prevents the continuous points of the real forward displacement from being misjudged as redundant points.
[0165] For example, if the speed of a trajectory point is 25m / s (90km / h) and the label is "second speed", the correction factor is reduced from the default 1.0 to 0.8, which reduces the search radius by 20% and ensures that the trajectory points collected every 0.1 seconds during high-speed driving are still retained.
[0166] Therefore, trajectory distortion can be effectively avoided in high-speed driving scenarios, and the continuity of the predicted trajectory can be maintained.
[0167] Optionally, in step S14, determining the set of points to be removed from the predicted trajectory point set based on the search radius and the multidimensional tree structure may include the following execution steps:
[0168] Step S141: Using the trajectory point as the center and the search radius corresponding to the trajectory point as the radius, perform a spatial range search in the multidimensional tree structure to obtain a set of spatial candidate points.
[0169] Step S142: Remove erroneous trajectory points from the spatial candidate point set to obtain a spatiotemporal candidate point set, wherein the difference between the timestamp of the erroneous trajectory point and the timestamp of the trajectory point is greater than a preset time threshold.
[0170] Step S143: If the spatiotemporal candidate point set contains a single trajectory point, mark the trajectory point as a representative point; or, if the spatiotemporal candidate point set contains multiple trajectory points, mark the trajectory point with the earliest timestamp among the multiple trajectory points as a representative point; or, if the timestamps of multiple trajectory points are the same, mark the trajectory point whose motion state label is consistent with the motion state label of the previous trajectory point among the multiple trajectory points as a representative point.
[0171] Step S144: Summarize the trajectory points in the spatiotemporal candidate point set except for the representative point to obtain the set of points to be eliminated.
[0172] In this embodiment, firstly, with the trajectory point as the center and the search radius corresponding to the trajectory point as the radius, the trajectory point processing system performs a spatial range search in a multi-dimensional tree structure to obtain a set of spatial candidate points. Specifically, the spatial range search refers to retrieving all neighboring points whose spatial coordinates lie within a certain radius of a trajectory point as the center and its adaptive search radius as the radius within the multi-dimensional tree structure.
[0173] The spatial candidate point set is the set of all points that satisfy the spatial distance constraints returned by the range search operation, including the target point itself and its neighboring points.
[0174] As can be seen, the trajectory point processing system takes the current trajectory point as the query center and its calculated adaptive search radius as the boundary. It performs spatial range query in the constructed two-dimensional priority multidimensional tree, filters out all trajectory points whose spatial coordinates are no more than the radius, and forms a set of spatial candidate points to be further filtered over time.
[0175] For example, for a trajectory point p3, its adaptive radius is 2.16m. The spatial range search returns three points around it, including p3 itself and two neighboring points with a spatial distance of less than 2.16m, which constitute a set of spatial candidate points.
[0176] This allows for the rapid identification of potential redundant points within a local space, reducing the data size for subsequent processing and improving deduplication efficiency and real-time performance.
[0177] Secondly, the trajectory point processing system removes erroneous trajectory points from the spatial candidate point set to obtain a spatiotemporal candidate point set, wherein the difference between the timestamp of the erroneous trajectory point and the timestamp of the trajectory point is greater than a preset time threshold.
[0178] An erroneous trajectory point refers to a trajectory point that is spatially adjacent but whose timestamp differs from the current point by more than a preset threshold and does not constitute a true continuous motion.
[0179] The spatiotemporal candidate point set refers to the set of trajectory points that meet the conditions in both spatial and temporal dimensions after filtering by the time dimension.
[0180] As can be seen, in the spatial candidate point set, the trajectory point processing system removes points whose timestamps differ from the current trajectory point by more than a preset time threshold (such as 150ms), and only retains points that are closely related in time, forming a spatiotemporal candidate point set for duplicate determination.
[0181] For example, the spatial candidate point set contains 6 points, of which 3 points have timestamps that differ from the center point by more than 150ms. After these 3 points are removed, the remaining 3 points with similar timestamps form the spatiotemporal candidate point set.
[0182] This effectively eliminates accidental neighboring points from different time periods, avoiding misjudging historical stop points or repeated paths across time periods as redundant trajectories.
[0183] Then, if the spatiotemporal candidate point set contains a single trajectory point, the trajectory point processing system marks the trajectory point as a representative point; or, if the spatiotemporal candidate point set contains multiple trajectory points, the trajectory point with the earliest timestamp among the multiple trajectory points is marked as a representative point; or, if the timestamps of multiple trajectory points are the same, the trajectory point whose motion state label is consistent with the motion state label of the previous trajectory point is marked as a representative point.
[0184] Among them, the representative point refers to the reserved point selected from the set of spatiotemporal candidate points based on time priority and motion state, which is used to characterize the reasonable observation value of the trajectory region.
[0185] It can be seen that when there is only one point in the space-time candidate point set, the trajectory point processing system directly marks it as the representative point; if there are multiple points, the point with the earliest timestamp is selected as the representative point first; if there are multiple points with the same timestamp, the trajectory point processing system selects the point whose motion state is consistent with the previous trajectory point as the representative point.
[0186] For example, the spatiotemporal candidate point set contains three points with timestamps of 1000ms, 1002ms, and 1002ms respectively. The latter two points have the same timestamp, and only the motion state in 1002ms is "uniform speed" and consistent with the previous trajectory point, so it is selected as the representative point.
[0187] This ensures that the retained trajectory points have temporal continuity and motion consistency, avoids trajectory breaks or abrupt changes, and improves the physical rationality of the deduplicated trajectory.
[0188] Finally, the trajectory point processing system summarizes the trajectory points in the spatiotemporal candidate point set, excluding the representative points, to obtain the set of points to be eliminated.
[0189] It can be seen that after determining the representative points in the spatiotemporal candidate point set, the trajectory point processing system includes all other trajectory points in the set into the set of points to be removed, as the basis for subsequent deletion from the original trajectory.
[0190] For example, the spatiotemporal candidate point set contains 5 points, of which the one with the earliest timestamp is selected as the representative point, and the remaining 4 points are aggregated into the set of points to be eliminated, waiting for unified elimination.
[0191] This allows for a clear distinction between retained and redundant points, enabling a systematic and traceable deduplication process and preventing the accidental deletion of valid trajectory data.
[0192] Optionally, any trajectory point in the multidimensional tree structure carries an expiration date label, which indicates the retention period of any trajectory point. The method may also include the following execution steps:
[0193] Step S16: During the vehicle's movement, insert the newly added trajectory points into the target node in the multidimensional tree structure.
[0194] Step S17: If the number of trajectory points corresponding to the target node is greater than the preset number threshold, the target node is split, wherein the number of trajectory points is the number of trajectory points contained in the sub-point set corresponding to the target node.
[0195] And / or, in step S18, the target trajectory point is deleted from the multidimensional tree structure according to the preset time interval and validity period label, and the invalid node is deleted from the multidimensional tree structure, wherein the difference between the timestamp of the target trajectory point and the current time is greater than the retention time corresponding to the target trajectory point, and the subset of points corresponding to the invalid node is empty.
[0196] In this embodiment of the application, each trajectory point is assigned an expiration label when inserted into the multidimensional tree, indicating its maximum survival time from the timestamp. After the expiration, it will be automatically cleaned up. The expiration label is a time attribute attached to each trajectory point in the multidimensional tree structure, used to identify the maximum time period that the point is allowed to remain after its generation.
[0197] First, during vehicle operation, the trajectory point processing system inserts new trajectory points into the target nodes of the multi-dimensional tree structure. These new trajectory points refer to the latest spatial-temporal coordinates generated by sensors or prediction models during real-time vehicle operation.
[0198] The target node refers to the spatial coordinates and timestamp of the newly added trajectory point in the multidimensional tree structure.
[0199] It can be seen that during vehicle operation, newly generated trajectory points are recursively searched for and inserted into the corresponding target nodes according to their spatial coordinates and timestamps along the hierarchical division logic of the multidimensional tree, thus maintaining the integrity and dynamic updating of the tree structure.
[0200] For example, the coordinates of the newly added trajectory point are (15.2, 8.7) and the timestamp is 10:05:12. After comparing the median of the x, t, and y dimensions layer by layer in the multidimensional tree, it is located to the node of the 4th layer in the left subtree and directly inserted into the point set of that node.
[0201] This enables real-time incremental updates of trajectory data, maintaining efficient retrieval and low-latency processing capabilities without rebuilding the tree structure.
[0202] Then, if the number of trajectory points corresponding to the target node is greater than the preset threshold, the trajectory point processing system splits the target node, where the number of trajectory points is the number of trajectory points contained in the sub-point set corresponding to the target node.
[0203] Splitting refers to recalculating the median based on the node's partitioning dimension (such as x-coordinate or timestamp) when the number of trajectory points stored in the target node exceeds a preset threshold, and dividing the point set into two child nodes to maintain tree balance and search efficiency.
[0204] It can be seen that when the number of trajectory points in the target node exceeds the preset threshold (such as 30), the trajectory point processing system reselects the median according to the division dimension of the node, and splits the trajectory points in the original node into two child nodes according to the new threshold.
[0205] For example, the target node originally stores 35 trajectory points, with the division dimension being the x-coordinate. After recalculating the median, the point set is divided into two subsets: x≤14.8 and x>14.8, and left and right child nodes are constructed respectively.
[0206] This enables real-time incremental updates of trajectory data without rebuilding the tree structure, maintaining efficient retrieval and low-latency processing capabilities.
[0207] In addition, the trajectory point processing system can also delete target trajectory points from the multidimensional tree structure and delete invalid nodes from the multidimensional tree structure according to preset time intervals and validity period labels. The difference between the timestamp of the target trajectory point and the current time is greater than the retention period corresponding to the target trajectory point, and the subset of points corresponding to the invalid node is empty.
[0208] An invalid node is a node in a multidimensional tree structure whose child point set is empty and no longer stores any trajectory points.
[0209] As can be seen, at preset time intervals, the system traverses the multidimensional tree structure, deletes target trajectory points whose timestamps have exceeded their validity period, and simultaneously cleans up invalid nodes that have become empty due to the removal of all child points, in order to maintain the compactness of the tree structure.
[0210] For example, a node once stored 5 trajectory points. After all of them expired and were deleted, its child point set became empty. The node was then identified as an invalid node and physically removed from the tree. Its parent node directly points to the original node's sibling node.
[0211] This avoids leaving useless nodes in the tree structure, reduces memory usage, and improves subsequent search efficiency.
[0212] This application overcomes the core limitations of traditional trajectory point deduplication techniques, focusing on the critical flaw of fixed parameters such as grid size and search radius in traditional methods. Such static parameters present significant adaptation challenges in practical applications. In high-density trajectory scenarios, such as urban commuting trajectories during morning and evening rush hours and dense delivery trajectories in logistics parks, fixed parameters easily lead to excessive deduplication, resulting in the loss of crucial details such as trajectory turns and stops. In low-density scenarios, such as suburban highway trajectories and long-distance freight trajectories, rigid parameters leave behind a large number of redundant and duplicate points, which not only consumes storage resources but also slows down the efficiency of subsequent trajectory analysis and prediction.
[0213] To this end, this application innovatively constructs an adaptive adjustment mechanism for trajectory point deduplication, which can dynamically optimize core parameters based on the local density distribution and scene characteristics of trajectory points, such as road type and traffic flow. It can accurately adapt to trajectory data of different densities and application scenarios without manual intervention, achieving a dynamic balance between deduplication accuracy and processing efficiency, and avoiding the drawbacks of the traditional one-size-fits-all approach.
[0214] Meanwhile, this application significantly reduces parameter sensitivity: traditional solutions rely on a large amount of prior knowledge in the domain to debug parameters, and even small changes in parameters may seriously affect the deduplication effect. However, this application weakens the reliance on human experience through adaptive logic. Even if the scene changes dynamically, such as from urban roads to highways, there is no need to repeatedly adjust the parameters, which significantly improves the generalization ability of the method and reduces the operation and maintenance costs in actual implementation.
[0215] Furthermore, in the multidimensional tree search stage of target trajectory prediction, this application deeply integrates adaptive deduplication and neighborhood search. During the trajectory point retrieval process, duplicate points can be efficiently and accurately removed in real time, avoiding redundant data from interfering with the accuracy of multidimensional tree neighborhood queries. This prevents duplicate points from interfering with feature extraction and path planning decisions in the trajectory prediction model, ensuring the reliability of prediction results and the rationality of planning schemes, and providing high-quality data support for trajectory-related applications.
[0216] To address the aforementioned problems, this embodiment provides a trajectory point processing method. Figure 2 This is a flowchart of a trajectory point processing technology solution according to an embodiment of this application, such as... Figure 2 As shown, the process includes the following steps: trajectory point preprocessing and improved multidimensional tree construction, adaptive radius calculation, spatiotemporal joint duplicate determination, duplicate point removal and dynamic updating, as detailed below:
[0217] Step S1: Trajectory point preprocessing and improved multidimensional tree construction.
[0218] (1) Trajectory point preprocessing: Obtain the set of target predicted trajectory points to be processed. Each trajectory point Includes three-dimensional features: spatial coordinates (in a two-dimensional scene) ), timestamp (Accurate to milliseconds), motion status tags It includes "uniform speed", "acceleration", "stationary", etc., where the motion state label can be based on Compared with the previous trajectory point The speed difference is calculated. Preprocessing involves filtering outliers from trajectory points: firstly, removing targets whose spatial coordinates exceed a preset range, such as predicted trajectory points outside the road boundary in autonomous driving scenarios; secondly, removing targets with disordered timestamps (e.g., ...). The outliers are identified, and the preprocessed point set is obtained. .
[0219] (2) Improved multidimensional tree construction: with spatial coordinates As the core dimension, timestamp To provide auxiliary dimensions, construct a multidimensional tree with "two-dimensional priority":
[0220] The odd-numbered levels of a tree (root node, tertiary nodes) are divided using spatial coordinates as the dimension: Root node selection Coordinates are the dividing dimensions, and calculations are performed. middle The median of the coordinates divides the point set. Left subtree sum less than or equal to median The right subtree is greater than the median; for third-level nodes, the y-coordinate is chosen as the partitioning dimension, and similarly, the median is used for partitioning.
[0221] Even-numbered levels of the tree (second-level nodes, fourth-level nodes) are timestamped. To define the dimension: Second-level nodes calculate the left or right subtree... The median divides the point set into... Subtrees less than or equal to the median Subtrees greater than the median.
[0222] Each tree node stores the point set, partition dimension, median, and standard deviation of the point set corresponding to that node. The standard deviation of the point set reflects the density of trajectory points in the node region and is used for the next step of adaptive search radius calculation.
[0223] Step S2: Adaptive radius calculation.
[0224] against Each trajectory point in Standard deviation of point sets based on improved multidimensional trees (i.e., kd-trees with "two-dimensional priority") With Adaptive Value nearest neighbor search dynamically calculates the unique search radius for each trajectory point. Specific steps:
[0225] (1) Adaptive Value determined: based on Standard deviation of the point set of the node in the multidimensional tree Adjustment Value: If ,in A preset density threshold indicates that the trajectory points in this area are dense; a larger value is set. The value expands the nearest neighbor range to ensure the radius covers enough repeating points; if This indicates that the trajectory points in this area are sparse, which can be addressed by setting a smaller value. The value narrows the nearest neighbor range to avoid misjudgment caused by an excessively large radius.
[0226] (2) Nearest neighbor search and distance calculation: Execution through improved multidimensional trees of Nearest neighbor search prioritizes searching within subtrees with similar timestamps (based on even-numbered time dimension partitioning) to obtain... The set of nearest neighbors ,calculate To the Euclidean distance between nearest neighbors .
[0227] (3) Dynamic adjustment of radius: Introducing motion state correction factor .like motion status labels The label can be set to "stationary" or "low speed," and the classification can be determined based on the actual test conditions. The motion state correction factor can be increased. To appropriately increase the radius and merge redundant points when stationary; if To achieve "high speed", the motion state correction factor can be reduced. To appropriately reduce the radius while retaining effective trajectory points for high-speed motion; ultimately, an adaptive radius... ,in It is a global scaling factor that can be finely adjusted according to real-vehicle testing scenarios without the need for frequent adjustments.
[0228] Step S3: Spatiotemporal joint repetition point search and marking.
[0229] Based on improved multidimensional tree and adaptive radius Construct a logic for determining repetition points in both spatial and temporal dimensions:
[0230] (1) Spatial range search: with Centered on, Using the radius as the search radius, and by improving the spatiotemporal joint search function of the multidimensional tree, we can find objects with a spatial distance less than or equal to... candidate point set .
[0231] (2) Time dimension filtering: for candidate point set Perform timestamp filtering and retain the timestamp difference. The point, among which A set of spatiotemporal candidate points is obtained by setting a preset time threshold. .
[0232] (3) Repeat point marking rules: If Only contains Self, Mark This is a reserved point. If Not only includes If it contains multiple other points, this point set is marked as a potential duplicate point set, and then, based on the principles of time priority and motion state priority, it is used to select points from the set. Representative points are selected. The priority principle is to retain the trajectory point with the earliest timestamp first, to ensure trajectory continuity. If trajectory points have the same timestamp, points with the same motion status label as the previous trajectory point are retained. The remaining non-representative points are marked as points to be removed and added to the global list of points to be removed. To avoid redundant processing, once a point is marked as a point to be removed, subsequent searches will not be performed with that point as the center.
[0233] Step S4: Duplicate point removal and dynamic update of the multidimensional tree.
[0234] (1) Clean trajectory generation: Traverse the original point set Remove all items from the list to be removed. From the points in the set, we obtain the clean trajectory point set after deduplication. .
[0235] (2) Dynamic optimization of multidimensional tree.
[0236] Insert update: Clean trajectory point set The newly added real-time predicted trajectory point insertion improves the multidimensional tree, directly locating the insertion position based on the node's partition dimension and median. If the number of nodes exceeds a preset threshold, the insertion position is determined based on the standard deviation of the current node's point set. Re-partitioning to avoid excessive node congestion.
[0237] Expired point deletion: Add expiration labels to multidimensional tree nodes to limit the storage time of trajectory points, and periodically traverse the tree structure to delete nodes and corresponding trajectory points whose timestamps have expired, keeping the tree structure lightweight and ensuring search efficiency.
[0238] Compared to traditional solutions, the technical advantages of this application are reflected in a significantly improved adaptive capability, making it suitable for multi-scenario and multi-density data. This is achieved through adaptive adjustment of the k-value and motion state correction factors. This allows for dynamic optimization of the search radius in different scenarios, reducing the false positive rate. Furthermore, the robustness of parameter settings in this application is enhanced, reducing operational costs. The core parameter only requires setting a global scaling factor. Density threshold Time threshold Furthermore, these core parameters do not require frequent adjustments based on the scenario, significantly reducing parameter adjustment costs and system complexity. Additionally, by introducing a time dimension for filtering, this application can accurately distinguish between spatiotemporally repetitive points and spatiotemporally independent points. For example, trajectory points at the same location within different time periods can be jointly determined spatiotemporally, avoiding misjudgments or omissions, thereby greatly improving the completeness and accuracy of trajectory data. Finally, this application utilizes an improved multi-dimensional tree's "dual-dimensional priority" structure to enhance the efficiency of k-nearest neighbor search and range search, reducing the computational complexity of predicting target trajectory points and meeting the needs of large-scale data processing.
[0239] Specifically, this embodiment provides a trajectory point processing method. Figure 3 This is a flowchart of trajectory point preprocessing and improved multidimensional tree construction according to an embodiment of this application, such as... Figure 3 As shown, the process includes the following steps: preprocessing operations and improved multidimensional tree construction, as detailed below:
[0240] (1) Preprocessing operations:
[0241] Outlier filtering: Considering the relationship between the target and the lane's non-crossable boundary, calculate whether the target's predicted trajectory points are outside the non-crossable boundary. If a trajectory point is outside the non-crossable lane boundary, it is directly removed. Simultaneously, check for anomalies in the timestamps between the target's predicted trajectory points; if anomalies are found, they are directly removed, resulting in a preprocessed point set. .
[0242] Motion state annotation: Predict the velocity of each point in the target's trajectory. Label the motion state, and label it as stationary, low speed, and high speed according to the speed threshold.
[0243] (2) Improved multidimensional tree construction:
[0244] based on of Coordinates and timestamps The "two-dimensional priority" multidimensional tree structure is constructed as follows:
[0245] Root node (level 1, odd level): with Coordinates are the dividing dimensions, and calculations are performed. middle median of coordinates ,Will Divided into left subtree and The right subtree.
[0246] Second-level node (level 2, even level): left subtree by timestamp the median of To divide the dimensions, it is divided into The subtree of this value and Subtree; the right subtree is divided into dimensions in the same way.
[0247] Level 3 nodes (level 3, odd-numbered levels): Calculate each second-level subtree using the y-coordinate as the dividing dimension. median of coordinates Further subdivision.
[0248] Each node includes the storage set of points, partition dimension, median, and standard deviation of the point set. Assume that the node corresponding to intersection B... It is 0.6m, which is less than Therefore, intersection B is a dense area; the node corresponding to straight road segment A. The value is 1.2m, which is greater than the standard deviation threshold of the point set. Therefore, straight road segment A is a sparse area.
[0249] Specifically, this embodiment provides a trajectory point processing method. Figure 4 This is a flowchart of an adaptive radius calculation according to an embodiment of this application, such as... Figure 4 As shown, the process includes the following steps: Value adaptive determination Nearest neighbor search and distance calculation, and dynamic radius adjustment are detailed below:
[0250] First, set the default value for the global parameter to: , =1.2.
[0251] (1) Value adaptively determined:
[0252] For the "low speed" point at intersection B, i.e. ,set up .
[0253] For the "uniform speed" point of straight road segment A, i.e. ,set up .
[0254] (2) Nearest neighbor search and distance calculation:
[0255] by Middle intersection Taking a motion state label of low speed as an example, this is achieved through improvements to the multidimensional tree execution. Nearest neighbor search, prioritizing Searching within nearby subtrees, assuming 8 nearest neighbors are obtained, calculate... Euclidean distance to the 8th nearest neighbor .
[0256] Points on straight road sections Taking a motion state labeled as uniform speed as an example. Execute Nearest neighbor search, assuming 3 nearest neighbor points are obtained, calculate Distance to the 3rd nearest neighbor .
[0257] (3) Dynamic adjustment of radius:
[0258] Its motion state is low speed. , .
[0259] Its motion is uniform. (Default value, no high-speed points) .
[0260] Traversal Midpoint, calculate the adaptive radius of all points. The radius ranges from 0.55m to 2.3m, which conforms to the pattern of small radius in dense areas and large radius in sparse areas.
[0261] Specifically, this embodiment provides a trajectory point processing method. Figure 5 This is a flowchart of a spatiotemporal joint repeat point search and marking according to an embodiment of this application, such as... Figure 5 As shown, the process includes the following steps: spatial range search, time dimension filtering, and marking duplicate points based on the results of the previous step, as detailed below:
[0262] First, set the time threshold. .
[0263] (1) Spatial range search:
[0264] by Centered on, Using the multidimensional tree's spherical region query (query_ball_point) method as the search radius, a set of candidate points with a spatial distance less than or equal to 0.66m is searched. (Include (and 8 surrounding points).
[0265] by Centered on, Given a radius, search for a set of candidate points with a spatial distance less than or equal to 2.16m. (Include (and two surrounding points).
[0266] (2) Time dimension filtering, for example:
[0267] right Calculate the sum of each point and... timestamp difference ,reserve The point, get (Include And 5 surrounding points, 3 of which are due to (Removed).
[0268] right :reserve The point, get (Contains only) Self, 2 nearest neighbors ).
[0269] (3) Mark duplicate points based on the results of the previous step:
[0270] Containing 6 points, marked as a potential duplicate point set, the point with the earliest timestamp is selected ( The first two points) are used as representative points, and the remaining five points (including) Mark as a point to be removed and add to the list. .
[0271] Only ,mark Reserved point.
[0272] Traversal All points are used to ultimately obtain the list of items to be removed. .
[0273] Specifically, this embodiment provides a trajectory point processing method. Figure 6 This is a flowchart of a duplicate point removal and multidimensional tree dynamic update according to an embodiment of this application, such as... Figure 6 As shown, the process includes the following steps: cleaning trajectory generation and dynamic updating of the multidimensional tree, as detailed below:
[0274] (1) Cleaning trajectory generation: from Remove from Midpoint, to obtain the cleaned trajectory point set The output is sent to the autonomous driving path planning module.
[0275] (2) Dynamic updates of the multidimensional tree:
[0276] Insert update: will The newly added real-time trajectory points are inserted into the multidimensional tree and directly located to the corresponding node. After insertion, the total number of all node points is ≤30 (preset threshold), and no splitting is required.
[0277] Expired point deletion: The multi-dimensional tree can be traversed every 10 minutes to delete points whose timestamps exceed 30 minutes (expiration time). Expired points are deleted on the first traversal, and the corresponding nodes are marked as leaf nodes. Expired point deletion can control the tree structure to avoid large-scale adjustments.
[0278] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, use and processing of the relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation entry points are provided for users to choose to authorize or refuse.
[0279] According to an embodiment of this application, a device embodiment for trajectory point processing is provided. It should be noted that the device can be used to perform the above-described trajectory point processing method.
[0280] Figure 7 This is a structural block diagram of a trajectory point processing apparatus according to one embodiment of this application, such as... Figure 7As shown, a trajectory point processing device 700 is used as an example. This device includes: an acquisition module 701, used to acquire a set of predicted trajectory points of a vehicle, wherein the trajectory points in the predicted trajectory point set carry spatial coordinates, timestamps, and motion state labels; a construction module 702, used to construct a multi-dimensional tree structure corresponding to the set of predicted trajectory points based on the spatial coordinates and timestamps, wherein the odd-numbered levels of the multi-dimensional tree structure are divided based on alternating horizontal and vertical coordinates of the spatial coordinates, and the even-numbered levels of the multi-dimensional tree structure are divided based on the timestamps; a first determination module 703, used to determine the search radius corresponding to the trajectory points based on the motion state labels and the multi-dimensional tree structure; a second determination module 704, used to determine the set of points to be removed from the set of predicted trajectory points based on the search radius and the multi-dimensional tree structure; and a removal module 705, used to remove the trajectory points from the set of points to be removed from the set of predicted trajectory points to obtain a target set of predicted trajectory points.
[0281] Embodiments of this application also provide a vehicle, including: a memory storing an executable program; and a processor for running the program, wherein the program executes the methods described in various embodiments of this application when it runs.
[0282] Embodiments of this application also provide a computer-readable storage medium including a stored executable program, wherein, when the executable program is running, it controls the device where the computer-readable storage medium is located to perform the methods of various embodiments of this application.
[0283] Embodiments of this application also provide a computer program product, including a computer program that, when executed by a processor, implements the methods of various embodiments of this application.
[0284] Embodiments of this application also provide a computer program product, including a non-volatile computer-readable storage medium for storing a computer program that, when executed by a processor, implements the methods in various embodiments of this application.
[0285] Embodiments of this application also provide a computer program that, when executed by a processor, implements the methods described in the various embodiments of this application.
[0286] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0287] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0288] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0289] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0290] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.
[0291] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A trajectory point processing method, characterized by, The method includes: Obtain a set of predicted trajectory points for the vehicle, wherein the trajectory points in the set of predicted trajectory points carry spatial coordinates, timestamps, and motion state labels; A multidimensional tree structure corresponding to the predicted trajectory point set is constructed based on the spatial coordinates and the timestamp, wherein the odd-numbered levels of the multidimensional tree structure are divided based on the alternating horizontal and vertical coordinates of the spatial coordinates, and the even-numbered levels of the multidimensional tree structure are divided based on the timestamp; Based on the motion state label and the multidimensional tree structure, determine the search radius corresponding to the trajectory point; Based on the search radius and the multidimensional tree structure, determine the set of points to be removed from the predicted trajectory point set; Remove the trajectory points from the set of points to be removed from the set of predicted trajectory points to obtain the target set of predicted trajectory points.
2. The method of claim 1, wherein, The set of predicted trajectory points for the vehicle includes: Obtain the initial predicted trajectory point set for the vehicle; The first predicted trajectory point is removed from the initial predicted trajectory point set to obtain the first predicted trajectory point set, wherein the spatial coordinates of the first predicted trajectory point are outside the target boundary; The second predicted trajectory point is removed from the first predicted trajectory point set to obtain the second predicted trajectory point set, wherein the timestamp of the second predicted trajectory point is less than the timestamp of the previous predicted trajectory point; According to a preset speed threshold, the predicted trajectory points in the second predicted trajectory point set are labeled with motion state tags to obtain the predicted trajectory point set, wherein the motion state tags are used to represent the motion mode corresponding to the predicted trajectory points.
3. The method of claim 1, wherein, The step of constructing the multidimensional tree structure corresponding to the predicted trajectory point set based on the spatial coordinates and the timestamp includes: The predicted trajectory point set is divided according to the median of the horizontal coordinates in the spatial coordinates to obtain a division result, wherein the division result includes a left child point set and a right child point set, wherein the horizontal coordinates of the predicted trajectory points in the left child point set are less than or equal to the median, and the horizontal coordinates of the predicted trajectory points in the right child point set are greater than the median. A root node is generated based on the partitioning result, wherein the root node is located at an odd level; Starting from the root node, the left and right child sets of the next level are partitioned sequentially to generate corresponding nodes until the multidimensional tree structure is constructed. The odd-numbered levels are partitioned alternately based on the median of the horizontal or vertical coordinates in the spatial coordinate system, while the even-numbered levels are partitioned based on the timestamp. Each node in the multidimensional tree structure carries the corresponding child set, partition dimension, median, and standard deviation of the child set.
4. The method of claim 1, wherein, Determining the search radius corresponding to the trajectory point based on the motion state label and the multidimensional tree structure includes: Adjust the number of nearest neighbors corresponding to the trajectory point based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure. In the multidimensional tree structure, a nearest neighbor search is performed on the trajectory points according to the number of nearest neighbor points and the priority search rule to obtain a set of nearest neighbor points. The priority search rule is used to search within the set of sub-points whose timestamps meet the search requirements. The Euclidean distance between the trajectory point and the target nearest neighbor is determined based on the set of nearest neighbors, wherein the target nearest neighbor is the nearest neighbor point in the set of nearest neighbors that is farthest from the trajectory point; The search radius corresponding to the trajectory point is determined based on the motion state label and the Euclidean distance.
5. The method of claim 4, wherein, The step of adjusting the number of nearest neighbors corresponding to the trajectory point based on the standard deviation of the point set corresponding to the node in the multidimensional tree structure includes: If the standard deviation of the point set is less than the preset density threshold, increase the number of nearest neighbor points. If the standard deviation of the point set is greater than or equal to the preset density threshold, the number of nearest neighbor points is reduced.
6. The method of claim 4, wherein, The step of determining the search radius corresponding to the trajectory point based on the motion state label and the Euclidean distance includes: Adjust the motion state correction factor corresponding to the trajectory point according to the motion state label; The search radius corresponding to the predicted trajectory point is determined based on the global scaling factor, the motion state correction factor, and the Euclidean distance.
7. The method of claim 6, wherein, The step of adjusting the motion state correction factor corresponding to the trajectory point based on the motion state label includes: If the motion state label is a stationary label or a first velocity label, increase the motion state correction factor; If the motion state label is a second speed label, the motion state correction factor is reduced, wherein the speed corresponding to the second speed label is higher than the speed corresponding to the first speed label.
8. The method of claim 1, wherein, The step of determining the set of points to be removed from the predicted trajectory point set based on the search radius and the multidimensional tree structure includes: Using the trajectory point as the center and the search radius corresponding to the trajectory point as the radius, a spatial range search is performed in the multidimensional tree structure to obtain a set of spatial candidate points; Erroneous trajectory points are removed from the spatial candidate point set to obtain a spatiotemporal candidate point set, wherein the difference between the timestamp of the erroneous trajectory point and the timestamp of the trajectory point is greater than a preset time threshold. If the spatiotemporal candidate point set contains a single trajectory point, the trajectory point is marked as a representative point; or, if the spatiotemporal candidate point set contains multiple trajectory points, the trajectory point with the earliest timestamp among the multiple trajectory points is marked as a representative point; or, if the timestamps of the multiple trajectory points are the same, the trajectory point whose motion state label is consistent with the motion state label of the previous trajectory point is marked as a representative point. The trajectory points in the spatiotemporal candidate point set, excluding the representative point, are summarized to obtain the set of points to be eliminated.
9. The method according to any one of claims 1-8, characterized in that, Each trajectory point in the multidimensional tree structure carries an expiration date label, which indicates the retention period of the trajectory point. The method further includes: During the vehicle's operation, new trajectory points are inserted into the target node of the multidimensional tree structure; If the number of trajectory points corresponding to the target node is greater than a preset threshold, the target node is split, wherein the number of trajectory points is the number of trajectory points contained in the sub-set corresponding to the target node; and / or, The target trajectory point is deleted from the multidimensional tree structure according to the preset time interval and the validity period label, and the invalid node is deleted from the multidimensional tree structure, wherein the difference between the timestamp of the target trajectory point and the current time is greater than the retention time corresponding to the target trajectory point, and the subset of points corresponding to the invalid node is empty.
10. A vehicle, characterized in that, include: Memory, which stores executable programs; A processor for running the program, wherein the program, when running, performs the trajectory point processing method according to any one of claims 1 to 9.