A risk scenario clustering method based on spatiotemporal interactive risk field
By constructing an asymmetric single-traffic entity probability occupancy field and time discount accumulation mechanism, combined with a deep embedding clustering method based on rotation-invariant feature learning, the problem of characterizing the interaction risks of multiple traffic participants is solved, and robust clustering and analysis of risk scenarios are achieved, thereby improving the effectiveness of autonomous driving testing and safety assessment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JILIN UNIVERSITY
- Filing Date
- 2026-07-02
- Publication Date
- 2026-07-31
AI Technical Summary
Existing technologies struggle to effectively characterize the interaction risks among multiple traffic participants and lack interpretable and structured risk scenario representations, impacting autonomous driving testing and safety assessments.
By constructing a single traffic body probability occupancy field with asymmetric front and rear, a multi-traffic body interaction risk field is formed. Combined with a time discount accumulation mechanism, risk segments are extracted, and a deep embedding clustering method with rotation invariant feature learning is used to cluster risk scenarios.
It enhances the ability to structurally represent traffic risks, discover typical scenarios, and analyze across scenarios, thereby improving the method's versatility and robustness, making it suitable for autonomous driving testing and traffic safety analysis.
Smart Images

Figure CN122490131A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of intelligent transportation and autonomous driving safety assessment technology, specifically involving a risk scenario clustering method based on spatiotemporal interactive risk fields. Background Technology
[0002] With the development of intelligent vehicles and high-level autonomous driving technologies, the safety challenges faced by vehicles in open road environments have gradually shifted from traditional single-objective perception and single-vehicle control to understanding the continuous interactive risks among multiple traffic participants. In real-world roads, vehicles, pedestrians, and non-motorized vehicles interact with each other in time and space. Potential conflicts are often not manifested at a single moment, but rather as a continuous risk accumulation process evolving over a short time domain. Therefore, effectively characterizing this interactive risk from trajectory data and further extracting representative hazardous scenarios has become a key issue in autonomous driving testing, verification, and safety assessment.
[0003] Existing solutions include rule-based, equivalent model-based, statistical probability-based, and deep learning-based methods to quantify risk distribution in space. However, they lack the ability to represent complex traffic interaction risks as continuous, interpretable, and further exploitable structured objects.
[0004] Existing rule-based methods (such as alternative safety indicators like time-distance and collision time) typically only output a single risk value, making it difficult to reflect the spatial distribution of risk or describe the coupling relationships between multiple traffic participants.
[0005] Methods based on equivalent models (such as the artificial potential field method) are mostly used for specific tasks, and they can basically only describe instantaneous states.
[0006] Deep learning-based methods have high learning costs, struggle to address the long-tail effect, and have weak interpretability. Summary of the Invention To address the aforementioned technical problems, the present invention aims to provide a risk scenario clustering method based on a spatiotemporal interactive risk field. This method constructs a multi-traffic body interactive risk field by building a single traffic body probability occupancy field with asymmetric front-to-back characteristics, and combines this with a time discount accumulation mechanism to characterize short-term time-domain risk features. Risk fragments are extracted from this field, and a deep embedding clustering method based on rotation-invariant feature learning is then introduced to achieve robust clustering of risk scenarios. This enhances the structured representation capability of traffic risks, the ability to discover typical scenarios, and the cross-scenario analysis capability. The method is specifically as follows: Includes the following steps: S1. Perform a unified interface conversion on vehicle trajectories from different datasets to form a standardized vehicle state representation; S2. Based on vehicle status and size information, construct the vehicle's single-vehicle probability occupancy field; S3, All vehicles at the same time The probability occupancy field of a single bicycle is mapped onto the common grid space to obtain the time step. The interactive risk field below will be constantly All interactive risk fields are superimposed onto the current prediction time to obtain the interactive risk field corresponding to the current prediction time. High-risk hotspots are extracted to obtain risk segments. The risk segments are then processed to obtain segment samples. S4. Introduce a rotation-invariant feature learning mechanism inside the encoder. Input the fragment samples into the encoder to obtain latent features. Cluster the latent features to obtain initial cluster centers. Use a soft assignment method to calculate the membership degree of the fragment samples to each cluster center.
[0007] Furthermore, the standardized vehicle state representation specifically refers to: for any vehicle At the present moment Its vehicle status is represented as: ; in, The center position of the vehicle. These refer to the vehicle's lateral and longitudinal dimensions, respectively. and These are the velocity and acceleration components, respectively. For heading angle, and These represent the vehicle's lateral and longitudinal directions, respectively.
[0008] Furthermore, regarding vehicles In the future The predicted state, let its center position be... The heading angle is In the vehicle's local coordinate system, any spatial point is denoted as... ,in Represents the longitudinal coordinate along the vehicle's heading direction. Represents the lateral coordinates along the vehicle's heading direction; based on vehicle status and size information, construct the vehicle... The probability of bicycles occupying space for: ; in: The longitudinal dimension occupied by the vehicle. The lateral dimensions occupied by the vehicle. This is the normalization coefficient.
[0009] Furthermore, at any time The interactive risk field under the following conditions is defined as: ; in, and For vehicle indexing, Indicates time Get off the vehicle The probability of bicycles occupying space. Indicates time Get off the vehicle The probability of a bicycle being occupied; The interactive risk field corresponding to the current prediction time is defined as: ;in, Indicates the current prediction time. This indicates the time discount weight.
[0010] Furthermore, the specific methods for obtaining risk segments are as follows: The interactive risk field is standardized to obtain a standard risk map. Then, set the core risk threshold. and supporting risk threshold ,in Construct a core area mask based on the core risk threshold: ; Construct a support region mask based on the support risk threshold: ; in, This indicates a core area with a high level of risk. This indicates a supporting area surrounding the core area that has a certain risk association. This is an indicator function; it takes the value 1 if the condition is met and 0 if the condition is not met. With core area mask The connected regions in the code are used as seed regions. Under the constraints of the main road direction or vehicle movement direction, the support region mask is applied. The adjacent regions in the segment are directionally grown. During the growth process, it is determined whether the adjacent regions meet the preset merging conditions. If the preset merging conditions are met, they are merged into the current risk segment; if the preset merging conditions are not met, they are kept as independent risk segments or split.
[0011] Furthermore, the risk segments are processed to obtain segment samples, specifically as follows: For each single-instance risk segment, an adaptive Region of Interest (ROI) is generated, and the ROI is cropped and scaled into a segment sample of uniform size. The segment sample includes a risk map channel and a binary map channel, where the risk map channel is used to represent the risk intensity distribution and the binary map channel is used to represent the location and shape of the effective risk area.
[0012] Furthermore, a rotation-invariant feature learning mechanism is introduced within the encoder, specifically as follows: Do not directly input the raw input Instead of encoding clustering features, we first construct multiple rotational viewpoints; let the rotational transformation operator be... Then for the sample generate Rotated views at different angles: For each rotational viewpoint, the same encoder with shared parameters is used for feature extraction.
[0013] Furthermore, when calculating the membership degree of fragment samples to each cluster center using the soft allocation method, the first... The sample belongs to the first The soft assignment probability of a cluster is defined as: ; in, Indicates sample Belongs to the The probability of a cluster. Indicates the first Latent features are obtained by encoding each sample using rotation-invariant encoding. Indicates the first Cluster centers, For distribution parameters, The index represents all candidate cluster centers. The closer a fragment sample is to a certain cluster center, the higher the corresponding cluster center. The larger the value, the better the sample size. The more likely it is to belong to the first One cluster.
[0014] The beneficial effects of the method described in this invention are as follows: 1. By unifying vehicle state representation and future state sequence extraction, the standardized organization of traffic participant information under different datasets and road scenarios is realized, providing a unified input basis for subsequent risk analysis and enhancing the versatility and transferability of the method.
[0015] 2. Modeling the spatial influence range of vehicles using the probability occupancy field of a single traffic body with asymmetric front and rear traffic flow is more consistent with the characteristic that forward risks are usually higher than backward risks in actual traffic, thereby improving the authenticity and interpretability of risk representation.
[0016] 3. The time-overlay interactive risk field not only reflects the risk at the current moment, but also reveals the evolution trend of future risks.
[0017] 4. Introducing a rotation-invariant feature learning mechanism during the encoding stage can significantly reduce the interference of changes in road orientation and coordinate system orientation on clustering results, enabling risk scenarios with the same essential structure but different orientations to be grouped into the same cluster, thereby improving the robustness and semantic consistency of clustering results.
[0018] 5. A complete technical process from trajectory input to risk scenario output has been established, which can directly serve autonomous driving testing and evaluation, construction of typical hazardous scenario databases and traffic safety analysis, and has good engineering application value. Attached Figure Description
[0019] Figure 1 This is a flowchart of the trajectory data input process in an embodiment of the present invention; Figure 2 This is a flowchart illustrating the interactive risk field establishment and risk segment generation in an embodiment of the present invention. Figure 3 This is a flowchart of risk scenario clustering based on rotationally invariant encoders in an embodiment of the present invention. Detailed Implementation
[0020] The technical solution of the present invention will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of the present invention.
[0021] Example 1 This embodiment provides a risk scenario clustering method based on a spatiotemporal interactive risk field, which will be described in detail here.
[0022] This method first performs a unified interface conversion on vehicle trajectories from different datasets to form a standardized vehicle state representation, as shown in the flowchart below. Figure 1 As shown. For any vehicle At the present moment Its state can be represented as: ; in, The center position of the vehicle. These refer to the vehicle's lateral and longitudinal dimensions, respectively. and These are the velocity and acceleration components, respectively. For heading angle, and These represent the vehicle's lateral and longitudinal directions, respectively.
[0023] Furthermore, in a given prediction time domain and a long walk Under the conditions, from the current time Extracting future time Get the vehicle status. ; Indicates the first Prediction step, or simply time step , For prediction of the time domain The total number of steps within the current prediction time.
[0024] This ensures that the construction of the subsequent risk field does not rely solely on the current instantaneous state, but rather on continuous temporal information.
[0025] In most driving environments, the forward-looking risk is much higher than the rear-looking risk, making a standard elliptical Gaussian field unsuitable. Therefore, this method employs an asymmetric strategy to ensure that the risk in the forward region is greater than that in the rear region. The specific single-vehicle probability occupancy field is established as follows: For vehicles In the future The predicted state, let its center position be... The heading angle is In the vehicle's local coordinate system, any spatial point is denoted as... ,in Represents the longitudinal coordinate along the vehicle's heading direction. This represents the lateral coordinate along the vehicle's heading. Based on the vehicle's motion state and dimensional information, a vehicle... The probability of a bicycle being occupied is: ; in: The longitudinal dimension occupied by the vehicle. The lateral dimensions occupied by the vehicle. This is the normalization coefficient.
[0026] The longitudinal and lateral dimensions of a vehicle are determined by its speed, acceleration, size, and prediction time, and can be summarized as follows: ; ; in, Indicates vehicle In time The standard deviation of the lateral uncertainty Indicates vehicle lateral acceleration, This represents the lateral acceleration coefficient. For vehicles The lateral vehicle size factor is used to characterize the lateral dimensions of a vehicle. The resulting uncertainty For vehicles The transverse time diffusion coefficient is used to represent the cumulative transverse time diffusion risk. Indicates vehicle In time The standard deviation of longitudinal uncertainty Indicates vehicle longitudinal acceleration, This represents the longitudinal acceleration coefficient. For vehicles The longitudinal vehicle size factor is used to characterize the longitudinal dimensions of a vehicle. The resulting uncertainty For vehicles The longitudinal time diffusion coefficient is used to calculate the longitudinal time cumulative diffusion risk.
[0027] Through the above construction, the field occupied by a single vehicle can evolve over time and reflect the spatial influence range of the vehicle in the short time domain in the future.
[0028] like Figure 2 As shown, in the multi-vehicle interaction risk field generation stage, this method generates all vehicles at the same time. The single-vehicle probability occupancy field is mapped onto a common grid space, and pairwise overlap analysis is performed on a unified grid. For time... The interactive risk field under the following conditions is defined as: ; in, and For vehicle indexing, Indicates time Get off the vehicle The probability of bicycles occupying space. Indicates time Get off the vehicle The probability of a single bike occupying a certain area.
[0029] Then time discount weights are applied to all prediction times. , Indicates time The adaptive adjustment parameters will be adjusted at any time. All the interaction risk fields are superimposed on the current prediction time to obtain the interaction risk field corresponding to the current prediction time: ; This risk field is essentially a "time-discounted cumulative expression of the overlap intensity of multiple vehicles in the future short-term time domain in the current frame." Therefore, it not only contains instantaneous conflict information but also reflects short-term evolutionary trends. It can effectively quantify the state risk in the current spatiotemporal context.
[0030] The next step is to extract high-risk hotspots from the entire interaction graph to obtain risk segments: In the risk segment extraction stage, the method first standardizes the interactive risk field to eliminate inconsistencies in risk numerical scales across different road environments, traffic densities, or data sources. Standard Risk Map It can be represented as: ; in To prevent abnormally small positive numbers in logarithmic operations, It is precisely for the interactive risk field After statistical analysis of the risk values, specific quantile values (e.g., selecting 1% and 99% quantiles) are used to eliminate the impact of extreme noise on the normalization scale.
[0031] Then, set the core risk threshold. and supporting risk threshold ,in ( and (These are two variable parameters). Construct the core area mask based on the core risk threshold: ; Construct a support region mask based on the support risk threshold: ; in, This indicates a core area with a high level of risk. This indicates a supporting area surrounding the core area that has a certain risk association. This is an indicator function; it takes the value 1 if the condition is met, and 0 if the condition is not met.
[0032] Furthermore, using the core area mask The connected regions in the code are used as seed regions. Under the constraints of the main road direction or vehicle movement direction, the support region mask is applied. Directional growth is carried out in adjacent regions.
[0033] During the growth process, the system determines whether adjacent areas belong to the same traffic risk event based on their directional differences, longitudinal spacing, lateral spacing, and spatial connectivity. If the preset merging conditions are met, the risk event is merged into the current risk segment; otherwise, it remains an independent risk segment or is split.
[0034] Specifically, the process for determining whether adjacent areas belong to the same traffic risk event is as follows: Calculate the shortest longitudinal distance between each candidate adjacent area and the boundary of the core area. Horizontal minimum spacing and the angle difference between the principal axes of the two regions. If the preset merging conditions are met: vertical spacing And horizontal spacing And direction difference ( If the adjacent area is determined to be highly consistent with the core area in terms of spatial and movement trends, and belongs to the same traffic risk event, it will be merged into the current risk segment; if the preset conditions are not met, it will remain an independent risk segment or be split.
[0035] Therefore, this method can extract several single-instance risk segments from a complete risk field, with each risk segment corresponding to a relatively independent vehicle interaction risk event. Compared with the fixed window cropping method, this method can avoid the cropping of a large number of risk-free background areas, while preserving the true spatial shape and extension direction of the risk area.
[0036] Finally, an adaptive Region of Interest (ROI) is generated for each single-instance risk fragment, and this ROI is cropped and scaled to a uniformly sized fragment sample. The fragment sample includes a risk map channel and a binary map channel, where the risk map channel represents the risk intensity distribution, and the binary map channel represents the location and shape of the effective risk region. By outputting standardized dual-channel fragment samples, a unified input can be provided for subsequent risk scene clustering, risk semantic recognition, or hazardous scene generation.
[0037] In the risk scenario clustering stage of this method, due to the different road shapes and orientations across multiple datasets, the generated risk patches will inherit some road orientations, causing changes in their principal axis direction. This can result in the same traffic risk being classified into different traffic risk categories due to different road orientations. To mitigate the interference of this orientation difference on the clustering results, this method incorporates rotation invariance improvements in the encoder.
[0038] like Figure 3 As shown, a rotation-invariant feature learning mechanism is directly introduced into the encoder, enabling the network to automatically learn latent representations that are insensitive to changes in planar rotation. The aim is that when the same type of risk scenarios differ only in orientation, the clustering results are no longer affected by absolute direction, but rather focus more on the intrinsic structure, local morphology, and interaction patterns of the risk distribution itself.
[0039] In this implementation, the input sample is a dual-channel risk segment: ; Among them, the first channel This represents a risk intensity distribution map, second channel. This represents the corresponding instance mask image. The dual-channel design enables the network to perceive both the grayscale distribution characteristics of the risk field and retain the geometric boundary information of the risk region, thus providing a more stable input representation for subsequent clustering. The encoder itself adopts a convolutional autoencoder structure, first mapping the input to a low-dimensional latent space through multiple layers of convolution and downsampling, and then outputting the latent feature vector through a fully connected layer. The decoder then restores the latent features to the original two-channel segments, which are used to reconstruct the constraints.
[0040] Unlike traditional autoencoders, this method does not directly process the raw input. Instead of encoding clustering features, we first construct multiple rotational viewpoints. Let the rotation transformation operator be... Then for the sample generate Rotated views at different angles: ; In a preferred embodiment, four discrete rectangular rotational viewing angles can be used, namely In another preferred embodiment, a covering may also be used. Uniform angle sampling within the interval. The former has lower computational cost and is suitable for large-scale samples; the latter provides more comprehensive rotational coverage and is suitable for scenarios with higher sensitivity to orientation.
[0041] For each rotational viewpoint, feature extraction is performed using an encoder with the same set of shared parameters. Let the encoder be mapped as... Then the first The potential representation of a rotational viewpoint is: ; Because all rotated views share the same encoder parameters, the network is forced to learn a shared set of representations that are interpretable for inputs in different directions, rather than learning a separate set of unrelated features for each direction. This makes the model more focused on the topological shape, banding, peak relationships, and channel correspondences of the risk distribution, rather than the absolute orientation of the image. This rotation-invariant representation serves as the input feature for subsequent deep embedding clustering.
[0042] Let the first Latent features are obtained from each sample after rotation-invariant encoding. ,Will Perform initial clustering, such as using the k-means method, to obtain initial clusters. Cluster centers; No. The cluster centers are , Used to indicate the first The central feature of risk-like scenarios in the potential feature space.
[0043] This method uses a soft-assignment approach to calculate the membership degree of a sample to each cluster center. The sample belongs to the first The soft assignment probability of a cluster is defined as: ; in, Indicates sample Belongs to the The probability of a cluster. For distribution parameters, This represents the index of all candidate cluster centers. The closer a sample is to a given cluster center, the higher its index. The larger the value, the more likely the sample is to belong to that cluster category.
[0044] This soft allocation method avoids the instability caused by hard clustering, allowing samples to gradually move closer to more suitable cluster centers during the training process.
[0045] To enhance the guiding role of high-confidence samples in cluster optimization, a target distribution is further constructed based on the current soft assignment results: ; in, The target distribution is then used. As an optimization guide, the encoder output is soft-assigned. Gradually approaching the target distribution This process continuously adjusts the latent feature representation and cluster center locations. In this way, similar risk segments can be clustered more closely in the latent space, and the distinction between different types of risk segments can be made more obvious, thereby improving the stability and interpretability of risk scenario clustering results.
Claims
1. A risk scenario clustering method based on a spatiotemporal interactive risk field, characterized in that, The method includes the following steps: S1. Perform a unified interface conversion on vehicle trajectories from different datasets to form a standardized vehicle state representation; S2. Based on vehicle status and size information, construct the vehicle's single-vehicle probability occupancy field; S3, All vehicles at the same time The probability occupancy field of a single bicycle is mapped onto the common grid space to obtain the time step. The interactive risk field below will be constantly All interactive risk fields are superimposed on the current prediction time to obtain the interactive risk field corresponding to the current prediction time. High-risk hotspots are extracted to obtain risk segments. Process the risky segments to obtain segment samples; S4. Introduce a rotation-invariant feature learning mechanism inside the encoder. Input the fragment samples into the encoder to obtain latent features. Cluster the latent features to obtain initial cluster centers. Use a soft assignment method to calculate the membership degree of the fragment samples to each cluster center.
2. The risk scenario clustering method based on a spatiotemporal interactive risk field according to claim 1, characterized in that, The standardized vehicle state representation is as follows: for any vehicle At the present moment Its vehicle status is represented as: ; in, The center position of the vehicle These refer to the vehicle's lateral and longitudinal dimensions, respectively. and These are the velocity and acceleration components, respectively. For heading angle, and These represent the vehicle's lateral and longitudinal directions, respectively.
3. The risk scenario clustering method based on spatiotemporal interactive risk field according to claim 2, characterized in that, For vehicles In the future The predicted state, let its center position be... The heading angle is In the vehicle's local coordinate system, any spatial point is denoted as... ,in Represents the longitudinal coordinate along the vehicle's heading direction. Represents the lateral coordinates along the vehicle's heading direction; based on vehicle status and size information, construct the vehicle... The probability of bicycles occupying space for: ; in: The longitudinal dimension occupied by the vehicle. The lateral dimensions occupied by the vehicle. This is the normalization coefficient.
4. The risk scenario clustering method based on spatiotemporal interactive risk field according to claim 3, characterized in that, time The interactive risk field under the following conditions is defined as: ; in, and For vehicle indexing, Indicates time Get off the vehicle The probability of bicycles occupying space. Indicates time Get off the vehicle The probability of a bicycle being occupied; The interactive risk field corresponding to the current prediction time is defined as: ;in, Indicates the current prediction time. This indicates the time discount weight.
5. A risk scenario clustering method based on a spatiotemporal interactive risk field according to claim 4, characterized in that, The specific methods for obtaining risk segments are as follows: The interactive risk field is standardized to obtain a standard risk map. Then, set the core risk threshold. and supporting risk threshold ,in Construct a core area mask based on the core risk threshold: ; Construct a support region mask based on the support risk threshold: ; in, This indicates a core area with a high level of risk. This indicates a supporting area surrounding the core area that has a certain risk association. This is an indicator function; it takes the value 1 if the condition is met and 0 if the condition is not met. With core area mask The connected regions in the code are used as seed regions. Under the constraints of the main road direction or vehicle movement direction, the support region mask is applied. The adjacent regions in the segment are directionally grown. During the growth process, it is determined whether the adjacent regions meet the preset merging conditions. If the preset merging conditions are met, they are merged into the current risk segment. If the preset merging conditions are not met, the risk segment will remain an independent risk segment or will be split.
6. The risk scenario clustering method based on a spatiotemporal interactive risk field according to claim 5, characterized in that, The risk segments are processed to obtain the following segment samples: For each single-instance risk segment, an adaptive Region of Interest (ROI) is generated, and the ROI is cropped and scaled into a segment sample of uniform size. The segment sample includes a risk map channel and a binary map channel, where the risk map channel is used to represent the risk intensity distribution and the binary map channel is used to represent the location and shape of the effective risk area.
7. A risk scenario clustering method based on a spatiotemporal interactive risk field according to claim 6, characterized in that, The rotation-invariant feature learning mechanism introduced within the encoder is specifically as follows: Do not directly input the raw input Instead of encoding clustering features, we first construct multiple rotational viewpoints; Let the rotation transformation operator be Then for the sample generate Rotated views at different angles: For each rotational viewpoint, the same encoder with shared parameters is used for feature extraction.
8. A risk scenario clustering method based on a spatiotemporal interactive risk field according to claim 7, characterized in that, When calculating the membership degree of a fragment sample to each cluster center using the soft allocation method, the th The sample belongs to the first The soft assignment probability of a cluster is defined as: ; in, Indicates sample Belongs to the The probability of a cluster. Indicates the first Latent features are obtained by encoding each sample using rotation-invariant encoding. Indicates the first Cluster centers, For distribution parameters, The index represents all candidate cluster centers. The closer a fragment sample is to a certain cluster center, the higher the corresponding cluster center. The larger the value, the better the sample size. The more likely it is to belong to the first One cluster.