Big data-based intelligent analysis method for running track of electric bicycle

By using an improved variational recurrent neural network and sparse gating mechanism, the problem of insufficient feature capture, which has long been a factor in the analysis of electric bicycle trajectory data, has been solved. This has enabled high-precision and high-stability trajectory pattern recognition, thereby improving the application effect of urban traffic management.

CN121786616APending Publication Date: 2026-04-03JINHUA QIAOBO ELECTRIC TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-19
Publication Date
2026-04-03

AI Technical Summary

Technical Problem

Existing methods for analyzing electric bicycle trajectory data struggle to capture long-term dynamic dependency features when processing massive amounts of data. Furthermore, they are affected by noise interference and missing data, resulting in insufficient analysis accuracy and reliability, making it difficult to meet the needs of practical applications.

Method used

An improved variational recurrent neural network is employed, combined with a bidirectional time-series latent state transfer mechanism and a dynamic adaptive sparse gating mechanism. By standardizing trajectory data, sparsely fusing and generating latent variables, the accuracy and stability of trajectory pattern recognition are improved.

Benefits of technology

It effectively improves the ability to capture long-term dynamic features of electric bicycle travel trajectories, significantly enhances the accuracy and robustness of trajectory pattern recognition, and strengthens the application level of urban traffic management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121786616A_ABST
    Figure CN121786616A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent analysis method for a running track of an electric bicycle based on big data. The method comprises the following steps: acquiring original track data and sequentially processing the original track data; constructing an improved variational recurrent neural network, fusing historical and predicted trajectory information by using a bidirectional time-crossing hidden state transfer mechanism, and generating a bidirectional hidden state representation sequence; constructing a dynamic adaptive sparse gating mechanism to calculate a sparse weight vector, and performing sparse fusion processing to obtain an optimized hidden state feature sequence; generating latent variable probability distribution based on the optimized hidden state feature sequence and sampling to obtain a track latent variable sample; and training and optimizing neural network parameters to obtain a trajectory pattern intelligent analysis model and realize trajectory pattern recognition. According to the invention, the track pattern recognition precision and stability are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of trajectory intelligent analysis technology, and in particular to a method for intelligent analysis of the driving trajectory of electric bicycles based on big data. Background Technology

[0002] In recent years, with the rapid and continuous growth in the number of electric bicycles, the resulting traffic safety issues and traffic management challenges have become increasingly prominent. Analyzing electric bicycle trajectory data using intelligent methods can help to deeply understand rider behavior characteristics and improve urban traffic management. Currently, the mainstream technical solutions for electric bicycle trajectory data analysis mainly employ methods based on clustering analysis, probabilistic statistical analysis, and shallow machine learning algorithms. These methods typically extract potential patterns and regularities from trajectory data through feature statistics, trajectory clustering, and temporal-space pattern analysis to support traffic management decisions.

[0003] However, electric bicycle trajectory data is characterized by its massive volume, complex spatiotemporal features, and inconsistent data quality. Existing trajectory pattern analysis methods generally suffer from the following technical bottlenecks when analyzing massive amounts of trajectory data:

[0004] (0) Traditional clustering analysis or probabilistic statistical analysis methods have limited processing capabilities and are difficult to capture long-term dynamic dependence features in trajectory data; (1) Conventional machine learning algorithms do not adequately consider the complex spatial and temporal correlations of trajectory data in trajectory feature modeling, making it difficult to extract deep trajectory semantic features; (2) Due to noise interference, missing data and abnormal offset in trajectory data, the analysis accuracy of existing methods is generally low, which makes it difficult to meet the requirements of trajectory pattern recognition accuracy and reliability in practical applications.

[0005] To address the aforementioned shortcomings, researchers have begun to explore the use of deep learning techniques to analyze trajectory data, particularly variational recurrent neural network (NRNN) models, which have demonstrated potential in trajectory analysis due to their excellent sequence modeling performance. However, traditional NRNNs suffer from long-term reliance on insufficient capture capabilities, redundant model parameters, and poor latent variable modeling, resulting in a lack of significant improvement in trajectory pattern recognition accuracy.

[0006] Therefore, how to provide a method for intelligent analysis of electric bicycle trajectories based on big data is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention

[0007] One objective of this invention is to propose an intelligent analysis method for the trajectory of electric bicycles based on big data. Addressing the problem of low accuracy in trajectory pattern recognition during the analysis of massive electric bicycle trajectory data, this invention proposes a technical solution that employs an improved variational recurrent neural network and deeply integrates a bidirectional transtemporal hidden state transfer mechanism with a dynamic adaptive sparse gating mechanism. This invention possesses the advantages of high accuracy in trajectory pattern recognition, strong model generalization performance, and high reliability of analysis results.

[0008] According to an embodiment of the present invention, an intelligent analysis method for the trajectory of an electric bicycle based on big data includes: The raw trajectory data of electric bicycles is collected and processed to obtain a standardized trajectory data sequence; An improved variational recurrent neural network is constructed and initialized based on standardized trajectory data sequences; Based on an improved variational recurrent neural network, a bidirectional cross-temporal hidden state transfer mechanism is used to fuse past and future trajectory information to generate a bidirectional hidden state representation sequence. A dynamic adaptive sparse gating mechanism is constructed, and a sparse weight vector is obtained by calculating the bidirectional hidden state representation sequence. Sparse weight vectors are used to sparsely fuse the bidirectional hidden state representation sequence to generate a sparsely optimized hidden state feature representation sequence. An optimized latent variable probability distribution is generated based on the sparse optimized latent state feature representation sequence and the standardized trajectory data sequence, and trajectory latent variable samples are obtained from it. By taking the trajectory latent variable samples and the sparsely optimized latent state feature representation sequence as input, the improved variational recurrent neural network parameters are trained and optimized to obtain a trajectory pattern intelligent analysis model. The electric bicycle trajectory data sequence to be analyzed is input into the trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result.

[0009] Optionally, the process of collecting and processing the raw trajectory data of the electric bicycle to obtain a standardized trajectory data sequence is as follows: The original trajectory data of electric bicycles is collected using positioning sensors to obtain a sequence of original trajectory data represented by latitude and longitude coordinates and timestamps; The instantaneous velocities of adjacent trajectory points in the original trajectory data sequence are calculated. Trajectory points with abnormal velocities are removed by a velocity threshold window, and latitude and longitude coordinates are processed by a sliding window mean filter to obtain a denoised trajectory data sequence. Based on road topology information, the shortest vertical projection distance between each trajectory point in the denoised trajectory data sequence and the real road is calculated. The trajectory points are then projected onto the candidate road segment with the smallest distance to obtain the trajectory data sequence with road constraints. Based on the valid data before and after the missing data points in the trajectory data sequence constrained by the road, the missing data is interpolated using a linear interpolation method to obtain a trajectory data sequence without missing data. The latitude and longitude coordinates and timestamps in the trajectory data sequence without missing data are processed by max-min normalization to obtain a standardized trajectory data sequence.

[0010] Optionally, the improved variational recurrent neural network includes an input layer, a bidirectional time-series latent state transfer layer, a dynamically adaptive sparse gating layer, and a variational latent variable generation layer. The input layer is used to receive standardized trajectory data sequences and map trajectory data points into fixed-dimensional trajectory data feature vectors through a linear mapping matrix to generate trajectory embedding representation sequences. The bidirectional time-series hidden state transfer layer is used to calculate the forward hidden state and backward hidden state of the current time step based on the trajectory embedding representation sequence using a forward recursive neural network and a backward recursive neural network, respectively, and then concatenates the forward hidden state and the backward hidden state to generate a bidirectional hidden state representation sequence. The dynamic adaptive sparse gating layer is used to calculate the sparse gating weight vector for each hidden state feature vector in the bidirectional hidden state representation sequence, and perform element-wise multiplication with the corresponding hidden state feature vector to obtain the sparse optimized hidden state feature representation sequence. The variational latent variable generation layer is used to take the sparsely optimized latent state feature representation sequence as input, calculate the mean vector and variance vector through two independent fully connected networks respectively, construct the Gaussian probability distribution of the latent variable, and randomly sample from the Gaussian probability distribution based on the reparameterization technique to obtain trajectory latent variable samples.

[0011] Optionally, the improved variational recurrent neural network employs a bidirectional cross-temporal hidden state transfer mechanism to fuse past and future trajectory information, generating a bidirectional hidden state representation sequence, specifically as follows: Input the trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence into the forward recurrent neural network to calculate the forward hidden state feature vector of the current time step; Input the trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence into the backward recurrent neural network to calculate the backward hidden state feature vector of the current time step. The forward hidden state feature vector and the backward hidden state feature vector of the current time step are fused using a predefined feature concatenation operation to obtain the initial bidirectional hidden state feature vector of the current time step. Using the initial bidirectional hidden state feature vector of the current time step as input, the attention weight system of the current time step is calculated through the bidirectional cross-time hidden state transfer mechanism; Based on the attention weight coefficient, the initial bidirectional hidden state feature vector of the current time step, the forward hidden state feature vector of multiple adjacent historical time steps, and the backward hidden state feature vector of multiple adjacent prediction time steps are weighted and summed to obtain the enhanced bidirectional hidden state representation vector of the current time step. Repeat the aforementioned hidden state feature calculation, attention weight coefficient calculation, and weighted summation of hidden state features to obtain an enhanced bidirectional hidden state representation sequence.

[0012] Optionally, the construction of the dynamic adaptive sparse gating mechanism obtains the sparse weight vector by calculating the bidirectional hidden state representation sequence, specifically as follows: The enhanced bidirectional hidden state representation vector at each time step in the enhanced bidirectional hidden state representation sequence is input into a dynamic adaptive sparse gating mechanism. In the dynamic adaptive sparse gating mechanism, the first linear mapping matrix performs a linear transformation on the enhanced bidirectional hidden state representation vector to obtain the intermediate feature representation vector. The intermediate feature representation vector is non-linearly mapped element-by-element using the Sigmoid function to obtain the initial sparse weight vector. Set the elements in the initial sparse weight vector whose values ​​are less than a fixed threshold parameter to zero to obtain a binary sparse weight mask vector. The initial sparse weight vector is selectively retained or set to zero based on the binarized sparse weight mask vector to obtain the final sparse weight vector. The final sparse weight vector is obtained by combining the enhanced bidirectional hidden state representation sequence in temporal order.

[0013] Optionally, the step of sparsely fusing the bidirectional hidden state representation sequence with sparse weight vectors to generate a sparsely optimized hidden state feature representation sequence specifically involves: The sparse weight vector is mapped one-to-one with the enhanced bidirectional hidden state representation sequence; Determine the positions of zero and non-zero elements in the sparse weight vector; The enhanced bidirectional hidden state representation vector is divided one by one according to the positions of elements with zero and non-zero values. Set the elements with zero values ​​in the enhanced bidirectional hidden state representation vector to zero; Sparse fusion is performed on all the enhanced bidirectional hidden state representation vectors in sequence to obtain the sparsely optimized hidden state feature representation vector at each time step. Arrange all the sparsely optimized hidden state feature representation vectors in their original order to obtain the sparsely optimized hidden state feature representation sequence.

[0014] Optionally, the step of generating an optimized latent variable probability distribution based on the sparse optimized latent state feature representation sequence and the standardized trajectory data sequence, and sampling from it to obtain trajectory latent variable samples, specifically involves: The sparsely optimized hidden state feature representation sequence is matched with the standardized trajectory data sequence according to the corresponding time steps, and the sparsely optimized hidden state feature representation vector of each time step is concatenated with the standardized trajectory data feature vector to obtain the joint feature vector. The joint feature vector is input into the first latent variable probability distribution generation network and the second latent variable probability distribution generation network to generate the mean vector and variance vector of the latent variable probability distribution, respectively. The variance vector is subjected to exponential operation to ensure that the value is positive. Establish a multidimensional Gaussian probability distribution of the latent variables at the current time step based on the mean vector and variance vector; Random noise vectors with the same dimension as the mean vector are collected from the standard multidimensional Gaussian distribution. The random noise vectors are multiplied element-wise by the variance vector and then added element-wise by the mean vector to complete the reparameterized random sampling of the latent variable probability distribution. The random sampling operation of the probability distribution of latent variables is performed sequentially at all time steps to obtain the trajectory latent variable samples.

[0015] Optionally, the step of using trajectory latent variable samples and sparsely optimized latent state feature representation sequences as input to train and optimize improved variational recurrent neural network parameters to obtain a trajectory pattern intelligent analysis model specifically involves: The trajectory latent variable samples are concatenated with the feature vectors of each time step in the sparsely optimized latent state feature representation sequence to generate a joint input feature vector. The joint input feature vector is fed into an improved variational recurrent neural network, which outputs the trajectory pattern prediction result at the current time step. Using preset trajectory pattern category labels, the cross-entropy loss between the trajectory pattern prediction result and the trajectory pattern category label is calculated; Calculate the KL divergence loss between the latent variable probability distribution and the standard Gaussian prior distribution, and sum it with the cross-entropy loss to obtain the comprehensive loss at the current time step; The gradient of the integrated loss with respect to the linear transformation matrix and bias vector parameters in the improved variational recurrent neural network is calculated using the backpropagation algorithm. By updating the linear transformation matrix and bias vector parameters in the improved variational recurrent neural network using gradients and learning rates, and repeatedly performing forward and backward propagation calculations until the comprehensive loss reaches the convergence threshold, a trajectory pattern intelligent analysis model is obtained.

[0016] Optionally, the step of inputting the electric bicycle trajectory data sequence to be analyzed into the trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result is as follows: The standardized trajectory data to be analyzed is mapped using a pre-trained linear mapping matrix to generate the trajectory embedding representation sequence to be analyzed; The bidirectional time-series hidden state transfer layer of the trained trajectory pattern intelligent analysis model generates an enhanced bidirectional hidden state representation sequence to be analyzed based on the trajectory embedding representation sequence. The dynamic adaptive sparse gating layer of the trajectory pattern intelligent analysis model, after training, is used to perform sparse fusion processing on the enhanced bidirectional hidden state representation sequence to be analyzed, so as to obtain the sparse optimized hidden state feature representation sequence to be analyzed. The variational latent variable generation layer of the trained trajectory pattern intelligent analysis model calculates the mean vector and variance vector of the probability distribution of latent variables based on the sparse optimized latent state feature representation sequence to be analyzed. The mean vector and variance vector are reparameterized and randomly sampled using a pre-defined standard Gaussian random noise vector within the model to obtain trajectory latent variable samples. The trajectory latent variable samples are concatenated with the sparsely optimized latent state feature representation vector, and then input into the trained trajectory pattern intelligent analysis model for forward operation, outputting the probability distribution of trajectory pattern category prediction. Based on the probability distribution, the category label with the highest probability value is determined as the trajectory pattern recognition result.

[0017] The beneficial effects of this invention are: (1) This invention effectively improves the ability to capture long-term dynamic features in the trajectory of electric bicycles by using an improved variational recurrent neural network deep fusion bidirectional cross-time hidden state transmission mechanism, thereby enhancing the reliability and stability of trajectory pattern recognition.

[0018] (2) This invention achieves accurate extraction and effective screening of key feature information of trajectory data through dynamic adaptive sparse gating mechanism, significantly improves the accuracy of trajectory pattern analysis, and shows better adaptability and robustness in the scenario of massive trajectory data analysis of electric bicycles.

[0019] (3) In terms of the accuracy of trajectory pattern recognition, this invention effectively solves the technical problem of insufficient feature capture for complex spatiotemporal trajectory data in the prior art through the synergistic effect of bidirectional cross-temporal hidden state transmission mechanism and dynamic adaptive sparse gating mechanism. It breaks through the bottleneck of low recognition accuracy of existing trajectory pattern analysis methods, realizes specific and significant progress in trajectory pattern recognition capability, and effectively improves the application level in the field of urban traffic management. Attached Figure Description

[0020] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:

[0021] Figure 1 This is a schematic diagram of the overall technical process of an intelligent analysis method for the driving trajectory of electric bicycles based on big data, as proposed in this invention. Figure 2 This is a schematic diagram of an improved variational recurrent neural network structure for an intelligent analysis method of electric bicycle travel trajectory based on big data proposed in this invention. Figure 3 This is a schematic diagram of the dynamic adaptive sparse gating mechanism of the intelligent analysis method for electric bicycle driving trajectory based on big data proposed in this invention. Detailed Implementation

[0022] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0023] refer to Figures 1-3 A method for intelligent analysis of electric bicycle trajectories based on big data, comprising: The original trajectory data of the electric bicycle is collected, and the original trajectory data is sequentially processed by data denoising, trajectory correction, missing data imputation and standardization to obtain a standardized trajectory data sequence. Based on standardized trajectory data sequences, an improved variational recurrent neural network is constructed, and the input layer, bidirectional intertemporal latent state transfer layer, variational latent variable generation layer, and output prediction layer in the improved variational recurrent neural network are initialized respectively. Based on the improved variational recurrent neural network, when generating the hidden state at the current time step, a bidirectional cross-time hidden state transfer mechanism is adopted to fuse trajectory information from several past historical time steps and several future predicted time steps to generate an enhanced bidirectional hidden state representation sequence. A dynamic adaptive sparse gating mechanism is constructed, and a sparse weight vector is obtained by calculating the bidirectional hidden state representation sequence. By using sparse weight vectors, a sparse fusion process is performed on the bidirectional hidden state representation sequence to generate a sparsely optimized hidden state feature representation sequence. Based on the sparse optimized latent state feature representation sequence and the standardized trajectory data sequence, an optimized latent variable probability distribution is generated, and trajectory latent variable samples are obtained by sampling from the optimized latent variable probability distribution. The trajectory latent variable samples and the sparsely optimized latent state feature representation sequence are used as inputs to train and iteratively optimize the parameters of the improved variational recurrent neural network, thereby obtaining a trained trajectory pattern intelligent analysis model. The electric bicycle trajectory data sequence to be analyzed is input into the trained trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result.

[0024] In this embodiment, the process of collecting the original trajectory data of the electric bicycle and then sequentially performing data denoising, trajectory correction, missing data imputation, and standardization on the original trajectory data to obtain a standardized trajectory data sequence is as follows: The original trajectory data of the electric bicycle is collected in real time by the positioning sensor installed on the electric bicycle, and the original trajectory data sequence is obtained in the form of latitude and longitude coordinates and corresponding timestamps. For noisy data in the original trajectory data sequence, the instantaneous velocity of any two adjacent trajectory points in the original trajectory data sequence is calculated. Trajectory points whose instantaneous velocity values ​​are outside the speed threshold window are judged and removed by a preset speed threshold window. The latitude and longitude coordinates of each trajectory point in the trajectory data sequence after removing noise points are respectively subjected to mean filtering by a sliding window centered on the trajectory point to obtain the denoised trajectory data sequence. Based on the pre-stored road topology information, for each trajectory point in the denoised trajectory data sequence, the shortest vertical projection distance between the trajectory point and each candidate road segment of the real road is calculated. The trajectory point is then projected onto the candidate road segment with the smallest distance, and the original trajectory point is replaced with the projected coordinate position to obtain the road-constrained trajectory data sequence. Based on the valid trajectory data before and after the missing data points in the trajectory data sequence constrained by the road, the missing data is interpolated using a linear interpolation method to obtain a trajectory data sequence without missing data. The latitude and longitude coordinates and corresponding timestamps in the trajectory data sequence without missing coordinates are standardized using the max-min normalization method to obtain a standardized trajectory data sequence.

[0025] In this embodiment, the improved variational recurrent neural network includes an input layer, a bidirectional time-series latent state propagation layer, a dynamically adaptive sparse gating layer, and a variational latent variable generation layer: The input layer is used to receive a standardized trajectory data sequence represented by latitude and longitude coordinates and corresponding timestamps, and to map each trajectory data point in the standardized trajectory data sequence into a trajectory data feature vector with a unified fixed dimension through a pre-trained linear mapping matrix, thereby generating a trajectory embedding representation sequence. The bidirectional time-series hidden state propagation layer is used to iteratively calculate the forward hidden state and backward hidden state of the current time step by time step, using the trajectory embedding representation sequence of each time step as input and employing both a forward recurrent neural network and a backward recurrent neural network respectively. The forward recurrent neural network integrates the current trajectory embedding representation vector and the hidden state of the previous historical time step in the hidden state calculation at each time step. The backward recurrent neural network integrates the current trajectory embedding representation vector and the hidden state of the next prediction time step in the hidden state calculation at each time step. The obtained forward and backward hidden states are concatenated at each time step to generate a bidirectional hidden state representation sequence. The dynamic adaptive sparse gating layer is used to take the hidden state feature vector of each time step in the bidirectional hidden state representation sequence as input, calculate the sparse gating weight vector corresponding to the hidden state feature vector of each time step through a sparse gating fully connected network, and multiply the sparse gating weight vector with the hidden state feature vector of the corresponding time step element by element to obtain the sparse optimized hidden state feature representation sequence. The variational latent variable generation layer is used to take the latent state feature vector of each time step in the sparsely optimized latent state feature representation sequence as input, and use two independent fully connected networks to perform linear mapping on each latent state feature vector respectively. The first fully connected network outputs the mean vector of the probability distribution of the latent variable at the corresponding time step, and the second fully connected network outputs the variance vector of the probability distribution of the latent variable at the corresponding time step. Based on the mean vector and variance vector obtained at each time step, a Gaussian probability distribution of the latent variable at the corresponding time step is established, and the Gaussian probability distribution is randomly sampled through the reparameterization technique to obtain trajectory latent variable samples.

[0026] In this embodiment, the improved variational recurrent neural network, when generating the hidden state at the current time step, employs a bidirectional cross-time hidden state transfer mechanism to fuse trajectory information from several past historical time steps and several future predicted time steps, generating an enhanced bidirectional hidden state representation sequence, specifically: The trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence is input into the forward recurrent neural network. At the same time, the trajectory embedding representation vector is concatenated with the forward hidden state feature vector of the previous historical time step, and linear mapping is performed through the linear transformation matrix in the forward recurrent neural network to calculate the forward hidden state feature vector of the current time step. The trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence is input into the backward recurrent neural network. At the same time, the trajectory embedding representation vector is concatenated with the backward hidden state feature vector of the next prediction time step, and linear mapping is performed through the linear transformation matrix in the backward recurrent neural network to calculate the backward hidden state feature vector of the current time step. The forward hidden state feature vector and the backward hidden state feature vector of the current time step are fused using a predefined feature concatenation operation to obtain the initial bidirectional hidden state feature vector of the current time step. Using the initial bidirectional hidden state feature vector of the current time step as input, the attention weight coefficient of the current time step is calculated through a bidirectional cross-temporal hidden state transfer mechanism. The attention weight coefficient is used to measure the interdependence between the hidden state feature vector of the current time step and the hidden state feature vectors of multiple adjacent historical and predicted time steps. The bidirectional cross-temporal hidden state transfer mechanism is as follows: using the initial bidirectional hidden state feature vector of the current time step as the query vector, and using the forward hidden state feature vectors of multiple adjacent historical time steps and the backward hidden state feature vectors of multiple adjacent predicted time steps as the key vector and value vector, respectively, the attention weight coefficient between the query vector and each key vector is calculated through the dot product attention function, and the value vectors are weighted and summed based on the attention weight coefficient, thereby fusing the trajectory information of adjacent historical and predicted time steps to generate the enhanced bidirectional hidden state representation vector of the current time step. Based on the attention weight coefficient, the initial bidirectional hidden state feature vector of the current time step, the forward hidden state feature vector of multiple adjacent historical time steps, and the backward hidden state feature vector of multiple adjacent prediction time steps are weighted and summed to obtain the enhanced bidirectional hidden state representation vector of the current time step. Using the trajectory embedding representation vector of each time step in the trajectory embedding representation sequence as the input of the current time step, the aforementioned hidden state feature calculation, attention weight coefficient calculation and weighted summation of hidden state features are repeatedly performed to obtain an enhanced bidirectional hidden state representation sequence.

[0027] In this embodiment, the construction of the dynamic adaptive sparse gating mechanism, which obtains the sparse weight vector by calculating the bidirectional hidden state representation sequence, specifically involves: The enhanced bidirectional hidden state representation vector at each time step in the enhanced bidirectional hidden state representation sequence is input into a dynamic adaptive sparse gating mechanism, which is as follows: The initial sparse weight vector is calculated by taking the enhanced bidirectional hidden state representation vector at each time step as input and performing linear mapping and Sigmoid activation operations sequentially through a sparse gated fully connected network. Then, using a fixed threshold parameter as a benchmark, thresholding is performed on each element of the initial sparse weight vector to generate a binary sparse weight mask vector. Finally, based on the binarized sparse weight mask vector, the element values ​​in the initial sparse weight vector are selectively retained or set to zero, thereby adaptively obtaining the final sparse weight vector for each time step. The enhanced bidirectional hidden state representation vector at each time step is linearly transformed by the first linear mapping matrix in the dynamic adaptive sparse gating mechanism to obtain the intermediate feature representation vector. The nonlinear sparse activation function performs an element-wise nonlinear mapping on the intermediate feature representation vector. The nonlinear sparse activation function uses the Sigmoid function to constrain the value of each element to between 0 and 1, thereby obtaining the initial sparse weight vector corresponding to each time step. For each element in the initial sparse weight vector obtained at each time step, a thresholding process is performed. The thresholding method is as follows: set a fixed threshold parameter, set the element in the initial sparse weight vector whose value is less than the fixed threshold parameter to the value 0, and obtain a binarized sparse weight mask vector. The element values ​​of the initial sparse weight vector corresponding to the non-zero element positions in the binarized sparse weight mask vector are retained, and the element values ​​of the initial sparse weight vector corresponding to the zero element positions are set to 0 to obtain the final sparse weight vector. The final sparse weight vectors of all time steps are combined and arranged in the time order of the original enhanced bidirectional hidden state representation sequence to obtain the sparse weight vector.

[0028] In this embodiment, the step of using sparse weight vectors to perform sparse fusion processing on the bidirectional hidden state representation sequence to generate a sparsely optimized hidden state feature representation sequence specifically involves: The sparse weight vector is mapped one-to-one with the enhanced bidirectional hidden state representation sequence at each time step; For each time step, determine the positions of elements with zero values ​​and the positions of elements with non-zero values ​​in the sparse weight vector. Based on the positions of elements with zero values ​​and elements with non-zero values, the values ​​of each element in the enhanced bidirectional hidden state representation vector at the corresponding time step in the enhanced bidirectional hidden state representation sequence are divided one by one. The values ​​of elements at non-zero positions in the enhanced bidirectional hidden state representation vector are preserved unchanged, while the values ​​of elements at zero positions are set to zero. Sparse fusion processing is performed sequentially on the enhanced bidirectional hidden state representation vectors at all time steps to obtain the sparsely optimized hidden state feature representation vectors at each time step. The sparsely optimized hidden state feature representation vectors of all time steps are combined and arranged in the time order of the original enhanced bidirectional hidden state representation sequence to obtain the sparsely optimized hidden state feature representation sequence.

[0029] In this embodiment, the step of using sparse weight vectors to perform sparse fusion processing on the bidirectional hidden state representation sequence to generate a sparsely optimized hidden state feature representation sequence specifically involves: The sparsely optimized hidden state feature representation sequence is matched with the standardized trajectory data sequence one by one according to the corresponding time step, and the sparsely optimized hidden state feature representation vector of each time step is concatenated with the standardized trajectory data feature vector of the corresponding time step to obtain the joint feature vector of each time step. The joint feature vector at each time step is input into the first latent variable probability distribution generation network and the second latent variable probability distribution generation network, respectively. The first latent variable probability distribution generation network consists of a linear transformation matrix and a bias vector, while the second latent variable probability distribution generation network consists of another independent linear transformation matrix and a bias vector. The first latent variable probability distribution generation network performs a linear transformation calculation on each joint feature vector and outputs the mean vector of the latent variable probability distribution corresponding to the current time step. The second latent variable probability distribution generation network performs a linear transformation calculation on each joint feature vector, outputs a variance vector corresponding to the latent variable probability distribution at the current time step, and performs an exponential operation on the value of each element of the obtained variance vector to ensure that the value of each element in the obtained variance vector is positive. The probability distribution of the latent variable at the current time step is established based on the mean vector and the variance vector. The probability distribution is a multidimensional Gaussian probability distribution with each element in the mean vector as the mean and each element in the variance vector as the variance. Random noise vectors with the same dimension as the mean vector are randomly collected from the standard multidimensional Gaussian distribution. The random noise vectors are then multiplied element-wise by the variance vector and then added element-wise by the mean vector to complete the reparameterized random sampling of the latent variable probability distribution at the current time step. Following the original time step order of the sparsely optimized latent state feature representation sequence, random sampling of the latent variable probability distribution of all time steps is performed sequentially to obtain trajectory latent variable samples.

[0030] In this embodiment, the step of using trajectory latent variable samples and the sparsely optimized latent state feature representation sequence as input to train and iteratively optimize the parameters of the improved variational recurrent neural network, thereby obtaining the trained trajectory pattern intelligent analysis model, specifically involves: The feature vectors of each time step in the trajectory latent variable sample and the sparsely optimized latent state feature representation sequence are concatenated one by one to generate the joint input feature vector of each time step. The joint input feature vector at each time step is fed into an improved variational recurrent neural network. The network is then used to calculate the trajectory pattern prediction result for the current time step through the linear transformation matrix and nonlinear activation function layer by layer. Using preset trajectory pattern category labels, cross-entropy is calculated on the error between the trajectory pattern prediction result output at each time step and the corresponding preset trajectory pattern category label to obtain the trajectory pattern recognition loss at each time step. The latent variable loss is calculated using the KL divergence between the latent variable probability distribution corresponding to the trajectory latent variable sample obtained at the current time step and the standard Gaussian prior distribution. The trajectory pattern recognition loss and the latent variable loss are weighted and summed to obtain the comprehensive loss at the current time step. The comprehensive loss over all time steps is summed, and the gradient of the comprehensive loss with respect to the parameters of each linear transformation matrix and bias vector in the improved variational recurrent neural network is calculated using the backpropagation algorithm. The gradient and predefined learning rate are used to update all linear transformation matrices and bias vector parameters in the improved variational recurrent neural network. The forward calculation of the joint input feature vector and the backpropagation calculation of the comprehensive loss are repeatedly performed until the comprehensive loss reaches the preset convergence threshold, thus obtaining the trained trajectory pattern intelligent analysis model.

[0031] The electric bicycle trajectory data sequence to be analyzed is input into the trained trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result.

[0032] In this embodiment, the step of inputting the electric bicycle trajectory data sequence to be analyzed into the trained trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result is specifically as follows: Obtain standardized trajectory data of electric bicycles to be analyzed, and use a pre-trained linear mapping matrix to map the trajectory data points of each time step into trajectory embedding representation vectors to generate the trajectory embedding representation sequence to be analyzed. The trajectory to be analyzed is embedded into the bidirectional time-series hidden state transfer layer of the trajectory pattern intelligent analysis model that has been trained by inputting the sequence representation. The enhanced bidirectional hidden state representation vector corresponding to each time step is calculated to generate the enhanced bidirectional hidden state representation sequence to be analyzed. The enhanced bidirectional hidden state representation sequence to be analyzed is input into the dynamic adaptive sparse gating layer of the trained trajectory pattern intelligent analysis model. The sparse weight vector is calculated, and the enhanced bidirectional hidden state representation vector is sparsely fused by element-wise multiplication to obtain the sparse optimized hidden state feature representation sequence to be analyzed. The variational latent variable generation layer of the trajectory pattern intelligent analysis model is trained by inputting the sparse optimized latent state feature representation sequence to be analyzed. The mean and variance of the probability distribution of the latent variables corresponding to the current trajectory data are calculated through linear mapping within the model. The mean and variance of the probability distribution of the latent variables are reparameterized and randomly sampled using a pre-set standard Gaussian random noise vector within the model to obtain the trajectory latent variable samples corresponding to the trajectory data to be analyzed. The trajectory latent variable samples are concatenated with the sparsely optimized latent state feature representation vector to form a joint input feature vector. The forward linear transformation and nonlinear activation operation are then performed through the trained trajectory pattern intelligent analysis model to output the probability distribution of trajectory pattern category prediction. Based on the probability distribution of the output, the category label with the highest probability value is determined as the trajectory pattern recognition result of the electric bicycle trajectory data sequence to be analyzed.

[0033] Example 1: To verify the feasibility of this invention in practice, it was applied to an electric bicycle intelligent trajectory analysis project carried out by a city traffic management department. The project mainly focused on the massive amount of electric bicycle trajectory data collected in the city center, implementing intelligent analysis and recognition of driving trajectory patterns to assist the management department in optimizing traffic planning and safety supervision strategies.

[0034] In this application scenario, traditional trajectory analysis methods are typically based on clustering algorithms or statistical analysis techniques, which struggle to effectively capture long-term dependent features in electric bicycle trajectory data. Furthermore, the massive data volume, coupled with significant data noise and missing data, leads to generally low accuracy and insufficient stability in pattern recognition. To address this issue, this embodiment utilizes the intelligent analysis method for electric bicycle driving trajectories based on big data proposed in this invention to conduct accurate trajectory pattern analysis and recognition.

[0035] In the specific implementation process, the original trajectory data of electric bicycles is first collected in real time using positioning sensors, including latitude and longitude coordinates and timestamp information. Then, the collected data is denoised, that is, the instantaneous speed of adjacent trajectory points is calculated, trajectory points with abnormal speeds are removed, and then sliding window mean filtering is applied. Subsequently, trajectory correction processing is performed based on road topology information, mapping the trajectory points to the real road locations, and missing data is filled in using linear interpolation methods. Finally, data standardization processing is completed to obtain a high-quality standardized trajectory data sequence.

[0036] An improved variational recurrent neural network is constructed based on standardized data. First, a pre-trained linear mapping matrix is ​​used to embed the standardized trajectory data sequence, generating a trajectory embedding representation sequence. Then, a bidirectional time-series hidden state propagation mechanism is used to calculate the forward and backward hidden states, and historical and future time-step trajectory information is fused to generate an enhanced bidirectional hidden state representation sequence. Next, a dynamic adaptive sparse gating mechanism is used to perform nonlinear transformations and sparse weight selection on the enhanced bidirectional hidden state representation sequence to obtain a sparsely optimized hidden state feature representation sequence. In the latent variable generation stage, the hidden state feature representation sequence is concatenated with the trajectory data, and a variational latent variable generation network is used to obtain the latent variable probability distribution. Finally, reparameterized random sampling is used to obtain trajectory latent variable samples.

[0037] The training and optimization phase then begins, where the trajectory latent variable samples and the latent state feature representation sequence are jointly input into the improved variational recurrent neural network. The comprehensive loss is calculated by weighted combination of trajectory pattern recognition loss and latent variable loss. The network parameters are iteratively optimized using the backpropagation algorithm. After 35 rounds of training, the comprehensive loss function value reaches the preset convergence threshold of 0.045, completing the model training.

[0038] After the model training was completed, five sets of electric bicycle trajectory data samples randomly collected in a real-world environment were selected for testing and verification. The following five key indicators were evaluated: trajectory pattern category prediction accuracy, trajectory clustering consistency coefficient, trajectory pattern stability coefficient, trajectory noise robustness coefficient, and trajectory anomaly detection accuracy. The comparison between the measured and predicted results is shown in Table 1. Table 1 Performance Comparison of Electric Bicycle Trajectory Pattern Analysis Models

[0039] A detailed analysis of Table 1 reveals that the intelligent analysis method proposed in this invention achieves significant advantages in several key performance indicators. The trajectory pattern prediction accuracy remains consistently above 93%, with sample B achieving a prediction accuracy of 95.2%, effectively improving trajectory pattern classification. Both the clustering consistency coefficient and pattern stability coefficient remain above 0.91, indicating that the method possesses excellent clustering analysis performance and pattern recognition stability. Furthermore, this method demonstrates outstanding robustness to data noise, with noise robustness coefficients for each sample exceeding 0.88, confirming the model's stable operation even under real-world data interference. Anomaly detection accuracy also performs excellently, with all samples achieving anomaly detection accuracy exceeding 90.7%, further demonstrating the reliability and efficiency of this invention in anomaly trajectory recognition.

[0040] In summary, through verification and analysis in a real-world application environment in this embodiment, the intelligent analysis method for electric bicycle trajectories based on big data proposed in this invention can significantly improve the accuracy and stability of electric bicycle trajectory pattern recognition, and effectively solve the key technical challenges of traditional trajectory analysis methods in processing large-scale trajectory data. It has significant practical application value for urban traffic management and planning.

[0041] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A method for intelligent analysis of electric bicycle travel trajectories based on big data, characterized in that, include: The raw trajectory data of electric bicycles is collected and processed to obtain a standardized trajectory data sequence; An improved variational recurrent neural network is constructed and initialized based on standardized trajectory data sequences; Based on an improved variational recurrent neural network, a bidirectional cross-temporal hidden state transfer mechanism is used to fuse past and future trajectory information to generate a bidirectional hidden state representation sequence. A dynamic adaptive sparse gating mechanism is constructed, and a sparse weight vector is obtained by calculating the bidirectional hidden state representation sequence. Sparse weight vectors are used to sparsely fuse the bidirectional hidden state representation sequence to generate a sparsely optimized hidden state feature representation sequence. An optimized latent variable probability distribution is generated based on the sparse optimized latent state feature representation sequence and the standardized trajectory data sequence, and trajectory latent variable samples are obtained from it. By taking the trajectory latent variable samples and the sparsely optimized latent state feature representation sequence as input, the improved variational recurrent neural network parameters are trained and optimized to obtain the trajectory pattern intelligent analysis model. The electric bicycle trajectory data sequence to be analyzed is input into the trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result.

2. The intelligent analysis method for electric bicycle travel trajectory based on big data according to claim 1, characterized in that, The process of collecting and processing the raw trajectory data of the electric bicycle to obtain a standardized trajectory data sequence is as follows: The original trajectory data of electric bicycles is collected using positioning sensors to obtain a sequence of original trajectory data represented by latitude and longitude coordinates and timestamps; The instantaneous velocities of adjacent trajectory points in the original trajectory data sequence are calculated. Trajectory points with abnormal velocities are removed by a velocity threshold window, and latitude and longitude coordinates are processed by a sliding window mean filter to obtain a denoised trajectory data sequence. Based on road topology information, the shortest vertical projection distance between each trajectory point in the denoised trajectory data sequence and the real road is calculated. The trajectory points are then projected onto the candidate road segment with the smallest distance to obtain the trajectory data sequence with road constraints. Based on the valid data before and after the missing data points in the trajectory data sequence constrained by the road, the missing data is interpolated using a linear interpolation method to obtain a trajectory data sequence without missing data. The latitude and longitude coordinates and timestamps in the trajectory data sequence without missing data are processed by max-min normalization to obtain a standardized trajectory data sequence.

3. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The improved variational recurrent neural network includes an input layer, a bidirectional time-series latent state propagation layer, a dynamically adaptive sparse gating layer, and a variational latent variable generation layer. The input layer is used to receive standardized trajectory data sequences and map trajectory data points into fixed-dimensional trajectory data feature vectors through a linear mapping matrix to generate trajectory embedding representation sequences. The bidirectional time-series hidden state transfer layer is used to calculate the forward hidden state and backward hidden state of the current time step based on the trajectory embedding representation sequence using a forward recursive neural network and a backward recursive neural network, respectively, and then concatenates the forward hidden state and the backward hidden state to generate a bidirectional hidden state representation sequence. The dynamic adaptive sparse gating layer is used to calculate the sparse gating weight vector for each hidden state feature vector in the bidirectional hidden state representation sequence, and perform element-wise multiplication with the corresponding hidden state feature vector to obtain the sparse optimized hidden state feature representation sequence. The variational latent variable generation layer is used to take the sparsely optimized latent state feature representation sequence as input, calculate the mean vector and variance vector through two independent fully connected networks respectively, construct the Gaussian probability distribution of the latent variable, and randomly sample from the Gaussian probability distribution based on the reparameterization technique to obtain trajectory latent variable samples.

4. The intelligent analysis method for electric bicycle travel trajectory based on big data according to claim 1, characterized in that, The improved variational recurrent neural network employs a bidirectional cross-temporal hidden state transfer mechanism to fuse past and future trajectory information, generating a bidirectional hidden state representation sequence, specifically: Input the trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence into the forward recurrent neural network to calculate the forward hidden state feature vector of the current time step; Input the trajectory embedding representation vector of the current time step in the trajectory embedding representation sequence into the backward recurrent neural network to calculate the backward hidden state feature vector of the current time step. The forward hidden state feature vector and the backward hidden state feature vector of the current time step are fused using a predefined feature concatenation operation to obtain the initial bidirectional hidden state feature vector of the current time step. Using the initial bidirectional hidden state feature vector of the current time step as input, the attention weight system of the current time step is calculated through the bidirectional cross-time hidden state transfer mechanism; Based on the attention weight coefficient, the initial bidirectional hidden state feature vector of the current time step, the forward hidden state feature vector of multiple adjacent historical time steps, and the backward hidden state feature vector of multiple adjacent prediction time steps are weighted and summed to obtain the enhanced bidirectional hidden state representation vector of the current time step. Repeat the aforementioned hidden state feature calculation, attention weight coefficient calculation, and weighted summation of hidden state features to obtain an enhanced bidirectional hidden state representation sequence.

5. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The construction of the dynamic adaptive sparse gating mechanism obtains the sparse weight vector by calculating the bidirectional hidden state representation sequence, specifically as follows: The enhanced bidirectional hidden state representation vector at each time step in the enhanced bidirectional hidden state representation sequence is input into a dynamic adaptive sparse gating mechanism. In the dynamic adaptive sparse gating mechanism, the first linear mapping matrix performs a linear transformation on the enhanced bidirectional hidden state representation vector to obtain the intermediate feature representation vector. The intermediate feature representation vector is non-linearly mapped element-by-element using the Sigmoid function to obtain the initial sparse weight vector. Set the elements in the initial sparse weight vector whose values ​​are less than a fixed threshold parameter to zero to obtain a binary sparse weight mask vector. The initial sparse weight vector is selectively retained or set to zero based on the binarized sparse weight mask vector to obtain the final sparse weight vector. The final sparse weight vector is obtained by combining the enhanced bidirectional hidden state representation sequence in temporal order.

6. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The step of sparsely fusing the bidirectional hidden state representation sequence with sparse weight vectors to generate a sparsely optimized hidden state feature representation sequence is as follows: The sparse weight vector is mapped one-to-one with the enhanced bidirectional hidden state representation sequence; Determine the positions of zero and non-zero elements in the sparse weight vector; The enhanced bidirectional hidden state representation vector is divided one by one according to the positions of elements with zero and non-zero values. Set the elements with zero values ​​in the enhanced bidirectional hidden state representation vector to zero; Sparse fusion is performed on all the enhanced bidirectional hidden state representation vectors in sequence to obtain the sparsely optimized hidden state feature representation vector at each time step. Arrange all the sparsely optimized hidden state feature representation vectors in their original order to obtain the sparsely optimized hidden state feature representation sequence.

7. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The optimized latent variable probability distribution is generated based on the sparse optimized latent state feature representation sequence and the standardized trajectory data sequence, and trajectory latent variable samples are obtained from it. Specifically: The sparsely optimized hidden state feature representation sequence is matched with the standardized trajectory data sequence according to the corresponding time steps, and the sparsely optimized hidden state feature representation vector of each time step is concatenated with the standardized trajectory data feature vector to obtain the joint feature vector. The joint feature vector is input into the first latent variable probability distribution generation network and the second latent variable probability distribution generation network to generate the mean vector and variance vector of the latent variable probability distribution, respectively. The variance vector is subjected to exponential operation to ensure that the value is positive. Establish a multidimensional Gaussian probability distribution of the latent variables at the current time step based on the mean vector and variance vector; Random noise vectors with the same dimension as the mean vector are collected from the standard multidimensional Gaussian distribution. The random noise vectors are multiplied element-wise by the variance vector and then added element-wise by the mean vector to complete the reparameterized random sampling of the latent variable probability distribution. The random sampling operation of the probability distribution of latent variables is performed sequentially at all time steps to obtain the trajectory latent variable samples.

8. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The process involves using trajectory latent variable samples and a sparsely optimized sequence of latent state feature representations as input to train and optimize the parameters of an improved variational recurrent neural network, thereby obtaining an intelligent trajectory pattern analysis model. Specifically: The trajectory latent variable samples are concatenated with the feature vectors of each time step in the sparsely optimized latent state feature representation sequence to generate a joint input feature vector. The joint input feature vector is fed into an improved variational recurrent neural network, which outputs the trajectory pattern prediction result at the current time step. Using preset trajectory pattern category labels, the cross-entropy loss between the trajectory pattern prediction result and the trajectory pattern category label is calculated; Calculate the KL divergence loss between the latent variable probability distribution and the standard Gaussian prior distribution, and sum it with the cross-entropy loss to obtain the comprehensive loss at the current time step; The gradient of the integrated loss with respect to the linear transformation matrix and bias vector parameters in the improved variational recurrent neural network is calculated using the backpropagation algorithm. By updating the linear transformation matrix and bias vector parameters in the improved variational recurrent neural network using gradients and learning rates, and repeatedly performing forward and backward propagation calculations until the comprehensive loss reaches the convergence threshold, a trajectory pattern intelligent analysis model is obtained.

9. The intelligent analysis method for the driving trajectory of an electric bicycle based on big data according to claim 1, characterized in that, The process involves inputting the electric bicycle trajectory data sequence to be analyzed into the trajectory pattern intelligent analysis model to obtain the trajectory pattern recognition result, specifically as follows: The standardized trajectory data to be analyzed is mapped using a pre-trained linear mapping matrix to generate the trajectory embedding representation sequence to be analyzed; The bidirectional time-series hidden state transfer layer of the trained trajectory pattern intelligent analysis model generates an enhanced bidirectional hidden state representation sequence to be analyzed based on the trajectory embedding representation sequence. The dynamic adaptive sparse gating layer of the trajectory pattern intelligent analysis model, after training, is used to perform sparse fusion processing on the enhanced bidirectional hidden state representation sequence to be analyzed, so as to obtain the sparse optimized hidden state feature representation sequence to be analyzed. The variational latent variable generation layer of the trained trajectory pattern intelligent analysis model calculates the mean vector and variance vector of the probability distribution of latent variables based on the sparse optimized latent state feature representation sequence to be analyzed. The mean vector and variance vector are reparameterized and randomly sampled using a pre-defined standard Gaussian random noise vector within the model to obtain trajectory latent variable samples. The trajectory latent variable samples are concatenated with the sparsely optimized latent state feature representation vector, and then input into the trained trajectory pattern intelligent analysis model for forward operation, outputting the probability distribution of trajectory pattern category prediction. Based on the probability distribution, the category label with the highest probability value is determined as the trajectory pattern recognition result.