CN116843069A - Commuting flow estimation method and system based on crowd activity intensity characteristics - Google Patents

Commuting flow estimation method and system based on crowd activity intensity characteristics Download PDF

Info

Publication number
CN116843069A
CN116843069A CN202310808160.8A CN202310808160A CN116843069A CN 116843069 A CN116843069 A CN 116843069A CN 202310808160 A CN202310808160 A CN 202310808160A CN 116843069 A CN116843069 A CN 116843069A
Authority
CN
China
Prior art keywords
commute
time
node
activity intensity
flow
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310808160.8A
Other languages
Chinese (zh)
Inventor
史清丽
卓莉
陶海燕
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sun Yat Sen University
Original Assignee
Sun Yat Sen University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sun Yat Sen University filed Critical Sun Yat Sen University
Priority to CN202310808160.8A priority Critical patent/CN116843069A/en
Publication of CN116843069A publication Critical patent/CN116843069A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/042Knowledge-based neural networks; Logical representations of neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/0464Convolutional networks [CNN, ConvNet]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/049Temporal neural networks, e.g. delay elements, oscillating neurons or pulsed inputs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Systems or methods specially adapted for specific business sectors, e.g. utilities or tourism
    • G06Q50/10Services
    • G06Q50/26Government or public services

Abstract

The invention relates to the technical field of urban crowd movement flow estimation and prediction, and discloses a commute flow estimation method and a commute flow estimation system based on crowd activity intensity characteristics.

Description

Commuting flow estimation method and system based on crowd activity intensity characteristics
Technical Field
The invention relates to the technical field of urban crowd mobile flow estimation and prediction, in particular to a commute flow estimation method and system based on crowd activity intensity characteristics.
Background
The commute flow refers to the daily average commute number from home to workplace, can represent the socioeconomic status of the city to a certain extent, reflects the city planning and traffic design level, and is an index of important attention of city residents, related management personnel, scientific researchers and the like. However, the commute flow is difficult to observe directly and is not easily estimated accurately. Improving the commute flow estimation method and increasing its estimation accuracy is an attractive and challenging research problem.
Two main methods represented by a space interaction model and a machine learning model are mainstream of commute flow estimation, and in recent years, with the rise of deep learning of a graph network, a graph convolution neural network model based on deep learning gradually becomes an important technical means for estimating the commute flow. However, these flow estimation methods still have the following disadvantages: 1) The spatial interaction model is derived from the laws of physics and aims to estimate the interaction strength between regions by the properties of the two regions and the interaction cost. Although the spatial interaction model has an easy-to-understand expression, it is difficult to describe complex nonlinear relationships between influencing factors and commute flows. 2) The commute flow model based on machine learning considers more regional socioeconomic and geographical landscape characteristics and the like besides population and distance factors, and utilizes methods such as gradient enhanced regression tree GBRT, random forest, artificial neural network and the like to construct a nonlinear relation between site characteristics and commute flow. Although the machine learning model improves the simulation capability of the nonlinear relation, the influence of the convection estimation of the adjacent area is difficult to be included, and when the machine learning model is applied to the fine space unit scale in the city, social and economic indexes such as employment, housing and the like which are necessary for the input of the model are difficult to be obtained and accurately quantized. 3) The deep learning based graph roll-up neural network model simulates the vicinity impact by establishing distances, topological relationships, or flow strengths between geographic cells. The technology improves the defect that a machine learning model is difficult to simulate an adjacent area, but the model has inconsistent contradiction of flow estimation methods in the training and prediction processes.
The prior art discloses a point location passenger flow prediction method based on point location fragment passenger flow, which specifically comprises the following steps: firstly, collecting offline data, including a large number of continuous long-period passenger flow samples of point positions, position information, site information, point position information, environment information, peripheral information, environment information, merchant brand information and the like; reconstructing a fragment passenger flow sample, and then carrying out data processing, feature engineering and model training; then collecting and constructing a fragment passenger flow video, and establishing a fragment video people counting model; and finally, predicting the expected daily passenger flow, the average daily passenger flow of the whole year and other passenger flow results sets of the required point location according to the input video sample and the time, the position, the place and other information of the acquired point location video. The invention adopts a mode of combining a machine learning regression algorithm and a deep learning algorithm, but the model has inconsistent contradiction of flow estimation methods in the training and prediction processes, and the data acquisition is difficult.
Disclosure of Invention
The purpose of the invention is that: the utility model provides a commute flow estimation method and system based on crowd activity intensity characteristics, which aims to solve the problems that a model in the prior art has inconsistent flow estimation methods and difficult data acquisition in the training and prediction processes.
In order to achieve the above object, the present invention provides a method for estimating commute traffic based on crowd activity intensity features, comprising:
s1, acquiring crowd activity intensity time sequence data, average commute duration data and commute flow data of a research area;
s2, dividing a research area into a plurality of grids with fixed sizes; preprocessing the crowd activity intensity time sequence data to obtain crowd activity intensity of each grid; preprocessing the average commute time length data to obtain the average commute time length among grids; respectively taking each grid as a graph node, taking the crowd activity intensity as a node characteristic, taking the average commute duration as an edge, and constructing a commute network graph;
s3, constructing a time chart attention network model, and training the time chart attention network model by using the commute flow data; the time chart attention network model is used for learning time characteristics of crowd activity intensity of the chart nodes and spatial structure characteristics of the chart nodes and outputting embedded vectors of the nodes;
s4, selecting a starting point and a terminal point on the commute network diagram, and learning time characteristics and space structure characteristics of crowd activity intensity of the starting point and the terminal point through a trained time diagram attention network model to obtain a starting point embedded vector and a terminal point embedded vector;
s5, taking the starting point embedded vector, the end point embedded vector and the distance characteristic between the starting point and the end point as input of a gradient enhancement regression tree method to obtain a commute flow estimated value between two places.
Preferably, in step S2, the process of preprocessing the time series data of crowd activity intensity is to store thermodynamic diagrams in a point format, wherein the point attribute field includes geographic longitude and latitude, time and the number of active users, the active users are selected to represent crowd activity intensity, thermodynamic diagrams of a plurality of working days are selected, each point is summarized to a grid according to a spatial relationship, and average values of the number of active users in different working days are obtained every hour;
the process of preprocessing the average commute duration data is to calculate the average commute duration between grids by calling a map API interface.
Preferably, in step S2, the investigation region is divided into N grids v of fixed size 1 ,v 2 ,…,v n The crowd activity intensity of the marking grid is act i ={act 1 ,act 2 ,…,act t ,act T Element act t The crowd activity intensity at the time t is represented; the commute flow is recorded as a triplet f= { (v) i ,v j ,f ij ) }, v is i Representing the origin residence, v j Representing the destination work place, f ij Representing commute flow, representing slave v i To v j Daily average commute number of (1), define in-flow and out-flow, and express in-flow as f :j Represents up to v j Total inflow commute number, out-flow is denoted as f i: Represents from v i The total commute number of people flowing out; the commute time period is marked as a triplet t= { (v) i ,v j ,t ij )},t ij Representing the slave v i To v j Average commute time length of commute of duty;
the commute network graph is a directed graph g= (V, T, a), where v= { V 1 ,v 2 ,…,v N -a set of grids as nodes of the graph; t= { T ij 1.ltoreq.i, j.gtoreq.N } is the set of commute durations, when t ij Satisfy condition 0<t ij Threshold value or less, representing node v i And v j There is an edge between, and the edge is characterized by t ij ;A={act 1 ,act 2 ,…,act N And is a set of crowd activity intensities as a node feature.
Preferably, in step S3, the time graph attention network model includes space-time convolution layers and time convolution layers, each space-time convolution layer is composed of one gating time convolution layer and one graph attention layer, each time convolution layer has only one gating time convolution layer, and the space-time convolution layers and the time convolution layers are alternately stacked.
Preferably, in step S3, the gating time convolution layer is used to learn the time characteristics of the crowd activity intensity; the chart attention layer is used for learning spatial structural features, wherein the spatial structural features are the spatial connection of all nodes of the commuting network chart; the time chart attention network model learns the time characteristics of the crowd activity intensity of the chart nodes and the spatial structure characteristics of the chart nodes through random initialization parameters to obtain embedded vectors of the nodes;
in step S4, estimating total outflow or total inflow of the starting point and the end point region and flow between the two regions by using a multi-task constraint learning strategy and a gradient enhancement regression tree method based on machine learning, and back-propagating a loss value obtained by calculation of an estimated value and a true value, obtaining optimal parameters of the time diagram attention network model by training the time diagram attention network model, and performing convolution operation of the matrix based on the optimal parameters and space-time dynamic characteristics of crowd activity intensity to obtain a starting point embedded vector and an end point embedded vector;
the process of training a time chart attention network model by utilizing a multi-task constraint learning strategy and a gradient enhancement regression tree method based on machine learning is to define the multi-task constraint learning strategy, define the multi-task constraint learning strategy as defining the estimated commute flow between two geographic units as a main task, define the inflow total amount in-flow of the estimated destination geographic unit and the outflow total amount out-flow of the starting geographic unit as two subtasks, and the total loss value of the model is the linear weighting of the loss values of the 3 tasks, wherein the total loss value is:
loss total =w main loss main +w sub loss in ++w sub loss out
wherein w is main 、w sub Respectively corresponding to the weights of the main task and the subtask, loss main 、loss in 、loss out Representing the loss value of the main task and the loss values of the two subtasks respectively,representing estimated commute flow,/->Represents the inflow total amount estimation value->Represents the estimated value of the total outflow quantity, f ij 、f : 、f i: Respectively representing real commute flow; by reversingThe total loss value is propagated to train the time diagram to pay attention to the parameters of the network model, so that a starting point embedded vector and an end point embedded vector are obtained.
Preferably, the time characteristic process of learning crowd activity intensity by using a gating time convolution layer is to select expansion causal convolution as the time convolution layer so as to learn the influence of the information characteristic of the historical crowd activity intensity on the current crowd activity intensity, adjust a convolution kernel and an expansion factor to increase a network receptive field and reduce the network layer number, and simultaneously, introduce a gating mechanism to control the utilization rate of the expansion causal convolution on the historical information;
the causal convolution of expansion is:
where act is a time series input, t represents a time step, f represents a convolution kernel, x represents a convolution operation, d is an expansion factor, and K is a convolution kernel size.
The causal convolution of dilation, which introduces gating mechanism control, consists of two causal convolutions of dilation:
A (l+1) =tanh(θ 1 A (l) +b)⊙σ(θ 2 A (l) +c)
wherein A represents a node crowd activity intensity feature matrix, l represents a first layer, theta 1 、θ 2 B and c represent the learning parameters of two causal convolutions of expansion, respectively, and by-represents the element multiplication mechanism, tanh (θ 1 A (l) +b) represents the activation of the causal convolution result of expansion, σ (θ) 2 A (l) +c) is a gating cell.
Preferably, the learning spatial structure features by using the attention layer of the graph comprise that the attention layer of the graph combines an attention mechanism in node aggregation operation, namely, different weights are distributed to different nodes of a neighborhood through the attention mechanism, then the node features are updated through aggregation, the weights are determined by the node features and the edge features of two connected nodes, and the two connected nodes are a central node and a neighborhood node.
Preferably, different weights are distributed to different nodes of the neighborhood through an attention mechanism, then the process of updating the node characteristics through aggregation is to perform linear transformation on the nodes and the edge characteristics for a graph attention layer, calculate attention scores of the neighborhood nodes, and perform normalization processing on the attention scores, wherein the formula is as follows:
in which W is (l) ∈R k×m And V (l) ∈R t×n Is a parameter matrix, z i Is the message vector to be passed to the neighbor, σ is a nonlinear activation function, ||represents the concatenation merge operation, a (l) ∈R (2k+t)×1 Is a trainable weight parameter vector of attention output, T represents a transpose,representing the attention score of neighborhood node j to center node i,/->To normalize the attention score, N (i) is the neighborhood node set for node i;
after the attention score of the node is obtained, the central node is aggregated to update the node characteristics, and the aggregation process comprises two parts, namely influence and self-influence of the neighborhood node, wherein the formula is as follows:
in the method, in the process of the invention,representing the node embedding vector of the node i at the (l+1) th, U (l) Is a parameter matrix->For normalizing the score->A message vector representing a neighbor node j.
Preferably, in step S5, the starting point embedding vector, the ending point embedding vector, and the distance feature between the starting point and the ending point are used as inputs of the gradient-enhanced regression tree method, and the formula for obtaining the estimated value of the commute flow between two places is as follows:
in the method, in the process of the invention,representing node i origin embedded vector,>representing node j endpoint embedding vector d ij Representing the distance between the start point i and the end point j.
The invention also provides a commute flow estimation system based on the crowd activity intensity characteristics, which comprises:
the data preprocessing module is used for acquiring and preprocessing crowd activity intensity time sequence data, average commute duration data and commute flow data of the working days of the research area and preprocessing the crowd activity intensity time sequence data, the average commute duration data and the commute flow data;
the chart construction module is used for constructing a commute network chart according to the preprocessed crowd activity intensity time sequence data and the preprocessed average commute duration data;
the graph node embedding learning module is used for alternately stacking a space-time convolution layer and a time convolution layer to construct a time graph attention network model, and combining a multitask constraint learning strategy and a gradient enhancement regression tree method based on machine learning to obtain a starting point embedding vector and an end point embedding vector;
and the commute flow prediction module is used for predicting and obtaining the commute flow according to the start point embedded vector, the end point embedded vector, the distance characteristic between the start point and the end point and the gradient enhancement regression tree method.
Compared with the prior art, the invention has the beneficial effects that: the input data adopts crowd activity intensity dynamic change data, has finer granularity of space-time resolution and is easier to acquire;
furthermore, the time graph attention network model can simultaneously consider the time and space dependence of the crowd activity intensity characteristics by combining space-time convolution and time convolution, and improves the accuracy of commute flow prediction by introducing a multi-task constraint learning strategy and adopting a unified flow estimation method in the training and prediction process.
Drawings
FIG. 1 is a flow chart of a method of commute flow estimation based on crowd activity intensity features in accordance with an embodiment of the invention;
FIG. 2 is a block diagram of a method of commute flow estimation based on crowd activity intensity features in accordance with an embodiment of the invention;
FIG. 3 is a schematic diagram of the structure of a time-diagram attention network model according to an embodiment of the present invention;
fig. 4 is a block diagram of a commute flow estimation system based on crowd activity intensity features in accordance with an embodiment of the invention.
In the figure, 101, a data preprocessing module; 102. a graph construction module; 103. the graph nodes are embedded into a learning module; 104. and a commute flow prediction module.
Detailed Description
The following describes in further detail the embodiments of the present invention with reference to the drawings and examples. The following examples are illustrative of the invention and are not intended to limit the scope of the invention.
In the description of the present invention, it should be noted that the terms "center", "longitudinal", "lateral", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, merely to facilitate description of the present invention and simplify the description, and do not indicate or imply that the apparatus or elements referred to must have a specific orientation, be configured and operated in a specific orientation, and therefore should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
In the description of the present invention, it should be noted that, unless explicitly specified and limited otherwise, the terms "mounted," "connected," and "connected" are to be construed broadly, and may be either fixedly connected, detachably connected, or integrally connected, for example; can be mechanically or electrically connected; can be directly connected or indirectly connected through an intermediate medium, and can be communication between two elements. The specific meaning of the above terms in the present invention will be understood in specific cases by those of ordinary skill in the art.
Furthermore, in the description of the present invention, unless otherwise indicated, the meaning of "a plurality" is two or more.
Example 1
As shown in fig. 1 and 2, a method for estimating commute traffic based on crowd activity intensity features according to a preferred embodiment of the present invention includes:
s1, acquiring crowd activity intensity time sequence data, average commute duration data and commute flow data of a research area;
s2, dividing a research area into a plurality of grids with fixed sizes; preprocessing the crowd activity intensity time sequence data to obtain crowd activity intensity of each grid; preprocessing the average commute time length data to obtain the average commute time length among grids; respectively taking each grid as a graph node, taking the crowd activity intensity as a node characteristic, taking the average commute duration as an edge, and constructing a commute network graph;
s3, constructing a time chart attention network model, and training the time chart attention network model by using the commute flow data; the time chart attention network model is used for learning time characteristics of crowd activity intensity of the chart nodes and spatial structure characteristics of the chart nodes and outputting embedded vectors of the nodes;
s4, selecting a starting point and a terminal point on the commute network diagram, and learning time characteristics and space structure characteristics of crowd activity intensity of the starting point and the terminal point through a trained time diagram attention network model to obtain a starting point embedded vector and a terminal point embedded vector;
s5, taking the starting point embedded vector, the end point embedded vector and the distance characteristic between the starting point and the end point as input of a gradient enhancement regression tree method to obtain a commute flow estimated value between two places.
In step S2, the process of preprocessing the time series data of the crowd activity intensity is to store the thermodynamic diagrams in a point format, wherein the point attribute field comprises geographic longitude and latitude, time and the number of active users, the active users are selected to represent the crowd activity intensity, the thermodynamic diagrams of a plurality of working days are selected, each point is summarized to a grid according to a spatial relationship, and the average value of the number of active users in different working days is obtained every hour;
the process of preprocessing the average commute duration data is to calculate the average commute duration between grids by calling a map application programming interface (Application Programming Interface, API).
In this embodiment, hundred-degree thermodynamic diagram data is taken as an example to represent dynamic changes of spatial distribution of activity intensity of people. The original hundred-degree thermodynamic diagram is stored in a point format, and the point attribute field comprises geographic longitude and latitude, time and the number of active users, and the active users are selected to represent the activity intensity of the crowd. In order to obtain the spatial distribution of the activity intensity of the crowd on average hours on a working day of a grid scale, hundred-degree thermodynamic diagrams on a plurality of working days are taken, each point is summarized to the grid according to a spatial relationship, and then the average value is taken for each hour on different working days. Acquiring and preprocessing average commute time length data to obtain average commute time length among grids, and calculating the commute time required by the grids by calling a hundred-degree map API interface; acquiring and preprocessing commute flow data to obtain commute flow data of a grid scale; the commute traffic data is provided by the mobile operator chinese UNICOM. Each row of data represents a pair of commute flows, the data fields including a grid id (residence/workplace), a commute duration, and a corresponding daily average commute number based on the extraction of the communication handset data. And summarizing the original commute flow to the corresponding grid scale according to the geographic coordinates of the grid center of the original commute flow in order to obtain the commute flow data of the grid scale.
For pretreated commute flow data, according to 6:2: the ratio of 2 is divided into a training set, a verification set and a test set randomly, wherein the training set and the verification set are used for training and verifying the training performance of the flow estimation model, and the test set is used for evaluating the prediction performance of the flow estimation model.
In step S2, the investigation region is divided into N grids v of fixed size 1 ,v 2 ,…,v n The crowd activity intensity of the marking grid is act i ={act 1 ,act 2 ,…,act t ,act T Element act t The crowd activity intensity at the time t is represented; the commute flow is recorded as a triplet f= { (v) i ,v j ,f ij ) }, v is i Representing the origin residence, v j Representing the destination work place, f ij Representing commute flow, representing slave v i To v j Daily average commute number of (1), define in-flow and out-flow, and express in-flow as f :j Represents up to v j Total inflow commute number, out-flow is denoted as f i: Represents from v i The total commute number of people flowing out; the commute time period is marked as a triplet t= { (v) i ,v j ,t ij )},t ij Representing the slave v i To v j Average commute time length of commute of duty;
in this embodiment, the city is divided into a plurality of grid geographic units with a fixed size, the time sequence of the activity intensity of the crowd in the grid is taken as the grid characteristic, and the average commute duration is used to represent the relationship between grids. And taking each grid as a graph node, taking the activity intensity of the dynamic crowd as a node characteristic, and taking the average commute duration as an edge of the graph.
The commute network graph is a directed graph g= (V, T, a), where v= { V 1 ,v 2 ,…,v N -a set of grids as nodes of the graph; t= { T ij 1.ltoreq.i, j.gtoreq.N } is the set of commute durations, when t ij Satisfy condition 0<t ij Threshold value or less, representing node v i And v j There is an edge between, and the edge is characterized by t ij ;A={act 1 ,act 2 ,…,act N And is a set of crowd activity intensities as a node feature.
Example two
The first difference between this embodiment and the first embodiment is that an integrated time convolution, graph meaning force and machine learning model (Temporal Graph Attention Network combined Machine Learning, TGAT-ML) is proposed, and a start point embedding vector and an end point embedding vector are obtained from both node space-time feature expression and node constraint. TGAT-ML firstly uses 2 time diagram attention network models (Temporal Graph Attention Network, TGAT) with the same structure to respectively learn the time-space dynamic characteristics of the activity intensity of the crowd of the geographic unit, and obtains the embedded vector of each node. TGAT consists of alternating stacks of spatiotemporal and temporal convolution layers, the temporal dependence of node features is learned by gated temporal convolution of the temporal convolution layer (Gated Temporal Convolutional Layer, GTCN), and the spatial dependence of node features is learned by spatial convolution map attention (Graph Attention Network, GAT) in the spatiotemporal convolution layer.
In step S3, as shown in fig. 3, the time graph attention network model includes spatiotemporal convolution layers and temporal convolution layers, each spatiotemporal convolution layer is composed of one gating time convolution layer and one graph attention layer, each temporal convolution layer has only one gating time convolution layer, and the spatiotemporal convolution layers and the temporal convolution layers are alternately stacked.
In step S3, the gating time convolution layer is used to learn the time characteristics of the crowd activity intensity; the chart attention layer is used for learning spatial structural features, wherein the spatial structural features are the spatial connection of all nodes of the commuting network chart; the time chart attention network model learns the time characteristics of the crowd activity intensity of the chart nodes and the spatial structure characteristics of the chart nodes through random initialization parameters to obtain embedded vectors of the nodes;
in step S4, estimating total outflow or total inflow of the starting point and the end point regions and flow between the two regions by using a multi-task constraint learning strategy and a gradient-enhanced regression tree method (Gradient Boosting Regressor Tree, GBRT) based on machine learning, and back-propagating a loss value calculated by the estimated value and a true value, obtaining optimal parameters of the time graph attention network model by training the time graph attention network model, and performing convolution operation of a matrix based on the optimal parameters and space-time dynamic characteristics of crowd activity intensity to obtain a starting point embedded vector and an end point embedded vector;
the process of training a time chart attention network model by utilizing a multi-task constraint learning strategy and a gradient enhancement regression tree method based on machine learning is to define the multi-task constraint learning strategy, define the multi-task constraint learning strategy as defining the estimated commute flow between two geographic units as a main task, define the inflow total amount in-flow of the estimated destination geographic unit and the outflow total amount out-flow of the starting geographic unit as two subtasks, and the total loss value of the model is the linear weighting of the loss values of the 3 tasks, wherein the total loss value is:
loss total =w main loss main +w sub loss in ++w sub loss out
wherein w is main 、w sub Respectively corresponding to the weights of the main task and the subtask, loss main 、loss in 、loss out Representing the loss value of the main task and the loss values of the two subtasks respectively,representing estimated commute flow,/->Represents the inflow total amount estimation value->Represents the estimated value of the total outflow quantity, f ij 、f : 、f i: Respectively representing real commute flow; the total loss value is back propagated to train the time diagram to pay attention to the parameters of the network model, so that a starting point embedded vector and an end point embedded vector are obtained.
Other structures of this embodiment are the same as those of the first embodiment, and will not be described here again.
Example III
The difference between the embodiment and the second embodiment is that the time characteristic process of learning the crowd activity intensity by using the gating time convolution layer is to select the expansion causal convolution as the time convolution layer so as to learn the influence of the historical crowd activity intensity information characteristic on the current crowd activity intensity, adjust the convolution kernel and the expansion factor to increase the network receptive field and reduce the network layer number, and simultaneously introduce the gating mechanism to control the utilization rate of the expansion causal convolution on the historical information;
the causal convolution of expansion is:
where act is a time series input, t represents a time step, f represents a convolution kernel, x represents a convolution operation, d is an expansion factor, and K is a convolution kernel size.
The causal convolution of dilation, which introduces gating mechanism control, consists of two causal convolutions of dilation:
A (l+1) =tanh(θ 1 A (l) +b)⊙σ(θ 2 A (l) +c)
wherein A represents a node crowd activity intensity feature matrix, l represents a first layer, theta 1 、θ 2 B and c represent the learning parameters of two causal convolutions of expansion, respectively, and by-represents the element multiplication mechanism, tanh (θ 1 A (l) +b) represents the activation of the causal convolution result of expansion, σ (θ) 2 A (l) +c) is a gating cell.
The method comprises the steps of utilizing a graph attention layer to learn spatial structure characteristics, wherein the graph attention layer combines an attention mechanism in node aggregation operation, namely, firstly, different weights are distributed to different nodes of a neighborhood through the attention mechanism, then, node characteristics are updated through aggregation, the weights are determined by node characteristics and edge characteristics of two connecting nodes, and the two connecting nodes are a center node and a neighborhood node.
Assume that the central node i is characterized at the first level byThe domain node of node i is denoted as node j, and the edges of node i and node j are characterized as e ij ∈R n×1 . Firstly, different weights are distributed to different nodes of a neighborhood through an attention mechanism, then, the linear transformation is carried out on the nodes and the edge characteristics for a graph attention layer through the process of updating the node characteristics through aggregation, the attention score of the neighborhood nodes is calculated, and normalization processing is carried out on the neighborhood nodes, wherein the formula is as follows:
in which W is (l) ∈R k×m And V (l) ∈R t×n Is a parameter matrix, z i Is the message vector to be passed to the neighbor, σ is a nonlinear activation function, ||represents the concatenation merge operation, a (l) ∈R (2k+t)×1 Is a trainable weight parameter vector of attention output, T represents a transpose,representing the attention score of neighborhood node j to center node i,/->To normalize the attention score, N (i) is the neighborhood node set for node i;
after the attention score of the node is obtained, the central node is aggregated to update the node characteristics, and the aggregation process comprises two parts, namely influence and self-influence of the neighborhood node, wherein the formula is as follows:
in the method, in the process of the invention,node embedded vector representing node i at the (l+1) th, u (l) Is a parameter matrix->For normalizing the score->A message vector representing a neighbor node j.
In this embodiment, to obtain the flow estimation value between two geographic units, the gradient-enhanced regression tree GBRT method based on machine learning ML embeds the start point embedding vector, the end point embedding vector and the distance feature d of the start point and the end point ij As the input of GBRT, two-place estimated values are obtained; in order to obtain the inflow total amount of the end point area and the outflow total amount estimated value of the start point area, the node embedded vector is obtained by linear transformation by using a linear transformation function.
After the best node embedding expression is obtained, the commute flow is predicted by the same method as the node embedding learning. That is, any two geographical areas are selected and used as home and workplace, their embedded vectors and their distances are combined together as input to GBRT regression, generating the commute traffic between the geographical areas and between.
In step S5, two nodes i and j are selected as the start point and end point regions based on the trained node embedding vector, and the start point embedding vector, the end point embedding vector, and the distance feature d between the start point and the end point are calculated ij As input to the gradient-enhanced regression tree method, the formula for obtaining the commute flow estimate between two places is:
in the method, in the process of the invention,representing node i origin embedded vector,>representing node j endpoint embedding vector d ij Representing the distance between the start point i and the end point j.
Other structures of this embodiment are the same as those of the embodiment, and will not be described here again.
Example IV
As shown in fig. 4, the present invention further provides a commute flow estimation system based on crowd activity intensity features, including:
the data preprocessing module 101 is used for acquiring and preprocessing crowd activity intensity time sequence data, average commute duration data and commute flow data of a working day of a research area and preprocessing the crowd activity intensity time sequence data, the average commute duration data and the commute flow data;
the diagram construction module 102 is configured to construct a commute network diagram according to the preprocessed crowd activity intensity time series data and the preprocessed average commute duration data;
the graph node embedding learning module 103 is used for alternately stacking a space-time convolution layer and a time convolution layer to construct a time graph attention network model, and combining a multitask constraint learning strategy and a gradient enhancement regression tree method based on machine learning to obtain a starting point embedding vector and an end point embedding vector;
the commute flow prediction module 104 is configured to predict and obtain the commute flow according to the start point embedding vector, the end point embedding vector, the distance characteristic between the start point and the end point, and the gradient enhancement regression tree method.
The working process of the invention is as follows:
s1, acquiring crowd activity intensity time sequence data, average commute duration data and commute flow data of a research area;
s2, dividing a research area into a plurality of grids with fixed sizes; preprocessing the crowd activity intensity time sequence data to obtain crowd activity intensity of each grid; preprocessing the average commute time length data to obtain the average commute time length among grids; respectively taking each grid as a graph node, taking the crowd activity intensity as a node characteristic, taking the average commute duration as an edge, and constructing a commute network graph;
s3, constructing a time chart attention network model, and training the time chart attention network model by using the commute flow data; the time chart attention network model is used for learning time characteristics of crowd activity intensity of the chart nodes and spatial structure characteristics of the chart nodes and outputting embedded vectors of the nodes;
s4, selecting a starting point and a terminal point on the commute network diagram, and learning time characteristics and space structure characteristics of crowd activity intensity of the starting point and the terminal point through a trained time diagram attention network model to obtain a starting point embedded vector and a terminal point embedded vector;
s5, taking the starting point embedded vector, the end point embedded vector and the distance characteristic between the starting point and the end point as input of a gradient enhancement regression tree method to obtain a commute flow estimated value between two places.
In summary, the embodiment of the invention provides a commute flow estimation method and a system based on crowd activity intensity characteristics, and the proposed time diagram attention network model can simultaneously consider time and space dependence of the crowd activity intensity characteristics by combining space-time convolution and time convolution, improves accuracy of commute flow prediction by introducing a multi-task constraint learning strategy and adopting a unified flow estimation method in training and predicting processes by the model, and has finer granularity of space-time resolution and easier acquisition by adopting crowd activity intensity dynamic change data as input data.
The foregoing is merely a preferred embodiment of the present invention, and it should be noted that modifications and substitutions can be made by those skilled in the art without departing from the technical principles of the present invention, and these modifications and substitutions should also be considered as being within the scope of the present invention.

Claims (10)

1. A commute flow estimation method based on crowd activity intensity characteristics, comprising:
s1, acquiring crowd activity intensity time sequence data, average commute duration data and commute flow data of a research area;
s2, dividing a research area into a plurality of grids with fixed sizes; preprocessing the crowd activity intensity time sequence data to obtain crowd activity intensity of each grid; preprocessing the average commute time length data to obtain the average commute time length among grids; respectively taking each grid as a graph node, taking the crowd activity intensity as a node characteristic, taking the average commute duration as an edge, and constructing a commute network graph;
s3, constructing a time chart attention network model, and training the time chart attention network model by using the commute flow data; the time chart attention network model is used for learning time characteristics of crowd activity intensity of the chart nodes and spatial structure characteristics of the chart nodes and outputting embedded vectors of the nodes;
s4, selecting a starting point and a terminal point on the commute network diagram, and learning time characteristics and space structure characteristics of crowd activity intensity of the starting point and the terminal point through a trained time diagram attention network model to obtain a starting point embedded vector and a terminal point embedded vector;
s5, taking the starting point embedded vector, the end point embedded vector and the distance characteristic between the starting point and the end point as input of a gradient enhancement regression tree method to obtain a commute flow estimated value between two places.
2. The method for commute traffic estimation based on crowd activity intensity features of claim 1, wherein: in step S2, the process of preprocessing the time series data of the crowd activity intensity is to store the thermodynamic diagrams in a point format, wherein the point attribute field comprises geographic longitude and latitude, time and the number of active users, the active users are selected to represent the crowd activity intensity, the thermodynamic diagrams of a plurality of working days are selected, each point is summarized to a grid according to a spatial relationship, and the average value of the number of active users in different working days is obtained every hour;
the process of preprocessing the average commute duration data is to calculate the average commute duration between grids by calling a map API interface.
3. The method for commute traffic estimation based on crowd activity intensity features of claim 1, wherein: in step S2, the investigation region is divided into N grids v of fixed size 1 ,v 2 ,....,v n The crowd activity intensity of the marking grid is act i ={act 1 ,act 2 ,...,act t ,act T Element act t The crowd activity intensity at the time t is represented; the commute flow is recorded as a triplet f= { (v) i ,v j ,f ij ) }, v is i Representing the origin residence, v j Representing the destination work place, f ij Representing commute flow, representing slave v i To v j Daily average commute number of (1), define in-flow and out-flow, and express in-flow as f :j Represents up to v j Total inflow commute number, out-flow is denoted as f i: Represents from v i The total commute number of people flowing out; the commute time period is marked as a triplet t= { (v) i ,v j ,t ij )},t ij Representing the slave v i To v j Average commute time length of commute of duty;
the commute network graph is a directed graph g= (V, T, a), where v= { V 1 ,v 2 ,...,v N -a set of grids as nodes of the graph; t= { T ij 1.ltoreq.i, j.gtoreq.N } is the set of commute durations, when t ij Satisfy the condition 0 < t ij Threshold value or less, representing node v i And v j There is an edge between, and the edge is characterized by t ij ;A={act 1 ,act 2 ,...,act N And is a set of crowd activity intensities as a node feature.
4. The method for commute traffic estimation based on crowd activity intensity features of claim 1, wherein: in step S3, the time graph attention network model includes spatiotemporal convolution layers and temporal convolution layers, each spatiotemporal convolution layer is composed of a gating time convolution layer and a graph attention layer, each temporal convolution layer has only one gating time convolution layer, and the spatiotemporal convolution layers and the temporal convolution layers are alternately stacked.
5. The method for commute traffic estimation based on crowd activity intensity features of claim 1, wherein: in step S3, the gating time convolution layer is used to learn the time characteristics of the crowd activity intensity; the chart attention layer is used for learning spatial structural features, wherein the spatial structural features are the spatial connection of all nodes of the commuting network chart; the time chart attention network model learns the time characteristics of the crowd activity intensity of the chart nodes and the spatial structure characteristics of the chart nodes through random initialization parameters to obtain embedded vectors of the nodes;
in step S4, estimating total outflow or total inflow of the starting point and the end point region and flow between the two regions by using a multi-task constraint learning strategy and a gradient enhancement regression tree method based on machine learning, and back-propagating a loss value obtained by calculation of an estimated value and a true value, obtaining optimal parameters of the time diagram attention network model by training the time diagram attention network model, and performing convolution operation of the matrix based on the optimal parameters and space-time dynamic characteristics of crowd activity intensity to obtain a starting point embedded vector and an end point embedded vector;
the process of training a time chart attention network model by utilizing a multi-task constraint learning strategy and a gradient enhancement regression tree method based on machine learning is to define the multi-task constraint learning strategy, define the multi-task constraint learning strategy as defining the estimated commute flow between two geographic units as a main task, define the inflow total amount in-flow of the estimated destination geographic unit and the outflow total amount out-flow of the starting geographic unit as two subtasks, and the total loss value of the model is the linear weighting of the loss values of the 3 tasks, wherein the total loss value is:
loss total =w main loss main +w sub loss in ++w sub loss out
wherein w is main 、w sub Respectively corresponding to the weights of the main task and the subtask, loss main 、loss in 、loss out Representing the loss value of the main task and the loss values of the two subtasks respectively,representing estimated commute flow,/->Represents the inflow total amount estimation value->Represents the estimated value of the total outflow quantity, f ij 、f :j 、f i: Respectively representing real commute flow; the total loss value is back propagated to train the time diagram to pay attention to the parameters of the network model, so that a starting point embedded vector and an end point embedded vector are obtained.
6. The method for commute traffic estimation based on crowd activity intensity features of claim 5, wherein: the time characteristic process of learning crowd activity intensity by using a gating time convolution layer is to select expansion causal convolution as the time convolution layer so as to learn the influence of the information characteristic of the historical crowd activity intensity on the current crowd activity intensity, adjust a convolution kernel and an expansion factor to increase a network receptive field and reduce the network layer number, and simultaneously introduce a gating mechanism to control the utilization rate of the expansion causal convolution on the historical information;
the causal convolution of expansion is:
where act is a time series input, t represents a time step, f represents a convolution kernel, x represents a convolution operation, d is an expansion factor, and K is a convolution kernel size.
The causal convolution of dilation, which introduces gating mechanism control, consists of two causal convolutions of dilation:
A (l+1) =tanh(θ 1 A (l) +b)⊙σ(θ 2 A (l) +c)
wherein A represents node crowd activityIntensity feature matrix, l represents layer I, θ 1 、θ 2 B and c represent the learning parameters of two causal convolutions of expansion, respectively, and by-represents the element multiplication mechanism, tanh (θ 1 A (l) +b) represents the activation of the causal convolution result of expansion, σ (θ) 2 A (l) +c) is a gating cell.
7. The method for commute traffic estimation based on crowd activity intensity features of claim 5, wherein: the method comprises the steps of utilizing a graph attention layer to learn spatial structure characteristics, wherein the graph attention layer combines an attention mechanism in node aggregation operation, namely, firstly, different weights are distributed to different nodes of a neighborhood through the attention mechanism, then, node characteristics are updated through aggregation, the weights are determined by node characteristics and edge characteristics of two connecting nodes, and the two connecting nodes are a center node and a neighborhood node.
8. The method for commute traffic estimation based on crowd activity intensity features of claim 7, wherein: firstly, different weights are distributed to different nodes of a neighborhood through an attention mechanism, then, the linear transformation is carried out on the nodes and the edge characteristics for a graph attention layer through the process of updating the node characteristics through aggregation, the attention score of the neighborhood nodes is calculated, and normalization processing is carried out on the neighborhood nodes, wherein the formula is as follows:
in which W is (l) ∈R k×m And V (l) ∈R t×n Is a parameter matrix, z i Is the message vector to be passed to the neighbor, σ is a nonlinear activation function, ||represents the concatenation merge operation, a (l) ∈R (2k+t)×1 Is a trainable weight parameter vector of attention output, T represents a transpose,representing the attention score of neighborhood node j to center node i,/->To normalize the attention score, N (i) is the neighborhood node set for node i;
after the attention score of the node is obtained, the central node is aggregated to update the node characteristics, and the aggregation process comprises two parts, namely influence and self-influence of the neighborhood node, wherein the formula is as follows:
in the method, in the process of the invention,representing node i embedded vector at 1+1st node, U (l) Is a parameter matrix->In order to normalize the score,a message vector representing a neighbor node j.
9. The method for commute traffic estimation based on crowd activity intensity features of claim 1, wherein: in step S5, the starting point embedding vector, the ending point embedding vector, and the distance features between the starting point and the ending point are used as inputs of the gradient-enhanced regression tree method, and the formula for obtaining the estimated value of the commute flow between two places is as follows:
in the method, in the process of the invention,representing node i origin embedded vector,>representing node j endpoint embedding vector d ij Representing the distance between the start point i and the end point j.
10. A commute flow estimation system based on crowd activity intensity characteristics, comprising:
the data preprocessing module is used for acquiring and preprocessing crowd activity intensity time sequence data, average commute duration data and commute flow data of the working days of the research area and preprocessing the crowd activity intensity time sequence data, the average commute duration data and the commute flow data;
the chart construction module is used for constructing a commute network chart according to the preprocessed crowd activity intensity time sequence data and the preprocessed average commute duration data;
the graph node embedding learning module is used for alternately stacking a space-time convolution layer and a time convolution layer to construct a time graph attention network model, and combining a multitask constraint learning strategy and a gradient enhancement regression tree method based on machine learning to obtain a starting point embedding vector and an end point embedding vector;
and the commute flow prediction module is used for predicting and obtaining the commute flow according to the start point embedded vector, the end point embedded vector, the distance characteristic between the start point and the end point and the gradient enhancement regression tree method.
CN202310808160.8A 2023-07-03 2023-07-03 Commuting flow estimation method and system based on crowd activity intensity characteristics Pending CN116843069A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310808160.8A CN116843069A (en) 2023-07-03 2023-07-03 Commuting flow estimation method and system based on crowd activity intensity characteristics

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310808160.8A CN116843069A (en) 2023-07-03 2023-07-03 Commuting flow estimation method and system based on crowd activity intensity characteristics

Publications (1)

Publication Number Publication Date
CN116843069A true CN116843069A (en) 2023-10-03

Family

ID=88159525

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310808160.8A Pending CN116843069A (en) 2023-07-03 2023-07-03 Commuting flow estimation method and system based on crowd activity intensity characteristics

Country Status (1)

Country Link
CN (1) CN116843069A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117809203A (en) * 2024-02-28 2024-04-02 南京信息工程大学 Multi-task continuous learning cross-sea area tropical cyclone strength estimation method
CN117809203B (en) * 2024-02-28 2024-05-14 南京信息工程大学 Multi-task continuous learning cross-sea area tropical cyclone strength estimation method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117809203A (en) * 2024-02-28 2024-04-02 南京信息工程大学 Multi-task continuous learning cross-sea area tropical cyclone strength estimation method
CN117809203B (en) * 2024-02-28 2024-05-14 南京信息工程大学 Multi-task continuous learning cross-sea area tropical cyclone strength estimation method

Similar Documents

Publication Publication Date Title
Liu et al. Dynamic spatial-temporal representation learning for traffic flow prediction
Liu et al. Contextualized spatial–temporal network for taxi origin-destination demand prediction
CN104239556B (en) Adaptive trajectory predictions method based on Density Clustering
CN110991713B (en) Irregular area flow prediction method based on multi-graph convolution sum GRU
CN109190795B (en) Inter-area travel demand prediction method and device
CN109508360B (en) Geographical multivariate stream data space-time autocorrelation analysis method based on cellular automaton
CN106780089B (en) Permanent basic farmland planning method based on neural network cellular automaton model
CN108172301A (en) A kind of mosquito matchmaker&#39;s epidemic Forecasting Methodology and system based on gradient boosted tree
CN112532439A (en) Network flow prediction method based on attention multi-component space-time cross-domain neural network model
CN108108808A (en) A kind of position predicting method and device based on depth belief network
CN110070144A (en) A kind of lake water quality prediction technique and system
CN108537691A (en) A kind of region visit intelligent management system and method
CN110310479A (en) A kind of Forecast of Urban Traffic Flow forecasting system and method
CN115204478A (en) Public traffic flow prediction method combining urban interest points and space-time causal relationship
CN110267292A (en) Cellular network method for predicting based on Three dimensional convolution neural network
CN113762595B (en) Traffic time prediction model training method, traffic time prediction method and equipment
CN112954623B (en) Resident occupancy rate estimation method based on mobile phone signaling big data
CN112766600A (en) Urban area crowd flow prediction method and system
Dai et al. Spatio-temporal deep learning framework for traffic speed forecasting in IoT
CN112926256A (en) Soil heavy metal content prediction method and system based on deep reinforcement learning
Shiri et al. Forecasting daily stream flows using artificial intelligence approaches
Zhang et al. Graph-based traffic forecasting via communication-efficient federated learning
Leprêtre et al. Fitness landscapes analysis and adaptive algorithms design for traffic lights optimization on SIALAC benchmark
CN117217779A (en) Training method and device of prediction model and information prediction method and device
CN107180286A (en) Manufacturing service supply chain optimization method and system based on modified pollen algorithm

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination