An individual travel pattern analysis method based on semi-supervised hypergraph clustering
By using the semi-supervised hypergraph clustering method in traffic data analysis, a high-order correlation relationship that represents passenger travel behavior through hypergraphs is constructed. Combined with the deep convolutional fusion module and the dual self-supervised module, the problem of insufficient clustering performance in the existing technology is solved, and more accurate individual travel mode analysis is achieved.
Patent Information
- Application Number
- CN202211218949.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-07
- Publication Date
- 2025-06-13
- Estimated Expiration
- 2042-10-07
AI Technical Summary
The prior art is difficult to accurately capture the complex many-to-many relationship between passenger travel, resulting in insufficient clustering performance and the inability to effectively explore individuals with similar travel behaviors.
The semi-supervised hypergraph clustering method is adopted to represent the high-order correlation between individuals by constructing hypergraphs, and combined with the deep convolutional fusion module and the dual self-supervised module, the accuracy of clustering results is improved.
Effectively capture and represent the complex relationship between passenger travel behavior, improve the accuracy and effectiveness of clustering, and better discover passengers with similar travel patterns.
Smart Images

Figure CN115809279B_ABST
Abstract
Description
Technical Field
[0001] This method mainly relates to the fields of traffic data analysis, deep learning, and hypergraph learning theory, and is an individual travel pattern analysis technology based on semi-supervised hypergraph clustering. Background Art
[0002] Understanding the travel patterns of individuals and identifying passengers with similar travel patterns contribute to public transportation planning and classification management. An individual's travel behavior on public transportation may exhibit random or repetitive patterns. Influenced by social relationships, when multiple individuals travel together to complete the same social activity, they may even have similar travel patterns. In this case, passengers with social relationships may have similar characteristics in terms of travel time, travel location, and travel preferences (such as travel frequency, travel consumption, and travel duration). The strong connection that links this similarity in the movement pattern is called mobility correlation. When a passenger has multiple travel behaviors and is correlated with the behaviors of multiple passengers, its correlation is of the many-to-many type, showing high-order complexity. For example, passengers may have similarities in terms of travel location, travel frequency, time correlation, OD path frequency, etc. This situation undoubtedly poses a huge obstacle to understanding passenger travel correlation. Capturing this complex and ubiquitous movement association will provide a solid foundation for classifying passengers with similar travel behaviors into one category. Potential research results contribute to providing customized services for passenger groups in the public transportation system.
[0003] One solution to identify mobility correlation is to classify individuals with similar travel patterns into one category. In these studies, the travel characteristics of passengers are first extracted from the original traffic data. Then, they are directly or modeled through a graph (a structure that connects one node to another node) to represent their pairwise correlations. The travel characteristics or graph-based characteristics are clustered to group passengers with similar travel patterns. However, since the graph structure can only represent one-to-one connections between two passengers and cannot quantify the many-to-many associations hidden among multiple passengers, their clustering performance still needs to be improved.
[0004] In recent decades, graph neural networks that represent the pairwise correlations between any two nodes in the field of deep learning have been widely used to model hidden feature representations in raw data. Previous studies have confirmed that such representations help improve the performance of graph-based clustering in multiple tasks. Therefore, it is suitable for mining the pairwise relationships between passenger travel behaviors. Only through pairwise one-to-one connections, it is difficult for this method to represent the high-order relationships existing among multiple nodes, let alone model the complex travel correlations of passengers with many-to-many mapping relationships. In this case, a new structure is needed to represent high-order correlations higher than pairwise relationships. Relevant literature shows that a hypergraph is a generalization of a graph, where a hyperedge can be represented as a set of specific vertices. A hypergraph can represent non-pairwise relationships between vertices with hyperedges. It is good at describing the relationships between objects with many-to-many correlations. Therefore, a hypergraph is adopted to replace a simple graph to represent non-pairwise relationships between vertices because a hypergraph can represent the complex associations between vertices with hyperedges, and hyperedges are suitable for representing the complex relationships between passenger travel behaviors.
[0005] In addition, considering the complexity and diversity of traffic data in practical applications, it is extremely laborious to label all the ground truth data. Previous studies have shown that compared with semi-supervised learning with less supervision information, unsupervised learning without prior data knowledge usually cannot obtain effective clustering results. Due to the social aggregation and travel similarity of humans, a small amount of labeled information can improve the accuracy of clustering results and save a large amount of manpower. Summary of the Invention
[0006] To solve the problem that the existing technology does not consider the complex correlation relationships between passenger travels and the difficulty of labeling traffic travel data in practical applications, and thus cannot accurately mine individuals with similar travel behaviors. This method provides an individual travel pattern analysis method based on semi-supervised hypergraph clustering, introducing a hypergraph to represent the high-order association relationships between travel individuals. Taking individuals as vertices, a hypergraph is constructed based on the similarity relationships of individual travel behaviors, so as to mine the internal relationships of travel behaviors. At the same time, a semi-supervised method is used to mine individual travel patterns from a large amount of smart card data to improve the accuracy of clustering results. The overall structure of the method is as shown in the appendix Figure 1 as follows.
[0007] (1) Feature Extraction
[0008] To depict the movement patterns of passengers, 14 quantitative features are extracted from the dimensions of time, space, and attributes.
[0009] Attribute dimension: The number of trips and the total number of trip OD pairs during the research period are denoted as traTimes and ODcnt respectively. The index freTraPct quantifies the proportion of frequent travel days in the total travel days, and the ratio of the most frequently used OD pair among all travel OD pairs of passengers is quantified by the index maxODcntPct. The proportion of the number of individual short trips (travel time not exceeding 15 minutes) in the total number of trips is defined as shrtTimePct.
[0010] Spatial dimension: The index abStaCounts quantifies the corresponding access times at the station level, and the index abStaPct is the proportion of the corresponding access times at the above station level in the total number of travel stations. Similarly, the total number of unique stations or station areas visited by passengers is described as uniqStaCounts and uniqStaLabCts respectively. The related index staODEntropy is used to illustrate the spatial entropy of passengers at the station level.
[0011] Time dimension: Define the indexes peakTmPct, nightpct and nonPkTraPct to measure the proportion of the number of trips of individuals during peak hours (7:00 - 9:59 or 17:00 - 19:59), night trips (20:00 - 23:59) and other periods in the total number of trips respectively. The related index staTimeEntropy is used to illustrate the time entropy of passengers at the station level.
[0012] Finally, 14 quantitative features are extracted to illustrate the human mobility pattern. Therefore, given a set of travel behavior features X = (x 1 , x 2 , …, x N ) ∈ R N×F as the input feature matrix for the clustering task, all elements in the R matrix are rational numbers, where N represents the number of passengers, F represents the number of quantitative features, and x i (i = 1, 2, ..., N) represents the feature sequence of the i-th passenger.
[0013] (2) Hypergraph construction
[0014] Regarding individuals as vertices in the hypergraph and the multi-faceted travel features of individuals as node features, an incidence matrix is used to describe the hypergraph. To learn the complex implicit information of individuals in the time, space and attribute dimensions of travel, the Euclidean distance is used to measure the distance between two nodes, so as to obtain the distance vector { i} i=1,2,…,N . The last vertex is connected to its S - 1 nearest neighbors to form a hyperedge.
[0015] D i = [ED(xi ,x 1 ),ED(x i ,x 2 ),…,ED(x i ,x N )]
[0016] Among them, ED represents the Euclidean distance algorithm.
[0017] (3) Hypergraph-based deep clustering module
[0018] For the input node features and graph structure, this method first uses AE and hypergraph convolution to learn deep feature representations from the perspectives of self-information and structural information respectively, and designs a deep convolutional fusion module to fuse the feature representations learned by AE into the corresponding HGCN layer, and finally achieves the clustering goal.
[0019] 1) Autoencoder feature representation: Use a stacked autoencoder to learn node representation features. Assume that the fully connected layer has L layers, and the input of the l-th layer is represented as H l-1 , then the expression learned in the l-th layer of AE is:
[0020] H l =ReLU(W l H l-1 +b l )
[0021] Among them, ReLU is the activation function of the fully connected layer, and W l ,b l are the weight matrix and bias of the l-th layer in the decoder respectively. X = H 0 represents the original input data, and the output of the last layer reconstructs the original data
[0022] 2) Structural information extraction based on hypergraph convolution: The frequency-domain convolution of the hypergraph is derived from the spectral theory of the hypergraph and the frequency-domain convolution of the graph, and can extract better feature representations from the original data using the hypergraph structure.
[0023] 3) Deep convolutional fusion module: This method designs a feature fusion module based on deep convolution. Concatenate the feature representation of the l-th layer of AE and the output feature of the l-th layer of hypergraph convolution into the data format M ∈ R 1*2*N*F′ , where N is the number of nodes and F′ is the feature dimension of the output of the previous layer. Then, learn useful information from the feature representation output by AE through a deep convolutional network and aggregate it to the feature representation output by hypergraph convolution, and finally output the updated feature representation.
[0024] (4) Dual self-supervised module: The autoencoder module and the hypergraph convolutional module are unified in a framework through the dual self-supervised module to guide the update of the clustering results.
[0025] (4) Semi-supervised learning based on hypergraph
[0026] First, construct a hypergraph H' using the labeled data X', and at the same time construct a similarity hypergraph H using all the data X. During the hypergraph convolution process, first update the features using the prior hyperedges, and then use the similarity hyperedges to guide the update of the graph nodes:
[0027]
[0028] X″ l = HGCN(X' l , H)
[0029] where is the output of the (l - 1)-th layer after feature fusion. X' l represents the features after the update of the labeled hypergraph, and X″ l represents the final node features, corresponding to the output Z of each layer of hypergraph convolution (l) , and HGCN represents the convolution process.
[0030] According to the above description, the following is an implementation process, but the scope protected by this patent is not limited to this implementation process:
[0031] Step 1: Travel feature extraction
[0032] The object of this method is the travel individual. First, extract the travel features of passengers from three dimensions: time dimension, space dimension, and attribute dimension based on the passenger travel chain data to depict the movement patterns of passengers.
[0033] Step 2: Hypergraph construction
[0034] Construct a travel behavior hypergraph according to the travel features of passengers. When constructing the hypergraph, use the k-nearest neighbor method to form hyperedges to construct the hypergraph. The specific process is as follows:
[0035] First, use the Euclidean distance to calculate the distance between each individual and other individuals, and select the k nearest individuals to itself to establish hyperedges, and use the hypergraph adjacency matrix to represent the hyperedges. We obtain the unsupervised hypergraph H.
[0036] In addition, during the construction of the hypergraph, the accuracy of the clustering results is improved through semi-supervised learning. When constructing the hypergraph using feature similarity, the labeled individuals will be divided into more hypergraph edges, guiding the unlabeled nodes to learn information from the optimized labeled node features, and the semi-supervised hypergraph H' can be obtained.
[0037] Step 3: Hypergraph Deep Clustering Module
[0038] To learn the latent features of high-dimensional data capable of performing clustering tasks, the travel feature sequence X of passengers, the unsupervised hypergraph H, and the semi-supervised hypergraph H' are respectively input into the autoencoder AE and the hypergraph convolution HGCN. The specific process of AE is as follows: Input X into the Linear1 layer and learn the embedded feature H through the non-linear activation function Relu 1 The same operation is taken for the rest. Then the overall network structure of the deep network is: Linear1→Relu→Linear2→Relu→Linear3→Relu→Linear4→Relu→Linear5→Relu→Linear6→Relu→Linear7→Relu→Linear8→Relu. The dimension transformation sequence between the fully connected layers is: F→500→500→2000→10→2000→500→500→F, where F is the feature dimension of the travel feature sequence X. From the dimension transformation sequence, the input dimension parameter of the Linear1 layer can be obtained as F, and the output dimension parameter is 500. The input dimension parameter of the Linear2 layer is 500, and the output dimension parameter is 500. The input dimension parameter of the Linear3 layer is 500, and the output dimension parameter is 2000. The input dimension parameter of the Linear4 layer is 2000, and the output dimension parameter is 10. The input dimension parameter of the Linear5 layer is 10, and the output dimension parameter is 2000. The input dimension parameter of the Linear6 layer is 2000, and the output dimension parameter is 500. The input dimension parameter of the Linear7 layer is 500, and the output dimension parameter is 500. The input dimension parameter of the Linear8 layer is 500, and the output dimension parameter is F
[0039] The hypergraph convolution channel is stacked by 5 layers of hypergraph convolution modules (HGCN), and each layer of HGCN includes two layers of hypergraph neural networks (HGNN). The propagation process of the hypergraph neural network is
[0040]
[0041] Z () represents the output of the l-th layer of convolution, Z (-1) is the input of the l-th layer of convolution, W is the weight matrix, H is the hypergraph adjacency matrix, H T represents the transpose matrix of the hypergraph adjacency matrix, D v and D e are respectively the diagonal matrices of the edge degree and vertex degree of the adjacency matrix. The filter matrix Θ is used to extract node features and the node dimension, with size Θ∈R 输入维度*输出维度 Θ (-1) represents the input filter matrix of the l-th layer of convolution
[0042] Input X and H' into the HGNN1 layer, and then learn the embedded features through the non-linear activation function Relu and use Dropout to solve the overfitting problem to obtain X1. Input X1 and H into the HGNN11 layer, and then learn the embedded features through the activation function Relu and use Dropout to solve the overfitting problem to obtain Z () , and the p parameter of Dropout is 0.5. Then perform the same operation. Finally, learn the embedded features through the activation function Relu and use Dropout to solve the overfitting problem to obtain Z () . Its overall network: (HGNN1→Relu→Dropout→HGNN11→Relu→Dropout)→(HGNN2→Relu→Dropout→HG NN22→Relu→Dropout)→(HGNN3→Relu→Dropout→HGNN33→Relu→Dropout)→(HG NN4→Relu→Dropout→HGNN44→Relu→Dropout)→(HGNN5→Relu→Dropout→HGNN55→Relu→Dropout). The change in dimensions is: F→500→500→500→500→2000→2000→10→10→number of clustering categories - number of clustering categories. From the dimension transformation sequence, it can be obtained that the input dimension parameter of HGNN1 is F, and the output dimension parameter is 500. The input dimension parameter of HGNN11 is 500, and the output dimension parameter is 500. The input dimension parameter of HGNN2 is 500, and the output dimension parameter is 500. The input dimension parameter of HGNN22 is 500, and the output dimension parameter is 500. The input dimension parameter of HGNN3 is 500, and the output dimension parameter is 2000. The input dimension parameter of HGNN33 is 2000, and the output dimension parameter is 2000. The input dimension parameter of HGNN4 is 2000, and the output dimension parameter is 10. The input dimension parameter of HGNN44 is 10, and the output dimension parameter is 10. The input dimension parameter of HGNN5 is 10, and the output dimension parameter is the number of clustering categories. The input dimension parameter of HGNN55 is the number of clustering categories, and the output dimension parameter is the number of clustering categories.
[0043] Then comes the feature fusion module. For the first four layers of the autoencoder and the first four groups of hypergraph convolutional layers, the feature representation H of the l-th layer of AE l and the output feature Z of the l-th layer of hypergraph convolution () are concatenated into a data format suitable for a 2D convolutional network Let \(N\) be the number of nodes and \(F'\) be the feature dimension of the output of the previous layer. A 2D depth convolution with a convolution kernel of \(3\times3\), a stride of 1, and the number of groups equal to the number of feature channels is used to fuse the output of the corresponding layer encoder and the hypergraph convolution of the corresponding group, so as to finally output the updated feature representation. Similarly It contains both labeled data and unlabeled data as the input of the \((l + 1)\)-th layer hypergraph convolution, so as to finally output the updated feature representation \(Z\). The overall process is shown as follows:
[0044]
[0045] Among them, represents the output of the \(l\)-th layer after feature fusion, \(DWCon2d\) represents the feature fusion process of depth convolution, and \(M\) is the data after feature concatenation.
[0046] Since the last layer of the hypergraph convolution is a multi-classification layer with a softmax function:
[0047]
[0048] The output \(Z\) is regarded as a probability distribution, and \(z\) ij \(\in Z\) indicates the probability that sample \(i\) belongs to cluster center \(j\).
[0049] Finally, based on the t-distribution, the k-means initialization center of the vectors learned by the encoder in the autoencoder and the vector representation of the last layer of the encoder are used to calculate the possibility that sample \(i\) is assigned to class \(j\), and the clustering result \(T\) is obtained. The Softmax layer of the last layer of the hypergraph convolution counts the scores of the output of the last layer of the hypergraph convolution to obtain the clustering distribution \(Z\). In order to make the data representation closer to the cluster center, each assignment in \(T\) is squared and normalized to obtain the clustering distribution \(P\), and \(P\) is used to double-supervise \(T\) and \(Z\). Therefore, the backpropagation loss of this method includes the objective function between \(P\) and \(T\) The objective function between \(P\) and \(Z\) and the loss function of the autoencoder
[0050]
[0051]
[0052]
[0053] Among them, is the Frobenius norm, \(p\) ij represents the probability that sample \(i\) is assigned to class \(j\) in the target distribution \(P\), and \(t\) ij is the probability that sample \(i\) is assigned to class \(j\) in the distribution \(T\).
[0054] The overall loss function is as follows:
[0055]
[0056] Among them, α and β are hyperparameters. α is the hyperparameter that balances the clustering optimization of the original data and the preservation of local structure, and β is the coefficient that controls the interference of the GCN module on the embedding space.
[0057] Compared with the prior art, it has the following obvious advantages and beneficial effects:
[0058] 1) This method proposes an individual travel pattern analysis method based on semi-supervised hypergraph clustering. This method considers the complex correlation relationships between the travels of pedestrians and improves the accuracy of clustering. 2) A new hypergraph representation of traffic travel data is proposed, establishing high-order correlation relationships between travel individuals, and corresponding hyperedges are constructed. A deep convolutional fusion module is proposed to obtain a feature representation suitable for clustering. 3) A semi-supervised learning strategy based on hypergraph is proposed. Through a small amount of supervised information, unlabeled nodes are guided to learn information from the optimized labeled node features, thereby improving the clustering effect. 4) By applying this method to the actual data of Beijing public transportation smart cards, experiments prove that the present invention can mine passengers with similar travel patterns. BRIEF DESCRIPTION OF THE DRAWINGS
[0059] Figure 1 Overall flowchart of the present invention
[0060] Figure 2 Feature heatmaps of four travel patterns
[0061] Figure 3 Visualization of travel features DETAILED DESCRIPTION OF THE EMBODIMENTS
[0062] First, according to the boarding and alighting records of passengers by swiping cards, the transaction records of buses and subways within 20 working days from August 3 to August 28, 2015 were collected. After unifying the station numbers, removing redundant data, and merging travel records, the final passenger travel chain data was obtained. The travel chain data includes more than 1 million travel records of 13,962 passengers. First, according to the above steps, 1) 14 quantitative features from the attribute, space, and time dimensions were extracted for each passenger from the travel chain data. 2) A travel behavior hypergraph was constructed according to the travel behavior. 3) The above travel feature sequence and hypergraph adjacency matrix were input into the clustering model as shown in Figure 1 to obtain the final clustering result.
[0063] The model training process is as follows:
[0064] 1) Set hyperparameters α = 0.1 and β = 0.01. The dimensions of the autoencoder are set to 500 - 500 - 2000 - 10. Additionally, the dimensions of the HGCN layer are also set to 500 - 500 - 2000 - 10. The learning rate is set to 10 -3 . The "AdamW" optimizer is used for training, and the total number of training epochs is set to 200.
[0065] 2) Four popular metrics are adopted: accuracy (ACC), normalized mutual information (NMI), average Rand index (ARI), and macro F1 - score (F1) to measure the clustering performance. For each metric, the larger the value, the better the clustering result.
[0066] The proposed method is compared with mainstream deep clustering models and traditional clustering models. In the semi - supervised experiment section, 10%, 15%, and 20% of the labeled data are randomly selected from the dataset as prior constraints respectively. The comparison results are as follows in the table:
[0067]
[0068]
[0069] 1) Without any prior information, the proposed method achieves state - of - the - art results on all metrics.
[0070] 2) In the semi - supervised experiment section, the proposed method can achieve better results with very little supervision information.
[0071] Visualization result analysis:
[0072] Through the above experiments, individuals with four types of travel patterns are obtained, as shown in the appendix Figure 2 . The x - axis of the visualization heatmap is the input sequence of individual travel characteristics, and the y - axis is the number of passengers in each category. Figure 3 It shows the proportion of travel characteristics in each dimension. It should be noted that (a), (b), (c), (d) in the appendix Figure 2 correspond to cluster1, cluster2, cluster 3, and cluster 4 in the appendix Figure 3 respectively.
[0073] From the appendix Figure 2 , 3It can be seen that the number of individual travel OD pairs in cluster 1 is the least, indicating that individuals make almost the same trips every day. The freTraPct is the lowest and is 0, and the maxODcntPct is the highest among the four categories, indicating that individuals have the most frequent travel OD pairs. The number of times of all different stations visited by individuals is almost the least, indicating that their travel regularity in space is relatively strong and the visited places are relatively fixed. The spatial entropy value and temporal entropy value of the stations in cluster 1 are both the lowest, indicating that this category has the strongest travel regularity in both space and time, and the access frequency is the highest during peak hours. In addition, there are a small number of trips during the night. It can be seen that cluster 1 tends to repetitively select the same time period and the same location for strongly regular public transportation travel activities, and most passengers mainly travel during the morning and evening peak hours. Therefore, it is speculated that the travel mode of this type is a commuting travel mode, and its travel purpose is mainly to go to and from work, traveling between home and the workplace.
[0074] The number of trips made by individuals in cluster 2 is the least, and the number of travel OD is relatively small. The freTraPct is the lowest and is 0, and the maxODcntPct is only lower than that of cluster 1 among the four categories, indicating that there are frequent travel OD pairs. The number of times of all different stations visited by individuals is relatively small, indicating that there is a certain degree of fixity in the visited places of individuals. The spatial entropy value of the stations in cluster 2 is only higher than that of cluster 1, from which it can be seen that the travel regularity of this category in space is second only to that of cluster 1. At the same time, the peak travel characteristics of cluster 2 are not obvious, and the commuting travel characteristics it reflects are relatively weak. The temporal entropy value of the stations is also only higher than that of cluster 1, indicating that the travel regularity of this category in time is second only to that of cluster 1. Therefore, it is inferred that the travel mode of this type of individuals is a lifestyle travel mode, and most passengers have a low travel frequency and are more likely to carry out daily life shopping activities at relatively fixed locations, such as buying vegetables and purchasing other daily necessities.
[0075] The number of trips and the number of travel OD of individuals in cluster 3 are extremely high and only lower than that of cluster 4, indicating a relatively high travel frequency. The freTraPct is higher than that of clusters 1 and 2, and the maxODcntPct is relatively low, indicating a high travel frequency and no fixed visited places. The travel of cluster 3 is relatively dispersed during the morning and evening peaks, at night and other time periods, and the travel time periods are relatively random; the number of all different stations it visits is not regular, indicating that there is also a certain degree of randomness in the visited places; in addition, the spatial entropy value and temporal entropy value of individuals in cluster 3 are both the highest, indicating that cluster 3 has the worst travel regularity in time and space, and the travel state is relatively random. Therefore, it is inferred that the travel mode of this type of individuals is a random travel mode.
[0076] Individuals in cluster 4 have the highest number of trips and trip OD numbers within 20 working days, with an extremely low maxODcntPct and the highest freTraPct. The above indicates that passengers have the highest travel frequency during the research period and their travel destinations are extremely unstable. The individual shrtTimePct is relatively high, and the abStaPct is also very high, indicating that individuals transfer frequently during the journey. Moreover, the spatial entropy value and station time entropy value of cluster 4 are only lower than those of cluster 3, indicating that the travel status is extremely irregular in terms of time and space. Therefore, it is speculated that the travel mode of such individuals is an abnormal travel mode, such as pickpocketing. Most trips usually occur during the morning and evening rush hours, indicating that they often follow the working groups during the rush hours to commit pickpocketing. In addition, pickpockets need to quickly leave the carriage after committing the crime, so there will be frequent transfers during the journey.
[0077] The above analysis fully demonstrates that this method can identify passengers with similar travel patterns from public transportation data.
Claims
1. An individual travel pattern analysis method based on semi-supervised hypergraph clustering, characterized in that it includes the following steps: Step 1: Travel feature extraction The object of study is the travel individual. First, based on the passenger travel chain data, the passenger travel features are extracted from three dimensions: the time dimension, the space dimension, and the attribute dimension, so as to depict the movement pattern of the passenger; Step 2: Hypergraph construction Construct a travel behavior hypergraph according to the travel features of passengers. When constructing the hypergraph, the k-nearest neighbor method is used to form hyperedges to construct the hypergraph. The specific process is as follows: First, use the Euclidean distance to calculate the distance between each individual and other individuals, and select the k nearest individuals to itself to establish hyperedges, and use the hypergraph adjacency matrix to represent the hyperedges; we obtain the unsupervised hypergraph H; In addition, during the process of constructing the hypergraph, the accuracy of the clustering result is improved through semi-supervised learning; when constructing the hypergraph using feature similarity, the labeled individuals will be divided into more hypergraph edges, guiding the unlabeled nodes to learn information from the features of the labeled nodes that have been optimized, and obtaining the semi-supervised hypergraph H'; Among them, the ratios of the labeled data to the unlabeled data are set to 9:1, 8:2, and 7:3 respectively to verify the effect of the semi-supervised experiment; Step 3: Hypergraph deep clustering module Input the travel feature sequence X of passengers, the unsupervised hypergraph H, and the semi-supervised hypergraph H' into the autoencoder AE and the hypergraph convolution HGCN respectively; the autoencoder AE is stacked by fully connected linear layers Linear; the specific process of AE is as follows: Input X into the Linear1 layer, and learn the embedded feature H through the non-linear activation function Relu 1 , and the same operations are taken for the rest; then the overall network structure of the deep network is: Linear1→Relu→Linear2→Relu→Linear3→Relu→Linear4→Relu→Linear5→Relu→Linear6→Relu→Linear7→Relu→Linear8→Relu; the dimension transformation sequence between the fully connected layers is: F→500→500→2000→10→2000→500→500→F, where F is the feature dimension of the travel feature sequence X. The input dimension parameter of the Linear1 layer is F, and the output dimension parameter is 500; the input dimension parameter of the Linear2 layer is 500, and the output dimension parameter is 500; the input dimension parameter of the Linear3 layer is 500, and the output dimension parameter is 2000; the input dimension parameter of the Linear4 layer is 2000, and the output dimension parameter is 10; the input dimension parameter of the Linear5 layer is 10, and the output dimension parameter is 2000; the input dimension parameter of the Linear6 layer is 2000, and the output dimension parameter is 500; the input dimension parameter of the Linear7 layer is 500, and the output dimension parameter is 500; the input dimension parameter of the Linear8 layer is 500, and the output dimension parameter is F; The hypergraph convolution channel is stacked by 5 layers of hypergraph convolution modules HGCN, and each layer of HGCN includes two layers of hypergraph neural networks HGNN; the propagation process of the hypergraph neural network is: Z (l) represents the output of the l-th convolutional layer, and Z (l-1) is the input of the l-th convolutional layer, W is the weight matrix, H is the hypergraph adjacency matrix, and H T represents the transpose matrix of the hypergraph adjacency matrix, D v and D e are the diagonal matrices of the edge degree and vertex degree of the adjacency matrix respectively, Θ represents the filter matrix, and Θ (l-1) represents the input filter matrix of the l-th convolutional layer; Input X and H′ into the HGNN1 layer, then learn the embedded features through the non-linear activation function Relu and use Dropout to solve the overfitting problem to obtain X1; input X1 and H into the HGNN11 layer, then learn the embedded features through the activation function Relu and use Dropout to solve the overfitting problem to obtain Z (1) , the p parameter of Dropout is 0.5; then the same operations are taken, and finally the embedded features are learned through the activation function Relu and Dropout is used to solve the overfitting problem to obtain Z (l) ; Its overall network: (HGNN1→Relu→Dropout→HGNN11→Relu→Dropout)→(HGNN2→Relu→Dropout→HGNN22→Relu→Dropout)→(HGNN3→Relu→Dropout→HGNN33→Relu→Dropout)→(HGNN4→Relu→Dropout→HGNN44→Relu→Dropout)→(HGNN5→Relu→Dropout→HGNN55→Relu→Dropout); The change in dimensions is: F→500→500→500→500→2000→2000→10→10→number of clustering categories - number of clustering categories. From the dimension transformation sequence, the input dimension parameter of HGNN1 is F and the output dimension parameter is 500, the input dimension parameter of HGNN11 is 500 and the output dimension parameter is 500; the input dimension parameter of HGNN2 is 500 and the output dimension parameter is 500, the input dimension parameter of HGNN22 is 500 and the output dimension parameter is 500; the input dimension parameter of HGNN3 is 500 and the output dimension parameter is 2000, the input dimension parameter of HGNN33 is 2000 and the output dimension parameter is 2000; the input dimension parameter of HGNN4 is 2000 and the output dimension parameter is 10, the input dimension parameter of HGNN44 is 10 and the output dimension parameter is 10; the input dimension parameter of HGNN5 is 10 and the output dimension parameter is the number of clustering categories, the input dimension parameter of HGNN55 is the number of clustering categories and the output dimension parameter is the number of clustering categories; Then there is the feature fusion module. For the first four layers of the autoencoder and the first four groups of hypergraph convolutional layers, the feature representation H of the l-th layer AE l and the output feature Z of the l-th layer hypergraph convolution (l) are concatenated into a data format M ∈ R 1*2*N*F′ , where N is the number of nodes and F′ is the feature dimension output by the previous layer; a 2D depth convolution with a convolution kernel of 3*3, a stride of 1, and the number of groups equal to the number of feature channels is used to fuse the outputs of the encoder of the corresponding layer and the hypergraph convolution of the corresponding group, so as to finally output the updated feature representation Similarly it contains both labeled data and unlabeled data as the input of the (l + 1)-th layer hypergraph convolution, so as to finally output the updated feature representation Z; the overall process is shown in the following formula: Among them, represents the output of the l-th layer after feature fusion. DWCon2d represents the feature fusion process of depth convolution. M is the data after feature concatenation; Since the last layer of hypergraph convolution is a multi-classification layer with a softmax function: The output Z is regarded as a probability distribution, where z ij ∈Z indicates the probability that sample i belongs to cluster center j; Finally, based on the t-distribution, the k-means initialization centers of the vectors learned by the encoder in the autoencoder and the vector representation of the last layer of the encoder are used to calculate the probability that sample i is assigned to class j, and the clustering result T is obtained; the Softmax layer of the last layer of the hypergraph convolution performs a score count on the output of the last layer of the hypergraph convolution to obtain the clustering distribution Z; in order to make the data representation closer to the clustering center, each assignment in T is squared and normalized to obtain the clustering distribution P, and P is used to doubly supervise T and Z; therefore, the backpropagation loss of this method includes the objective function between P and T The objective function between P and Z and the loss function of the autoencoder X is the input data, is the data reconstructed by the autoencoder, is the Frobenius norm; p ij represents the probability that sample i in the target distribution P is assigned to class j, t ij is the probability that sample i in the distribution T is assigned to class j; The overall loss function is: where α and β are hyperparameters. α is the hyperparameter that balances the clustering optimization of the original data and the preservation of local structure, and β is the coefficient that controls the interference of the GCN module on the embedding space. By optimizing the network parameters, the overall loss function is minimized, and at this time, α is 0.1 and β is 0.
01. At the same time, the learning rate is set to 10 -3 ; the "AdamW" optimizer is used for training, and the total number of training batches is set to 200, thereby obtaining the clustering results of travel patterns.