## 3 Materials and Methods
### Vehicle Behavior Spatio-Temporal Interaction
#### 3.2.2 Enhanced Temporal Interaction Diagram Generation  
In modern traffic prediction and vehicle interaction analysis, traditional temporal interaction map generation methods often consider only simple temporal evolution information. They cannot adequately capture complex vehicle dynamics and variable traffic scenarios. An enhanced temporal interaction graph generation method was designed to address this issue. This method focuses on temporal changes and captures complex interactions such as vehicle acceleration, hard braking, hard acceleration, and behavioral patterns under complex traffic conditions (e.g., rainy days and nighttime). The generated temporal interaction diagram includes information such as \"Moving Forward\", \"Moving Backward\", \"Moving Left to Right\", \"Moving Right to Left\", \"No Change\", and more complex interactions. This comprehensive approach enables the model to capture and understand dynamic vehicle interactions better, thereby improving prediction accuracy and adaptability to diverse traffic scenarios.  
To represent the time series graph, the traffic scenario at each time step \(t\) is modeled using the following equation:  
\[G_{t}=\left(V_{t},E_{t}\right) \tag{8}\]  
where \(V_{t}\) represents the set of nodes at time \(t\), including all vehicles and road objects involved in the interaction at that moment, and \(E_{t}\) denotes the set of edges at time \(t\), representing the interactions between these nodes.  
To capture the dynamic interaction of vehicles over time, we consider the dynamic changes in edge weights \(w_{ij}(t)\). The relationship between vehicles \(v_{i}\) and \(v_{j}\) is assumed to depend not only on their current state but also their behavior in previous frames. This relationship can be modeled using the following equation:  
\[w_{ij}(t)=\sum_{\tau=0}^{\Delta t}\lambda^{\tau}\cdot f\left(v_{i}(t-\tau),v_{ j}(t-\tau)\right) \tag{9}\]  
where \(\Delta t\) represents the time window indicating the number of past time steps considered, \(\lambda\) is a decay factor that controls the influence of past time steps on the current edge weights, and \(f\left(v_{i}(t-\tau),v_{j}(t-\tau)\right)\) is a function that calculates the interactions between vehicles \(v_{i}\) and \(v_{j}\) at time \(t-\tau\), which may be based on differences in velocity, relative positions, accelerations, and other factors.  
Furthermore, we introduce the concept of time series convolution to capture complex interaction patterns over time. This technique aggregates vehicle interaction information over time, generating a new edge weight. The convolution operation can be expressed as follows:  
\[\widetilde{w}_{ij}(t)=\sigma\left(\sum_{k=0}^{K-1}W_{k}\cdot w_{ij}(t-k)+b_{ k}\right) \tag{10}\]  
where \(\widetilde{w}_{ij}(t)\) represents the edge weight after time convolution; \(K\) is the size of the convolution kernel, indicating the number of time steps considered; \(W_{k}\) is the convolution kernel weight for the \(k\) th time step; \(b_{k}\) is the bias term; and \(\sigma\) is the nonlinear activation function.  
At each time step \(t\), we obtain a temporally convolved graph \(\widetilde{G}_{t}=\left(V_{t},\widetilde{E}_{t}\right)\), where \(\widetilde{E}\) represents the set of edges obtained after convolving the time series. To capture the dynamic interactions over the entire period, we aggregate the convolved graphs from all time steps to obtain the final temporal interaction graph \(G_{\text{temp}}\):  
\[G_{temp}=\sum_{t=1}^{T}\widetilde{G}_{t} \tag{11}\]  
where \(T\) denotes the total number of time steps. This temporal interaction graph synthesizes the complex behavioral patterns of vehicles over time, effectively reflecting dynamic changes throughout the entire time series. It is well suited for accurate behavioral prediction and analysis. Time series convolution enhances the model's ability to capture complex interactions in the temporal dimension, thereby improving its performance in time-dynamic scenarios.