Cross-modal transferable population travel demand prediction method and device

Through the pre-processing and analysis of multimodal transportation demand data, a travel demand prediction model is generated, which solves the sampling deviation problem caused by single mode data and improves the accuracy of population travel demand prediction.

CN119648269AActive Publication Date: 2025-03-18SHENZHEN UNIV
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202411672478.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-21
Publication Date
2025-03-18
Estimated Expiration
2044-11-21

AI Technical Summary

Technical Problem

The existing population travel demand forecasting method relies on single mode travel data, which leads to the prediction model that can only reflect the travel behavior of a specific group and cannot reflect the travel behavior of other groups other than that group. There is sampling bias, resulting in inaccurate prediction results.

Method used

By acquiring and preprocessing a variety of transportation demand data (bus, subway, taxi), a transportation demand characteristic matrix is ​​generated, and inputting it into the travel demand prediction model for analysis and processing to output the prediction results.

Benefits of technology

Through multimodal transportation demand data, the full amount of population travel demand data is predicted, and the sampling deviation caused by single mode data is overcome, and the accuracy of prediction results is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119648269A_ABST
    Figure CN119648269A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of traffic planning. The invention discloses a cross-modal transferable population travel demand prediction method and device, which can improve the accuracy of the total population travel demand. The cross-modal transferable population travel demand prediction method comprises the steps of obtaining bus travel demand data, subway travel demand data and taxi travel demand data of a to-be-predicted area; preprocessing the bus travel demand data, the subway travel demand data and the taxi travel demand data to obtain a traffic travel demand feature matrix; and inputting the traffic travel demand characteristic matrix into a travel demand prediction model, analyzing the traffic travel demand characteristic matrix by the travel demand prediction model, and outputting a prediction result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of traffic planning, and more specifically, to a method and device for predicting population travel demand that is cross-modal and transferable. Background Art

[0002] The prediction of population travel demand refers to the prediction of people's travel demand in a specific area in the future. Most of the current population travel demand prediction methods use deep neural networks to model a single historical travel time series (such as bus card swiping data, taxi travel data or shared bicycle usage data) in a specific area to obtain a prediction model, and then use the prediction model to predict the full amount of population travel data (that is, the prediction result) in the specific area. However, this method still has shortcomings. Specifically, the formation of the prediction model used in this method relies on single-mode travel data (that is, one of the travel data of bus card swiping data, taxi travel data or shared bicycle usage data), so that the prediction model can only reflect the travel behavior of a specific group in the specific area, and cannot reflect the travel behavior of other groups except the specific group. Therefore, the prediction model has a sampling bias, which makes the prediction result of this method inaccurate and difficult to reflect the full amount of population travel demand. Summary of the invention

[0003] The purpose of the embodiment of the present application is to provide a cross-modal and transferable population travel demand prediction method and device, which can improve the accuracy of the total amount of population travel demand. The embodiment of the present application is mainly achieved through the following technical solutions:

[0004] In a first aspect of an embodiment of the present application, a cross-modal and transferable population travel demand prediction method is provided, comprising:

[0005] Obtain bus travel demand data, subway travel demand data and taxi travel demand data for the area to be predicted;

[0006] Preprocessing the bus travel demand data, the subway travel demand data, and the taxi travel demand data to obtain a traffic travel demand characteristic matrix;

[0007] The traffic travel demand characteristic matrix is ​​input into a travel demand prediction model, and the travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs a prediction result.

[0008] According to an embodiment of the present application, the step of preprocessing the bus travel demand data, the subway travel demand data, and the taxi travel demand data to obtain a traffic travel demand characteristic matrix includes:

[0009] Performing a elimination operation on the public transportation travel demand data to obtain first data to be processed;

[0010] Extract all boarding station information and boarding time information corresponding to each boarding station information from the first data to be processed to obtain second data to be processed;

[0011] Performing a elimination operation on the subway travel demand data to obtain third data to be processed;

[0012] Extract all the station entry position information and the station entry time information corresponding to each of the station entry position information from the third data to be processed to obtain fourth data to be processed;

[0013] Performing a elimination operation on the taxi travel demand data to obtain fifth data to be processed;

[0014] Extract all departure location information and departure time information corresponding to each departure location information from the fifth data to be processed to obtain sixth data to be processed;

[0015] Generate a total demand feature matrix based on the second data to be processed, the fourth data to be processed, and the sixth data to be processed;

[0016] The traffic travel demand characteristic matrix is ​​extracted from the total demand characteristic matrix using a time window splitting method.

[0017] According to one embodiment of the present application, the step of generating a total demand feature matrix based on the second data to be processed, the fourth data to be processed, and the sixth data to be processed includes:

[0018] Generate a first feature matrix to be processed based on the second data to be processed, the fourth data to be processed and the sixth data to be processed;

[0019] All elements in the first feature matrix to be processed are connected according to the time dimension to obtain the total demand feature matrix.

[0020] According to an embodiment of the present application, the step of extracting the traffic travel demand characteristic matrix from the total demand characteristic matrix by using a time window splitting method includes:

[0021] Set the length of the first sliding window;

[0022] Setting the step size of the first sliding window;

[0023] The traffic travel demand characteristic matrix is ​​extracted from the total demand characteristic matrix based on the length and the step size.

[0024] According to one embodiment of the present application, the training step of the travel demand prediction model includes:

[0025] Obtain bus training data set, subway training data set, taxi training data set and label data set;

[0026] Preprocessing the target bus training data, the target subway training data, and the target taxi training data to obtain a traffic training feature matrix, wherein the target bus training data is any element in the bus training data set, the target subway training data is an element in the subway training data set that belongs to the same time series as the target bus training data, and the target taxi training data is an element in the taxi training data set that belongs to the same time series as the target bus training data;

[0027] The traffic training feature matrix is ​​input into a recurrent neural network model, and the recurrent neural network model analyzes and processes the traffic training feature matrix and outputs a training result;

[0028] Calculate a first loss function based on the training result and the label data set;

[0029] The first model parameter of the recurrent neural network model is adjusted based on the first loss function to form the travel demand prediction model.

[0030] According to one embodiment of the present application, the calculation formula of the first loss function is:

[0031]

[0032] in, is the first loss function, θ pred is the first model parameter, K is the K most dissimilar time series, j = 1, 2, ..., K, is the length of the jth time series, is the square error loss function, is the label value of the i-th time step in the j-th time series in the label data set, is the training result (i.e., the output result of the recurrent neural network model), is the feature vector of the i-th time step of the j-th time series in the traffic training feature matrix.

[0033] According to one embodiment of the present application, after the step of adjusting the first model parameter of the recurrent neural network model based on the first loss function, the step of training the travel demand prediction model further includes:

[0034] Set the importance vector;

[0035] constructing a second loss function based on the importance vector;

[0036] A second model parameter of the travel demand prediction model is adjusted based on the second loss function.

[0037] A second aspect of the embodiment of the present application provides a cross-modal and transferable population travel demand prediction device, comprising:

[0038] An acquisition module is used to acquire bus travel demand data, subway travel demand data and taxi travel demand data in the area to be predicted;

[0039] A traffic travel demand characteristic matrix obtaining module is used to pre-process the bus travel demand data, the subway travel demand data and the taxi travel demand data to obtain a traffic travel demand characteristic matrix;

[0040] The prediction result output module is used to input the traffic travel demand characteristic matrix into the travel demand prediction model, and the travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs the prediction result.

[0041] According to a third aspect of an embodiment of the present application, a terminal device is provided, including: a processor and a memory, the memory being used to store a computer program, the processor being used to call and run the computer program stored in the memory, and executing the steps of the cross-modal and transferable population travel demand prediction method provided in the first aspect of the embodiment of the present application.

[0042] According to the fourth aspect of the embodiments of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium is used to store a computer program, wherein the computer program enables a computer to execute the steps of the cross-modal and transferable population travel demand forecasting method provided in the first aspect of the embodiments of the present application.

[0043] The beneficial effects of the embodiments of the present application include:

[0044] The embodiment of the present application predicts the total amount of population travel demand data by using multimodal transportation travel demand data. Specifically, the embodiment of the present application uses the bus travel demand data, subway travel demand data and taxi travel demand data of the area to be predicted as basic data, and pre-processes these basic data to obtain the transportation travel demand characteristic matrix, which is used as the input of the travel demand prediction model. After the transportation travel demand characteristic matrix is ​​analyzed and processed by the travel demand prediction model, the prediction result is output, which is the total amount of population travel demand data. Therefore, the multimodal transportation travel demand data in the embodiment of the present application can overcome the sampling bias phenomenon caused by the single-modal transportation travel demand data in the prior art, thereby improving the accuracy of the prediction results, that is, improving the accuracy of predicting the total amount of population travel demand. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the conventional technology, the drawings required for use in the embodiments or the conventional technology descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0046] Figure 1 A flowchart of the cross-modal and transferable population travel demand prediction method of the present application in some embodiments;

[0047] Figure 2 A principle block diagram of the cross-modal and portable population travel demand prediction device of the present application in some embodiments;

[0048] Figure 3 This is a functional block diagram of the terminal device of the present application in some embodiments. DETAILED DESCRIPTION

[0049] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are described in detail below in conjunction with the accompanying drawings. In the following description, many specific details are set forth to facilitate a full understanding of the present application. However, the present application can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without violating the connotation of the present application, so the present application is not limited by the specific embodiments disclosed below.

[0050] It should be noted that the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0051] The terms "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0052] The terms "comprises," "includes," or any other variations thereof are intended to cover a non-exclusive inclusion, for example, a process, method, system, product, or apparatus that comprises a series of steps or elements is not necessarily limited to those steps or elements explicitly listed but may include other steps or elements not explicitly listed or inherent to such process, method, product, or apparatus.

[0053] Unless otherwise defined, all technical and scientific terms used in the specification of this application have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "and / or" used in the specification of this application includes any and all combinations of one or more related listed items.

[0054] The specific implementation of the present application is further described below in conjunction with the accompanying drawings.

[0055] <Cross-modal transferable population travel demand prediction method>

[0056] like Figure 1 FIG. 1 is a flowchart of a method for predicting population travel demand that can be transferred across modalities according to the first aspect of the embodiment of the present application. Figure 1 In the above, the cross-modal transferable population travel demand prediction method includes:

[0057] S1. Obtain bus travel demand data, subway travel demand data and taxi travel demand data for the area to be predicted.

[0058] The public transportation travel demand data includes boarding station information for all first users in the predicted area, boarding time information corresponding to each boarding station information, alighting station information, and alighting time information corresponding to each alighting station information.

[0059] The first user is a user who takes public transportation in the area to be predicted.

[0060] The public transportation travel demand data is derived from public transportation card swiping data and GPS data. In other implementations, it can also be obtained through other data sources such as traffic surveys.

[0061] The subway travel demand data includes the entry position information of all second users in the predicted area who take the subway, the entry time information corresponding to each entry position information, the exit position information, and the exit time information corresponding to each exit position information.

[0062] The second user is a user who takes the subway in the area to be predicted.

[0063] The subway travel demand data is derived from subway card swiping records. In other implementations, the data can also be obtained through other data sources such as traffic surveys.

[0064] The taxi travel demand data includes the departure location information of all third users taking taxis in the predicted area, the departure time information corresponding to each of the departure location information, the destination point information, the arrival time information corresponding to each of the destination point information, and the service status information corresponding to the departure time information or the arrival time information.

[0065] The third user is a user who takes a taxi in the area to be predicted.

[0066] The taxi travel demand data is derived from the GPS data set of the taxis. In other implementations, the data can also be obtained through other data sources such as traffic surveys.

[0067] In other implementations, the data used in the embodiments of the present application are not limited to the bus travel demand data, the subway travel demand data, and the taxi travel demand data, and these data can be changed according to different usage scenarios.

[0068] S2. Preprocess the bus travel demand data, the subway travel demand data, and the taxi travel demand data to obtain a traffic travel demand characteristic matrix.

[0069] Furthermore, the S2 step includes:

[0070] S21. Perform a elimination operation on the public transportation travel demand data to obtain first data to be processed.

[0071] Furthermore, the elimination operation on the public transportation travel demand data refers to eliminating the boarding station information without corresponding boarding time information or the boarding time information without corresponding boarding station information in the public transportation travel demand data.

[0072] S22. Extract all the boarding station information and the boarding time information corresponding to each of the boarding station information from the first data to be processed to obtain second data to be processed.

[0073] It should be understood that the second data to be processed only includes all the boarding station information and the boarding time information corresponding to each of the boarding station information in the first data to be processed, and does not include the alighting station information and the alighting time information corresponding to each of the alighting station information.

[0074] S23: performing a elimination operation on the subway travel demand data to obtain third data to be processed.

[0075] Furthermore, the elimination operation on the subway travel demand data refers to eliminating the entry position information without corresponding entry time information or the entry time information without corresponding entry position information in the subway travel demand data.

[0076] S24, extracting all the station entry position information and the station entry time information corresponding to each station entry position information from the third data to be processed, to obtain fourth data to be processed.

[0077] It should be understood that the fourth data to be processed only includes all the entry position information and the entry time information corresponding to each entry position information in the third data to be processed, and does not include the exit position information and the exit time information corresponding to each exit position information.

[0078] S25. Perform a elimination operation on the taxi travel demand data to obtain fifth data to be processed.

[0079] Furthermore, the elimination operation on the taxi travel demand data refers to eliminating the departure location information without corresponding departure time information, the service status information without corresponding departure time information, and the departure location information without corresponding service status information in the taxi travel demand data.

[0080] Furthermore, the embodiment of the present application adopts a state change identification mechanism to set the service state information. For example, when the taxi is in an idle state (that is, the taxi does not have the departure time information), the service state information is set to 0; when the taxi is in a service state (that is, the taxi has the departure time information), the service state information is set to 1. It should be understood that if the taxi trip has not started, it is in an idle state; if the taxi trip has started, it is in a service state.

[0081] S26. Extract all departure location information and departure time information corresponding to each departure location information from the fifth data to be processed to obtain sixth data to be processed.

[0082] The sixth data to be processed only includes all the departure location information in the fifth data to be processed and the departure time information corresponding to each of the departure location information, that is, the departure location and time of each taxi trip.

[0083] S27. Generate a total demand feature matrix based on the second data to be processed, the fourth data to be processed, and the sixth data to be processed.

[0084] Furthermore, the step S27 includes:

[0085] S271. Generate a first feature matrix to be processed based on the second data to be processed, the fourth data to be processed, and the sixth data to be processed.

[0086] More specifically, the step S271 includes:

[0087] S2711. Divide the area to be predicted into a plurality of first traffic cells using a spatial division method. In an embodiment of the present application, the area to be predicted is divided into 1386 first traffic cells based on a Voronoi (Thyssen polygon) diagram of the main roads in the area to be predicted. In other embodiments, the spatial division method is not limited to the above-mentioned method of dividing using a Voronoi diagram, and those skilled in the art may select one according to actual needs. Furthermore, the number of the first traffic cells is not limited to the aforementioned 1386, and the specific number of the first traffic cells may also be determined by those skilled in the art according to actual needs.

[0088] S2712. Use the GeoPandas library in Python to match the second data to be processed, the fourth data to be processed, and the sixth data to be processed to the multiple first traffic areas. Then, count the first traffic travel demands of different traffic modes in each first traffic area with a time resolution of 1 hour, and form a first feature matrix to be processed with all the first traffic travel demands.

[0089] The first feature matrix to be processed can be expressed as the following formula:

[0090]

[0091] Among them, X taz (i) is the first feature matrix to be processed, i∈{1,2,…,1386}, and each element in the formula is x j,k,m It is expressed in the form of, where j represents the jth day, k represents the kth hour, m represents the travel demand of the mth mode of transportation at the kth hour on the jth day, the second data to be processed belongs to the first mode of transportation, the fourth data to be processed belongs to the second mode of transportation, and the sixth data to be processed belongs to the third mode of transportation, and m∈{1,2,3}.

[0092] The first feature matrix to be processed is a travel demand feature matrix of various modes of transportation in the area to be predicted. S272: Connect all elements of the first feature matrix to be processed according to the time dimension to obtain the total demand feature matrix.

[0093] The time dimension is a day dimension. In other implementations, the time dimension can be set by those skilled in the art according to actual needs.

[0094] S28. Extracting the traffic travel demand characteristic matrix from the total demand characteristic matrix using a time window splitting method.

[0095] Furthermore, the step S28 includes:

[0096] S281. Set the length of the first sliding window.

[0097] The length of the first sliding window is one hour, one day or one week. According to the specific prediction task (short-term prediction or long-term prediction), the appropriate length of the first sliding window (ie, time window) is selected.

[0098] S282: Set the step size of the first sliding window.

[0099] The step size of the first sliding window can be determined by those skilled in the art according to actual needs.

[0100] S283. Extract the traffic travel demand characteristic matrix from the total demand characteristic matrix based on the length and step size of the first sliding window.

[0101] The traffic travel demand characteristic matrix is ​​a sequence extracted from the total demand characteristic matrix, that is, starting from the beginning of the time dimension of the total demand characteristic matrix, the first sliding window is slid according to the step size to extract the data of the total demand characteristic matrix corresponding to the current first sliding window.

[0102] S3. Input the traffic travel demand characteristic matrix into a travel demand prediction model. The travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs a prediction result.

[0103] The prediction result is the full data of population travel.

[0104] In the above technical solution, the embodiment of the present application predicts the total amount of population travel demand data by using multi-modal traffic travel demand data. Therefore, the embodiment of the present application can overcome the sampling bias phenomenon caused by single-modal traffic travel demand data in the prior art, thereby improving the accuracy of the prediction result, that is, improving the accuracy of predicting the total amount of population travel demand.

[0105] In some implementations, the step of training the travel demand prediction model includes:

[0106] S41. Obtain a bus training data set, a subway training data set, a taxi training data set, and a label data set.

[0107] Each element in the bus training data set has the same data structure and data type as the bus travel demand data. Each element in the subway training data set has the same data structure and data type as the subway travel demand data. Each element in the taxi training data set has the same data structure and data type as the taxi travel demand data.

[0108] The bus training data set, the subway training data set, the taxi training data set and the label data set are all collected in the same research area.

[0109] S42. Preprocess the target bus training data, the target subway training data, and the target taxi training data to obtain a traffic training feature matrix, wherein the target bus training data is any element in the bus training data set, the target subway training data is an element in the subway training data set that belongs to the same time series as the target bus training data, and the target taxi training data is an element in the taxi training data set that belongs to the same time series as the target bus training data.

[0110] Furthermore, each element in the label data set is a population travel demand data corresponding to the target bus training data, the target subway training data and the target taxi training data.

[0111] In an embodiment of the present application, the population travel demand data corresponding to the target bus training data, the target subway training data, and the target taxi training data are set as the target population travel demand data. The target population travel demand data is derived from mobile phone signaling data, and the mobile phone signaling data is user location information provided by a mobile communication operator. The user location information includes base station switching records and call information of the mobile terminal. In other embodiments, the target population travel demand data can be obtained through traffic surveys or other data sources. The target population travel demand data is one of the elements in the label data set.

[0112] Furthermore, the step of preprocessing the target bus training data, the target subway training data and the target taxi training data to obtain the traffic training feature matrix includes:

[0113] S421. Perform a elimination operation on the target public transportation training data to obtain seventh data to be processed.

[0114] Specifically, the removing operation on the target public transport training data refers to removing the boarding station information without corresponding boarding time information or the boarding time information without corresponding boarding station information in the target public transport training data.

[0115] S422: extract all the boarding station information and the boarding time information corresponding to each of the boarding station information from the seventh data to be processed to obtain the eighth data to be processed.

[0116] The eighth data to be processed only includes all the boarding station information and the boarding time information corresponding to each of the boarding station information in the seventh data to be processed, and does not include the alighting station information and the alighting time information corresponding to each of the alighting station information.

[0117] S423: performing a elimination operation on the target subway training data to obtain ninth data to be processed.

[0118] Specifically, the removing operation on the target subway training data refers to removing the station entry position information without corresponding station entry time information or the station entry time information without corresponding station entry position information in the target subway training data.

[0119] S424, extracting all the station entry position information and the station entry time information corresponding to each station entry position information from the ninth data to be processed, to obtain tenth data to be processed.

[0120] The tenth data to be processed only includes all the entry position information and the entry time information corresponding to each entry position information in the ninth data to be processed, and does not include the exit position information and the exit time information corresponding to each exit position information.

[0121] S425: performing a elimination operation on the target taxi training data to obtain eleventh data to be processed.

[0122] Specifically, the elimination operation on the target taxi training data refers to eliminating the departure location information without corresponding departure time information, the service status information without corresponding departure time information, and the departure location information without corresponding service status information in the target taxi training data.

[0123] S426. Extract all departure location information and departure time information corresponding to each departure location information from the eleventh data to be processed to obtain twelfth data to be processed.

[0124] The twelfth data to be processed only includes all the departure location information in the eleventh data to be processed and the departure time information corresponding to each of the departure location information.

[0125] S427: Generate a traffic training demand characteristic matrix based on the eighth data to be processed, the tenth data to be processed, and the twelfth data to be processed.

[0126] Furthermore, the step S427 includes:

[0127] S4271. Generate a second feature matrix to be processed based on the eighth data to be processed, the tenth data to be processed, and the twelfth data to be processed.

[0128] More specifically, the 4271 step includes:

[0129] S42711. Divide the study area into a plurality of second traffic areas using a spatial division method. In the embodiment of the present application, the study area is divided into 1386 second traffic areas based on the Voronoi diagram of the main roads in the study area. In other implementations, the number of the second traffic areas is not limited to the aforementioned 1386, and the specific number of the second traffic areas can also be determined by those skilled in the art according to actual needs. The number of the second traffic areas can be the same as the number of the first traffic areas.

[0130] S42712. Use the GeoPandas library in Python to match the eighth data to be processed, the tenth data to be processed, and the twelfth data to be processed to the multiple second traffic areas. Then, count the second transportation travel demands of different transportation modes (i.e., buses, subways, and taxis) in each second traffic area with a time resolution of 1 hour, and form a second feature matrix to be processed by all the second transportation travel demands.

[0131] The formula expression of the second feature matrix to be processed can refer to the first feature matrix to be processed X taz S4272: Connect all elements in the second feature matrix to be processed according to the time dimension to obtain the traffic training demand feature matrix.

[0132] S428: extracting the traffic training feature matrix from the traffic training demand feature matrix using a time window splitting method.

[0133] Furthermore, the step S428 includes:

[0134] S4281. Set the length of the second sliding window.

[0135] The length of the second sliding window is one hour, one day or one week. According to the specific prediction task, the appropriate length of the second sliding window is selected.

[0136] S4282. Set the step size of the second sliding window.

[0137] The step size of the second sliding window can be determined by those skilled in the art according to actual needs.

[0138] S4283. Extract the traffic training feature matrix from the traffic training demand feature matrix based on the length and step size of the second sliding window.

[0139] Furthermore, the embodiment of the present application also needs to pre-process the target population travel demand data to obtain a population travel demand matrix.

[0140] Specifically, the step of preprocessing the target population travel demand data to obtain a population travel demand matrix includes:

[0141] S51. Perform a elimination operation on the target population travel demand data to obtain thirteenth data to be processed.

[0142] It should be understood that the elimination operation of the target population travel demand data refers to eliminating the mobile phone signaling data that switches to different base stations multiple times in a short period of time and the mobile phone signaling data that is not in the study area in the target population travel demand data. In other implementations, other abnormal signaling records can also be eliminated.

[0143] S52. Use the GeoPandas library in Python to match the thirteenth data to be processed to the multiple second traffic areas, then count the population travel demand in each second traffic area with a time resolution of 1 hour, and form a third feature matrix to be processed with all the population travel demand.

[0144] The third feature matrix to be processed can be expressed in the following form:

[0145]

[0146] Among them, Y taz (i) is the third feature matrix to be processed, i∈{1,2,…,1386}, and each element in the formula is y j,k It is expressed in the form of , where j represents the jth day and k represents the kth hour.

[0147] S53: Connect all elements in the third feature matrix to be processed according to the time dimension to obtain a population training demand feature matrix.

[0148] S54: Set the length and step size of the third sliding window. The length and step size of the third sliding window are the same as the length and step size of the second sliding window.

[0149] S55. Extracting the population travel demand matrix from the population training demand feature matrix based on the length and step size of the third sliding window.

[0150] It should also be understood that when the second sliding window is in the first time step, the elements in the traffic training demand characteristic matrix corresponding to the first time step are used as the traffic training characteristic matrix; at the same time, the elements in the population training demand characteristic matrix corresponding to the third sliding window in the second time step are used as the population travel demand matrix, or the elements in the population training demand characteristic matrix corresponding to multiple time steps after the first time step of the third sliding window are used as the population travel demand matrix.

[0151] In the embodiment of the present application, the traffic training feature matrix is ​​used as the input of the recurrent neural network model, and the population travel demand matrix is ​​used as the output target of the recurrent neural network model. Therefore, it can also be understood that the label data set is composed of multiple population travel demand matrices.

[0152] Furthermore, the relationship between the input and output of the recurrent neural network model described in the embodiment of the present application can be expressed by the basic formula: Among them, Y is the population travel demand matrix, is the recurrent neural network model (that is, part of the model prediction parameters), X is the traffic training feature matrix, and θ is the third model parameter of the recurrent neural network model. In the basic formula, it can be understood that this application predicts the population travel demand matrix through the traffic training feature matrix, that is, multimodal traffic travel demand data is used to predict the full amount of population travel demand data. This basic formula establishes the relationship between the population travel demand matrix and the traffic training feature matrix, so that the recurrent neural network model has a higher accuracy.

[0153] In other implementations, the step of preprocessing the target population travel demand data to obtain a population travel demand matrix further includes:

[0154] S61. Sort the base station switching records of each user in the target population travel demand data in chronological order to construct an activity trajectory of each user.

[0155] S62. Identify the residence time of each user at the target base station, calculate the duration of the user's continuous signaling record at the target base station, and determine the user's activity area based on the residence time and the duration, wherein the target base station is any base station in the base station switching record corresponding to the user.

[0156] S63: Set a stay threshold.

[0157] S64: When the stay time exceeds the stay threshold, the target base station is regarded as point O, and point O is the departure point.

[0158] S65: When the user switches from the target base station to another base station and the time the user stays at the another base station exceeds the stay threshold, the another base station is regarded as point D.

[0159] The point D represents the end of the travel event.

[0160] S66. Record the timestamp of point O as the departure time, and record the timestamp of point D as the arrival time.

[0161] Through the above S51-S55 and S61-S66, the departure location and time of each user in each trip can be counted.

[0162] S43, inputting the traffic training feature matrix into a recurrent neural network model, and the recurrent neural network model analyzes and processes the traffic training feature matrix and outputs a training result.

[0163] It should be understood that in order to overcome the problems of timeliness and portability of the existing model, the embodiment of the present application sets an optimization model (i.e., optimization problem), and the technical means adopted by the optimization model is to segment the time series data so as to maximize the difference between the segmented time series data. Specifically, the optimization model is expressed as:

[0164]

[0165] Among them, K is the K most dissimilar time series; K0 is a hyperparameter used to avoid over-segmentation; i is the i-th time series; j is the j-th time series; d is the distance measurement method; is the length of the i-th time series; is the length of the jth time series; Δ1 and Δ2 are predefined parameters used to avoid the optimization model from obtaining cumbersome solutions; and n is the total length of the time series.

[0166] The optimization model can be solved by a greedy algorithm or a dynamic programming algorithm to obtain K segments of the most dissimilar time series. The purpose of the optimization model can be simply understood as dividing the entire segment of data input at the beginning into K segments, that is, obtaining the K segments of the most dissimilar time series.

[0167] Furthermore, the embodiment of the present application adopts CORAL distance (Deep Correlation Alignment) as the distance measurement method, and the specific calculation formula is as follows:

[0168]

[0169] in, is the length of the i-th time series, q is the dimension of the feature, is the length of the jth time series, ∥·∥ F is the Frobenius norm of the matrix, C i is the covariance matrix of the i-th time series, C j is the covariance matrix of the j-th time series.

[0170] In other implementations, the distance measurement method may be set by those skilled in the art according to actual needs.

[0171] Furthermore, the embodiment of the present application adopts a gated recurrent unit of a recurrent neural network model for modeling. The calculation formula of the gated recurrent unit is as follows:

[0172] z t =σ(W z ·[h t-1 ,x t ]);

[0173] r t =σ(W r ·[h t-1 ,x t ]);

[0174]

[0175] O t =W o ·h t +b o ;

[0176] Among them, z t is the update gate of the gated recurrent unit; σ is the Sigmoid activation function; W z is the weight matrix corresponding to the update gate; t-1 is the hidden state of the previous moment; x t is the input at the current moment, x t Data belonging to the K most dissimilar time series (the embodiment of the present application uses the K most dissimilar time series data as the input of the gated recurrent unit); r t is the reset gate of the gated recurrent unit; W r is a weight matrix corresponding to the reset gate; is the candidate hidden state; tanh is the hyperbolic tangent activation function; W h is the weight matrix corresponding to the hyperbolic tangent activation function; ⊙ is the element-by-element multiplication symbol; h t is the current hidden state; O t is the output at that moment, that is, the travel data output at that moment; W o For O t The corresponding weight matrix; b o For O t The corresponding bias term.

[0177] S44. Calculate a first loss function based on the training result and the label data set.

[0178] Furthermore, the calculation formula of the first loss function is:

[0179]

[0180] in, is the first loss function; θ predis the first model parameter, that is, the model prediction part of the undetermined parameters (this part of the parameters includes the recurrent neural network hidden layer parameters θ hidden and the output layer parameters θ output );K is the K most dissimilar time series; j=1,2,…,K; is the length of the jth time series; is the square error loss function; is the label value of the i-th time step in the j-th time series in the label data set; is the training result, that is, the output of the recurrent neural network model; is the feature vector of the i-th time step of the j-th time series in the traffic training feature matrix.

[0181] Furthermore, the calculation formula of the square error loss function is:

[0182]

[0183] in, is the length of the jth time series, is the label value of the i-th time step in the j-th time series in the label data set, is the training result.

[0184] In other implementations, the calculation formula of the square error loss function is not limited to the above formula and can be set by those skilled in the art according to actual needs.

[0185] S45. Adjust the first model parameter of the recurrent neural network model based on the first loss function to form the travel demand prediction model.

[0186] In some embodiments, it is assumed that if the model can reduce the distribution difference of the K most dissimilar time series obtained above, the model has the strongest generalization ability. Therefore, after the step of adjusting the first model parameter of the recurrent neural network model based on the first loss function, the training step of the travel demand forecasting model further includes:

[0187] S46. Set the importance vector.

[0188] The importance vector is used to describe the relative importance of each hidden state.

[0189] The embodiment of the present application introduces the importance vector in order to learn the relative importance of each hidden layer of the recurrent neural network (the recurrent neural network model) at V moments, weight all hidden states with a normalized α, and minimize the time series pair (D i ,D j), so that the distribution distance of the hidden state of each time segment can be dynamically reduced, so as to learn the shared knowledge of time series with different distributions, thereby effectively solving the timeliness and transferability problems of the existing model.

[0190] S47. Construct a second loss function based on the importance vector.

[0191] Furthermore, the calculation formula of the second loss function is:

[0192]

[0193] in, is the second loss function, θ is the second model parameter, α is the importance vector, α is a V-dimensional vector (that is, the importance weights of the hidden layers at V moments), is the first loss function, θ pred are some unknown parameters for model prediction, λ is a trade-off term, is the average distribution distance between each time series segment, K is the K most dissimilar time series, i is the i-th time series, j is the j-th time series, is the third loss function, is the length of the i-th time series, is the length of the jth time series, θ tdm is the fourth model parameter.

[0194] Furthermore, the calculation formula of the third loss function is:

[0195]

[0196] Among them, V is V moments, t∈[1,V], For the time segment and The importance of the distribution at time t, d is the distance measurement method, For the time segment The hidden state at time t is For the time segment The hidden state at time t, θ tdm is the fourth model parameter, and α is the importance vector. The fourth model parameter is a part of the undetermined parameters of the model migration regularization term, that is, the parameters in the time series distribution matching process. This part of the parameters includes the hidden layer parameters θ of the recurrent neural network. hidden and the parameter θ in the distance measurement process d .

[0197] S48. Adjust the second model parameter of the travel demand prediction model based on the second loss function.

[0198] In some embodiments, since the representation learned by the hidden layer is weak in the early stage of training, which results in that the importance vector α cannot be learned well, the embodiment of the present application is provided with a pre-training stage, which uses data from all time series segments to learn the model parameters θ to facilitate the learning of α.

[0199] Specifically, the steps of promoting the learning of the importance vector α include:

[0200] S71. Set a pre-training round to obtain parameter θ0.

[0201] S72, based on the parameter θ0, the importance vector α is learned using the following Boosting process. It should be understood that, initially, for each layer of the recurrent neural network, all weights are initialized to the same value, i.e., α i,j ={1 / V} V , α i,j is the relative importance of the i-th time series and the j-th time series at V moments.

[0202] S73. If the distribution distance of the n+1th round is larger than the distribution distance of the nth round, the corresponding importance vector is increased. In this way, the diversity of distribution can be reduced, and the learning of shared knowledge between different distribution time series can be promoted.

[0203] In some embodiments, the Boosting process can be described as:

[0204]

[0205] in,

[0206] in,

[0207] in,

[0208] in, is the number in round n+1 That is, the time segment in the n+1th round and The importance of the distribution at time t; For the nth round That is, the time segment in round n and The importance of the distribution at time t; σ is the Sigmoid activation function; is the distribution distance between the hidden layers of the i-th time series and the j-th time series at time t in the n-1th round; d is the cross-domain distribution distance measurement method, and the embodiment of the present application adopts the domain adversarial difference measurement method; D is the domain discriminator; For the time segment The hidden state at time t; For the time segment The hidden state at time t; is the adversarial loss of the hidden state at time t in the i-th time segment; is the adversarial loss of the hidden state at time t in the jth time segment.

[0209] The travel demand prediction model provided in the embodiment of the present application can be applied to areas where travel demand changes rapidly and has significant spatial heterogeneity, thereby improving the applicability of the model and reducing the training cost of the model.

[0210] <Cross-modal and transferable population travel demand prediction device>

[0211] like Figure 2 , which is a principle block diagram of a cross-modal and transferable population travel demand prediction device provided by the second aspect of the embodiment of the present application. Figure 2 In the embodiment, the cross-modal and transferable population travel demand prediction device 100 comprises:

[0212] An acquisition module 101 is used to acquire public transportation travel demand data, subway travel demand data and taxi travel demand data of a region to be predicted;

[0213] A traffic travel demand characteristic matrix obtaining module 102 is used to pre-process the bus travel demand data, the subway travel demand data and the taxi travel demand data to obtain a traffic travel demand characteristic matrix;

[0214] The prediction result output module 103 is used to input the traffic travel demand characteristic matrix into the travel demand prediction model, and the travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs the prediction result.

[0215] <Terminal Equipment>

[0216] A third aspect of the embodiments of the present application provides a terminal device. The principle block diagram of the terminal device can be as follows: Figure 3As shown. The terminal device includes a processor, a memory, a network interface, a display screen and a temperature sensor connected via a system bus. Among them, the processor is used to provide computing and control capabilities. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the terminal device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a cross-modal and transferable population travel demand prediction method is implemented. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the temperature sensor is pre-set inside the terminal device to detect the operating temperature of the internal device.

[0217] Those skilled in the art will understand that Figure 3 The principle block diagram shown in the figure is only a block diagram of a partial structure related to the scheme of the present invention, and does not constitute a limitation on the terminal device to which the scheme of the present invention is applied. The specific terminal device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0218] In some embodiments, an embodiment of the present application provides a terminal device, which includes a processor and a memory, the memory is used to store a computer program, and the processor is used to call and run the computer program stored in the memory to execute the steps of the cross-modal and transferable population travel demand forecasting method provided in the first aspect of the above-mentioned embodiment of the present application.

[0219] <Computer Readable Storage Medium>

[0220] According to the fourth aspect of the embodiments of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium is used to store a computer program, wherein the computer program enables a computer to execute the steps of the cross-modal and transferable population travel demand forecasting method provided in the first aspect of the embodiments of the present application.

[0221] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided by the present invention can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0222] The technical features of the above embodiments can be combined without changing the basic principles of the present application. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0223] The above embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the scope of patent protection of the present application shall be subject to the attached claims.

Claims

1. A cross-modal and transferable population travel demand prediction method, characterized in that: include: Obtain bus travel demand data, subway travel demand data and taxi travel demand data for the area to be predicted; Preprocessing the bus travel demand data, the subway travel demand data, and the taxi travel demand data to obtain a traffic travel demand characteristic matrix; The traffic travel demand characteristic matrix is ​​input into a travel demand prediction model, and the travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs a prediction result.

2. The cross-modal and transferable population travel demand prediction method according to claim 1 is characterized in that: The step of preprocessing the bus travel demand data, the subway travel demand data and the taxi travel demand data to obtain a traffic travel demand characteristic matrix comprises: Performing a elimination operation on the public transportation travel demand data to obtain first data to be processed; Extract all boarding station information and boarding time information corresponding to each boarding station information from the first data to be processed to obtain second data to be processed; Performing a elimination operation on the subway travel demand data to obtain third data to be processed; Extract all the station entry position information and the station entry time information corresponding to each of the station entry position information from the third data to be processed to obtain fourth data to be processed; Performing a elimination operation on the taxi travel demand data to obtain fifth data to be processed; Extract all departure location information and departure time information corresponding to each departure location information from the fifth data to be processed to obtain sixth data to be processed; Generate a total demand feature matrix based on the second data to be processed, the fourth data to be processed, and the sixth data to be processed; The traffic travel demand characteristic matrix is ​​extracted from the total demand characteristic matrix using a time window splitting method.

3. The cross-modal and transferable population travel demand prediction method according to claim 2 is characterized in that: The step of generating a total demand feature matrix based on the second data to be processed, the fourth data to be processed and the sixth data to be processed comprises: Generate a first feature matrix to be processed based on the second data to be processed, the fourth data to be processed and the sixth data to be processed; All elements in the first feature matrix to be processed are connected according to the time dimension to obtain the total demand feature matrix.

4. The cross-modal and transferable population travel demand prediction method according to claim 2 is characterized in that: The step of extracting the traffic travel demand characteristic matrix from the total demand characteristic matrix by using a time window splitting method comprises: Set the length of the first sliding window; Setting the step size of the first sliding window; The traffic travel demand characteristic matrix is ​​extracted from the total demand characteristic matrix based on the length and the step size.

5. The cross-modal and transferable population travel demand prediction method according to claim 1, characterized in that: The training steps of the travel demand prediction model include: Obtain bus training data set, subway training data set, taxi training data set and label data set; Preprocessing the target bus training data, the target subway training data, and the target taxi training data to obtain a traffic training feature matrix, wherein the target bus training data is any element in the bus training data set, the target subway training data is an element in the subway training data set that belongs to the same time series as the target bus training data, and the target taxi training data is an element in the taxi training data set that belongs to the same time series as the target bus training data; The traffic training feature matrix is ​​input into a recurrent neural network model, and the recurrent neural network model analyzes and processes the traffic training feature matrix and outputs a training result; Calculate a first loss function based on the training result and the label data set; The first model parameter of the recurrent neural network model is adjusted based on the first loss function to form the travel demand prediction model.

6. The cross-modal transferable population travel demand prediction method according to claim 5, characterized in that: The calculation formula of the first loss function is: in, is the first loss function, θ pred is the first model parameter, K is the K most dissimilar time series, j = 1, 2, ..., K, is the length of the jth time series, is the square error loss function, is the label value of the i-th time step in the j-th time series in the label data set, is the training result, is the feature vector of the i-th time step of the j-th time series in the traffic training feature matrix.

7. The cross-modal and transferable population travel demand prediction method according to claim 6, characterized in that: After the step of adjusting the first model parameter of the recurrent neural network model based on the first loss function, the step of training the travel demand prediction model further includes: Set the importance vector; constructing a second loss function based on the importance vector; A second model parameter of the travel demand prediction model is adjusted based on the second loss function.

8. A cross-modal and transferable population travel demand prediction device, characterized in that: include: An acquisition module is used to acquire bus travel demand data, subway travel demand data and taxi travel demand data in the area to be predicted; The traffic travel demand characteristic matrix obtaining module is used to pre-process the bus travel demand data, the subway travel demand data and the taxi travel demand data to obtain the traffic travel demand characteristic matrix: The prediction result output module is used to input the traffic travel demand characteristic matrix into the travel demand prediction model, and the travel demand prediction model analyzes and processes the traffic travel demand characteristic matrix and outputs the prediction result.

9. A terminal device, characterized in that: include: A processor and a memory, the memory being used to store a computer program, the processor being used to call and run the computer program stored in the memory to execute the steps of the cross-modal and transferable population travel demand prediction method as described in any one of claims 1 to 7 above.

10. A computer-readable storage medium, characterized in that: Used to store a computer program, wherein the computer program enables a computer to execute the steps of the cross-modal and transferable population travel demand prediction method as described in any one of claims 1 to 7 above.

Citation Information

Patent Citations

  • Urban hot spot area peak travel demand prediction method based on multi-source data fusion

    CN113222645A

  • Multi-mode traffic short-time passenger flow collaborative prediction method based on multi-task learning

    CN115146844A

  • Urban multimode traffic super-network situation prediction method based on hypergraph deep network

    CN115345354A

  • ConvLSTM-based taxi travel demand prediction method

    CN116029407A

  • Urban spatio-temporal data prediction method based on hybrid perception and causal depolarization

    CN116307293A