Location prediction method and system based on spatiotemporal behavior pattern

By building a recurrent neural network and attention mechanism, integrating long-term regularity and short-term randomness, the problem of low position prediction accuracy in the existing technology is solved, and more accurate user position prediction is achieved.

CN114692022BActive Publication Date: 2024-12-20WUHAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210346045.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-31
Publication Date
2024-12-20
Estimated Expiration
2042-03-31

AI Technical Summary

Technical Problem

When existing position prediction algorithms process multivariate heterogeneous spatiotemporal trajectory data, it is difficult to effectively capture the long-term regularity and short-term randomness of user behavior, resulting in low prediction accuracy.

Method used

Using a method based on spatiotemporal behavior pattern, by constructing multiple recurrent neural networks, the user's historical trajectory data is obtained, the time, date, place and text vector sequence information is extracted, combined with attention mechanism, and long-term regularity and short-term randomness are integrated to generate Final position prediction results.

Benefits of technology

Improve the accuracy of position prediction, capture the user's time and space behavior patterns more accurately, and enhance the reliability of prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114692022B_ABST
    Figure CN114692022B_ABST
Patent Text Reader

Abstract

The present invention discloses a location prediction method and system based on spatiotemporal behavior patterns. The method comprises the following steps: step S1, obtaining an embedded expression vector according to the user's historical trajectory data; step S2, constructing multiple recurrent neural networks; step S3, obtaining the splicing results of some recurrent neural networks, inputting the splicing results to the fully connected layer, and obtaining the long-term regularity of the user in multiple feature spaces; step S4, obtaining the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, inputting the output result to the fully connected layer, and obtaining the short-term randomness of the user's spatiotemporal behavior pattern; step S5, fusing the obtained long-term regularity and short-term randomness to obtain the final location prediction result. The location prediction method based on spatiotemporal behavior patterns provided in the present application improves the accuracy of location prediction by considering long-term regularity and short-term randomness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of information prediction, and in particular to a location prediction method and system based on spatiotemporal behavior patterns. Background Art

[0002] Location prediction is a technology that predicts the possible location of a user in the future based on the user's historical trajectory data over a period of time. It is usually used in smart cities, point of interest recommendations, crime prediction and other fields. Therefore, location prediction is a research hotspot in current big data analysis and multimedia applications.

[0003] In recent years, there has been a lot of research on location prediction. These research works can be divided into three categories: matrix decomposition-based methods, Markov chain-based methods, and deep network-based methods. However, people's spatiotemporal trajectory information is multi-dimensional, such as time, space, and social space. The records left by users on social networks also contain a lot of semantic texts, from which multi-dimensional features can be extracted. In addition, people's behavior patterns are not immutable. They not only have regularities, but also random disturbances. Therefore, location prediction is still a difficult task. Summary of the invention

[0004] The purpose of the present invention is to overcome the problems of data multivariate heterogeneity and behavior randomness in existing similar algorithms, and to provide a location prediction method and system based on spatiotemporal behavior patterns.

[0005] In a first aspect, the present application provides a location prediction method based on a spatiotemporal behavior pattern, comprising the following steps:

[0006] Step S1, obtaining an embedded expression vector according to the user's historical trajectory data;

[0007] Step S2, constructing multiple recurrent neural networks;

[0008] Step S3, obtaining the splicing results of some recurrent neural networks, inputting the splicing results into the fully connected layer, and obtaining the long-term regularity of the user in multiple feature spaces;

[0009] Step S4: Obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern;

[0010] Step S5: The long-term regularity and short-term randomness obtained by fusion processing are obtained to obtain the final position prediction result.

[0011] According to the first aspect, in a first possible implementation manner of the first aspect, step S1 includes the following steps:

[0012] Step S11, obtaining the user's historical trajectory data;

[0013] Step S12, obtaining sequence information extracted from the historical trajectory data, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence;

[0014] Step S13: input sequence information into the embedding layer to obtain an embedded expression vector.

[0015] According to the first aspect, in a second possible implementation manner of the first aspect, step S2 specifically includes the following steps:

[0016] Step S20: construct multiple recurrent neural networks, wherein the network length of some recurrent neural networks is M, the length of the remaining recurrent neural networks is N, and M and N are not equal.

[0017] According to the second possible implementation manner of the first aspect, in a third possible implementation manner of the first aspect, after step S20, the following steps are further included:

[0018] The loss function model is constructed in combination with the labels, and the optimized recurrent neural network is obtained through optimization training using the ADAM optimization algorithm.

[0019] According to the second possible implementation manner of the first aspect, in a fourth possible implementation manner of the first aspect, step S3 specifically includes the following steps:

[0020] Step S31, obtaining the concatenation result of the output results of the last time of the partial recurrent neural network;

[0021] Step S32: Input the concatenated result to the fully connected layer to obtain the long-term regularity of the user in multiple feature spaces.

[0022] According to a fourth possible implementation manner of the first aspect, in a fifth possible implementation manner of the first aspect, step S4 includes the following steps:

[0023] Step S41, adding an attention mechanism to adjust the hidden layer state values ​​of the remaining neural networks;

[0024] Step S42, obtaining an output result according to the adjusted hidden layer state value;

[0025] Step S43: Input and output the results to the fully connected layer to obtain the short-term randomness of the user's spatiotemporal behavior pattern.

[0026] According to the fifth possible implementation manner of the first aspect, in a sixth possible implementation manner of the first aspect, step S5 specifically includes the following steps:

[0027] According to the following formula, the long-term regularity and short-term randomness obtained by fusion processing are obtained to obtain the final position prediction result:

[0028] P f =γ*P long +(1-γ)*P short ,

[0029] Among them, P long For long-term regularity, P short Short-term randomness.

[0030] In a second aspect, the present application provides a location prediction system based on spatiotemporal behavior patterns, comprising:

[0031] The embedded expression vector acquisition module acquires the embedded expression vector based on the user's historical trajectory data;

[0032] Neural network building blocks for building multiple recurrent neural networks;

[0033] A long-term regularity acquisition module, which is in communication with the embedding expression vector acquisition module and the neural network construction module, is used to obtain the splicing results of the partial recurrent neural network, input the splicing results to the fully connected layer, and obtain the long-term regularity of the user in multiple feature spaces;

[0034] A short-term randomness acquisition module is connected to the embedding expression vector acquisition module and the neural network construction module, and is used to obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern;

[0035] The final position result acquisition module is in communication connection with the long-term regularity acquisition module and the short-term randomness acquisition module, and is used for fusing the acquired long-term regularity and short-term randomness to obtain the final position prediction result.

[0036] According to the second aspect, in a first possible implementation manner of the second aspect, the embedded expression vector acquisition module includes:

[0037] A historical trajectory data acquisition unit, used to acquire the historical trajectory data of the user;

[0038] a sequence information acquisition unit, which is in communication with the historical trajectory data acquisition unit and is used to acquire sequence information extracted from the historical trajectory data, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence;

[0039] The embedded expression vector acquisition unit is connected to the sequence information acquisition unit for inputting sequence information into the embedding layer to acquire the embedded expression vector.

[0040] According to the second aspect, in a second possible implementation manner of the second aspect, the long-term regularity acquisition module includes:

[0041] A splicing result acquisition unit, used to obtain the splicing result of the output result of the last time of the partial recurrent neural network;

[0042] The long-term regularity acquisition unit is connected to the splicing result acquisition unit for inputting the splicing result into the fully connected layer to acquire the long-term regularity of the user in multiple feature spaces.

[0043] Compared with the prior art, the advantages of the present invention are as follows:

[0044] The location prediction method based on spatiotemporal behavior patterns provided in the present application improves the accuracy of location prediction by considering long-term regularity and short-term randomness. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] Figure 1 is a method flow chart of a location prediction method based on a spatiotemporal behavior pattern according to an embodiment of the present invention;

[0046] Figure 2 Another method flow chart of the location prediction method based on spatiotemporal behavior pattern according to an embodiment of the present invention;

[0047] Figure 3 A functional module block diagram of a location prediction system based on spatiotemporal behavior patterns according to an embodiment of the present invention;

[0048] Figure 4 This is another functional module block diagram of the location prediction system based on spatiotemporal behavior patterns according to an embodiment of the present invention. DETAILED DESCRIPTION

[0049] Reference will now be made in detail to specific embodiments of the present invention, examples of which are illustrated in the accompanying drawings. Although the present invention will be described in conjunction with specific embodiments, it will be understood that it is not intended to limit the present invention to the embodiments described. On the contrary, it is intended to cover changes, modifications and equivalents included in the spirit and scope of the present invention as defined by the appended claims. It should be noted that the method steps described herein can all be implemented by any functional block or functional arrangement, and any functional block or functional arrangement can be implemented as a physical entity or a logical entity, or a combination of the two.

[0050] In order to enable those skilled in the art to better understand the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0051] Note: The example to be introduced below is only a specific example, and is not intended to limit the embodiments of the present invention to the following specific steps, values, conditions, data, sequences, etc. Those skilled in the art can apply the concept of the present invention to construct more embodiments not mentioned in this specification by reading this specification.

[0052] Location prediction is a current research hotspot in big data analysis and multimedia applications. Existing location prediction research is mainly divided into three categories: matrix decomposition-based methods, Markov chain-based methods, and deep network-based methods. However, existing similar algorithms have problems such as multivariate heterogeneity of data and randomness of behavior, resulting in low location prediction accuracy.

[0053] See also Figure 1 As shown, an embodiment of the present invention provides a location prediction method and system based on spatiotemporal behavior patterns, comprising the following steps:

[0054] Step S1, obtaining an embedded expression vector according to the user's historical trajectory data;

[0055] Step S2, constructing multiple recurrent neural networks;

[0056] Step S3, obtaining the splicing results of some recurrent neural networks, inputting the splicing results into the fully connected layer, and obtaining the long-term regularity of the user in multiple feature spaces;

[0057] Step S4: Obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern;

[0058] Step S5: The long-term regularity and short-term randomness obtained by fusion processing are obtained to obtain the final position prediction result.

[0059] The location prediction method based on spatiotemporal behavior patterns provided in the present application improves the accuracy of location prediction by considering long-term regularity and short-term randomness.

[0060] In one embodiment, please refer to Figure 2 , the step S1 comprises the following steps:

[0061] Step S11, obtaining the user's historical trajectory data, i.e., the user's spatiotemporal behavior pattern data set, including the user's ID, time information, date information, location ID, location latitude and longitude coordinates, activity type, and other information;

[0062] The user's spatiotemporal behavior pattern dataset in step 1 includes: user ID, time information, date information, location ID, longitude and latitude coordinates of the location, activity type and other information.

[0063] Get the user's historical trajectory data. For each user u, its historical trajectory data is expressed as Among them, represents a single record at time t, The corresponding elements represent user information, latitude and longitude coordinates of the location, date, hour, activity type, location and timestamp.

[0064] Step S12: Acquire sequence information extracted from the historical trajectory data to obtain trajectory information of the user's multi-feature space, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence.

[0065] The historical trajectory data is extracted from time t1 to t n The time series, date series, location series, activity type series and text vector series of moments are represented as g, d, l, c, x respectively. Specifically, each moment is composed of different features to form a text vector x = {d, g, c, l, t tr ,geo tr},t tr ,geo tr Respectively represent the time interval and geographical distance between two check-in points, from time t1 to time t n The sequence of moments is denoted by x.

[0066] Step S13: input sequence information into the embedding layer to obtain an embedded expression vector.

[0067] In a more specific embodiment, the inputs g, d, l, c, x, and the corresponding outputs are represented by e g , e d , e l , e c , e x .

[0068] In one embodiment, the step S2 specifically includes the following steps:

[0069] Step S20: construct multiple recurrent neural networks, wherein the network length of some recurrent neural networks is M, the length of the remaining recurrent neural networks is N, and M and N are not equal.

[0070] In a more specific embodiment, five recurrent neural networks are constructed and are labeled as network1, network2, network3, network4, and network5, respectively. The length of network5 is M, and network1, network2, network3, and network4 are four identical networks with a length of N.

[0071] In one embodiment, after step S20, the following steps are further included:

[0072] The loss function model is constructed in combination with the labels, and the optimized recurrent neural network is obtained through optimization training using the ADAM optimization algorithm.

[0073] According to the second possible implementation manner of the first aspect, in a fourth possible implementation manner of the first aspect, step S3 specifically includes the following steps:

[0074] Step S31, obtaining the concatenation result of the output results of the last time of the partial recurrent neural network;

[0075] Step S32: Input the concatenated result to the fully connected layer to obtain the long-term regularity of the user in multiple feature spaces.

[0076] In one embodiment, before step S31, the following steps are further specifically included:

[0077] Embed the expression vector to embed the expression e g , e d , e l , e c , e x Input to network1, network2, network3, network4, network5 respectively. Among them, the hidden layer iteration process of network1 is:

[0078]

[0079]

[0080]

[0081]

[0082]

[0083] Among them, at t i At time, input is The hidden layer state is The output is r and z represent the reset gate and update gate of the recurrent neural network GRU at t i The state value at the moment, σ represents the sigmoid function, and tanh represents the activation function; W r , W z ,W,W ois the parameter to be learned; we take the hidden layer at the last moment as the final output of the network module. The network structures of network1, network2, network3, and network4 are the same, the difference lies in the difference in input and output, and the output results are represented as P G , P D , P L , P C .

[0084] In a more specific embodiment, the step S31 is specifically implemented as follows:

[0085] The last moment t of network1, network2, network3, and network4 N The output results are spliced ​​into a whole, which is the user's long-term behavior pattern P long =[P G ,P D ,P L ,P C ].

[0086] In one embodiment, the step S4 comprises the following steps:

[0087] Step S41, adding an attention mechanism to adjust the hidden layer state values ​​of the remaining neural networks;

[0088] Step S42, obtaining an output result according to the adjusted hidden layer state value;

[0089] Step S43: Input the output result of step S42 to the fully connected layer to obtain the short-term randomness of the user's spatiotemporal behavior pattern.

[0090] As mentioned above, the fully connected layer is a fully connected layer. In the neural network, the core operation of the fully connected layer is the matrix-vector product, that is, y=Wx. The function of the fully connected layer is mainly to linearly transform the feature space into another feature space, which is equivalent to the function of the classifier.

[0091] In one embodiment, step S4 is specifically implemented as follows:

[0092] The hidden layer of network5 is added with attention mechanism. The hidden layer iteration process of network5 is the same as that of network1. The difference is that the length of the network module is different. In addition, the attention mechanism is added to network5 to adjust the state value of the hidden layer of network5 recurrent neural network. The specific formula for calculating the weight of the attention mechanism is:

[0093]

[0094]

[0095] x(t i )'=α(t i ) T ·x(t i );

[0096]

[0097] It should be noted that is through Calculated. Among them, tanh represents the activation function, W short , W s1 , W s2 , W s3 , b s1 , b s2 is the parameter that needs to be trained, d x represents the dimension of the text vector x, Represents the weight corresponding to the hidden layer state after the attention mechanism is added. For example, the dimension of data feature x is d x , then x(t i )'=α(t i ) T ·x(t i ) means that each dimension of feature x is assigned a weight Thus, a new eigenvector is obtained, where T is the time or period. i )' represents the updated text vector after adding the attention mechanism, Indicates t i The final output is the last time t after the attention mechanism is introduced. M The output is denoted as P short .

[0098] In one embodiment, the step S5 specifically includes the following steps:

[0099] The long-term regularity and short-term randomness obtained above are input into the fully connected layer and fused for location prediction to obtain the final location prediction result:

[0100] P f =γ*P long +(1-γ)*P short ,

[0101] Among them, P long For long-term regularity, P short is short-term randomness, γ is the value that needs to be trained, 0<γ<1.

[0102] Based on the same invention concept, please refer to Figure 3 , the present application provides a location prediction system based on spatiotemporal behavior patterns, comprising:

[0103] The embedded expression vector acquisition module 100 acquires the embedded expression vector according to the user's historical trajectory data;

[0104] A neural network construction module 200 is used to construct a plurality of recurrent neural networks;

[0105] The long-term regularity acquisition module 300 is in communication with the embedding expression vector acquisition module 100 and the neural network construction module 200, and is used to obtain the splicing results of the partial recurrent neural network, input the splicing results to the fully connected layer, and obtain the long-term regularity of the user in multiple feature spaces;

[0106] The short-term randomness acquisition module 400 is in communication with the embedding expression vector acquisition module 100 and the neural network construction module 200, and is used to obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern;

[0107] The final position result acquisition module is in communication with the long-term regularity acquisition module 300 and the short-term randomness acquisition module 400, and is used for fusing the acquired long-term regularity and short-term randomness to obtain the final position prediction result.

[0108] In one embodiment, please refer to Figure 4 , the embedding expression vector acquisition module 100 comprises:

[0109] A historical trajectory data acquisition unit 110 is used to acquire the historical trajectory data of the user;

[0110] A sequence information acquisition unit 120 is connected to the historical trajectory data acquisition unit 110 for acquiring sequence information extracted from the historical trajectory data, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence;

[0111] The embedded expression vector acquisition unit 130 is connected to the sequence information acquisition unit 120 for inputting sequence information into the embedding layer to acquire the embedded expression vector.

[0112] In one embodiment, the long-term regularity acquisition module includes:

[0113] A splicing result acquisition unit, used to obtain the splicing result of the output result of the last time of the partial recurrent neural network;

[0114] The long-term regularity acquisition unit is connected to the splicing result acquisition unit for inputting the splicing result into the fully connected layer to acquire the long-term regularity of the user in multiple feature spaces.

[0115] Based on the same inventive concept, an embodiment of the present application further provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, all or part of the method steps of the above method are implemented.

[0116] The present invention implements all or part of the process in the above method, and can also be completed by instructing related hardware through a computer program. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of each method embodiment can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying computer program code, recording medium, USB flash drive, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium does not include electric carrier signals and telecommunication signals.

[0117] Based on the same inventive concept, an embodiment of the present application also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program running on the processor, and when the processor executes the computer program, all or part of the method steps in the above method are implemented.

[0118] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of a computer device, and uses various interfaces and lines to connect various parts of the entire computer device.

[0119] The memory can be used to store computer programs and / or modules. The processor realizes various functions of the computer device by running or executing the computer programs and / or modules stored in the memory, and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system and at least one application required for a function (such as a sound playback function, an image playback function, etc.); the data storage area can store data created according to the use of the mobile phone (such as audio data, video data, etc.). In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (SmartMedia Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0120] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, servers or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) containing computer-usable program codes.

[0121] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), servers, and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as a combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0122] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0123] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0124] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A location prediction method based on spatiotemporal behavior patterns, characterized in that: The following steps are involved: Step S1, obtaining an embedded expression vector according to the user's historical trajectory data; Step S2, constructing multiple recurrent neural networks; Step S3, obtaining the splicing results of some recurrent neural networks, inputting the splicing results into the fully connected layer, and obtaining the long-term regularity of the user in multiple feature spaces; Step S4: Obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern; Step S5, fusing the obtained long-term regularity and short-term randomness to obtain the final position prediction result; The step S2 specifically comprises the following steps: Step S20, constructing multiple recurrent neural networks, wherein the network length of some recurrent neural networks is M, the length of the remaining recurrent neural networks is N, and M and N are not equal; The step S3 specifically comprises the following steps: Step S31, obtaining the concatenation result of the output results of the last time of the partial recurrent neural network; Step S32: input the concatenated result to the fully connected layer to obtain the long-term regularity of the user in multiple feature spaces; The step S4 comprises the following steps: Step S41, adding an attention mechanism to adjust the hidden layer state values ​​of the remaining neural networks; Step S42, obtaining an output result according to the adjusted hidden layer state value; Step S43: Input and output the results to the fully connected layer to obtain the short-term randomness of the user's spatiotemporal behavior pattern.

2. The location prediction method based on spatiotemporal behavior pattern according to claim 1, characterized in that: The step S1 comprises the following steps: Step S11, obtaining the user's historical trajectory data; Step S12, obtaining sequence information extracted from the historical trajectory data, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence; Step S13: input sequence information into the embedding layer to obtain an embedded expression vector.

3. The location prediction method based on spatiotemporal behavior pattern according to claim 1, characterized in that: After step S20, the following steps are also included: The loss function model is constructed in combination with the labels, and the optimized recurrent neural network is obtained through optimization training using the ADAM optimization algorithm.

4. The location prediction method based on spatiotemporal behavior pattern according to claim 1, characterized in that: The step S5 specifically comprises the following steps: According to the following formula, the long-term regularity and short-term randomness obtained by fusion processing are obtained to obtain the final position prediction result: , in, For long-term regularity, Short-term randomness.

5. A location prediction system based on spatiotemporal behavior patterns, characterized in that: include: The embedded expression vector acquisition module acquires the embedded expression vector based on the user's historical trajectory data; Neural network building blocks for building multiple recurrent neural networks; A long-term regularity acquisition module, which is in communication with the embedding expression vector acquisition module and the neural network construction module, is used to obtain the splicing results of the partial recurrent neural network, input the splicing results to the fully connected layer, and obtain the long-term regularity of the user in multiple feature spaces; A short-term randomness acquisition module is connected to the embedding expression vector acquisition module and the neural network construction module, and is used to obtain the hidden layer state of the remaining recurrent neural network plus the output result of the attention mechanism, input the output result to the fully connected layer, and obtain the short-term randomness of the user's spatiotemporal behavior pattern; A final position result acquisition module, which is in communication connection with the long-term regularity acquisition module and the short-term randomness acquisition module, and is used for fusing the acquired long-term regularity and short-term randomness to obtain a final position prediction result; The neural network construction module is further used to construct multiple recurrent neural networks, wherein the network length of some recurrent neural networks is M, the length of the remaining recurrent neural networks is N, and M and N are not equal; The long-term regularity acquisition module includes: A splicing result acquisition unit, used to obtain the splicing result of the output result of the last time of the partial recurrent neural network; A long-term regularity acquisition unit, which is in communication connection with the splicing result acquisition unit and is used to input the splicing result into the fully connected layer to acquire the long-term regularity of the user in multiple feature spaces; The short-term randomness acquisition module is also used to add an attention mechanism to adjust the hidden layer state value of the remaining neural network; obtain the output result according to the adjusted hidden layer state value; input the output result to the fully connected layer to obtain the short-term randomness of the user's spatiotemporal behavior pattern.

6. The location prediction system based on spatiotemporal behavior patterns as claimed in claim 5, characterized in that: The embedding expression vector acquisition module includes: A historical trajectory data acquisition unit, used to acquire the historical trajectory data of the user; a sequence information acquisition unit, which is in communication with the historical trajectory data acquisition unit and is used to acquire sequence information extracted from the historical trajectory data, wherein the sequence information includes a time sequence, a date sequence, a location sequence, an activity type sequence, and a text vector sequence; The embedded expression vector acquisition unit is connected to the sequence information acquisition unit for inputting sequence information into the embedding layer to acquire the embedded expression vector.