Trajectory generation method and system based on joint measurement of pedestrian visual spatio-temporal information
By adopting a trajectory generation method based on the joint measurement of pedestrian visual spatio-temporal information in the video surveillance system, the problem of difficulty in quickly and accurately generating the trajectory sequence of target pedestrians within a short period of time in the video surveillance system is solved, and efficient and accurate trajectory generation is achieved, which provides the basis for wisdom. Campus and intelligent person tracing provide solutions.
Patent Information
- Application Number
- CN202411326065.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-23
- Publication Date
- 2025-01-24
AI Technical Summary
In the prior art, it is difficult to quickly and accurately generate the trajectory sequence of the target pedestrian in a short period of time in a video surveillance system, especially when the environment is complex and the pedestrian postures are diverse, there are a large number of errors.
A trajectory generation method based on joint measurement of pedestrian visual spatio-temporal information is adopted. By constructing a video surveillance base library, visual features are extracted, visual feature similarity is calculated, historical trajectory features are input into the multi-modal recurrent neural network model, and the next-hop spatio-temporal transition is output. probability, and update the trajectory sequence via logistic smoothing parameters.
In real time monitoring systems, the trajectory sequence of target pedestrians is quickly and accurately generated in the short -term period of target pedestrians, improving the accuracy and efficiency of trajectory generation, and providing efficient solutions for applications such as smart campuses and intelligent tracing.
Smart Images

Figure CN119360053A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing technology, and in particular to a trajectory generation method and system based on joint measurement of pedestrian visual spatiotemporal information. Background Art
[0002] Human mobility is usually described by trajectories, which are defined as a time-ordered sequence of spatiotemporal points, each of which consists of a timestamp or time segment and a pair of spatial coordinates (such as latitude and longitude). Typical trajectory data sources currently include travel data, check-in data, taxi logs, GPS-enabled tracking devices or mobile phone records, and video surveillance data. Video surveillance systems naturally have rich visual feature information and spatiotemporal information. How to effectively process thousands of camera images, quickly and accurately generate a trajectory sequence of a target pedestrian in a short period of time, and shorten the trajectory tracking time is crucial for applications such as urban planning, traffic management, and smart campuses.
[0003] At present, some methods use traditional multi-target cross-camera technology for trajectory matching, target tracking technology within a single lens, and traditional pedestrian re-identification methods between multiple lenses. However, in actual monitoring scenarios, due to the complex and diverse environment and the different postures of the subjects, the accuracy is far less than that on public datasets. Some other methods use the attention mechanism to mix historical and current trajectories for next-hop prediction. Although this spatiotemporal constraint eliminates a large number of irrelevant pedestrian images in a large-scale database, even if an accurate distribution map of transfer relations between cameras is constructed, the uncertainty of walking trajectory and speed, as well as the accumulation of historical trajectory generation errors, leads to a large number of errors. Summary of the invention
[0004] Based on the technical problems existing in the background technology, the present invention proposes a trajectory generation method and system based on the joint measurement of pedestrian visual spatiotemporal information, which realizes the trajectory sequence generation of a single pedestrian trip.
[0005] The trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information proposed in the present invention comprises the following steps:
[0006] Step 1: Build a video surveillance database and extract visual features from each data in the video surveillance database;
[0007] Step 2: Given the seed information and high-dimensional visual features of the target pedestrian u, calculate the similarity between the high-dimensional visual features and the visual features in the base database, and add the visual features that exceed the set similarity to the initial trajectory sequence corresponding to the target pedestrian to create a historical trajectory sequence;
[0008] Step 3: Cut and encode the historical trajectory sequence according to the time window of the set time to obtain multiple historical trajectory features, input the historical trajectory features into the multimodal recursive neural network model to output the next hop spatiotemporal transfer probability of each camera, and add it to the historical trajectory sequence;
[0009] Step 4: Calculate the similarity probability matrix between all high-dimensional visual features in the historical trajectory sequence and all pedestrian visual features in the base database within a set time, calculate the logical smoothing parameter based on each similarity in the similarity probability matrix and the next-hop spatiotemporal transition probability, select the trajectory information corresponding to the maximum value of the logical smoothing parameter as the trajectory sequence point at the next moment, and update the historical trajectory sequence;
[0010] Step 5: Determine whether the time interval between the newly added trajectory sequence point and the previous trajectory sequence point is greater than the preset time threshold. If it is greater than the time threshold, return to step 3. If it is less than or equal to the time threshold, the trajectory update is completed and the updated historical trajectory sequence is returned.
[0011] Furthermore, in step 1, in a set park, a video surveillance database is constructed based on a single travel trajectory of pedestrians, specifically:
[0012] Each record of a pedestrian's single trip trajectory is represented by a pedestrian tuple with a timestamp, camera number, and pedestrian position number, and the pedestrian tuple is added to the frequency monitoring base database in real time;
[0013] The image corresponding to the pedestrian's single travel trajectory at each moment is decoded and the image is passed through the target detection model and the pedestrian re-identification model in turn to extract visual features.
[0014] Furthermore, the person re-identification model is trained as follows:
[0015] The residual network ResNet50 is used as the backbone network to output REID features and ID prediction values. The REID features are used to calculate the triplet loss, and the ID prediction value is used to calculate the cross entropy loss. The triplet loss and the cross entropy loss are added to get the center loss.
[0016] The pedestrian re-identification model is trained using the center loss, batch normalization is performed using BNNeck, and the model parameters of the pedestrian re-identification model are updated using the Adam optimizer;
[0017] The triplet loss L tri (x,y,z)=max(d(x,y)-d(x,z)+margin,0), where (x,y,z) are the anchor point, positive sample, and negative sample, respectively. Margin is the interval parameter of the triplet loss function. d(x,y) represents the distance between the anchor point and the positive sample, and d(x,z) represents the distance between the anchor point and the negative sample.
[0018] Furthermore, in step 3, the historical trajectory features are input into the multimodal recurrent neural network model to output the next-hop spatiotemporal transition probability of each camera, specifically:
[0019] Input historical trajectory features into the multimodal recurrent neural network model to output the current trajectory;
[0020] The historical trajectory features and the current trajectory are combined and input into the multimodal recurrent neural network model again to output the next-hop spatiotemporal transition probability of the camera.
[0021] Further, in step 4, a logical smoothing parameter is calculated based on each similarity in the similarity probability matrix and the next hop spatiotemporal transition probability. The logical smoothing parameter Eqn joint The specific calculation is as follows:
[0022]
[0023] Among them, M ij is the similarity probability matrix between the i-th high-dimensional visual feature in the historical trajectory sequence and the i-th pedestrian visual feature in the base library within a set time, V is the P-dimensional vector of the next-hop spatiotemporal transfer probability, λ0, λ1 are smoothing factors, and γ0, γ1 are shrinkage factors.
[0024] The trajectory generation system based on the joint measurement of pedestrian visual spatiotemporal information is characterized by comprising a base library construction module, a historical trajectory sequence creation module, a next hop generation module, a trajectory update module and a loop module;
[0025] The base database construction module is used to construct a video surveillance base database and extract visual features from each data in the video surveillance base database;
[0026] The historical trajectory sequence creation module is used to calculate the similarity between the visual high-dimensional features and the visual features in the base library when the seed information and visual high-dimensional features of the target pedestrian u are given, and add the visual features exceeding the set similarity to the initial trajectory sequence corresponding to the target pedestrian to create a historical trajectory sequence;
[0027] The next-hop generation module is used to cut and encode the historical trajectory sequence in a time window of a set time to obtain multiple historical trajectory features, and input the historical trajectory features into the multimodal recurrent neural network model to output the next-hop spatiotemporal transfer probability of each camera and add it to the historical trajectory sequence;
[0028] The trajectory update module is used to calculate the similarity probability matrix between all high-dimensional visual features in the historical trajectory sequence and all pedestrian visual features in the base database within a set time, calculate the logical smoothing parameter based on each similarity in the similarity probability matrix and the next hop spatiotemporal transition probability, select the trajectory information corresponding to the maximum value of the logical smoothing parameter as the trajectory sequence point at the next moment, and update the historical trajectory sequence;
[0029] The loop module is used to determine whether the time interval between the newly added trajectory sequence point and the previous trajectory sequence point is greater than the preset time threshold. If it is greater than the time threshold, it returns to the next hop generation module. If it is less than or equal to the time threshold, the trajectory update is completed and the updated historical trajectory sequence is returned.
[0030] The advantages of the trajectory generation method and system based on the joint measurement of pedestrian visual spatiotemporal information provided by the present invention are: solving the problem of quickly and accurately generating a trajectory sequence of a target pedestrian in a short period of time in a large-scale feature library generated by a real-time video monitoring system; combining visual features and historical trajectory features through a joint measurement method, continuously iteratively generating each trajectory point, and finally realizing the generation of a trajectory sequence for a single pedestrian trip; providing an efficient trajectory generation solution for smart campuses, intelligent search for people, etc. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 It is a structural schematic diagram of the present invention. DETAILED DESCRIPTION
[0032] Below, the technical solution of the present invention is described in detail through specific embodiments. Many specific details are set forth in the following description to facilitate a full understanding of the present invention. However, the present invention can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific implementation disclosed below.
[0033] like Figure 1 As shown, the trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information proposed in the present invention includes the following steps:
[0034] Step 1: Build a video surveillance database and extract visual features from each data in the video surveillance database;
[0035] Human trajectory flow data is crucial for various applications, and the spread of COVID-19 (new coronavirus infection) has further highlighted its usefulness in population epidemic analysis and simulation. Data sets commonly used for trajectory generation can be divided into GPS tracking data, social media data, mobile phone data, smart card data, surveys, and simulation data. Video surveillance data, as a natural data source that simultaneously possesses location positioning (camera GPS), time information, and visual features (pedestrians in the picture), is rarely used for single-trip. This embodiment studies the generation of single-trip trajectories of pedestrians in a video surveillance system, and represents each record in the real-time added video surveillance base library with a pedestrian tuple of timestamp, camera number, and pedestrian position number. For example, (1715238438000,2341,1) represents the pedestrian with position number 1 in the picture captured by the camera numbered 2341 at 15:07:18 on 2024-05-09, where the position number is input from the camera picture into the target detection model, and then is sequentially calculated according to the minimum boundary value (x min ,y min ) and the maximum boundary value (x max ,y max ) are obtained after ascending sorting. While decoding the rtsp stream in real time, the pictures corresponding to the pedestrian's single travel trajectory at each moment are decoded and the pictures are sequentially passed through the target detection model and the pedestrian re-identification model to extract visual features, so as to improve the retrieval speed when searching for people offline.
[0036] Among them, the training process of the pedestrian re-identification model is as follows:
[0037] Construct a pedestrian training dataset: resize each image to 256×128 pixels, fill 10 pixels with zero values, and then randomly crop it into a 256×128 rectangular image. For each rectangular image, flip it horizontally with a probability of 0.5. Each image is decoded into a 32-bit floating-point original pixel value in [0,1], and then the RGB channels are normalized to construct a pedestrian training dataset.
[0038] The pedestrian re-identification model uses the residual network ResNet50 as the backbone network, and the pedestrian training dataset is used as the input of the pedestrian re-identification model to output REID features and ID prediction values;
[0039] The REID feature is used to calculate the triplet loss, and the ID prediction value is used to calculate the cross entropy loss. The triplet loss and the cross entropy loss are added to get the center loss;
[0040] The pedestrian re-identification model is trained using the center loss, BNNeck batch normalization is used, and the Adam optimizer is used to update the model parameters of the pedestrian re-identification model. The initial learning rate is set to 0.00035 and reduced by 0.1 at the 40th epoch and the 70th epoch, respectively, for a total of 120 epochs.
[0041] Among them, the triple loss L tri (x,y,z)=max(d(x,y)-d(x,z)+margin,0), where (x,y,z) are the anchor point, positive sample, and negative sample, respectively. Margin is the interval parameter of the triplet loss function. d(x,y) represents the distance between the anchor point and the positive sample, and d(x,z) represents the distance between the anchor point and the negative sample.
[0042] In this embodiment, the pedestrian re-identification model is obtained by training by fusing the public dataset market1501 and some business data, and the feature dimension of the model output is 1536.
[0043] Step 2: Given the seed information and high-dimensional visual features of the target pedestrian u, calculate the similarity between the high-dimensional visual features and the visual features in the base database, and add the visual features that exceed the set similarity to the initial trajectory sequence corresponding to the target pedestrian to create a historical trajectory sequence;
[0044] In the process of creating a historical trajectory sequence, first determine whether the historical trajectory sequence is empty based on the seed information. If it is not empty, the subsequent trajectory preprocessing and time window cutting processing will be performed on the historical trajectory sequence that is not empty. If it is empty, the similarity calculation is performed with the visual features in the base library to create a historical trajectory sequence. The following is the process of creating a historical trajectory sequence when it is empty:
[0045] Given the seed information q0 = (moment0, cid0) of the target pedestrian u and the visual high-dimensional features, moment0 is the initial timestamp, cid0 is the initial camera number, and the initial trajectory sequence S u =q0, before inputting the multimodal recurrent neural network model, it is necessary to create historical features by similarity matching of visual features in the base library, and add k high-similarity features as trajectory points to the initial trajectory sequence S u =q0, thus the historical trajectory sequence.
[0046] Step 3: Cut and encode the historical trajectory sequence according to the time window of the set time to obtain multiple historical trajectory features, input the historical trajectory features into the multimodal recursive neural network model to output the next hop spatiotemporal transfer probability of each camera, and add it to the historical trajectory sequence;
[0047] In this embodiment, the time window can be set to 10 minutes. The time window is used to cut the historical trajectory sequence, and the adjacent recording cameras are deduplicated. A pedestrian may contain multiple records. i , extract and encode the event time and location of each historical trajectory feature (the cut trajectory). One trajectory can generate multiple data. The second point is predicted based on the first point, and the third point is predicted based on the first two points. The data format is historical position, historical time, current position, current time, next position, next time.
[0048] The historical trajectory sequence is cut into multiple historical trajectory features, thereby avoiding the defect of high computational complexity when the multimodal recurrent neural network model processes a large amount of data simultaneously.
[0049] When the multimodal recurrent neural network model predicts the next hop trajectory, the training of the multimodal recurrent neural network model is as follows:
[0050] Define q = (moment, cid), where moment is the timestamp, cid is the camera number, specify the target pedestrian ID r, and give r's current trajectory sequence S r =q1q2…q n , predict the next cid of the future trajectory. This embodiment uses the DeepMove multimodal recurrent neural network model to capture complex transfer relationships and capture the multi-level periodicity of human movement by combining the most relevant historical trajectories under the current movement state.
[0051] DeepMove mainly includes three modules: feature extraction and embedding, repetition module, and historical attention and prediction. First, the historical trajectory features are input into the multimodal recurrent neural network model to output the current trajectory, that is, the current trajectory includes the current trajectory and the historical trajectory. The current trajectory is processed by the GRU recurrent layer to simulate complex sequence information. Then, the historical trajectory features and the current trajectory are combined and input into the multimodal recurrent neural network model again to output the probability of the next hop spatiotemporal transfer of the camera.
[0052] The historical attention module includes an attention candidate generator and an attention selector, which are used to generate candidates. After combining the historical trajectory features and the current trajectory, they are input into the multimodal recurrent neural network model again, and the similarity between the query vector (current trajectory) and the candidate vector (historical trajectory features) is calculated to generate a context vector. Among them, the final context vector c t =∑a i s i , a i =σ(f(h t ,s i )), f(h t ,s)=tanh(ht W s ), s is the historical trajectory feature, W is the learnable parameter, h t is the query vector of the current trajectory from the recurrent layer, f is the score function, and σ is the softmax function.
[0053] During the training process, predicting the next location (next hop spatiotemporal transition probability) from a limited list of discrete locations (historical trajectory features) can be regarded as a multi-classification problem, and cross-entropy is selected as the loss function. During the experiment, the multimodal recurrent neural network model was trained using back propagation through time (BPTT) and the Adam optimizer. The historical attention module was parameterized as a feedforward neural network that can be trained together with the entire recurrent neural network.
[0054] Step 4: Calculate the similarity probability matrix between all high-dimensional visual features in the historical trajectory sequence and all pedestrian visual features in the base database within a set time, calculate the logical smoothing parameter based on each similarity in the similarity probability matrix and the next-hop spatiotemporal transition probability, select the trajectory information corresponding to the maximum value of the logical smoothing parameter as the trajectory sequence point at the next moment, and update the historical trajectory sequence;
[0055] After obtaining the high-dimensional visual features (next-hop spatiotemporal transfer probability) of the target pedestrian in the picture, expand the target feature library (historical trajectory sequence) and establish the similarity probability matrix M between the visual feature vectors of all pedestrians in the base library within a short period of time (t minutes), where M ij is the similarity between the pedestrian visual feature i and the target feature j, M ij ={CalculateSimilarity(F i ,F j )|i=1,2,…,N,j=1,2,…,T}, where N is the number of pedestrians appearing in the images of all P cameras in the park within t minutes, T is the target feature library composed of all high-dimensional visual features in the current historical trajectory, and F i is the visual features extracted by the pedestrian re-identification model in the base database, F j is the visual feature extracted by the pedestrian re-identification model in the target feature library, and CalculateSimilarity is the cosine similarity measurement function.
[0056] The next-hop spatiotemporal transfer probability output by the multimodal recurrent neural network model is a P-dimensional vector V, corresponding to the spatial probability of each next-hop transfer to the camera, which aims to provide spatial continuity so that points do not jump in space. Using only spatiotemporal probability is unreliable and uncontrollable because people's walking trajectory and speed are uncertain. This embodiment introduces a logical smoothing method to adjust the probability of rare events. Define the logical smoothing parameter λ0,λ1 are smoothing factors, γ0,γ1 are shrinkage factors. joint The largest value qmax=(moment,cid) is used as the trajectory sequence for the next moment, and S is updated r =q1q2…q n q max .
[0057] Step 5: Determine whether the time interval between the newly added trajectory sequence point and the previous trajectory sequence point is greater than the preset time threshold. If it is greater than the time threshold, return to step 3. If it is less than or equal to the time threshold, the trajectory update is completed and the updated historical trajectory sequence is returned.
[0058] Through steps one to five, trajectory generation is achieved, and in the process of trajectory generation, the wrong trajectory points are continuously corrected with the help of time intervals, thereby improving the accuracy of trajectory generation. In addition, the historical trajectory sequence in this embodiment changes as the cycle proceeds, and the historical trajectory sequence after each update is used as the initial historical trajectory sequence of the next cycle to predict the trajectory at the next moment, thereby achieving trajectory generation in a certain area.
[0059] Therefore, this embodiment solves the problem of quickly and accurately generating a target pedestrian's trajectory sequence in a short period of time in a large-scale feature library generated by a real-time video monitoring system. By combining visual features and historical trajectory features through a joint measurement method, each trajectory point is continuously iterated to finally achieve the generation of a trajectory sequence for a single pedestrian trip. This embodiment provides an efficient trajectory generation solution for smart campuses, intelligent search for people, and other aspects.
[0060] Taking a park covering an area of 1,000 acres, with up to 2,000 cameras and 21 buildings as an example, the number of pedestrian features to be matched in one day is as high as 2 million. The trajectory generation method of this embodiment continuously uses visual features and historical trajectory features to iteratively generate each trajectory point, achieving an accuracy rate of 80% in generating trajectory sequences, and the generation time is about 5 seconds. Compared with the current situation where the use of annotation tools takes 11 minutes and manual investigation takes at least 30 minutes, this embodiment significantly saves labor costs.
[0061] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes according to the technical scheme and inventive concept of the present invention within the technical scope disclosed by the present invention, which should be covered by the protection scope of the present invention.
Claims
1. A trajectory generation method based on joint measurement of pedestrian visual spatiotemporal information, characterized in that: The steps include: Step 1: Build a video surveillance database and extract visual features from each data in the video surveillance database; Step 2: Given the seed information and high-dimensional visual features of the target pedestrian u, calculate the similarity between the high-dimensional visual features and the visual features in the base database, and add the visual features that exceed the set similarity to the initial trajectory sequence corresponding to the target pedestrian to create a historical trajectory sequence; Step 3: Cut and encode the historical trajectory sequence according to the time window of the set time to obtain multiple historical trajectory features, and input them into the multimodal recursive neural network model to output the next hop spatiotemporal transfer probability of each camera and add it to the historical trajectory sequence; Step 4: Calculate the similarity probability matrix between all high-dimensional visual features in the historical trajectory sequence and all pedestrian visual features in the base database within a set time, calculate the logical smoothing parameter based on each similarity in the similarity probability matrix and the next-hop spatiotemporal transition probability, select the trajectory information corresponding to the maximum value of the logical smoothing parameter as the trajectory sequence point at the next moment, and update the historical trajectory sequence; Step 5: Determine whether the time interval between the newly added trajectory sequence point and the previous trajectory sequence point is greater than the preset time threshold. If it is greater than the time threshold, return to step 3. If it is less than or equal to the time threshold, the trajectory update is completed and the updated historical trajectory sequence is returned.
2. The trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information according to claim 1 is characterized in that: In step 1, in a set park, a video surveillance database is constructed based on a single travel trajectory of pedestrians, specifically: Each record of a pedestrian's single trip trajectory is represented by a pedestrian tuple with a timestamp, camera number, and pedestrian position number, and the pedestrian tuple is added to the frequency monitoring base database in real time; The image corresponding to the pedestrian's single travel trajectory at each moment is decoded and the image is passed through the target detection model and the pedestrian re-identification model in turn to extract visual features.
3. The trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information according to claim 2 is characterized in that: The pedestrian re-identification model is trained as follows: The residual network ResNet50 is used as the backbone network to output REID features and ID prediction values. The REID features are used to calculate the triplet loss, and the ID prediction value is used to calculate the cross entropy loss. The triplet loss and the cross entropy loss are added to get the center loss. The pedestrian re-identification model is trained using the center loss, batch normalization is performed using BNNeck, and the model parameters of the pedestrian re-identification model are updated using the Adam optimizer; The triplet loss L tri (x, y, z) = max(d(x, y) - d(x, z) + margin, 0), where (x, y, z) are the anchor point, the positive sample, and the negative sample, respectively. Margin is the interval parameter of the triplet loss function. d(x, y) represents the distance between the anchor point and the positive sample, and d(x, z) represents the distance between the anchor point and the negative sample.
4. The trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information according to claim 1 is characterized in that: In step 3, the historical trajectory features are input into the multimodal recurrent neural network model to output the next-hop spatiotemporal transition probability of each camera, specifically: Input historical trajectory features into the multimodal recurrent neural network model to output the current trajectory; The historical trajectory features and the current trajectory are combined and input into the multimodal recurrent neural network model again to output the next-hop spatiotemporal transition probability of the camera.
5. The trajectory generation method based on the joint measurement of pedestrian visual spatiotemporal information according to claim 1 is characterized in that: In step 4, the logical smoothing parameter is calculated based on each similarity in the similarity probability matrix and the next hop spatiotemporal transition probability. The logical smoothing parameter Eqn joint The specific calculation is as follows: Among them, M ij is the similarity probability matrix between the i-th high-dimensional visual feature in the historical trajectory sequence and the i-th pedestrian visual feature in the base library within a set time, V is the P-dimensional vector of the next-hop spatiotemporal transfer probability, λ0 and λ1 are smoothing factors, and γ0 and γ1 are shrinkage factors.
6. A trajectory generation system based on joint measurement of pedestrian visual spatiotemporal information, characterized in that: It includes a base library construction module, a historical trajectory sequence creation module, a next hop generation module, a trajectory update module and a loop module; The base database construction module is used to construct a video surveillance base database and extract visual features from each data in the video surveillance base database; The historical trajectory sequence creation module is used to calculate the similarity between the visual high-dimensional features and the visual features in the base library when the seed information and visual high-dimensional features of the target pedestrian u are given, and add the visual features exceeding the set similarity to the initial trajectory sequence corresponding to the target pedestrian to create a historical trajectory sequence; The next-hop generation module is used to cut and encode the historical trajectory sequence in a time window of a set time to obtain multiple historical trajectory features, and input the historical trajectory features into the multimodal recurrent neural network model to output the next-hop spatiotemporal transfer probability of each camera and add it to the historical trajectory sequence; The trajectory update module is used to calculate the similarity probability matrix between all high-dimensional visual features in the historical trajectory sequence and all pedestrian visual features in the base database within a set time, calculate the logical smoothing parameter based on each similarity in the similarity probability matrix and the next hop spatiotemporal transition probability, select the trajectory information corresponding to the maximum value of the logical smoothing parameter as the trajectory sequence point at the next moment, and update the historical trajectory sequence; The loop module is used to determine whether the time interval between the newly added trajectory sequence point and the previous trajectory sequence point is greater than the preset time threshold. If it is greater than the time threshold, it returns to the next hop generation module. If it is less than or equal to the time threshold, the trajectory update is completed and the updated historical trajectory sequence is returned.