Crowd flow prediction model construction method and device and related equipment

By converting the original transaction data into a dynamic graph structure and using the first and second prediction models in the self-supervised learning framework to capture real-time features and long-term dependencies, the problem of poor prediction performance of existing models is solved, and flow prediction with higher accuracy and generalization capabilities is achieved.

CN120409830AActive Publication Date: 2025-08-01CHINA MOBILE INFORMATION TECHNOLOGY CO LTD +1
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510745053.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-05
Publication Date
2025-08-01
Estimated Expiration
2045-06-05

AI Technical Summary

Technical Problem

Existing population mobility prediction models fail to effectively utilize the intrinsic links between data features, resulting in poor prediction performance and difficulty in migrating valuable information in different prediction tasks.

Method used

The original transaction data is converted into a dynamic graph structure of continuous time, the real-time characteristics of the current period are captured through the first prediction model, and the second prediction model is combined with the historical and future information of adjacent periods, and the loss function is designed for iterative training, to generate complementary node representations, and a stable supervision signal is calculated using exponential moving average.

Benefits of technology

It improves the accuracy and generalization of inflow, outflow and OD flow prediction, and can better capture the timing dependence, periodicity and sudden changes of population flow, and adapt to the needs of multi-task prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120409830A_ABST
    Figure CN120409830A_ABST
Patent Text Reader

Abstract

The invention provides a crowd flow prediction model construction method and device and related equipment, and relates to the technical field of artificial intelligence, and the method comprises the steps: converting obtained original transaction data into a continuous-time dynamic graph structure; inputting the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure; inputting the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure; and performing iterative training on the first prediction model and the second prediction model based on a loss value between a prediction result corresponding to the first node representation and the second node representation until the loss value is less than or equal to a preset threshold value, and determining a first parameter of the first prediction model and a second parameter of the second prediction model after iteration training as target parameters of the crowd flow prediction model. And the prediction performance of the crowd flow prediction model is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and in particular, to a method, apparatus, and related device for constructing a population flow prediction model. Background Art

[0002] Through the population flow prediction model, spatio-temporal data can be mined, so as to perform prediction tasks such as inflow prediction, outflow prediction, and origin-destination (OD) flow prediction. However, existing population flow modeling methods usually process each data feature as an independent feature. Although these data features are derived from the same original data, the internal relationships between them are not effectively utilized. As a result, valuable information in one prediction task is difficult to transfer to other prediction tasks, which limits the overall efficiency of the prediction model.

[0003] It can be seen that the existing population flow prediction model has the problem of poor prediction performance. Summary of the Invention

[0004] Embodiments of this application provide a method, apparatus, and related device for constructing a population flow prediction model to solve the problem of poor prediction performance of the existing population flow prediction model.

[0005] To solve the above technical problems, this application is implemented as follows:

[0006] In a first aspect, embodiments of this application provide a method for constructing a population flow prediction model, and the method includes:

[0007] Converting the obtained original transaction data into a dynamic graph structure of continuous time, where the original transaction data includes a transaction triple composed of a starting node, a destination node, and a timestamp, the dynamic graph structure includes graph nodes and directed edges, the graph nodes are used to represent the starting node or the destination node, the directed edges are used to represent the personnel flow information between the starting node and the destination node, and the directed edges carry the timestamp;

[0008] Inputting the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure, where the first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure;

[0009] Input the dynamic graph structure into the second prediction model to obtain the second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples in the first time period, the transaction triples in the second time period, and the transaction triples in the third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time;

[0010] Based on the loss value between the prediction result corresponding to the first node representation and the second node representation, iteratively train the first prediction model and the second prediction model until the loss value is less than or equal to a preset threshold, and determine the first parameter of the first prediction model and the second parameter of the second prediction model after iterative training as the target parameters of the crowd flow prediction model.

[0011] Optionally, the dynamic graph structure includes a set of graph nodes and a set of directed edges. The set of graph nodes includes graph nodes at multiple moments within the t time period, and the set of directed edges includes directed edges at multiple moments within the t time period;

[0012] The first prediction model is implemented according to the following formula:

[0013]

[0014] where, g t =(V, {e k |t k <t}); f() represents the encoder in the first prediction model, g t is the dynamic graph structure, V is the set of graph nodes, e k is the directed edge at time t k , is the starting node at time t k , is the destination node at time t k , Z t is the first node representation, is the representation vector of the i-th node among N graph nodes, and Z t ∈R N*d , d is the dimension of the first node representation.

[0015] Optionally, the second prediction model is implemented according to the following formula:

[0016]

[0017] where, B t ={em |t - <t m ≤t}; For the representation of the second node, f ξ Indicates that the encoder parameter in the second prediction model is ξ, f θ Indicates that the encoder parameter in the first prediction model is θ, B t Is the transaction triple within the first time period, Is the augmented data, Includes the transaction triples within the second time period and the transaction triples within the third time period, e m Is t m The directed edge at time t, Is t m The starting node at time t, Is t m The destination node at time t, t - Is the last moment among multiple moments in the second time period, Is the memory state of the starting node at t - At time, The memory state of the destination node at t - At time, M o,t Is the memory state of the starting node at time t, M d,t The memory state of the destination node at time t, and Is the dimension of the representation of the second node.

[0018] Optionally, the loss value is calculated according to the following formula:

[0019]

[0020] Where, H t = p θ (Z t ); L is the loss value, H t Is the prediction result corresponding to the representation of the first node, p θ Is the predictor corresponding to the encoder in the first prediction model, Z t Is the representation of the first node, Is the representation vector of node i at time t in the representation of the second node, Is the prediction result corresponding to the representation vector of node i at time t in the prediction result corresponding to the representation of the first node, ||·|| is the L2 norm of the vector.

[0021] Optionally, the second parameter is obtained according to the following formula:

[0022] ξ′ = αξ+(1 - α)θ;

[0023] Where θ is the first parameter, ξ′ is the updated second parameter, ξ is the second parameter before update, and α is a hyperparameter.

[0024] Optionally, the converting the obtained original transaction data into a dynamic graph structure in continuous time includes:

[0025] Converting the obtained original transaction data into a triple form to obtain an initial triple;

[0026] Performing data cleaning on the initial triple to obtain the transaction triple, where the transaction triple is triple data obtained by removing abnormal data in the initial triple, and the abnormal data includes data with any one of the starting node, the destination node, and the timestamp missing;

[0027] Converting the transaction triple into the dynamic graph structure.

[0028] In a second aspect, an embodiment of the present application provides a device for constructing a crowd flow prediction model, and the device includes:

[0029] A conversion module, configured to convert the obtained original transaction data into a dynamic graph structure in continuous time, where the original transaction data includes a transaction triple composed of a starting node, a destination node, and a timestamp, the dynamic graph structure includes graph nodes and directed edges, the graph nodes are used to represent the starting node or the destination node, the directed edges are used to represent the personnel flow information between the starting node and the destination node, and the directed edges carry the timestamp;

[0030] A first input module, configured to input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure, where the first node representation is a vector representation determined according to the transaction triples in a first time period in the dynamic graph structure;

[0031] A second input module, configured to input the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure, where the second node representation is a vector representation determined according to the transaction triples in the first time period, the transaction triples in a second time period, and the transaction triples in a third time period in the dynamic graph structure, the second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time;

[0032] A training module, configured to iteratively train the first prediction model and the second prediction model based on a loss value between a prediction result corresponding to the first node representation and the second node representation, until the loss value is less than or equal to a preset threshold, and determine first parameters of the first prediction model and second parameters of the second prediction model after the iterative training as target parameters of the population flow prediction model.

[0033] In a third aspect, an embodiment of the present application provides an electronic device, including a transceiver and a processor.

[0034] The processor is configured to convert the acquired original transaction data into a dynamic graph structure in continuous time. The original transaction data includes a transaction triple composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, and the directed edges are used to represent the personnel flow information between the starting node and the destination node. The directed edges carry the timestamp.

[0035] The transceiver is configured to input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure. The first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure.

[0036] The transceiver is further configured to input the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples within the first time period, the transaction triples within a second time period, and the transaction triples within a third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time.

[0037] The transceiver is further configured to iteratively train the first prediction model and the second prediction model based on a loss value between a prediction result corresponding to the first node representation and the second node representation, until the loss value is less than or equal to a preset threshold, and determine first parameters of the first prediction model and second parameters of the second prediction model after the iterative training as target parameters of the population flow prediction model.

[0038] In a fourth aspect, an embodiment of the present application provides an electronic device, including: a processor, a memory, and a program stored on the memory and executable on the processor. When the program is executed by the processor, the steps of the population flow prediction model construction method as described in the first aspect are implemented.

[0039] Fifth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the crowd flow prediction model construction method described in the first aspect are implemented.

[0040] In the embodiment of the present application, first, the original transaction is converted into a timestamped dynamic graph structure to provide a structured input for time series analysis; then, the first prediction model is used to capture the immediate features of the current period, and the second prediction model fuses the historical and future information of adjacent periods to construct long-term dependencies to form complementary representation learning; based on the difference between the two representations, a loss function is designed, and through iterative training, the first prediction model is forced to learn more robust features, and at the same time, the parameters of the second prediction model are slowly updated using exponential moving average calculation to provide a stable supervision signal. Finally, the generated node representation effectively captures the time series dependencies, periodicity, and sudden changes of crowd flow, and combined with the multi-task adaptation ability, effectively improves the accuracy and generalization of the prediction of the inflow, outflow, and OD flow. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings required for the embodiments or the description of the prior art. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0042] Figure 1 is one of the flowcharts of a crowd flow prediction model construction method provided by an embodiment of the present application;

[0043] Figure 2 [[ID=No.16]]is the second flowchart of a crowd flow prediction model construction method provided by an embodiment of the present application;

[0044] Figure 3 is the structural schematic diagram of a crowd flow prediction model construction device provided by an embodiment of the present application;

[0045] Figure 4 is the structural schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0046] The following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art without creative efforts based on the embodiments of the present application belong to the scope of protection of the present application.

[0047] SeeFigure 1 , Figure 1 is a flowchart of a method for constructing a population flow prediction model provided by an embodiment of the present application. As Figure 1 shown, the method includes the following steps:

[0048] Step 101: Convert the obtained original transaction data into a dynamic graph structure of continuous time. The original transaction data includes transaction triples composed of a starting point node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting point node or the destination node, and the directed edges are used to represent the personnel flow information between the starting point node and the destination node. The directed edges carry the timestamp;

[0049] In this step, the original data can be collected from the transportation system. The original transaction data includes the starting point, destination, and travel time of each passenger. This information can be converted into transaction triples, that is, (starting point node, destination node, timestamp). Exemplarily, the transaction triple can be expressed as where represents the m-th starting point node, represents the m-th destination node, and t m represents the time when the passenger travels from m to at time t. The dynamic graph structure of continuous time includes graph nodes and directed edges. Each graph node can represent a transportation entity, such as a subway station. A finite set of N graph nodes can be expressed as V = {v1, v2,..., v N}; the m-th directed edge in the dynamic graph structure can be expressed as The set of M transactions can be expressed as E = {e1, e2,..., e M}, and the dynamic graph structure at time t can be denoted as g t = (V, {e k |t k < t}), and g t contains all the transactions that occurred before time t.

[0050] In this way, the obtained original transaction data is converted into a dynamic graph structure of continuous time. The starting point and destination nodes in the original data are directly corresponding to the graph nodes (GraphNodes), and each one-way flow event is represented by each directed edge (Directed Edges). Moreover, the directed edges carry timestamps to depict the chronological order of events, making the graph structure dynamic. The graphs at different time points contain different edge sets (for example, the graph at time t contains all the edges at t k<t的边)。将非结构化的流动数据转化为结构化的动态图,为后续的时序图分析提供基础;时间戳的引入使模型能够捕捉流动事件的时间依赖(如早晚高峰的周期性、突发事件的即时影响)。

[0051] Optionally, the step 101 of converting the acquired original transaction data into a continuous-time dynamic graph structure includes:

[0052] Convert the acquired original transaction data into triples to obtain initial triples;

[0053] Performing data cleaning on the initial triple to obtain the transaction triple, wherein the transaction triple is triple data with abnormal data in the initial triple removed, wherein the abnormal data includes data with any one of a starting point node, a destination node, and a timestamp missing;

[0054] The transaction triplet is converted into the dynamic graph structure.

[0055] In this example, the original data is first organized into initial triples containing the origin node, destination node, and timestamp. Then, through data cleaning, abnormal data with any missing item (node or timestamp) is eliminated to obtain transaction triples with standardized format and complete information. Finally, these cleaned triples are converted into a continuous-time dynamic graph structure with graph nodes and directed edges with timestamps as core elements, providing high-quality input data for subsequent modeling.

[0056] Step 102: Input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure, where the first node representation is a vector representation determined based on transaction triples within a first time period in the dynamic graph structure;

[0057] In this step, if Figure 2 As shown, the first prediction model can be a branch in the self-supervised learning framework, namely an online branch. The online branch realizes the real-time update of node information and the maintenance of the first node representation of the node. Whenever new transaction data is obtained, the online encoder in the first prediction model will update the memory state of the relevant node and adjust the first node representation of the node accordingly. This allows the output of the first prediction model to dynamically reflect the latest crowd flow situation. Specifically, the online encoder of the first prediction model can be denoted as f θ, where θ is the parameter of the online encoder. Inputting the dynamic graph structure into the first prediction model to obtain the first node representation corresponding to the dynamic graph structure, generating instant vector features by quickly responding to transaction triples within the first time period, providing timeliness support for real-time prediction; the first node representation can be directly applied to downstream prediction models (such as fully connected networks, graph neural networks) for real-time prediction of inflow, outflow, and origin-destination (OD) flows. Each dimension in the vector implicitly contains key features of the current time period (such as the activity level of the node as a starting point and the instant interaction intensity of adjacent nodes). By converting the complex time-series graph structure into a low-dimensional vector, while retaining key information, the computational complexity is reduced, supporting the efficient processing and pattern extraction of large-scale dynamic graphs.

[0058] Optionally, the dynamic graph structure includes a set of graph nodes and a set of directed edges. The set of graph nodes includes graph nodes at multiple moments within the t time period, and the set of directed edges includes directed edges at multiple moments within the t time period;

[0059] The first prediction model is implemented according to the following formula:

[0060]

[0061] where g t =(V,{e k |t k <t}); f() represents the encoder in the first prediction model, g t is the dynamic graph structure, V is the set of graph nodes, e k is the directed edge at time t k , is the starting node at time t k , is the destination node at time t k , Z t is the first node representation, is the representation vector of the i-th node among N graph nodes, and Z t ∈R N*d , d is the dimension of the first node representation, and the encoder in the first prediction model is used to convert the dynamic graph structure into a low-dimensional, dense node vector representation.

[0062] In this example, given the dynamic graph structure g t =(V,{e k |t k <t}) before time t, the goal is to train the online encoder f() in the first prediction model such that Convert the dynamic graph g through the online encoder f() t into a low-dimensional, dense node vector representation matrix Z t ∈R N*d , and the representation of each node i compresses all interaction information of the node before time t (such as flow records as the starting / ending point, time-dependent features). The core goal of the online encoder is to enable the generated first node representation to effectively capture the spatio-temporal dependencies of the dynamic graph (such as recent flow trends, node interaction patterns) through training, providing efficient feature inputs for downstream inflow, outflow, and OD flow predictions.

[0063] Specifically, three types of population flow tasks can be considered: inflow prediction, outflow prediction, and OD flow prediction. Among them, inflow prediction refers to predicting how many people enter a certain node within a period of time. The inflow of a node i can be defined as X I,t:t+τ , where τ is a preset time interval, and X I,t:t+τ can be expressed as:

[0064]

[0065] Outflow prediction refers to predicting how many people leave a certain node within a period of time. The outflow of a node i can be defined as and can be expressed as:

[0066]

[0067] OD flow prediction refers to predicting how people flow between each pair of nodes, which can be expressed as a matrix where the (i, j) entry represents how many people flow from v i to v j . and can be expressed as:

[0068]

[0069] In this way, when performing the inflow prediction task based on the first prediction model, the corresponding output can be expressed as:

[0070]

[0071] When performing the outflow prediction task based on the first prediction model, the corresponding output can be expressed as:

[0072]

[0073] When performing the OD flow prediction task based on the first prediction model, the corresponding output It can be expressed as:

[0074]

[0075] where f I 、f O and f OD are all online encoders in the first prediction model.

[0076] Step 103: Input the dynamic graph structure into the second prediction model to obtain the second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples in the first time period, the transaction triples in the second time period, and the transaction triples in the third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time;

[0077] In this step, the second prediction model can be another branch in the self-supervised learning framework, that is, the target branch. The target branch can have a similar structure to the online branch. By using the information from the online branch and combining context-aware data augmentation techniques through the target branch, stable target node representations (i.e., the second node representations) are generated. These second node representations are used to compare with the output of the online branch to optimize the model parameters. The original transaction data is compressed into meaningful representation vectors through a bootstrap process, and these vectors can capture the key features of crowd flow. This process is achieved through the collaborative work of the online branch and the target branch, where the online branch processes real-time data and the target branch provides stability and a comparison benchmark. Moreover, the target branch contains a target encoder with the same structure as the online encoder. Before being input into the target encoder, the data is first augmented by a context-aware data augmentation module. The target encoder generates the second node representations for the augmented batches in a similar manner. Specifically, the target encoder of the second prediction model can be denoted as f ξ , where ξ is the target encoder parameter. Inputting the dynamic graph structure into the second prediction model to obtain the second node representation corresponding to the dynamic graph structure, the transaction triples in the dynamic graph structure include three consecutive time periods (such as the previous hour, the current hour, and the next hour). The second prediction model processes the data of these three time periods simultaneously to construct a more complete time context. So that the generated second node representation not only contains the immediate features of the current time period, but also integrates past historical patterns (such as the morning rush hour pattern) and future potential trends (such as the growth of mall passenger flow in the afternoon), enabling the model to capture longer-range time dependencies. By integrating cross-period information, the short-term fluctuation problem that may exist in the first prediction model (based only on the current time period) is alleviated, providing a more stable and comprehensive feature representation for crowd flow prediction, especially suitable for scenarios that require capturing periodic patterns or long-term impacts.

[0078] Optionally, the second prediction model is implemented according to the following formula:

[0079]

[0080] where B t = {e m |t - <t m ≤ t}; is the second node representation, f ξ represents that the encoder parameter in the second prediction model is ξ, f θ represents that the encoder parameter in the first prediction model is θ, B t is the transaction triple within the first time period, is the augmented data, including the transaction triples within the second time period and the transaction triples within the third time period, e m is the directed edge at time t m , is the starting node at time t m , is the destination node at time t m , t - is the last moment among multiple moments in the second time period, is the memory state of the starting node at time t - , the memory state of the destination node at time t - , M o,t is the memory state of the starting node at time t, M d,t the memory state of the destination node at time t, and is the dimension of the second node representation.

[0081] In this example, the target encoder f ξ of the second prediction model is based on the memory states - of the starting and destination nodes at time t and , and combines the augmented data (including the previous period B t , the data of the past time period adjacent to the current time period, and the data of the future time period adjacent to the current time period) to generate the second node representation By fusing multi-period information, the model can capture longer-term time dependencies and cross-period impacts. Moreover, the online encoder f θBased on the current period B t Update the memory state to M o,t and M d,t while the second prediction model reuses the old memory and ensure that the two models process different time contexts.

[0082] Among them, the second parameter is obtained according to the following formula:

[0083] ξ′ = αξ+(1 - α)θ;

[0084] where θ is the first parameter, ξ′ is the updated second parameter, ξ is the second parameter before update, and α is a hyperparameter.

[0085] f ξ is the same in structure as f θ but has different parameters. ξ′ is slowly updated from θ through Exponential Moving Average (EMA), making become a more stable target representation for supervising the training of the first prediction model, improving the modeling ability for time dependence.

[0086] Specifically, the input of the online encoder is the current B t , which consists of transactions between the current time t and the last update time t - . B t can be expressed as:

[0087] B t ={e k ∈B|t - <t k ≤t}.

[0088] The transaction triple B t corresponding to the previous batch adjacent to B - can be expressed as:

[0089] B - ={e k ∈B|t - - τ < t k ≤t -};

[0090] The transaction triple B t corresponding to the next batch adjacent to B + can be expressed as:

[0091] B + ={e k ∈B|t < t k ≤t + τ};

[0092] The transaction set composed of the edges of the current batch and its adjacent batches can be denoted as ε, where ε can be expressed as:

[0093] ε = {e k ∈ B -} ∪ {e k ∈ B t} ∪ {e k ∈ B +}.

[0094] contains (1 + r) * |B t | directed edges randomly sampled from ε, where |B t | is the number of edges in B t , and r is the ratio controlling the augmented batch size. Then B - is used as the input to the target encoder.

[0095] In this way, by randomly sampling the edges of the current batch and its adjacent batches, augmented data is generated and input into the target encoder. This enhancement strategy improves the model's adaptability to time changes, enabling the model to better capture dynamic changes over time, thereby achieving more accurate predictions in a dynamic traffic environment. Through context-aware data augmentation, the model can better utilize temporal correlations and improve prediction performance.

[0096] Step 104: Based on the loss value between the prediction result corresponding to the first node representation and the second node representation, iteratively train the first prediction model and the second prediction model until the loss value is less than or equal to a preset threshold, and determine the first parameter of the first prediction model and the second parameter of the second prediction model after iterative training as the target parameters of the crowd flow prediction model.

[0097] Among them, the second parameter is obtained by performing exponential moving average calculation based on the first parameter. The crowd flow prediction model includes the first prediction model and the second prediction model. The crowd flow prediction model is used to perform prediction tasks, and the prediction tasks include inflow prediction, outflow prediction, and origin-destination OD flow prediction.

[0098] In this step, a self-supervised contrastive learning framework is adopted, and a pre-training stage is designed: calculate the loss value (such as cosine similarity loss) between the prediction result of the first prediction model (based on the immediate first node representation at the current time period) and the second node representation output by the second prediction model (a stable representation that fuses multi-time period context), and construct a self-supervised learning objective. Alternately update the parameter θ of the first prediction model (directly optimized by gradient descent) and the parameter ξ′ of the second prediction model (slowly synchronized from θ through exponential moving average), so that the two models focus on capturing immediate dynamics and long-term dependencies respectively. When the loss value is less than the preset threshold, the model is considered to converge, and the current parameters are saved as the final crowd flow prediction model. In this way, a continuous-time dynamic encoder and contrastive learning are used to update the model without external labeled data, thereby realizing the optimization of the model parameters of the crowd flow prediction model. It reduces the dependence on a large amount of labeled data, improves the generalization ability of the model, enables the model to perform transfer learning between different tasks, and enhances the adaptability and robustness of the model.

[0099] Among them, the loss value is calculated according to the following formula:

[0100]

[0101] Among them, H t = p θ (Z t ); L is the loss value, H t is the prediction result corresponding to the first node representation, p θ is the predictor corresponding to the encoder in the first prediction model, Z t is the first node representation, is the representation vector of node i at time t in the second node representation, is the prediction result corresponding to the representation vector of node i at time t in the prediction result corresponding to the first node representation, ||·|| is the L2 norm of the vector.

[0102] Among them, the first parameter θ of the online encoder in the first prediction model can be expressed as: θ←optimize(θ, lr, L).

[0103] In this way, in the embodiments of the present application, the original transaction is first converted into a dynamic graph structure with timestamps to provide a structured input for time series analysis; then the first prediction model is used to capture the immediate features of the current period, and the second prediction model fuses the historical and future information of adjacent periods to construct long-term dependencies to form complementary representation learning; a loss function is designed based on the representation differences between the two, and through iterative training, the first prediction model is forced to learn more robust features, while the parameters of the second prediction model are slowly updated using exponential moving average calculation to provide a stable supervision signal. Finally, the generated node representations effectively capture the time series dependencies, periodicity, and sudden changes of crowd flows. Combining with the multi-task adaptation ability, the accuracy and generalization of the inflow, outflow, and OD flow predictions are effectively improved.

[0104] In some alternative embodiments, the obtained original transaction data is converted into a dynamic graph structure of continuous time, and by inputting the dynamic graph structure into the first prediction model, the first node representation corresponding to the dynamic graph structure is obtained. The specific description can be seen as follows:

[0105] For each traffic node v i , the online encoder will maintain the memory of the source node of the last update and the memory of the target node where is the weighted sum of the node states that interacted with node v i previously, is the normalized weighted counter, is the last update time of node v i . Given a batch of data B t , the online encoder first calculates the messages of each transaction therein. For a transaction triple (v i , v j , t k ) ∈ B t , the source message and the destination message are calculated as:

[0106]

[0107] where F ∈ R N*dF is the node feature, is the source message, is the destination message. Regarding the node state, it will be in a stagnant state, and the part from the memory will be multiplied by the decay term between the transaction time t k and the last update time of the memory.

[0108] Moreover, considering the computational efficiency, the messages of a batch of different transactions are aggregated to update the corresponding memories of the interacting nodes. For the transaction triple (v i , v j , t k ) ∈ B tFor example, the interaction node is the starting node v i and the destination node v j . is B t the timestamp of the last transaction in B i starting with v is B t the timestamp of the last transaction in B j ending with v

[0109]

[0110] Given the messages of the interactive calculation in B t the original memory of node v i is updated to:

[0111]

[0112] wherein, is the updated initial memory, and the latest update time of node v i is updated by the timestamp of the last batch transaction in starting with v i as the original node.

[0113] Given the messages of the interactive calculation in B t the original memory of node v j is updated to:

[0114]

[0115] wherein, is the updated initial memory, and the latest update time of node v j is determined by .

[0116] After updating the source memory and target memory of the corresponding node, the final node representation of node v i is calculated as:

[0117]

[0118] In this embodiment, by directly operating on the continuous-time dynamic graph, detailed time information is retained, and more complex spatio-temporal patterns and dynamic changes in population flow can be captured. Specifically, the method combines timestamp and node interaction information, calculates the source message and destination message of each traffic node, and updates the memory state of the node through the message passing mechanism. Finally, by integrating the source memory and target memory, the final representation of the node is generated. This method not only retains the temporal continuity but also considers the interaction relationship between nodes, thereby improving the representation ability and prediction accuracy of the model.

[0119] In addition, general node representations can be learned during the pre-training phase and then fine-tuned in downstream tasks. The model can quickly adapt and improve the performance of specific tasks. The specific steps include: during the pre-training phase, learning the general representations of nodes through a self-supervised contrastive learning framework; in downstream tasks, using the learned general representations for fine-tuning to optimize the performance of specific tasks. This training strategy improves the training efficiency and prediction accuracy of the model, enabling the model to adapt to various population flow modeling tasks, such as inflow / outflow prediction and OD flow prediction, and enhancing the generalization ability and practicality of the model.

[0120] The population flow prediction model obtained by the method for constructing a population flow prediction model provided in the embodiments of the present application has effective technical advantages in population flow modeling, and these advantages are confirmed by the following quantitative results:

[0121] Compared with the Graph-based Evolving Memory Learning (GEML) method, for the population flow prediction model on the BJSubway dataset, the Root Mean Squared Error (RMSE) for inflow prediction decreased by approximately 10% (from 0.980 to 0.882), the Mean Absolute Error (MAE) decreased by approximately 8% (from 0.657 to 0.604), and the Pearson Correlation Coefficient (PCC) increased by approximately 3% (from 0.985 to 0.998). Similar performance was also observed on the NYTaxi dataset.

[0122] In the OD prediction task, compared with the Temporal Graph Network (TGN) method, for the population flow prediction model on the BJSubway dataset, the RMSE decreased by approximately 15% (from 0.850 to 0.723), the MAE decreased by approximately 12% (from 0.550 to 0.484), and the PCC increased by approximately 2% (from 0.970 to 0.990).

[0123] For traffic flow prediction, the RMSE of the crowd flow prediction model on the BJSubway dataset is reduced by approximately 8% (from 0.900 to 0.828), the MAE is reduced by approximately 6% (from 0.600 to 0.564), and the PCC is increased by approximately 1% (from 0.975 to 0.985) compared to the Multivariate Time Series Forecasting with Graph Neural Networks (MTGNN).

[0124] Compared with the Diffusion Convolutional Recurrent Neural Network (DCRNN), the RMSE of the crowd flow prediction model on the BJSubway dataset is reduced by approximately 12% (from 180 to 158), the MAE is reduced by approximately 10% (from 120 to 108), and the PCC is increased by approximately 3% (from 0.80 to 0.83). Through the above quantitative results, the present invention not only demonstrates innovation in theory, but also proves its technical advantages and practical value in practical applications.

[0125] See Figure 3 , Figure 3 is a schematic structural diagram of a crowd flow prediction model construction device provided by an embodiment of the present application. As Figure 3 shown, the crowd flow prediction model construction device 300 includes:

[0126] A conversion module 301, configured to convert the obtained original transaction data into a dynamic graph structure of continuous time. The original transaction data includes a transaction triple composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, and the directed edges are used to represent the personnel flow information between the starting node and the destination node. The directed edges carry the timestamp;

[0127] A first input module 302, configured to input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure. The first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure;

[0128] The second input module 303 is configured to input the dynamic graph structure into the second prediction model to obtain a second node representation corresponding to the dynamic graph structure, where the second node representation is a vector representation determined according to transaction triples in the first time period, transaction triples in the second time period, and transaction triples in the third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time;

[0129] The training module 304 is configured to iteratively train the first prediction model and the second prediction model based on a loss value between a prediction result corresponding to the first node representation and the second node representation until the loss value is less than or equal to a preset threshold, and determine first parameters of the first prediction model and second parameters of the second prediction model after iterative training as target parameters of the crowd flow prediction model.

[0130] Optionally, the dynamic graph structure includes a graph node set and a directed edge set. The graph node set includes graph nodes at multiple moments within the t time period, and the directed edge set includes directed edges at multiple moments within the t time period;

[0131] The first prediction model is implemented according to the following formula:

[0132]

[0133] where g t =(V, {e k |t k <t}); f() represents an encoder in the first prediction model, g t is the dynamic graph structure, V is the graph node set, e k is a directed edge at the t k moment, is the starting node at the t k moment, is the destination node at the t k moment, Z t is the first node representation, is the representation vector of the i-th node among N graph nodes, and Z t ∈R N*d , d is the dimension of the first node representation.

[0134] Optionally, the second prediction model is implemented according to the following formula:

[0135]

[0136] where, B t = {e m | t - < t m ≤ t}; For the representation of the second node, f ξ Indicates that the encoder parameter in the second prediction model is ξ, f θ Indicates that the encoder parameter in the first prediction model is θ, B t Is the transaction triple within the first time period, Is the augmented data, Includes the transaction triples within the second time period and the transaction triples within the third time period, e m Is t m The directed edge at time t, Is the starting node at time t m Of t Is the destination node at time t m Of t - Is the last moment among multiple moments of the second time period, Is the memory state of the starting node at t - Of time, The memory state of the destination node at t - Of time, M o,t Is the memory state of the starting node at time t, M d,t The memory state of the destination node at time t, and Is the dimension of the representation of the second node.

[0137] Optionally, the loss value is calculated according to the following formula:

[0138]

[0139] Where, H t = p θ (Z t ); L is the loss value, H t Is the prediction result corresponding to the representation of the first node, p θ Is the predictor corresponding to the encoder in the first prediction model, Z t Is the representation of the first node, Is the representation vector of node i at time t in the representation of the second node, Is the prediction result corresponding to the representation vector of node i at time t in the prediction result corresponding to the representation of the first node, ||·|| is the L2 norm of the vector.

[0140] Optionally, the second parameter is obtained according to the following formula:

[0141] ξ′ = αξ+(1 - α)θ;

[0142] where θ is the first parameter, ξ′ is the updated second parameter, ξ is the second parameter before update, and α is a hyperparameter.

[0143] Optionally, the conversion module 301 is specifically configured to:

[0144] Convert the obtained original transaction data into a triple form to obtain an initial triple;

[0145] Clean the data of the initial triple to obtain the transaction triple. The transaction triple is triple data obtained by removing abnormal data in the initial triple, and the abnormal data includes data with any one of the starting node, destination node, and timestamp missing;

[0146] Convert the transaction triple into the dynamic graph structure.

[0147] The crowd flow prediction model construction device 300 can implement each process of the above embodiments of the crowd flow prediction model construction method applied to the network operation and maintenance management platform, with corresponding technical features one by one, and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.

[0148] The embodiment of the present application further provides an electronic device, including: a processor, a memory, and a program stored on the memory and executable on the processor. When the program is executed by the processor, it implements each process of the above embodiment of the crowd flow prediction model construction method, and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.

[0149] Specifically, referring to Figure 4 , the embodiment of the present application further provides an electronic device, including a bus 401, a transceiver 402, an antenna 403, a bus interface 404, a processor 405, and a memory 406.

[0150] Among them, the processor 405 is configured to convert the obtained original transaction data into a dynamic graph structure of continuous time. The original transaction data includes a transaction triple composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, the directed edges are used to represent the personnel flow information between the starting node and the destination node, and the directed edges carry the timestamp;

[0151] A transceiver 402, configured to input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure, where the first node representation is a vector representation determined according to transaction triples within a first time period in the dynamic graph structure;

[0152] The transceiver 402 is further configured to input the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure, where the second node representation is a vector representation determined according to the transaction triples within the first time period, the transaction triples within a second time period, and the transaction triples within a third time period in the dynamic graph structure, the second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time;

[0153] A processor 405 is further configured to, based on a loss value between a prediction result corresponding to the first node representation and the second node representation, perform iterative training on the first prediction model and the second prediction model until the loss value is less than or equal to a preset threshold, and determine first parameters of the first prediction model and second parameters of the second prediction model after the iterative training as target parameters of the crowd flow prediction model.

[0154] Optionally, the dynamic graph structure includes a set of graph nodes and a set of directed edges, the set of graph nodes includes graph nodes at multiple moments within a time period t, and the set of directed edges includes directed edges at multiple moments within the time period t;

[0155] The first prediction model is implemented according to the following formula:

[0156]

[0157] where g t =(V, {e k |t k <t}); f() represents an encoder in the first prediction model, g t is the dynamic graph structure, V is the set of graph nodes, e k is a directed edge at time t k , is the starting node at time t k , is the destination node at time t k , Z t is the first node representation, is a representation vector of the i-th node among N graph nodes, and Z t ∈R N*d , d is the dimension of the first node representation.

[0158] Optionally, the second prediction model is implemented according to the following formula:

[0159]

[0160] where B t ={e m |t - <t m ≤t}; is the second node representation, f ξ represents that the encoder parameter in the second prediction model is ξ, f θ represents that the encoder parameter in the first prediction model is θ, B t is the transaction triple within the first time period, is the augmented data, including the transaction triples within the second time period and the transaction triples within the third time period, e m is the directed edge at time t m , is the starting node at time t m , is the destination node at time t m , t - is the last moment among the multiple moments in the second time period, is the memory state of the starting node at time t - , the memory state of the destination node at time t - , M o,t is the memory state of the starting node at time t, M d,t the memory state of the destination node at time t, and is the dimension of the second node representation.

[0161] Optionally, the loss value is calculated according to the following formula:

[0162]

[0163] where H t =p θ (Z t ); L is the loss value, H t is the prediction result corresponding to the first node representation, p θ is the predictor corresponding to the encoder in the first prediction model, Z t is the first node representation, is the representation vector of node i at time t in the second node representation It represents the prediction result corresponding to node i at time t in the corresponding prediction result for the first node, and ||·|| is the L2 norm of the vector.

[0164] Optionally, the second parameter is obtained according to the following formula:

[0165] ξ′ = αξ+(1 - α)θ;

[0166] Where θ is the first parameter, ξ′ is the updated second parameter, ξ is the second parameter before update, and α is a hyperparameter.

[0167] Optionally, the conversion of the obtained original transaction data into a dynamic graph structure in continuous time includes:

[0168] Convert the obtained original transaction data into a triple form to obtain an initial triple;

[0169] Clean the data of the initial triple to obtain the transaction triple. The transaction triple is triple data obtained by removing abnormal data in the initial triple, and the abnormal data includes data with any one of the starting node, destination node, and timestamp missing;

[0170] Convert the transaction triple into the dynamic graph structure.

[0171] In Figure 4 In the bus architecture (represented by bus 401), bus 401 may include any number of interconnected buses and bridges. Bus 401 links together various circuits including one or more processors represented by processor 405 and a memory represented by memory 406. Bus 401 may also link together various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and thus will not be further described herein. Bus interface 404 provides an interface between bus 401 and transceiver 402. Transceiver 402 may be one element or multiple elements, such as multiple receivers and transmitters, and provides a unit for communicating with various other devices on the transmission medium. The data processed by processor 405 is transmitted over the wireless medium through antenna 403. Further, antenna 403 also receives data and transmits the data to processor 405.

[0172] Processor 405 is responsible for managing bus 401 and general processing, and can also provide various functions including timing, peripheral interface, voltage regulation, power management, and other control functions. And memory 406 can be used to store data used by processor 405 when performing operations.

[0173] Optionally, the processor 405 may be a Central Processing Unit (CPU), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA), or a Complex Programmable Logic Device (CPLD).

[0174] An embodiment of this application also provides a computer-readable storage medium. A computer program is stored on the computer-readable storage medium. When the computer program is executed by a processor, it implements each process of the above embodiment of the method for constructing a crowd flow prediction model and can achieve the same technical effect. To avoid repetition, it will not be elaborated here. Among them, the computer-readable storage medium is, for example, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disc, etc.

[0175] An embodiment of this application also provides a computer program product, including computer instructions. When the computer instructions are executed by a processor, they implement each process of the above embodiment of the method for constructing a crowd flow prediction model and can achieve the same technical effect. To avoid repetition, it will not be elaborated here.

[0176] It should be noted that in this article, the terms "including", "comprising", or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device including a series of elements not only includes those elements but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article, or device. Without more limitations, an element defined by the statement "including a..." does not exclude the existence of additional identical elements in the process, method, article, or device including that element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of this application is not limited to performing functions in the order discussed, and may also include performing functions in a substantially simultaneous manner or in the reverse order according to the functions involved. For example, the described method may be executed in an order different from that described, and various steps may be added, omitted, or combined. Additionally, the features described with reference to certain examples may be combined in other examples.

[0177] Through the description of the above embodiments, those skilled in the art can clearly understand that the above method of the embodiments can be implemented by means of software plus a necessary general hardware platform. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes several instructions for causing a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of the present application.

[0178] The embodiments of the present application have been described above with reference to the accompanying drawings. However, the present application is not limited to the above specific embodiments. The above specific embodiments are merely illustrative and not restrictive. Under the inspiration of the present application, those of ordinary skill in the art can also make many forms without departing from the purpose of the present application and the scope protected by the claims, and all of them fall within the protection scope of the present application.

Claims

1. A method for constructing a population flow prediction model, characterized in that, The method includes: Converting the obtained original transaction data into a dynamic graph structure in continuous time. The original transaction data includes transaction triples composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, and the directed edges are used to represent the personnel flow information between the starting node and the destination node. The directed edges carry the timestamp; Inputting the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure. The first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure; Inputting the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples within the first time period, the transaction triples within a second time period, and the transaction triples within a third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time; Based on the loss value between the prediction result corresponding to the first node representation and the second node representation, iteratively train the first prediction model and the second prediction model until the loss value is less than or equal to a preset threshold. Determine the first parameter of the first prediction model and the second parameter of the second prediction model after iterative training as the target parameters of the crowd flow prediction model.

2. The method according to claim 1, wherein The dynamic graph structure includes a graph node set and a directed edge set. The graph node set includes graph nodes at multiple moments within a t time period, and the directed edge set includes directed edges at multiple moments within the t time period; The first prediction model is implemented according to the following formula: Among them, g t =(V, {e k |t k <t}); f() represents the encoder in the first prediction model, g t is the dynamic graph structure, V is the set of graph nodes, e k is the directed edge at time t k , is the starting node at time t k , is the destination node at time t k , Z t is the first node representation, is the representation vector of the i-th node among N graph nodes, and Z t ∈R N*d , d is the dimension of the first node representation.

3. The method according to claim 2, wherein The second prediction model is implemented according to the following formula: Among them, B t = {e m |t - <t m ≤ t}; is the representation of the second node, f ξ represents that the encoder parameter in the second prediction model is ξ, f θ represents that the encoder parameter in the first prediction model is θ, B t is the transaction triple in the first time period, is the augmented data, includes the transaction triples in the second time period and the transaction triples in the third time period, e m is the directed edge at time t m is the starting node at time t is the starting node at time t m is the starting node at time t is the destination node at time t m is the destination node at time t, t - is the last moment among the multiple moments in the second time period, is the memory state of the starting node at time t - is the memory state of the starting node at time t is the memory state of the destination node at time t - is the memory state of the destination node at time t, M o,t is the memory state of the starting node at time t, M d,t is the memory state of the destination node at time t, and is the dimension of the representation of the second node.

4. The method according to any one of claims 1 to 3, characterized in that The loss value is calculated according to the following formula: where H t = p θ (Z t ); L is the loss value, H t is the prediction result corresponding to the first node representation, p θ is the predictor corresponding to the encoder in the first prediction model, Z t is the first node representation, is the representation vector of node i at time t in the second node representation, is the prediction result corresponding to the representation vector of node i at time t in the prediction result corresponding to the first node representation, ||·|| is the L2 norm of the vector.

5. The method according to any one of claims 1 to 3, characterized in that The second parameter is obtained according to the following formula: ξ′ = αξ+(1 - α)θ; Where θ is the first parameter, ξ′ is the updated second parameter, ξ is the second parameter before update, and α is a hyperparameter.

6. The method according to any one of claims 1 to 3, characterized in that The converting the obtained original transaction data into a dynamic graph structure in continuous time includes: Converting the obtained original transaction data into a triple form to obtain initial triples; Performing data cleaning on the initial triples to obtain the transaction triples. The transaction triples are triple data obtained by removing abnormal data in the initial triples. The abnormal data includes data with any one of the starting node, the destination node, and the timestamp missing; Converting the transaction triples into the dynamic graph structure.

7. An apparatus for constructing a population flow prediction model, characterized in that The device includes: A conversion module for converting the acquired original transaction data into a dynamic graph structure in continuous time. The original transaction data includes transaction triples composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, and the directed edges are used to represent the personnel flow information between the starting node and the destination node. The directed edges carry the timestamp. A first input module for inputting the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure. The first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure. A second input module for inputting the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples within the first time period, the transaction triples within a second time period, and the transaction triples within a third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time. A training module for iteratively training the first prediction model and the second prediction model based on the loss value between the prediction result corresponding to the first node representation and the second node representation until the loss value is less than or equal to a preset threshold, and determining the first parameter of the first prediction model and the second parameter of the second prediction model after iterative training as the target parameters of the crowd flow prediction model.

8. An electronic device, characterized in that, It includes a transceiver and a processor. The processor is used to convert the acquired original transaction data into a dynamic graph structure in continuous time. The original transaction data includes transaction triples composed of a starting node, a destination node, and a timestamp. The dynamic graph structure includes graph nodes and directed edges. The graph nodes are used to represent the starting node or the destination node, and the directed edges are used to represent the personnel flow information between the starting node and the destination node. The directed edges carry the timestamp. The transceiver is used to input the dynamic graph structure into a first prediction model to obtain a first node representation corresponding to the dynamic graph structure. The first node representation is a vector representation determined according to the transaction triples within a first time period in the dynamic graph structure. The transceiver is further used to input the dynamic graph structure into a second prediction model to obtain a second node representation corresponding to the dynamic graph structure. The second node representation is a vector representation determined according to the transaction triples within the first time period, the transaction triples within a second time period, and the transaction triples within a third time period in the dynamic graph structure. The second time period is an adjacent time period before the first time, and the third time period is an adjacent time period after the first time. The transceiver is further configured to iteratively train the first prediction model and the second prediction model based on the loss value between the prediction result represented by the first node and the second node representation, until the loss value is less than or equal to a preset threshold, and determine the first parameter of the first prediction model and the second parameter of the second prediction model after the iterative training as the target parameters of the crowd flow prediction model.

9. An electronic device, characterized in that, It includes: a processor, a memory, and a program stored on the memory and executable on the processor, where the program, when executed by the processor, implements the steps of the crowd flow prediction model construction method according to any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, it implements the steps of the crowd flow prediction model construction method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Traffic flow prediction model construction method and prediction method based on adaptive dynamic graph

    CN116187555A

  • Crowd activity prediction method based on dynamic graph assisted neural differential model

    CN116467635A

  • Unmanned aerial vehicle cluster track prediction method based on graph neural network

    CN116976512A

  • Multi-task learning urban crowd flow prediction method based on adaptive multi-graph fusion

    CN117726070A

  • Flow prediction method based on dynamic graph space-time correlation and adaptive adversarial training

    CN119211044A