Model for anonymous spatio-temporal trajectory recognition
By constructing a multi-scale trajectory diagram and using the graph attention network and multi-head self-attention mechanism layer to extract the trajectory spatial characteristics, the problem of neglecting spatial information and fixed-length recognition in the existing technology is solved, and a higher trajectory recognition accuracy is achieved. flexibility.
Patent Information
- Application Number
- CN202411433967.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-15
- Publication Date
- 2025-02-21
- Estimated Expiration
- 2044-10-15
AI Technical Summary
Existing anonymous trajectory recognition technology is prone to ignore the spatial information in the trajectory and when identifying it with a fixed trajectory length, it faces the problems of poor recognition performance and lack of flexibility.
By constructing the original trajectory map and multi-scale trajectory map, the trajectory spatial features are extracted using the graph attention network and the multi-head self-attention mechanism layer, and combining global average pooling and aggregation units, multi-scale trajectory spatial features are generated for identification.
It improves the accuracy of trajectory recognition, can effectively utilize and learn trajectory space information, adapt to trajectory data of any length, and improves the recognition ability and flexibility of the model in actual scenarios.
Smart Images

Figure CN119494967A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of neural networks, in particular to the field of anonymous trajectory information recognition, and more particularly to a model for anonymous spatiotemporal trajectory recognition. Background Art
[0002] The most relevant research direction of anonymous trajectory recognition technology is trajectory-user linking, which is a technology that connects trajectories to the anonymous users who generated them. There are currently two main types of solutions for anonymous trajectory recognition technology, including traditional trajectory similarity-based research and deep learning-based models.
[0003] Traditional research based on trajectory similarity is usually based on mathematical statistics methods to find the statistical characteristics of spatial information in trajectories, such as deep Bayesian networks (DBNs), hidden Markov models (HMMs), and longest common subsequences (LCSSs). However, traditional solutions require researchers to use feature engineering based on domain knowledge to differentiate the spatial information in trajectories, and then provide mathematical statistics methods to analyze these data. This type of method often cannot effectively solve the linear indistinguishability and noise problems in trajectory representation encountered in large trajectory datasets, and in terms of accuracy, this is a common difficulty faced by paired point matching similarity calculations.
[0004] Compared with statistical methods and machine learning techniques, deep learning has attracted widespread attention due to its excellent nonlinear modeling capabilities and in-depth analysis of spatial relationships. Deep learning methods for anonymous trajectory recognition technology can be divided into trajectory sequence methods and trajectory graph methods. For example, the trajectory sequence recognition method presented in reference [1] (the method in this reference is referred to as TULER) is inspired by word embedding in natural language processing. This type of method regards the geographic information in the trajectory as words and the entire trajectory as a sentence, thereby embedding the two-dimensional spatial information into a high-dimensional vector, thereby enabling the temporal dependency information in the trajectory sequence to be learned during the deep learning process. Following this work, methods represented by reference [2] (the method in this reference is referred to as TULVAE) are based on generative networks such as variational autoencoders, using variational inference to mine the potential distribution of trajectories to optimize the representation of spatial information in trajectories, and applying semi-supervised learning methods to allow unlabeled trajectory sequences to participate in the training process. Taking reference [3] (the method in this paper is referred to as STULIG) and reference [4] (the method in this paper is referred to as TGAN) as examples, both methods enhance the original training set based on the above. The difference between the two methods is that the former STULIG uses a variational autoencoder with hierarchical latent factors, while the latter TGAN is developed based on a generative adversarial network. However, models that use generative networks lack good parallel computing capabilities and often have high computational complexity. If generative tasks are used to improve the performance of classification tasks, it will also lead to intolerable time costs.
[0005] Since then, trajectory sequence type methods have also adopted attention methods and focused on analyzing spatial information in the order of trajectory sequences. Reference [5] (the method in this reference is referred to as DeepTUL) designed an attention module based on historical trajectories to obtain contextual information for understanding human mobility patterns. Although anonymous trajectory recognition technology that regards trajectories as sequences makes good use of the sequential information involved in trajectories, spatial information is not fully utilized. The recent reference [6] (the method in this reference is referred to as GraphSAGE) learns the neighbor features of each node. However, this method requires a fixed number of spatial information samples to aggregate spatial information, which inevitably leads to the neglect of spatial information or the introduction of redundant information. At the same time, the user trajectory data in actual scenarios is extremely sparse, which will hinder the effective representation of trajectory spatial information. Therefore, existing methods will ignore spatial information to varying degrees.
[0006] Based on the above analysis, although existing deep learning models have achieved satisfactory results, there are still the following problems that limit their performance:
[0007] (1) Ignoring spatial information: The model ignores the unique spatial information in the trajectory. That is, a large number of current works only regard the trajectory as a special time series, and only represent the geographic spatial information in the trajectory as sequential data according to the chronological order. This trajectory representation technology determines the upper limit of the accuracy of anonymous trajectory recognition from the starting point. This obviously violates the understanding of complex human mobility patterns and lags behind the research methods in the field of transportation. Recognition based on spatial information also ignores some spatial information.
[0008] (2) Sampling leads to information loss: Due to the limitations of the model structure, the model needs to sample or pad trajectories based on a fixed length so that the trajectory can be represented in a standardized manner for input into the model. In the implementation scenario, the length of the trajectory is always variable because users can generate short trajectories for short shopping trips or long trajectories for commuting.
[0009] Therefore, in the existing deep learning models for trajectory recognition, on the one hand, it is easy to ignore the spatial information in the trajectory and there is a problem of not being able to understand human movement patterns well. On the other hand, recognition is performed based on a fixed trajectory length, which has problems such as poor recognition performance and lack of flexibility when facing trajectory diversity.
[0010] It should be noted that this background technology is only used to introduce the relevant information of the present invention to help understand the technical solution of the present invention, but it does not mean that the relevant information is necessarily the prior art. If there is no evidence that the relevant information has been disclosed before the application date of the present invention, the relevant information shall not be regarded as the prior art.
[0011] References:
[0012] [1] Gao, Q., Zhou, F., Zhang, K., Trajcevski, G., Luo, X., Zhang, F.: Identifying human mobility via trajectory embeddings. In: IJCAI. vol. 17, pp.1689–1695 (2017).
[0013] [2] Zhou, F., Gao, Q., Trajcevski, G., Zhang, K., Zhong, T., Zhang, F.: Trajectory-user linking via variational autoencoder. In: IJCAI. pp. 3212–3218 (2018).
[0014] [3] Zhou, F., Liu,
[0015] [4] Zhou, F., Yin, R., Trajcevski, G., Zhang, K., Wu, J., Khokhar, AA, 2021c. Improving human mobility identification with trajectoryaugmentation. GeoInformatica 25, 453–483.
[0016] [5] Miao, C., Wang, J., Yu, H., Zhang, W., Qi, Y., 2020. Trajectory-user linking with attentive recurrent network, in: AAMAS '20, Auckland, New Zealand, May 9-13, 2020, International Foundation for Autonomous Agents andMultiagent Systems. pp. 878–886.
[0017] [6] Hamilton, WL, Ying, Z., Leskovec, J., 2017. Inductiverepresentation learning on large graphs, in: NIPS 2017, December 4-9, 2017, Long Beach, CA, USA, pp. 1024–1034. Summary of the invention
[0018] Therefore, the purpose of the present invention is to overcome the defects of the prior art and provide a model for anonymous spatiotemporal trajectory recognition.
[0019] The objective of the present invention is achieved through the following technical solutions:
[0020] According to a first aspect of the present invention, a model for anonymous spatiotemporal trajectory recognition is provided, the model comprising:
[0021] The original trajectory graph construction module is used to construct an original trajectory graph based on the trajectory data generated by the anonymous user within a period of time, which includes multiple nodes for representing multiple check-in records of the trajectory data and multiple edges for representing the relationship between the nodes, and embeds the multiple nodes of the original trajectory graph respectively to obtain the spatial information of the multiple nodes;
[0022] A multi-scale trajectory graph construction module is used to sample nodes from the original trajectory graph according to a preset plurality of sampling rates to construct multiple trajectory graphs of different scales;
[0023] A trajectory spatial information extraction module is used to extract spatial features of each node in each trajectory graph in multiple trajectory graphs based on spatial information of multiple nodes, aggregate the spatial features of each node in each trajectory graph in multiple trajectory graphs, and obtain multi-scale trajectory spatial features;
[0024] The trajectory recognition module is used to recognize the probability value that the trajectory data belongs to each known user according to the multi-scale trajectory space features.
[0025] In some embodiments of the present invention, the trajectory space information extraction module includes:
[0026] Multiple graph attention networks, each of which is used to determine the attention value between each node in each trajectory graph and any node among all other nodes based on the spatial information of the nodes in each trajectory graph, and update the initial features of each node according to the attention value;
[0027] The multi-head self-attention mechanism layer is used to determine the relationship weight between each node and any of all other nodes based on the initial features of each node in each trajectory graph using the multi-head self-attention mechanism, and obtain the spatial features of each node in each trajectory graph according to the relationship weight;
[0028] A global average pooling unit is used to perform global average pooling processing on the spatial features of each node in each of the multiple trajectory graphs to obtain the graph spatial features of each trajectory graph, wherein the dimensions of the graph spatial features corresponding to the multiple trajectory graphs are the same;
[0029] The aggregation unit is used to concatenate the graph space features of multiple trajectory graphs to obtain multi-scale trajectory space features.
[0030] In some embodiments of the present invention, each of the multiple check-in records includes a timestamp and a geographic location. In the original trajectory map construction module, a method for constructing the original trajectory map includes: obtaining multiple grid areas obtained by evenly dividing the surface space according to a preset geographic space size, and taking a grid area where the geographic location of each check-in record in the trajectory data is located as a node for representing the check-in record; according to the order of the timestamps of all the check-in records in the trajectory data, the grid areas corresponding to all the check-in records are connected in sequence to form multiple edges to obtain the original trajectory map.
[0031] In some embodiments of the present invention, the multi-scale trajectory graph construction module includes:
[0032] A node sampling unit, used for sampling nodes from the original trajectory graph multiple times according to a plurality of preset sampling rates and a sampling method preset for each sampling rate, to obtain a plurality of node sets, wherein the plurality of sampling rates include sampling at 100%;
[0033] The edge construction unit is used to determine whether there is an edge relationship between any two nodes in each node set according to a preset edge construction rule, and to establish an edge between the two nodes with an edge relationship, so as to obtain a trajectory map of a scale under each sampling rate.
[0034] In some embodiments of the present invention, in the edge construction unit, the preset edge construction rules include: when any two nodes meet any one of the preset time conditions and the preset spatial distance conditions, it is determined that there is an edge relationship between the two nodes, wherein the preset time condition includes that the timestamps of the check-in records corresponding to the two nodes are adjacent, and the preset spatial distance condition includes that the distance between the geographical locations corresponding to the two nodes is less than a preset threshold.
[0035] In some embodiments of the present invention, the trajectory recognition module includes:
[0036] The trajectory embedding layer is used to process multi-scale trajectory spatial features using a recurrent neural network to obtain fused trajectory spatial features;
[0037] The link unit is used to represent the fused trajectory space features using a multi-layer perceptron to obtain the final trajectory space features, and obtain the probability value of the trajectory data belonging to each known user according to the final trajectory space features through the Softmax function.
[0038] According to a second aspect of the present invention, a training method for a model for anonymous spatiotemporal trajectory recognition is provided, the training method comprising: obtaining a training set, which comprises a plurality of samples, each sample comprising trajectory data generated by a known user within a period of time and a corresponding user label sequence, the user label sequence comprising a plurality of user labels, each user label being used to indicate whether the corresponding trajectory data belongs to the known user; using the training set to train the model described in the first aspect of the present invention, according to the input trajectory data, to obtain a probability value that the trajectory data belongs to each known user, and to update the parameters of the model with the optimization goal of minimizing the difference between the probability value of each known user and the user label sequence to obtain a trained model.
[0039] According to a third aspect of the present invention, there is provided an anonymous spatiotemporal trajectory recognition method, the method comprising: obtaining trajectory data generated by an anonymous user within a period of time; processing the trajectory data using a trained model obtained by the method according to the second aspect of the present invention to obtain probability values of the trajectory data belonging to each known user; and identifying the known users to whom the trajectory data belongs according to the probability values of each known user.
[0040] According to a fourth aspect of the present invention, there is provided an electronic device comprising: one or more processors; and a memory, wherein the memory is used to store executable instructions; the one or more processors are configured to implement the steps of the method described in the second aspect or the third aspect of the present invention by executing the executable instructions.
[0041] Compared with the prior art, the advantages of the present invention are:
[0042] The model of the present invention samples the original trajectory map at multiple preset sampling rates, constructs multiple trajectory map representations for a trajectory data, extracts and identifies spatial features based on multiple trajectory maps, and improves the trajectory recognition accuracy of the model algorithm. In addition, the trajectory data input by the model is composed of multiple check-in records generated by anonymous users over a period of time, and the trajectory length of different users over a period of time is always variable, which satisfies the model's feature learning and recognition of trajectories of any length, avoids the loss of information features, improves the model's trajectory recognition ability in actual scenarios, and improves the flexibility of model application. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] The embodiments of the present invention are further described below with reference to the accompanying drawings, in which:
[0044] Figure 1 A schematic diagram of a model structure for anonymous spatiotemporal trajectory recognition according to an embodiment of the present invention;
[0045] Figure 2 A schematic diagram of the data processing principle of the original trajectory graph construction module according to an embodiment of the present invention;
[0046] Figure 3 A schematic diagram of the principle of the construction process of multiple trajectory graphs of different scales according to an embodiment of the present invention;
[0047] Figure 4 It is a schematic diagram of the overall framework of the model and the complete process principle of processing trajectory data according to an embodiment of the present invention. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below through specific embodiments in conjunction with the accompanying drawings. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0049] As mentioned in the background technology section, existing deep learning models for trajectory recognition, on the one hand, tend to ignore the spatial information in the trajectory and have the problem of not being able to understand human movement patterns well; on the other hand, recognition is performed based on a fixed trajectory length, which results in poor recognition performance and lack of flexibility when faced with trajectory diversity.
[0050] Based on the above problems, the inventors proposed a model for anonymous spatiotemporal trajectory recognition. The model identifies each known user to whom the trajectory belongs based on the trajectory data generated by the anonymous user within a period of time. Among them, the inventors found that the reasons for the first aspect of the problem include: 1. The existing trajectory is regarded as a time series for trajectory recognition; 2. In some methods for trajectory recognition based on spatial information, due to the extreme randomness of the sign-in records submitted by users in actual scenarios, each sign-in record in the acquired trajectory data often has a sparsity problem, which hinders the effective representation of trajectory spatial information. Therefore, the above two points make the existing model often unable to fully utilize and learn spatial information during trajectory recognition, thereby ignoring the problem of spatial information. In view of the analysis of the problem in the first aspect, the model of the present invention samples the original trajectory graph according to a plurality of preset sampling rates, constructs trajectory graphs of multiple scales for a trajectory data, so as to fully display the trajectory spatial information through a plurality of trajectory graphs, and extracts and recognizes spatial features based on a plurality of trajectory graphs, thereby improving the trajectory recognition accuracy of the model. In response to the second problem, the present invention does not standardize the trajectory data of the input model, that is, the trajectory data of the input model is composed of multiple check-in records generated by anonymous users within a period of time, and the trajectory length of different users within a period of time is always variable, so that the model of the present invention can perform feature learning and recognition on trajectories of arbitrary length, avoid the loss of information features, improve the trajectory recognition ability of the model in actual scenarios, and improve the flexibility of model application.
[0051] In general, according to one embodiment of the present invention, see Figure 1, which is a structural diagram of a model for anonymous spatiotemporal trajectory recognition. The model shown in the figure includes four parts: an original trajectory graph construction module, a multi-scale trajectory graph construction module, a trajectory space information extraction module and a trajectory recognition module. Among them, the original trajectory graph construction module is used to construct an original trajectory graph according to the trajectory data generated by an anonymous user within a period of time, which includes multiple nodes for representing multiple check-in records of trajectory data and multiple edges for representing the relationship between nodes, and embeds multiple nodes of the original trajectory graph respectively to obtain spatial information of multiple nodes; the multi-scale trajectory graph construction module is used to sample nodes from the original trajectory graph according to multiple preset sampling rates to construct multiple trajectory graphs of different scales; the trajectory space information extraction module is used to extract the spatial features of each node of each trajectory graph in multiple trajectory graphs based on the spatial information of multiple nodes, aggregate the spatial features of each node of each trajectory graph in multiple trajectory graphs, and obtain multi-scale trajectory space features; the trajectory recognition module is used to identify the probability value of the trajectory data belonging to each known user according to the multi-scale trajectory space features. In order to better understand the present invention, the model structure, model training and application scenarios are described in detail below in combination with specific embodiments.
[0052] 1. Model Structure
[0053] (1) Original trajectory graph construction module
[0054] According to one embodiment of the present invention, before describing the original trajectory map construction module, the trajectory data of the input model is described first. The trajectory data is composed of multiple check-in records generated by an anonymous user within a period of time, and the multiple check-in records are arranged in chronological order. Each check-in record can be automatically generated in the background after the anonymous user opens the mobile phone software, wherein the check-in record at least contains the latitude and longitude and timestamp information of the user. That is, each check-in record includes a timestamp and a corresponding geographical location represented by longitude and latitude.
[0055] According to an embodiment of the present invention, in the original trajectory map construction module, the method of constructing the original trajectory map includes: obtaining multiple grid areas obtained by evenly dividing the surface space according to the preset geographic space size, and taking a grid area where the geographical location of each check-in record in the trajectory data is located as a node for representing the check-in record; according to the order of the timestamps of all the check-in records in the trajectory data, the grid areas corresponding to all the check-in records are connected in sequence to form multiple edges to obtain the original trajectory map. Among them, when all the check-in records of the overall trajectory data are converted into grid areas for node representation, when there are multiple check-in records with geographical locations in the same grid area, the grid area can be used to represent multiple check-in records. The technical solution of this embodiment can at least achieve the following beneficial technical effects: first, the method of using the divided grid areas to replace the check-in records to represent the check-in records merges the check-in records with similar spatial locations, reducing the spatial size of the original spatial information representation; second, the grid area representation is simpler and faster than other representation methods; finally, directly using the grid area as a node for representation facilitates the subsequent modeling and analysis of multiple different scales of trajectory map structures.
[0056] According to an embodiment of the present invention, the division of the surface space includes: dividing the surface space evenly according to 0.01 longitude and 0.01 latitude to obtain multiple grid areas; or dividing the surface space evenly according to 0.02 longitude and 0.02 latitude. It should be understood that the size of the geographic space can be preset according to actual needs, for example, it can also be divided into 0.03 longitude and 0.03 latitude, and the present invention is not limited to this.
[0057] According to one embodiment of the present invention, a pre-trained embedding representation is performed on the grid areas corresponding to all the check-in records of the trajectory data, and the grid areas are converted into vectors. Since the grid area is used as a node, the only attribute of the node is the vector corresponding to the grid area, and the vector is used as the spatial information of the node. When there are multiple check-in records with their geographical locations in the same grid area, the nodes corresponding to the multiple check-in records are the same grid area, that is, the nodes of the multiple check-in records have the same vector. Among them, the embedding representation can be expressed in the form of word embedding, that is, the vector of each grid area is used as a word vector. Schematically, the grid area is embedded using the CBOW model of Word2vec to obtain a low-dimensional dense vector. The technical solution of this embodiment can at least achieve the following beneficial technical effects: Since the above-mentioned division rules will generate tens of thousands of grid areas, the present invention uses word embedding to embed the grid area, transforming it from a unique hot code representation of tens of thousands of dimensions to a low-dimensional and dense vector, and the word embedding further compresses the representation size of the original spatial information of the trajectory to improve the subsequent data processing efficiency.
[0058] Indicatively, see Figure 2 , which is a schematic diagram of the data processing principle of the original trajectory graph construction module. First, obtain the trajectory data generated by an anonymous user. The trajectory data includes multiple check-in records from timestamp 1 to They are: the first sign-in record: (position 1, timestamp 1), the second sign-in record: (position 2, timestamp 2), ..., Check-in records: (Location , timestamp ). In the figure, the first layer is the trajectory data graph, which is a discrete representation of the geographical locations of all check-in records of the trajectory data in the surface space generated according to the trajectory data, and is recorded as ( ),and The latitude and longitude values of each geographical location are recorded in the discrete representation. Taking the trajectory data graph as an example, the trajectory data includes 9 check-in records, and the latitude and longitude values of 9 geographical locations are included in the discrete representation. After that, the surface space is evenly divided, and the grid area where the geographical location of each check-in record in the trajectory data graph is located can be seen. The second layer is the original trajectory graph, which is based on the surface space after the grid area is divided, and the grid area representation result of each check-in record of the trajectory data is expressed in the manner of the above embodiment, which is recorded as In the original trajectory graph, according to the order of the timestamps of all the check-in records in the trajectory data, the grid areas corresponding to all the check-in records are connected in sequence. In addition, since the second check-in record and the third check-in record belong to the same grid area, there is an edge connecting the grid areas corresponding to the second check-in record and the third check-in record, and finally 9 edges are formed. The third layer is the vectorization result of the embedding representation of the original trajectory graph, which is recorded as , since there are 9 check-in records, the vectorized A vector consisting of 9 grid regions.
[0059] (2) Multi-scale trajectory graph construction module
[0060] Since the sign-in record is actively provided by the user's behavior of using the software, the time interval between the sign-in records may be large, which causes the user's sign-in record to be random and sparse, which will hinder the effective representation of trajectory spatial information. Therefore, according to one embodiment of the present invention, a node sampling unit and an edge construction unit are provided in the multi-scale trajectory graph construction module. The node sampling unit is used to sample nodes from the original trajectory graph multiple times according to a preset multiple sampling rate and a sampling method preset for each sampling rate to obtain multiple node sets, wherein the multiple sampling rates include sampling at 100%; the edge construction unit is used to determine whether there is an edge relationship between any two nodes in each node set according to a preset edge construction rule, and establish an edge between the two nodes with an edge relationship to obtain a trajectory graph of a scale under each sampling rate. The technical solution of this embodiment can at least achieve the following beneficial technical effects: the present invention includes complete sampling at 100% during sampling, and retains complete spatial information. In addition, in order to avoid affecting the recognition accuracy of the model due to the sparsity of the sign-in record, it also deletes some nodes in the trajectory according to the sampling rate, and represents the trajectory graph again, which can help the model better learn the characteristics of the trajectory, thereby improving the recognition ability of the actual trajectory.
[0061] According to one embodiment of the present invention, in the node sampling unit, the sampling rate can be set to 50%, 33% or 25%, etc. Schematically, three sampling rates are preset, and they are 100%, 50% and 33% respectively. When the node sampling is performed at 50% and 33%, the interval sampling is performed according to the timestamp of the check-in record. For example, for the 10 nodes from node 1 to node 10, the sampling method preset for 50% includes: according to the timestamp of the check-in record, sampling every two nodes in chronological order, to achieve the interval sampling of multiple nodes corresponding to the overall trajectory, and obtain node 1, node 3, node 5, node 7 and node 9. The sampling method preset for 33% includes: according to the timestamp of the check-in record, sampling every three nodes in chronological order, to achieve the interval sampling of multiple nodes corresponding to the overall trajectory, and obtain node 1, node 4, node 7 and node 10. Among them, since the grid area is used as the node representing the check-in record, the sampling node represents the grid area corresponding to the sampling, and the trajectory map is constructed based on the sampled grid area.
[0062] It should be understood that the sampling rate and sampling method of the above embodiment are only for illustration and can be set according to actual needs. For example, only two sampling rates can be preset, and the two sampling rates are 100% and 50% respectively, or the two sampling rates are 100% and 33% respectively, or four sampling rates can be preset, and they are 100%, 50%, 33% and 25% respectively. Among them, the sampling method can also select the random sampling method, and the present invention does not limit the sampling rate and sampling method.
[0063] According to one embodiment of the present invention, in the edge construction unit, the preset edge construction rules include: when any two nodes meet any of the preset time conditions and the preset spatial distance conditions, it is determined that there is an edge relationship between the two nodes, wherein the preset time condition includes that the timestamps of the check-in records corresponding to the two nodes are adjacent, and the preset spatial distance condition includes that the distance between the geographical locations corresponding to the two nodes is less than the preset threshold. Timestamp adjacency means: in a series of nodes sampled at a sampling rate of 100%, for example, the timestamps corresponding to nodes 1, 2, 3, 4 and 5 are 1:20, 1:30, 1:50, 2 and 2:30 respectively, then the timestamps corresponding to nodes 1 and 2 are adjacent, the timestamps corresponding to nodes 2 and 3 are adjacent, the timestamps corresponding to nodes 3 and 4 are adjacent, and the timestamps corresponding to nodes 4 and 5 are adjacent. In addition, in a series of nodes sampled at a sampling rate of 50%, for example, the timestamps corresponding to nodes 1, 3, and 5 are 1:20, 1:50, and 2:30, respectively, then the timestamps corresponding to nodes 1 and 3 are adjacent, and the timestamps corresponding to nodes 3 and 5 are adjacent. The technical solution of this embodiment can at least achieve the following beneficial technical effects: by considering the time sequence in the trajectory and the proximity in the geographic space, the grid areas (also called nodes) representing the check-in records are connected into a construction of check-in oriented graphs (abbreviated as COGs, also called trajectory graphs) structure, so that these constructed check-in oriented graphs can represent the geographic space information of the trajectory.
[0064] According to one embodiment of the present invention, in an edge construction unit, for a trajectory data, first, it is determined whether the preset time condition is met: in terms of time, if the timestamps of two check-in records are adjacent, then the grid areas (also called nodes) corresponding to the geographical locations of the two check-in records have an edge relationship. Therefore, according to the order of the timestamps of all the check-in records in the trajectory data, the grid areas corresponding to all the check-in records are connected in sequence to form multiple edges. Secondly, it is determined whether the preset spatial distance condition is met: in terms of space, if the geographical locations of the grid areas corresponding to the geographical locations of the two check-in records are adjacent, then the two grid areas have an edge relationship. Among them, the determination of whether the geographical locations are adjacent can be performed by calculating the Euclidean distance between the two grid areas, and then manually presetting a threshold to determine whether the calculated Euclidean distance is less than the preset threshold. If the Euclidean distance is less than the preset threshold, the two grid areas have an edge relationship. Therefore, the two grid areas with adjacent geographical locations are connected to obtain one or more edges. Finally, all the edges constructed in terms of time and space are combined to obtain a general non-Euclidean graph structure. Among them, the determination method of the preset spatial distance condition is as follows:
[0065] ,
[0066] in, Represents two grid areas (i.e., grid areas and grid area ), there is an edge relationship between them. 0 means grid area and grid area There is no boundary relationship between Represents the grid area The longitude of the location, Represents the grid area The longitude of the location, Represents the grid area The latitude, Represents the grid area The latitude, Indicates the preset threshold.
[0067] Indicatively, see Figure 3 , which is a schematic diagram of the construction process of multiple trajectory maps of different scales. Figure 2 Taking the original trajectory graph obtained in as an example, in order to enable the model to process trajectory data of different lengths, a multi-scale sampling method is used (i.e., multiple sampling rates are preset to sample the nodes in the original trajectory graph). In the figure, three sampling rates are preset, which are 100%, 50% and 33% respectively, and when sampling nodes at 50% and 33%, interval sampling is performed according to the timestamp of the sign-in record. After sampling, the above-mentioned edge construction rule is used to establish edges for each node in each sampled node set, so as to obtain three trajectory graphs of different scales. Among them, among the three trajectory graphs obtained from top to bottom on the right, the first trajectory graph is obtained by constructing edges after sampling at 100%. Compared with the original trajectory graph, due to the consideration of time and space, the number of edges constructed by only considering time compared to the original trajectory graph, the constructed trajectory graph has 6 more edges; the second trajectory graph is obtained by sampling and constructing edges at intervals of 50%; the third trajectory graph is obtained by sampling and constructing edges at intervals of 33%; thus, multiple check-in-oriented graphs of different scales are obtained.
[0068] (3) Trajectory spatial information extraction module
[0069] According to one embodiment of the present invention, the trajectory spatial information extraction module includes multiple graph attention networks, multi-head self-attention mechanism layers, global average pooling units and aggregation units. Among them, each graph attention network (GraphAttention Networks, referred to as GAT) is used to determine the attention value between each node in each trajectory graph and any node among all other nodes based on the spatial information of the nodes in each trajectory graph, and update the initial features of each node according to the attention value; the multi-head self-attention mechanism layer is used to use the multi-head self-attention mechanism to determine the relationship weight between each node and any node among all other nodes based on the initial features of each node in each trajectory graph, and obtain the spatial features of each node in each trajectory graph according to the relationship weight; the global average pooling unit is used to perform global average pooling processing on the spatial features of each node in each trajectory graph in multiple trajectory graphs to obtain the graph spatial features of each trajectory graph, wherein the dimensions of the graph spatial features corresponding to the multiple trajectory graphs are the same; the aggregation unit is used to splice the graph spatial features of multiple trajectory graphs to obtain multi-scale trajectory spatial features.
[0070] The technical solution of the above embodiment can at least achieve the following beneficial technical effects: First, for each scale of trajectory graph constructed based on the original trajectory graph, since no fixed number of nodes are sampled, the amount of spatial information contained in the trajectory graph is arbitrary. In order to process any amount of spatial information and keep the time complexity as low as possible, the present invention uses a graph attention network to embed the spatial information of each node into a low-dimensional vector space, so as to facilitate effective application in real scenarios. Secondly, the graph attention network is used to update the spatial feature representation of the node by calculating the attention value between the nodes, so that the spatial relationship between different check-in records can be captured. Further, a multi-head self-attention mechanism is used to better characterize the spatial relationship between the check-in records, effectively analyze the spatial information and spatial interaction between the nodes, and the mechanism can process multiple attention heads in parallel, improve the model's ability to characterize the spatial relationship of the nodes and improve the running speed. Then, the global average pooling method is used to aggregate the node embedding vectors of different numbers into a unified dimension. The present invention uses global average pooling to realize information processing of trajectory data of any length and improve the accuracy of anonymous trajectory recognition. Finally, the graph spatial features of all trajectory graphs after multi-scale sampling are aggregated to better capture the multi-scale information of the trajectory.
[0071] According to one embodiment of the present invention, in the multi-head self-attention mechanism layer, the spatial features of each node of each trajectory graph are obtained according to the relationship weight as follows:
[0072] ,
[0073] in, Indicates The spatial characteristics of the nodes, represents the number of network layers of the multi-head self-attention mechanism layer, The network layer number representing the multi-head self-attention mechanism layer, represents the activation function sigmoid, Indicates The node belongs to Trajectory diagram The nodes in Indicates the input A trajectory diagram, Represents the first layer of the multi-head self-attention mechanism The network layer determines the The node and The relationship weight of the edge between nodes, , , express function, express function, represents the attention score, Indicates The initial features of the nodes With learnable parameters Multiply, Indicates The initial features of the nodes With learnable parameters Multiply, Represents the first layer of the multi-head self-attention mechanism The network layer determines the The node and The edge relationship of the nodes, Represents the first layer of the multi-head self-attention mechanism The learnable parameters of the network layers, Indicates Nodes belong to the trajectory graph Nodes in .
[0074] According to one embodiment of the present invention, the global average pooling processing method is as follows:
[0075] ,
[0076] in, Indicates Trajectory diagram The graph space features of Indicates taking the average, Indicates Trajectory diagram The spatial characteristics of the first node of Indicates Trajectory diagram The spatial characteristics of the second node of Indicates the input Trajectory diagram The spatial characteristics of the last node.
[0077] According to one embodiment of the present invention, the aggregation unit is processed as follows:
[0078] ,
[0079] in, Represents multi-scale trajectory spatial features, Represents the graph space features of splicing all trajectory graphs, Represents the total number of trajectory maps constructed after multi-scale sampling.
[0080] (4) Trajectory recognition module
[0081] According to one embodiment of the present invention, the trajectory recognition module includes a trajectory embedding layer and a link unit. The trajectory embedding layer is used to process multi-scale trajectory space features using a recurrent neural network to obtain fused trajectory space features. The link unit includes a multi-layer perceptron and a Softmax function. The multi-layer perceptron is used to represent the fused trajectory space features to obtain the final trajectory space features, and obtain the probability value of the trajectory data belonging to each known user according to the final trajectory space features through the Softmax function.
[0082] According to one embodiment of the present invention, the recurrent neural network preferably uses a bidirectional long short-term memory network (BiLSTM), and may also use a bidirectional recurrent neural network (Bi-RNN) and other recurrent neural networks, which are not limited by the present invention. Among them, a bidirectional long short-term memory network (BiLSTM) is used to fuse trajectory representations of different scales. BiLSTM processes multi-scale trajectory spatial features by combining forward LSTM and backward LSTM, captures the relationship between trajectory representations at different scales, and obtains the fused trajectory spatial features as follows:
[0083] ,
[0084] in, represents the fused trajectory spatial features, Indicates splicing, Represents the multi-scale trajectory space features of the input forward LSTM, Represents the multi-scale trajectory spatial features input to the backward LSTM.
[0085] According to an embodiment of the present invention, a multilayer perceptron is used in the link unit to connect the trajectory data of the anonymous user to each known user, and the fused trajectory space feature is represented to obtain the final trajectory space feature, and the final trajectory space feature is used as the input of the Softmax function. The probability value of the trajectory data belonging to each known user is calculated by the Softmax function. The method of calculating the probability value is as follows:
[0086] ,
[0087] in, represents the probability value that the trajectory data belongs to the i-th known user, represents the user label of the i-th user, represents the learnable parameters, It represents the fused trajectory space features obtained after the trajectory data of the i-th anonymous user is processed by the model. represents the learnable bias of the multilayer perceptron, Indicates the ID of the anonymous user. Represents the total number of anonymous users. Represents the fused trajectory space features obtained after the trajectory data of the kth anonymous user is processed by the model.
[0088] In general, the model structure and its overall data processing process are as follows Figure 4 As shown, Figure 4 The following is a schematic diagram of the overall framework of the model and the complete process of processing trajectory data. The overall data processing process is as follows: Steps 1-4:
[0089] 1. Use the original trajectory graph construction module to construct the original trajectory graph based on the input trajectory data composed of multiple check-in records, and embed each node in the original trajectory graph to obtain the spatial information of each node. The processing process of the original trajectory graph construction module and Figure 2 The processing examples shown are the same and will not be repeated here.
[0090] 2. The multi-scale trajectory map construction module constructs multiple trajectory maps of different scales based on the original trajectory map. Figure 3 The process examples shown are the same and will not be repeated here. The trajectory diagrams of the three different scales are recorded as , , , , , Refers to the number of nodes (number of grid areas) of the first, second and third trajectory graphs respectively, The dimension that represents the spatial information of each node (grid area).
[0091] 3. The trajectory spatial information extraction module extracts multi-scale trajectory spatial features based on trajectory graphs and node spatial information of multiple scales. Figure 3 Taking the three trajectory graphs of different scales as examples, a graph attention network is constructed for each trajectory graph, then three graph attention networks are required and are recorded as GAT1, GAT2 and GAT3 respectively. Each graph attention network is used to embed each node in each trajectory graph to obtain the initial representation of each node in each trajectory graph, and the multi-head self-attention mechanism layer is used to further process the initial representation of each node in each trajectory graph to obtain the spatial features of each node. In this way, the overall output of the spatial features of all nodes in each of the three trajectory graphs is recorded as , , , It represents the dimension of the spatial features of each node (grid area) of the trajectory graph after being processed by the graph attention network and the multi-head self-attention mechanism layer. The spatial features of each node of each trajectory graph are processed by the global average pooling unit to obtain the graph spatial features of the trajectory graph, where the dimensions of the graph spatial features corresponding to multiple trajectory graphs are the same; the aggregation unit splices the graph spatial features of multiple trajectory graphs to obtain multi-scale trajectory spatial features.
[0092] 4. The trajectory recognition module obtains the probability value of the trajectory data belonging to each known user based on the multi-scale trajectory spatial features. The trajectory embedding layer of the trajectory recognition module uses a recurrent neural network to process the multi-scale trajectory spatial features to obtain fused trajectory spatial features; it uses a multi-layer perceptron to represent the fused trajectory spatial features to obtain the final trajectory spatial features, and uses the Softmax function to obtain the probability value of the trajectory data belonging to each known user based on the final trajectory spatial features.
[0093] 2. Model Training
[0094] According to one embodiment of the present invention, a training method for a model for anonymous spatiotemporal trajectory recognition is provided, the method comprising steps S1 and S2:
[0095] Step S1: Obtain a training set, which includes multiple samples, each sample includes trajectory data generated by a known user within a period of time and a corresponding user label sequence, the user label sequence includes multiple user labels, and each user label is used to indicate whether the corresponding trajectory data belongs to the known user.
[0096] According to one embodiment of the present invention, the trajectory data of the sample can be obtained from the background database of the existing social network service software, such as the background database corresponding to any one of the social network service software such as Gowalla and Brightkite, to obtain the check-in records and trajectory data of multiple known users. Among them, a known user contains one or more trajectory data. The sample in the training set includes a trajectory data and a corresponding user label sequence, each user label is represented by label 1 or label 0, label 1 indicates that the corresponding trajectory data belongs to the known user, and label 0 indicates that the corresponding trajectory data does not belong to the known user. Among them, there are as many known users in the entire data set as there are user label sequences of as many dimensions as one trajectory data. For example, there are 5 known users in the current data set, namely known user 1, known user 2, known user 3, known user 4 and known user 5. If the trajectory data belongs to known user 2, the user label sequence corresponding to one trajectory data is [0,1,0,0,0].
[0097] Step S2: Using the training set to train the model described in the above embodiment, according to the input trajectory data, the probability value of the trajectory data belonging to each known user is obtained, and the parameters of the model are updated with the optimization goal of minimizing the difference between the probability value of each known user and the user label sequence to obtain a trained model.
[0098] According to an embodiment of the present invention, the training task of the model is a TUL (Trajectory-User Linking) task, which is a task of associating trajectory data of anonymous users with known users. Therefore, the loss function is calculated using a multi-classification cross entropy loss function.
[0099] It should be noted that high time complexity is an important issue that limits the training time of anonymous trajectory recognition technology and its application and promotion. Traditional anonymous trajectory recognition technology often analyzes the geographic information in the trajectory one by one in chronological order, and thus lacks a certain parallel computing capability. In addition, some technologies use generative networks to assist in recognition work and learn trajectory features by reconstructing trajectories. This undoubtedly introduces additional computing requirements, resulting in high computing complexity and further increase in trajectory recognition time. Relying on the model structure of the present invention, the above embodiment can at least achieve the following beneficial effects: during the model training process, since the model structure realizes a faster and more accurate anonymous trajectory recognition technology, the training time is only half of that of the traditional anonymous trajectory recognition technology, and the training time is one-tenth of the related technology that introduces the generative network, so that the technology can be deployed to end-to-end application scenarios faster. In particular, the multiple graph attention networks and multi-head self-attention mechanism layers set in the model alleviate the problem of large data computing requirements by performing parallel computing on multiple trajectory graphs and compressing them into low-dimensional space.
[0100] 3. Application Scenarios
[0101] According to one embodiment of the present invention, there is provided an anonymous spatiotemporal trajectory recognition method, the method comprising: obtaining trajectory data generated by an anonymous user within a period of time; processing the trajectory data using a trained model obtained by the training method of the above embodiment to obtain probability values of the trajectory data belonging to each known user; and identifying the known user to which the trajectory data belongs according to the probability values of each known user.
[0102] According to an embodiment of the present invention, by determining whether the probability value of each known user exceeds a preset probability value, the known users exceeding the preset probability value are selected as the recognition results. Alternatively, the probability values of each known user are sorted, and the known users corresponding to the first or more probability values in the sorting are selected as the recognition results.
[0103] To verify the beneficial effects of the present invention, the inventors conducted the following experiments:
[0104] First, for the model of the present invention (TULMGAT for short), three sampling rates are preset, which are 100%, 50% and 33% respectively. When the node sampling is performed at 50% and 33%, the interval sampling is performed according to the timestamp of the check-in record. Based on the above three sampling rates, the following four variants of the model of the present invention are obtained:
[0105] ①TULMGAT-O (also known as TUL-GAT): Only 100% sampling is performed to obtain a scaled trajectory map.
[0106] ②TULMGAT-T: Only 100% and 50% sampling is performed to obtain trajectory maps of two different scales.
[0107] ③TULMGAT-TH: Sampling is performed at 100%, 50% and 33% to obtain trajectory maps of three different scales, and the output of the global average pooling layer is concatenated for subsequent recognition.
[0108] ④TULMGAT-Add: Sampling is performed at 100%, 50% and 33% to obtain trajectory maps of three different scales, and the output of the global average pooling layer is directly accumulated for subsequent recognition without further fusion using the recurrent neural network.
[0109] Secondly, the trajectory dataset is obtained from two social networking service software, Gowalla and Brightkite. The training set and test set are generated according to the datasets of the two software. Using the datasets obtained under each software, the four variants of the model of the present invention are compared with the existing methods. Among them, the existing methods include TULER-LSTM method, TULER-GRU method, BiTULER method, TULVAE method, TULAR method, STULIG method, GNNTUL method, and TULRN method. Among them, TULER-LSTM, TULER-GRU and BiTULER are variant methods of TULER. TULER is the first model to solve the TUL task, which uses various RNNs to learn the mobility of users and realize classification tasks.
[0110] Finally, the experimental comparison results are reflected by five evaluation indicators: ACC@1, ACC@5, Macro-P, Macro-R and Macro-F1. Among them, ACC@K represents the classification accuracy of user links (the proportion of correctly predicted users in the first K prediction results), that is, ACC@1 represents the proportion of correctly predicted users in the first prediction result, ACC@5 represents the proportion of correctly predicted users in the first 5 prediction results, Macro-P, Macro-R and Macro-F1 represent the macro-average accuracy, macro-average recall and macro-average F1 value of all user categories respectively.
[0111] Using the data set obtained under the software Gowalla, four variants of the model of the present invention are compared with the existing methods. The experimental comparison results are shown in Table 1 below:
[0112] Table 1
[0113]
[0114] In Table 1 above, |U|=149 and |U|=247 respectively indicate that the number of known users is 149 and 247, and in Table 1, the best results are marked in bold, especially in the two variants of TULMGAT-T and TULMGAT-TH, which shows that the present invention has good anonymous trajectory recognition capability and has higher accuracy than the existing methods.
[0115] Using the data set obtained under the software Brightkite, four variants of the model of the present invention were compared with the existing methods. The comparison results are shown in Table 2 below:
[0116] Table 2
[0117]
[0118] |U|=141 and |U|=223 in Table 2 above respectively indicate that the number of known users is 141 and 223, and in Table 1, the best results are marked in bold, especially in the three variants of TULMGAT-O, TULMGAT-T and TULMGAT-TH, which shows that the present invention has good anonymous trajectory recognition ability, has lower training time and higher efficiency than existing work.
[0119] Using two data sets obtained under the software Gowalla and the software Brightkite, four variants of the model of the present invention and the model of the existing method are trained, and the time required to complete the training is recorded and compared in hours. The training time comparison results are shown in Table 3 below:
[0120] Table 3
[0121]
[0122] According to Table 3 above, the training time required for the model of the present invention is the shortest. Therefore, the model of the present invention not only achieves a higher trajectory recognition accuracy, but also achieves a higher training efficiency.
[0123] The existing methods are as follows:
[0124] TULER: refers to the above-mentioned reference [1], where TULER-LSTM method, TULER-GRU method and BiTULER method are variants of TULER;
[0125] TULVAE method: the same as the above-mentioned reference [2];
[0126] TULAR method: T. Sun, Y. Xu, F. Wang, L. Wu, T. Qian, Z. Shao, Trajectory-user link with attention recurrent networks, in: ICPR, 2020, pp.4589–4596.
[0127] STULIG method: the same as the above reference [3];
[0128] GNNTUL method: F. Zhou, S. Chen, J. Wu, C. Cao, S. Zhang, Trajectory-userlinking via graph neural network, in: ICC 2021, 2021, pp. 1–6.
[0129] TULRN method: Y. Sang, Z. Xie, W. Chen, L. Zhao, Tulrn: Trajectory userlinking on road networks, World Wide Web (2022) 1–17.
[0130] It should be noted that although the above describes the various steps in a specific order, it does not mean that the various steps must be executed in the above specific order. In fact, some of these steps can be executed concurrently or even in a different order as long as the required functions can be achieved.
[0131] The present invention may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present invention.
[0132] A computer-readable storage medium may be a tangible device that holds and stores instructions used by an instruction execution device. Computer-readable storage media may include, for example, but are not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. More specific examples (non-exhaustive list) of computer-readable storage media include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a protruding structure in a groove on which instructions are stored, and any suitable combination thereof.
[0133] The embodiments of the present invention have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A model for anonymous spatiotemporal trajectory recognition, characterized in that: The model includes: The original trajectory graph construction module is used to construct an original trajectory graph based on the trajectory data generated by the anonymous user within a period of time, which includes multiple nodes for representing multiple check-in records of the trajectory data and multiple edges for representing the relationship between the nodes, and embeds the multiple nodes of the original trajectory graph respectively to obtain the spatial information of the multiple nodes; A multi-scale trajectory graph construction module is used to sample nodes from the original trajectory graph according to a preset plurality of sampling rates to construct multiple trajectory graphs of different scales; A trajectory spatial information extraction module is used to extract spatial features of each node in each trajectory graph in multiple trajectory graphs based on spatial information of multiple nodes, aggregate the spatial features of each node in each trajectory graph in multiple trajectory graphs, and obtain multi-scale trajectory spatial features; The trajectory recognition module is used to recognize the probability value that the trajectory data belongs to each known user according to the multi-scale trajectory space features.
2. The model according to claim 1, characterized in that The trajectory space information extraction module comprises: Multiple graph attention networks, each of which is used to determine the attention value between each node in each trajectory graph and any node among all other nodes based on the spatial information of the nodes in each trajectory graph, and update the initial features of each node according to the attention value; The multi-head self-attention mechanism layer is used to determine the relationship weight between each node and any of all other nodes based on the initial features of each node in each trajectory graph using the multi-head self-attention mechanism, and obtain the spatial features of each node in each trajectory graph according to the relationship weight; A global average pooling unit is used to perform global average pooling processing on the spatial features of each node in each of the multiple trajectory graphs to obtain the graph spatial features of each trajectory graph, wherein the dimensions of the graph spatial features corresponding to the multiple trajectory graphs are the same; The aggregation unit is used to concatenate the graph space features of multiple trajectory graphs to obtain multi-scale trajectory space features.
3. The model according to claim 1, characterized in that Each of the plurality of sign-in records includes a timestamp and a geographic location. In the original trajectory map construction module, the method of constructing the original trajectory map includes: Acquire multiple grid areas obtained by evenly dividing the surface space according to a preset geographic space size, and use a grid area where the geographic location of each check-in record in the trajectory data is located as a node for representing the check-in record; According to the order of the timestamps of all the check-in records in the trajectory data, the grid areas corresponding to all the check-in records are connected in sequence to form multiple edges to obtain the original trajectory graph.
4. The model according to claim 3, characterized in that The multi-scale trajectory graph construction module includes: A node sampling unit, used for sampling nodes from the original trajectory graph multiple times according to a plurality of preset sampling rates and a sampling method preset for each sampling rate, to obtain a plurality of node sets, wherein the plurality of sampling rates include sampling at 100%; The edge construction unit is used to determine whether there is an edge relationship between any two nodes in each node set according to a preset edge construction rule, and to establish an edge between the two nodes with an edge relationship, so as to obtain a trajectory map of a scale under each sampling rate.
5. The model according to claim 4, characterized in that In the edge construction unit, the preset edge construction rules include: When any two nodes meet any of the preset time conditions and the preset spatial distance conditions, it is determined that there is an edge relationship between the two nodes, wherein the preset time condition includes that the timestamps of the check-in records corresponding to the two nodes are adjacent, and the preset spatial distance condition includes that the distance between the geographical locations corresponding to the two nodes is less than a preset threshold.
6. The model according to claim 1, characterized in that The trajectory recognition module comprises: The trajectory embedding layer is used to process multi-scale trajectory spatial features using a recurrent neural network to obtain fused trajectory spatial features; The link unit is used to represent the fused trajectory space features using a multi-layer perceptron to obtain the final trajectory space features, and obtain the probability value of the trajectory data belonging to each known user according to the final trajectory space features through the Softmax function.
7. A training method for a model for anonymous spatiotemporal trajectory recognition, characterized in that: Training methods include: Obtain a training set, which includes multiple samples, each sample includes trajectory data generated by a known user within a period of time and a corresponding user label sequence, the user label sequence includes multiple user labels, and each user label is used to indicate whether the corresponding trajectory data belongs to the known user; The model described in any one of claims 1 to 6 is trained using a training set to obtain the probability value of the trajectory data belonging to each known user based on the input trajectory data, and the parameters of the model are updated with the optimization goal of minimizing the difference between the probability value of each known user and the user label sequence to obtain a trained model.
8. An anonymous spatiotemporal trajectory recognition method, characterized in that: Methods include: Obtain the trajectory data generated by anonymous users over a period of time; Using the trained model obtained by the method of claim 7, the trajectory data is processed to obtain a probability value that the trajectory data belongs to each known user; The known users to which the trajectory data belongs are identified according to the probability values of the known users.
9. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and the computer program can be executed by a processor to implement the steps of the method according to claim 7 or 8.
10. An electronic device, characterized in that: include: one or more processors; as well as A memory, wherein the memory is used to store executable instructions; The one or more processors are configured to implement the steps of the method of claim 7 or 8 by executing the executable instructions.
Citation Information
Patent Citations
POI (Point of Interest) recommendation method fusing crowd movement track and time-space-category
CN118171000A
Pedestrian trajectory prediction method and system based on multi-interaction spatiotemporal graph network
US11495055B1
Destination recommendation method and system based on multi-source heterogeneous information network
WO2023178608A1