Methods, systems, computer equipment and storage media for predicting passenger flow at rail transit platforms

By constructing a directed network based on the automatic fare collection system and a CNN-BiLSTM-Attention model, and combining weather factors, the problem of real-time accuracy in rail transit passenger flow analysis was solved, enabling more accurate platform passenger flow prediction and supporting more effective passenger transport organization.

CN119809021BActive Publication Date: 2026-01-30SUZHOU UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411764505.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-04
Publication Date
2026-01-30
Estimated Expiration
2044-12-04

AI Technical Summary

Technical Problem

Existing rail transit passenger flow analysis methods cannot accurately reflect the real-time dynamic distribution of passenger flow across the network, resulting in poor effectiveness of passenger transport organization measures, especially with significant errors in passenger flow calculations at transfer stations.

Method used

Based on the entry and exit records of the automatic fare collection system, a fully directed network is constructed to extract directed OD pairs, determine the travel time, and combine the CNN-BiLSTM-Attention passenger flow prediction model, taking into account weather factors, to predict the passenger flow on the platform.

Benefits of technology

It improves the accuracy of passenger flow forecasting at rail transit platforms, enabling it to more accurately reflect the real-time dynamic distribution of passenger flow across the network and support more effective passenger transport organization measures.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119809021B_ABST
    Figure CN119809021B_ABST
Patent Text Reader

Abstract

This invention provides a method, system, computer equipment, and storage medium for predicting passenger flow at rail transit stations. The method extracts directed origin-destination (OD) pairs from the entry and exit records of an automated fare collection system using a fully directed network; determines the travel time for non-transfer and single-transfer journeys; determines the real-time location of passengers based on the OD pairs and travel time; determines the passenger flow at each station within a target time period based on the passengers' real-time locations; acquires and processes weather factors; constructs a CNN-BiLSTM-Attention passenger flow prediction model; and uses the passenger flow at each station within the target time period and weather factors as input variables to predict the passenger flow at each station using the CNN-BiLSTM-Attention passenger flow prediction model. This invention considers the influence of weather factors, time dependence, and spatial characteristics, enhancing the focus on key features and improving the accuracy of station passenger flow prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of rail transit technology, and in particular relates to a method, system, computer equipment and storage medium for predicting passenger flow at rail transit platforms. Background Technology

[0002] In recent years, urban rail transit has developed rapidly, and more and more cities have ushered in a new era of networked operation. Networked operation of urban rail transit has brought convenience to urban residents' travel. However, as the scale of urban rail transit grows larger and its tasks in urban transportation become heavier, it becomes increasingly difficult to grasp the passenger flow situation of rail transit in different scenarios.

[0003] Currently, passenger flow on the main rail transit line is calculated by summing the number of people entering and exiting stations. Passenger flow data is recorded by swiping cards at turnstiles, and each transaction is recorded as a single entry to accumulate the number of people entering or exiting the station. For transfer passengers between lines, a sorting algorithm is used, combined with factors such as the shortest path, cost, and sorting ratio, to calculate the transfer passenger flow. Because the volume of passenger flow transactions is typically very large, and data collection occurs approximately every 5-15 minutes, it is usually calculated uniformly after the rail transit system ceases operation each day to generate daily or historical passenger flow statistics.

[0004] However, existing passenger flow analysis methods rely on the time it takes for ticket revenue to be collected at turnstiles. This time-based approach results in a discrepancy between passenger flow statistics and actual network traffic, failing to accurately reflect the real-time dynamic distribution of passenger flow. Transfer passenger flow calculated using algorithms typically only includes transfers between lines, failing to precisely capture the passenger flow at each station on a particular line in different directions. Furthermore, with a minimum data collection interval of 5 minutes, tens of thousands of data points are generated within that timeframe, making the computational workload for detailed breakdowns of transfer passenger flow to each destination extremely large. Without real-time, accurate passenger flow analysis, it's difficult to determine the passenger flow distribution across different sections of the network. The results calculated using existing methods will be delayed compared to actual passenger flow distribution, hindering the effectiveness of implemented passenger organization measures. Summary of the Invention

[0005] This invention addresses the shortcomings of existing technologies by providing a method, system, computer equipment, and storage medium for predicting passenger flow at rail transit platforms.

[0006] In a first aspect, the present invention provides a method for predicting passenger flow at rail transit stations, comprising:

[0007] Extract directed OD pairs from the entry and exit records of the automated fare collection system based on a fully directed network;

[0008] Determine the travel time for non-transfer and single-transfer journeys; the travel time includes the time it takes for passengers to walk to the platform, the average waiting time for non-transfer journeys, the train's dwell time on the platform, the average walking time for transfer journeys, the average waiting time for transfer journeys, and the time it takes to walk from the platform to the exit gate.

[0009] Determine the passenger's real-time location based on the directed origin-destination (OD) pairs and the journey time;

[0010] Based on the real-time location of passengers, determine the passenger flow of each platform within the target time period;

[0011] Acquire and process weather factors, including wind speed, temperature, and precipitation.

[0012] Construct a CNN-BiLSTM-Attention passenger flow prediction model;

[0013] Passenger flow and weather factors at each station within the target time period are used as input variables, and the CNN-BiLSTM-Attention passenger flow prediction model is used to predict the passenger flow at each station.

[0014] Optionally, the extraction of directed OD pairs from the entry and exit records of the automatic fare collection system based on a fully directed network includes:

[0015] The system converts individual card swipe records collected by the automated fare collection system into undirected origin-destination (OD) pairs. Passenger records are grouped by ID number, and within each group, they are sorted by time sequence and entry / exit status, with entry records preceding exit records. The entire list is then moved up one line and concatenated with the original list. Records with different ID numbers or mismatched entry / exit statuses are deleted to extract OD pairs based on the station within a day. Each OD pair contains the passenger's departure station number and destination station number.

[0016] The stations are renumbered based on the fully directed network, with the format being "line + station number";

[0017] A fully directed metro network topology is constructed based on transfer and non-transfer records; where OD pairs are on the same line, they are non-transfer, and OD pairs are on different lines, they are transfers.

[0018] Obtain the number of stations and platform numbers traversed by the non-transfer record and determine the shortest path between OD pairs based on the fully directed metro network topology to obtain the first shortest path;

[0019] Obtain the number of stations and platform numbers traversed by the transfer record, and based on the fully directed metro network topology, determine the shortest path between OD pairs with the goal of minimizing the number of transfers, thus obtaining the second shortest path;

[0020] The stations traversed by the transfer record are sliced, and stations with the same route belong to a non-transfer sub-record, so as to divide a transfer OD pair into multiple non-transfer OD pairs.

[0021] Non-transfer OD pairs and multiple non-transfer OD pairs with transfers are corrected into directed OD pairs. The subway line stations are constructed into a vector according to the subway running direction. The index of the destination platform number in the vector is subtracted from the index of the departure platform number in the vector. If the difference is positive, the destination platform number and the departure platform number remain unchanged; if the difference is negative, the destination platform number and the departure platform number become their respective opposites, thus obtaining the directed OD pairs.

[0022] Optionally, determining the travel time for non-transfer and single-transfer journeys includes:

[0023] Calculate the non-transfer travel time using the following formula:

[0024]

[0025] in, For non-transfer scenarios, the time it takes for passenger k to swipe their card and exit platform p at station s on line l during time slot (t,d); The time during which passenger k swipes his card to enter platform p of station s on line l under non-transfer conditions (t,d); The time it takes for passenger k to walk from station s turnstile on line l to platform p, or the time it takes for passenger k to walk from platform p on line l to exit station s turnstile. α represents the shortest waiting time for passenger k at platform p in station s of line l, without transfers; s,l β is the time it takes for the train to travel from station s to station s+l. s,l The time the train stays at station s; s represents the number of stations the train passes through; s represents the index of the station that passenger k passes through on line l.

[0026] Calculate the transfer travel time using the following formula:

[0027]

[0028] Where t is the number of time slots in a day; d is the index of the day in a week; The time during which passenger k swipes his card and exits from platform p at station s on line l during time slot (t,d) in the case of a transfer; The time during which passenger k swipes his card to enter platform p of station s on line l during time slot (t,d) in the case of transfer; q represents the shortest waiting time for passenger k at platform p in station s on line l when transferring; k For the number of transfers for passengers; t q The average time spent on the transfer process; k Let be the total number of routes traveled by passenger k; and let i be the index of all routes traveled by passenger k.

[0029] Optionally, the step of using passenger flow and weather factors at each platform within the target time period as input variables, and employing the CNN-BiLSTM-Attention passenger flow prediction model to predict passenger flow at each platform, includes:

[0030] Obtain passenger flow at transfer platforms within the target time period Let n be the passenger flow at platform p of station s on line l during the nth observation time window; n is the total length of the time series.

[0031] Interpolation was performed on wind speed, temperature, and precipitation to ensure that each of these parameters maintained the same time series length as the passenger flow within the corresponding observation period; where wind speed was M. t ={m 1 ,m 2 ,…,m n The temperature is C. t ={c 1 ,c 2 ,…,c n The precipitation was I. t ={i 1 i 2 ,…,i n};m n c represents the wind speed during the nth observation time window. n Let i be the temperature of the nth observation time window; n Let be the precipitation during the nth observation time window;

[0032] X p,s,l M t C t and I t The data is fed into the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow at each station.

[0033] Secondly, the present invention provides a passenger flow prediction system for rail transit platforms, comprising:

[0034] The extraction module is used to extract directed OD pairs from the entry and exit records of the automatic fare collection system based on a fully directed network;

[0035] The first determining module is used to determine the travel time for non-transfer and single-transfer journeys; wherein, the travel time includes the time for passengers to walk to the platform, the average waiting time for non-transfer journeys, the train's dwell time on the platform, the average walking time for transfer journeys, the average waiting time for transfer journeys, and the time to walk from the platform to the exit gate.

[0036] The second determination module is used to determine the real-time location of passengers based on the directed OD pair and the journey time;

[0037] The third determination module is used to determine the passenger flow of each platform within the target time period based on the real-time location of passengers.

[0038] The acquisition module is used to acquire and process weather factors, including wind speed, temperature, and precipitation.

[0039] The building block is used to construct the CNN-BiLSTM-Attention passenger flow prediction model;

[0040] The prediction module uses passenger flow and weather factors as input variables for each station within a target time period, and uses the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow for each station.

[0041] Optionally, the extraction module includes:

[0042] The conversion unit is used to convert single card swipe records collected by the automatic fare collection system into undirected origin-destination (OD) pairs, group passenger records by ID number, sort within each group by time sequence and entry / exit status (entry first, exit second), move the entire list up one line and concatenate it with the original list, and delete records with different ID numbers or mismatched entry / exit statuses to extract station-based OD pairs for the day; each OD pair contains the passenger's departure station number and destination station number.

[0043] Numbering unit, used to renumber stations based on a fully directed network, in the format of "line + station number";

[0044] The construction unit is used to construct a fully directed metro network topology based on transfer and non-transfer records; where OD pairs are on the same line, they are non-transfer, and OD pairs are on different lines, they are transfers.

[0045] The first acquisition unit is used to acquire the number of stations and platform numbers passed through by the non-transfer record and determine the shortest path between OD pairs according to the fully directed metro network topology to obtain the first shortest path.

[0046] The second acquisition unit is used to acquire the number of stations and platform numbers passed through by the transfer record and, based on the fully directed metro network topology, determine the shortest path between OD pairs with the goal of minimizing the number of transfers, and obtain the second shortest path.

[0047] The station slicing unit is used to slice the stations passed through by the transfer record. Stations with the same route belong to a non-transfer sub-record, so as to divide a transfer OD pair into multiple non-transfer OD pairs.

[0048] The extraction unit is used to correct non-transfer OD pairs and multiple non-transfer OD pairs for transfers into directed OD pairs. The subway line stations are constructed into a vector according to the subway running direction. The index of the destination platform number in the vector is subtracted from the index of the departure platform number in the vector. If the difference is positive, the destination platform number and the departure platform number remain unchanged; if the difference is negative, the destination platform number and the departure platform number become their respective opposites, thus obtaining the directed OD pairs.

[0049] Optionally, the first determining module includes:

[0050] The first calculation unit is used to calculate the non-transfer travel time according to the following formula:

[0051]

[0052] in, For non-transfer scenarios, the time it takes for passenger k to swipe their card and exit platform p at station s on line l during time slot (t,d); The time during which passenger k swipes his card to enter platform p of station s on line l under non-transfer conditions (t,d); The time it takes for passenger k to walk from station s turnstile on line l to platform p, or the time it takes for passenger k to walk from platform p on line l to exit station s turnstile. α represents the shortest waiting time for passenger k at platform p in station s of line l, without transfers; s,l β is the time it takes for the train to travel from station s to station s+l. s,l The time the train stays at station s; s represents the number of stations the train passes through; s represents the index of the station that passenger k passes through on line l.

[0053] The second calculation unit is used to calculate the transfer travel time according to the following formula:

[0054]

[0055] Where t is the number of time slots in a day; d is the index of the day in a week; The time during which passenger k swipes his card and exits from platform p at station s on line l during time slot (t,d) in the case of a transfer; The time during which passenger k swipes his card to enter platform p of station s on line l during time slot (t,d) in the case of transfer; q represents the shortest waiting time for passenger k at platform p in station s on line l when transferring; k For the number of transfers for passengers; t q The average time spent on the transfer process; k Let be the total number of routes traveled by passenger k; and let i be the index of all routes traveled by passenger k.

[0056] Optionally, the prediction module includes:

[0057] The third acquisition unit is used to acquire passenger flow data for transfer platforms within the target time period. Let n be the passenger flow at platform p of station s on line l during the nth observation time window; n is the total length of the time series.

[0058] The interpolation unit is used to interpolate wind speed, temperature, and precipitation to ensure that wind speed, temperature, and precipitation maintain the same time series length as passenger flow within the corresponding observation period; where wind speed is M. t ={m 1 ,m 2 ,…,m n The temperature is C. t ={c 1 ,c 2 ,…,c n The precipitation was I. t ={i 1 i 2 ,…,i n};m n c represents the wind speed during the nth observation time window. n Let i be the temperature of the nth observation time window; n Let be the precipitation during the nth observation time window;

[0059] Prediction unit, used to predict X p,s,l M t C t and I t The data is fed into the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow at each station.

[0060] Thirdly, the present invention provides a computer device including a processor and a memory; wherein, when the processor executes a computer program stored in the memory, it implements the steps of the rail transit platform passenger flow prediction method described in the first aspect.

[0061] Fourthly, the present invention provides a computer-readable storage medium for storing a computer program; when the computer program is executed by a processor, it implements the steps of the rail transit platform passenger flow prediction method described in the first aspect.

[0062] This invention provides a method, system, computer equipment, and storage medium for predicting passenger flow at rail transit platforms. The method utilizes a fully bidirectional metro network model and data from the metro fare collection system to calculate the specific passenger flow at platforms within a target time period. It constructs a typical architecture that considers the influence of weather factors, time dependence, and spatial features. The CNN-BILSTM-Attention model combines the spatial feature extraction capabilities of convolutional neural networks with the sequence processing capabilities of bidirectional long short-term memory networks. By incorporating an attention mechanism, this model enhances its focus on key features, improving the accuracy of platform passenger flow prediction. Attached Figure Description

[0063] To more clearly illustrate the technical solution of the present invention, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0064] Figure 1 A flowchart illustrating a method for predicting passenger flow at rail transit platforms provided in an embodiment of the present invention;

[0065] Figure 2 This is a time composition diagram of transfer and non-transfer journeys provided in an embodiment of the present invention;

[0066] Figure 3 This is a schematic diagram of the structure of the CNN-BiLSTM-Attention passenger flow prediction model provided in an embodiment of the present invention;

[0067] Figure 4 This is a schematic diagram of a passenger flow prediction system for rail transit platforms provided in an embodiment of the present invention. Detailed Implementation

[0068] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0069] Example 1

[0070] like Figure 1 As shown, this embodiment provides a method for predicting passenger flow at rail transit platforms, including:

[0071] Step 101: Extract directed OD pairs from the entry and exit records of the automatic fare collection system based on a fully directed network.

[0072] The extraction of directed origin-exit (OD) pairs is essentially a process of correcting the start and end numbers of the Automated Fare Collection System (AFCS). An arrival or departure record includes the passenger's identification number, timestamp (arrival or departure time), station number (arrival or departure number), status (arrival or departure), and payment method. An OD pair represents a travel record that includes both departure and destination. To convert a single record into a station-based OD pair, records are first grouped by ID number, ensuring that records belonging to the same passenger are grouped together. Within each group, they are sorted by time and status, ensuring that arrival records come first, followed by departure records. Then, the sorted list of records is shifted up one line and concatenated with the original list so that each departure record is preceded by a corresponding arrival record. Records with different ID numbers or mismatched arrival / departure statuses are deleted to extract station-based OD pairs for the entire day, each containing the passenger's departure and destination.

[0073] After converting the records into station-based OD pairs, it's necessary to determine whether each OD pair involves a transfer based on the metro network topology. If the origin and destination stations are on the same route, it's considered a non-transfer; if they are different, it's considered a transfer. Furthermore, considering that passengers generally prefer journeys with relatively few transfers, a network topology is constructed to minimize the number of transfers. The weight of transfer stations is set to a lower value (e.g., 1), while the weight between connecting platforms is set to a higher value (e.g., 10). After initial processing of the traffic data, the station-based OD pairs are then converted into platform-based OD pairs. The platform represents the actual location where passengers board and alight, more accurately reflecting their travel trajectories. For OD pairs involving transfers, it's necessary to divide them into several non-transfer journeys. Each segmented journey involves only one route, and these segmented journeys can be used for more detailed passenger flow analysis.

[0074] For non-transfer journeys, all stations on the route are sorted according to the train's natural direction of travel (i.e., upstream), forming an ordered vector. Each station has a unique location index, indicating its ordinal position on the route. The direction of the journey is determined by subtracting the location index of the starting point from the location index of the destination. If the result is positive, the train will travel upstream; otherwise, it will travel downstream. Passenger departure and arrival platforms are also determined. "+" indicates upstream and "-" indicates downstream. For example, if the starting point is +107, it means the passenger departs from platform 7 upstream of station 7 on Line 1.

[0075] Based on passenger entry and exit records and the subway network topology, transfer journeys are divided into multiple non-transfer journeys. Then, for each segment, the up and down directions are determined using the same method as for non-transfer journeys. It's important to note that for special cases where the starting point is a transfer station, the ending point is a transfer station, or both the starting and ending points are transfer stations, the specific platform for entering and exiting the station should be determined. For example, if a passenger swipes their card at transfer station 5 on Lines 1 and 4, according to the numbering rules, this station includes stations 105 and 405. Assume the passenger's entry station is 105. When dividing transfer journeys into non-transfer journeys, if the passenger actually enters the station at 105, then 105 will be classified as a journey of length greater than 2. Conversely, if the length is 1, only 105 is included, which is an invalid travel behavior. In this case, the journey of length 1 is deleted, and the first number of the first journey is redefined as the starting point to confirm the specific station from which the passenger departs. Then, the specific departure platform is determined by judging the direction: +105, -105, +405, or -405. The same applies when the destination is a transfer station or both the origin and destination are transfer stations.

[0076] For example, this step includes:

[0077] The individual card swipe records collected by the automatic fare collection system are converted into undirected origin-destination (OD) pairs. Passenger records are grouped by ID number, and within each group, they are sorted by time sequence and entry / exit status, with entry occurring before exit. The entire list is moved up one line and concatenated with the original list. Records with different ID numbers or mismatched entry / exit statuses are deleted to extract OD pairs based on the station within a day. Each OD pair contains the passenger's departure station number and destination station number.

[0078] The stations are renumbered based on a fully directed network, with the format being "line + station number".

[0079] A fully directed metro network topology is constructed based on transfer and non-transfer records; where OD pairs are on the same line, they are non-transfer pairs, and OD pairs are on different lines, they are transfer pairs.

[0080] Obtain the number of stations and platform numbers traversed by the non-transfer record, and determine the shortest path between OD pairs based on the fully directed metro network topology to obtain the first shortest path.

[0081] Obtain the number of stations and platform numbers traversed by the transfer record, and based on the fully directed metro network topology, determine the shortest path between OD pairs with the goal of minimizing the number of transfers, thus obtaining the second shortest path.

[0082] The stations traversed by the transfer record are sliced. Stations with the same route belong to a non-transfer sub-record, thus dividing a transfer OD pair into multiple non-transfer OD pairs. If the station is a transfer station, the correct number will be included in a journey with a length greater than 2 station numbers. If the length is 1, it is an invalid record and is deleted.

[0083] Non-transfer OD pairs and multiple non-transfer OD pairs with transfers are corrected into directed OD pairs. The subway line stations are constructed into a vector according to the subway running direction. The index of the destination platform number in the vector is subtracted from the index of the departure platform number in the vector. If the difference is positive, the destination platform number and the departure platform number remain unchanged; if the difference is negative, the destination platform number and the departure platform number become their respective opposites, thus obtaining the directed OD pairs.

[0084] Step 102: Determine the travel time for non-transfer and single-transfer journeys; wherein, the travel time includes the time for passengers to walk to the platform, the average waiting time for non-transfer journeys, the train's dwell time on the platform, the average walking time for transfer journeys, the average waiting time for transfer journeys, and the time to walk from the platform to the exit gate.

[0085] To identify a passenger's real-time location during their journey, in addition to extracting directed origin-destination (OD) pairs, it is also necessary to analyze the time spent by passengers at each stage of their journey, including the time composition of transfer and non-transfer journeys, as follows: Figure 2 As shown, for non-transfer travel, the journey can be divided into walking to the platform, waiting, boarding the train, and walking out of the station.

[0086] For transfer journeys, compared to non-transfer journeys, there are several additional transfer processes, which include walking, waiting, and travel time.

[0087] For example, the non-transfer travel time is calculated according to the following formula:

[0088]

[0089] in, For non-transfer scenarios, the time it takes for passenger k to swipe their card and exit platform p at station s on line l during time slot (t,d); The time during which passenger k swipes his card to enter platform p of station s on line l under non-transfer conditions (t,d); The time it takes for passenger k to walk from station s turnstile on line l to platform p, or the time it takes for passenger k to walk from platform p on line l to exit station s turnstile. α represents the shortest waiting time for passenger k at platform p in station s of line l, without transfers; s,l β is the time it takes for the train to travel from station s to station s+l. s,l The time the train stays at station s; s represents the number of stations the train passes through; s represents the index of the station that passenger k passes through on line l.

[0090] Calculate the transfer travel time using the following formula:

[0091]

[0092] Where t is the number of time slots in a day; d is the index of the day in a week; The time during which passenger k swipes his card and exits from platform p at station s on line l during time slot (t,d) in the case of a transfer; The time during which passenger k swipes his card to enter platform p of station s on line l during time slot (t,d) in the case of transfer; q represents the shortest waiting time for passenger k at platform p in station s on line l when transferring; k For the number of transfers for passengers; t q The average time spent on the transfer process; k Let be the total number of routes traveled by passenger k; and let i be the index of all routes traveled by passenger k.

[0093] This embodiment establishes a general model to capture passenger movement within a station and to count the actual number of passengers on the platform within a certain time interval, based on the following assumptions:

[0094] 1) Assume that passengers do not make irrational round-trip travel decisions;

[0095] 2) Passengers have the same walking time when entering and exiting the station;

[0096] 3) The passenger waiting time for the shortest journey between any two stations is 0;

[0097] For the shortest non-transfer journey, assuming there is no waiting time, the non-transfer journey time is calculated using the following formula:

[0098]

[0099] After extracting the record with the shortest travel time between any stations, the proportion of travel time between stations is determined based on the straight-line distance between stations. The number of train stops is determined based on the shortest travel path. Using multiple linear regression, the walking time, travel time between stations, and the time of one train stop can be calculated from the above formula. Then, for the travel record with 1 transfer and the shortest travel time between any stations, assuming that its waiting time is also 0, the walking time required for the transfer process can be calculated, and then the average waiting time for the transfer can be calculated.

[0100] Step 103: Determine the passenger's real-time location based on the directed OD pair and the journey time.

[0101] Taking passengers as the research object, the journey process is divided into stages such as walking, waiting, riding, getting off the vehicle, and walking again. Based on the specific time taken in each stage, the approximate location of passengers at each time point can be inferred relatively accurately, thereby capturing the spatial needs of passengers during the journey.

[0102] Step 104: Determine the passenger flow of each platform within the target time period based on the real-time location of the passengers.

[0103] The capture of space requirements in step 103 is crucial for the operation of subway or rail transit systems. For ordinary platforms, platform demand can usually be considered as the number of passengers directly swiping their cards to enter. However, the situation is more complex when it comes to transfer stations. The demand at transfer stations cannot be simply equated with the number of passengers swiping their cards to enter, because the passenger flow transferring from other lines to this line must also be considered. These transfer passengers also require platform space and are therefore an important component of platform demand.

[0104] A typical platform is defined as the number of passengers waiting at the point in time, which is the platform's capacity requirement X. p,s,l (t,d)=K p,s,l (t,d), K p,s,l (t,d) is the set of passengers waiting at platform p in station s on line l during time slot (t,d).

[0105] Passenger flow at transfer platforms during the target time period The capacity requirement of this station Let P be the set of passengers who transfer from other stations on line l to station p during time slot (t,d).

[0106] Step 105: Obtain and process weather factors, including wind speed, temperature, and precipitation.

[0107] Step 106: Construct the CNN-BiLSTM-Attention passenger flow prediction model.

[0108] CNN-BILSTM-Attention is a model that combines a Convolutional Neural Network (CNN), a Bidirectional Long Short-Term Memory Neural Network (BILSTM), and an attention mechanism for natural language processing tasks such as text classification and sentiment analysis. CNN captures local patterns and features in the data, while BILSTM can handle long-term dependencies in the data capture. The attention mechanism allows the model to focus on key information, thereby improving prediction accuracy. Based on the characteristics of CNN, BILSTM, and the attention mechanism, a passenger flow prediction model based on CNN-BILSTM-Attention was established, such as... Figure 3 As shown.

[0109] One-dimensional convolutional neural networks (1D CNNs) are widely used to process time-series data in machine learning, particularly in natural language processing (NLP), speech recognition, and time-series prediction. The models typically consist of multiple convolutional layers, activation functions, pooling layers, and fully connected layers, and are trained using the backpropagation algorithm. CNNs for time-series data possess strong feature extraction capabilities, large-scale data processing capabilities, and flexibility, meaning they can identify time patterns and trends useful to the target variable. CNNs extract features from input data by stacking multiple convolutional and pooling layers. Each convolutional layer contains multiple convolutional kernels to capture different features. On the other hand, pooling layers are used to reduce the dimensionality of the data, decrease computational load, and enhance the model's robustness.

[0110] Step 107: Using the passenger flow and weather factors of each station within the target time period as input variables, the CNN-BiLSTM-Attention passenger flow prediction model is used to predict the passenger flow of each station.

[0111] In this step, the passenger flow of the transfer platform within the target time period is obtained. Let be the passenger flow at platform p of station s on line l during the nth observation time window; n is the total length of the time series.

[0112] Interpolation was performed on wind speed, temperature, and precipitation to ensure that each of these parameters maintained the same time series length as the passenger flow within the corresponding observation period; where wind speed was M. t ={m 1 ,m 2 ,…,m n The temperature is C. t ={c 1 ,c 2 ,…,c n The precipitation was I. t ={i 1 i 2 ,…,i n};m n c represents the wind speed during the nth observation time window. n Let i be the temperature of the nth observation time window; n Let be the precipitation amount during the nth observation time window.

[0113] X p,s,l M t C t and I t The data is fed into the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow at each station.

[0114] In summary, this embodiment provides a method for predicting passenger flow at rail transit platforms. It utilizes a fully bidirectional metro network model and data from the metro fare collection system to calculate the specific passenger flow at platforms within a target time period. A typical architecture considering weather factors, time dependence, and spatial characteristics is constructed. The CNN-BILSTM-Attention model combines the spatial feature extraction capabilities of convolutional neural networks with the sequence processing capabilities of bidirectional long short-term memory networks. By incorporating an attention mechanism, this model enhances its focus on key features, improving the accuracy of platform passenger flow prediction.

[0115] Example 2

[0116] Based on the same inventive concept as Embodiment 1, this embodiment provides a rail transit platform passenger flow prediction system. Since the principle of this system in solving the problem is similar to the aforementioned rail transit platform passenger flow prediction method, the implementation of this system can refer to the implementation of the rail transit platform passenger flow prediction method.

[0117] like Figure 4 As shown, the rail transit station platform passenger flow prediction system includes:

[0118] Extraction module 10 is used to extract directed OD pairs from the entry and exit records of the automatic fare collection system based on a fully directed network.

[0119] The first determining module 20 is used to determine the travel time for non-transfer and single-transfer journeys; wherein, the travel time includes the time for passengers to walk to the platform, the average waiting time for non-transfer journeys, the time for the train to stay on the platform, the average walking time for transfer journeys, the average waiting time for transfer journeys, and the time to walk from the platform to the exit gate.

[0120] The second determining module 30 is used to determine the real-time location of the passenger based on the directed OD pair and the journey time.

[0121] The third determining module 40 is used to determine the passenger flow of each platform within a target time period based on the real-time location of passengers.

[0122] The acquisition module 50 is used to acquire and process weather factors, including wind speed, temperature and precipitation.

[0123] Module 60 is used to build a CNN-BiLSTM-Attention passenger flow prediction model.

[0124] The prediction module 70 is used to predict the passenger flow of each station within the target time period and the weather factors as input variables, and uses the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow of each station.

[0125] For example, the extraction module includes:

[0126] The conversion unit is used to convert single card swipe records collected by the automatic fare collection system into undirected origin-destination (OD) pairs, group passenger records by ID number, sort within each group by time sequence and entry / exit status (entry first, exit second), move the entire list up one line and concatenate it with the original list, and delete records with different ID numbers or mismatched entry / exit statuses to extract station-based OD pairs for the day; each OD pair contains the passenger's departure station number and destination station number.

[0127] The numbering unit is used to renumber stations based on a fully directed network, and the format is "line + station number".

[0128] The construction unit is used to construct a fully directed metro network topology based on transfer and non-transfer records; where OD pairs are on the same line, they are non-transfer, and OD pairs are on different lines, they are transfers.

[0129] The first acquisition unit is used to acquire the number of stations and platform numbers passed through by the non-transfer record and determine the shortest path between OD pairs according to the fully directed metro network topology to obtain the first shortest path.

[0130] The second acquisition unit is used to acquire the number of stations and platform numbers passed through in the transfer record and, based on the fully directed metro network topology, determine the shortest path between OD pairs with the goal of minimizing the number of transfers, thus obtaining the second shortest path.

[0131] The station slicing unit is used to slice the stations traversed by the transfer record. Stations with the same route belong to a non-transfer sub-record, so as to divide a transfer OD pair into multiple non-transfer OD pairs.

[0132] The extraction unit is used to correct non-transfer OD pairs and multiple non-transfer OD pairs for transfers into directed OD pairs. The subway line stations are constructed into a vector according to the subway running direction. The index of the destination platform number in the vector is subtracted from the index of the departure platform number in the vector. If the difference is positive, the destination platform number and the departure platform number remain unchanged; if the difference is negative, the destination platform number and the departure platform number become their respective opposites, thus obtaining the directed OD pairs.

[0133] For example, the first determining module includes:

[0134] The first calculation unit is used to calculate the non-transfer travel time according to the following formula:

[0135]

[0136] in, For non-transfer scenarios, the time it takes for passenger k to swipe their card and exit platform p at station s on line l during time slot (t,d); The time during which passenger k swipes his card to enter platform p of station s on line l under non-transfer conditions (t,d); The time it takes for passenger k to walk from station s turnstile on line l to platform p, or the time it takes for passenger k to walk from platform p on line l to exit station s turnstile. α represents the shortest waiting time for passenger k at platform p in station s of line l, without transfers; s,l β is the time it takes for the train to travel from station s to station s+l. s,l The time the train stays at station s; s represents the number of stations the train passes through; s represents the index of the station that passenger k passes through on line l.

[0137] The second calculation unit is used to calculate the transfer travel time according to the following formula:

[0138]

[0139] Where t is the number of time slots in a day; d is the index of the day in a week; The time during which passenger k swipes his card and exits from platform p at station s on line l during time slot (t,d) in the case of a transfer; The time during which passenger k swipes his card to enter platform p of station s on line l during time slot (t,d) in the case of transfer; q represents the shortest waiting time for passenger k at platform p in station s on line l when transferring; k For the number of transfers for passengers; t q The average time spent on the transfer process; k Let be the total number of routes traveled by passenger k; and let i be the index of all routes traveled by passenger k.

[0140] For example, the prediction module includes:

[0141] The third acquisition unit is used to acquire passenger flow data for transfer platforms within the target time period. Let be the passenger flow at platform p of station s on line l during the nth observation time window; n is the total length of the time series.

[0142] The interpolation unit is used to interpolate wind speed, temperature, and precipitation to ensure that wind speed, temperature, and precipitation maintain the same time series length as passenger flow within the corresponding observation period; where wind speed is M. t ={m 1 ,m 2 ,…,m n The temperature is C. t ={c 1 ,c 2 ,…,c nThe precipitation was I. t ={i 1 i 2 ,…,i n};m n c represents the wind speed during the nth observation time window. n Let i be the temperature of the nth observation time window; n Let be the precipitation amount during the nth observation time window.

[0143] Prediction unit, used to predict X p,s,l M t C t and I t The data is fed into the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow at each station.

[0144] For more detailed information on the working process of each of the above modules, please refer to the relevant content disclosed in Example 1, which will not be repeated here.

[0145] Example 3

[0146] This embodiment provides a computer device, including a processor and a memory; wherein, when the processor executes the computer program stored in the memory, it implements the steps of the rail transit platform passenger flow prediction method described in Embodiment 1.

[0147] For a more detailed explanation of the above method, please refer to the relevant content disclosed in Example 1, which will not be repeated here.

[0148] Example 4

[0149] This embodiment provides a computer-readable storage medium for storing a computer program; when the computer program is executed by a processor, it implements the steps of the rail transit platform passenger flow prediction method described in Embodiment 1.

[0150] For a more detailed explanation of the above method, please refer to the relevant content disclosed in Example 1, which will not be repeated here.

[0151] Example 5

[0152] This embodiment provides a computer program product, including computer-executable instructions or a computer program. When the computer-executable instructions or the computer program are executed by a processor, they implement the steps of the rail transit platform passenger flow prediction method described in Embodiment 1.

[0153] For a more detailed explanation of the above method, please refer to the relevant content disclosed in Example 1, which will not be repeated here.

[0154] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the systems, devices, storage media, and computer program products disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the descriptions are relatively simple, and relevant parts can be referred to the method section.

[0155] Those skilled in the art will clearly understand that the techniques in the embodiments of the present invention can be implemented using software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solutions in the embodiments of the present invention, or the parts that contribute to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments or certain parts of the embodiments of the present invention.

[0156] In some embodiments, computer-executable instructions may take the form of programs, software, software modules, scripts, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as stand-alone programs or as modules, components, subroutines, or other units suitable for use in a computing environment.

[0157] As an example, computer-executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple co-located files (e.g., files that store one or more modules, subroutines, or code sections).

[0158] As an example, computer-executable instructions can be deployed to execute on a single electronic device, or on multiple electronic devices located in one location, or on multiple electronic devices distributed across multiple locations and interconnected via a communication network.

[0159] The present invention has been described in detail above with reference to specific embodiments and exemplary examples; however, these descriptions should not be construed as limiting the present invention. Those skilled in the art will understand that various equivalent substitutions, modifications, or improvements can be made to the technical solutions and embodiments of the present invention without departing from the spirit and scope of the invention, and all such modifications and improvements fall within the scope of the present invention. The scope of protection of the present invention is defined by the appended claims.

Claims

1. A method for passenger flow prediction of a rail transit platform, characterized in that, The method comprises the following steps: extracting a directed OD pair from the entry and exit records of the automatic fare collection system based on a complete directed network; determining the journey time of non-transfer and one-time transfer; wherein the journey time includes the time for a passenger to walk to the platform, the average waiting time of non-transfer, the train stay time at the platform, the average walking time of transfer, the average waiting time of transfer, and the time for a passenger to walk from the platform to the exit gate; determining the real-time position of the passenger according to the directed OD pair and the journey time; determining the passenger flow of each platform in the target time period according to the real-time position of the passenger; obtaining and processing weather factors; wherein the weather factors include wind speed, temperature, and precipitation; constructing a CNN-BiLSTM-Attention passenger flow prediction model; taking the passenger flow of each platform in the target time period and the weather factors as input variables, and using the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow of each platform; wherein the determination of the journey time of non-transfer and one-time transfer comprises: calculating the journey time of non-transfer according to the following formula: ; wherein, is the time when passenger k swipes in at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k swipes out at station s on platform p for non-transfer case; is the time when passenger k swipes in at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k swipes out at station s on platform p for non-transfer case; is the time when passenger k walks from the gate at station s to platform p for non-transfer case; is the time when passenger k walks from platform p to the gate at station s for non-transfer case; is the time when passenger k waits for the train at platform p in station s for non-transfer case; is the time when passenger k waits for the train at platform p in station s for non-transfer case; is the time when passenger k waits for the train at platform p in station s for non-transfer case; is the time when train runs from station s to station s+1; is the time when train runs from station s to station s+1; is the time when train runs from station s to station s+1; is the time when train runs from station s to station s+1; is the time when train runs from station s to station s+1; calculating the journey time of transfer according to the following formula: ; where t is the number of time slots in a day; d is the index of day in a week; is the time when passenger k swipes in at station s on line for the time slot (t, d) in the case of transfer; is the time when passenger k swipes out at station s on line for the time slot (t, d) in the case of transfer; is the shortest time when passenger k waits for a train at station p in station s on line for the time slot (t, d) in the case of transfer; is the number of transfers for passenger k; is the average time spent in the process of transfer; is the total number of lines that passenger k has traveled on; i is the index of all lines that passenger k has traveled on. 2.The rail transit platform passenger flow prediction method of claim 1, wherein, the extraction of the directed OD pair from the entry and exit records of the automatic fare collection system based on a complete directed network comprises: converting a single card swiping record collected by the automatic fare collection system into a non-directed OD pair, grouping passenger records by ID number, sorting the records in the group by time sequence and entry and exit state, moving the entire list up by one row and splicing it with the original list, and deleting records with different ID numbers or mismatched entry and exit states, to extract the OD pair based on the station within a day; wherein each OD pair contains the departure station number and the destination station number of a passenger; re-numbering the platforms based on a complete directed network, in the format of "line + platform number"; constructing a complete directed subway network topology structure according to the transfer and non-transfer records; wherein the OD pairs on the same line are non-transfer, and the OD pairs on different lines are transfer; obtaining the number of stations passed by the non-transfer records and the platform numbers, and determining the shortest path between the OD pairs according to the complete directed subway network topology structure, to obtain the first shortest path; obtaining the number of stations passed by the transfer records and the platform numbers, and determining the shortest path between the OD pairs according to the complete directed subway network topology structure, to obtain the second shortest path; slicing the stations passed by the transfer records, and dividing the OD pairs of a transfer into multiple non-transfer OD pairs according to the stations on the same line; correcting the non-transfer OD pairs and the multiple non-transfer OD pairs of the transfer into directed OD pairs, and constructing a vector according to the subway line stations in the running direction, subtracting the sequence number of the departure platform number in the vector from the sequence number of the terminal platform number in the vector, if the difference is positive, the terminal platform number and the departure station number remain unchanged; if the difference is negative, the terminal platform number and the departure station number are changed to their respective opposites, to obtain the directed OD pair.

3. The rail transit platform passenger flow prediction method of claim 1, wherein, The passenger flow of each platform in a target time period and weather factors are taken as input variables, and a CNN-BiLSTM-Attention passenger flow prediction model is used to predict the passenger flow of each platform. Obtaining passenger flow of transfer platform in target time period ; Passenger flow of platform p of site s on line n is total length of time series; The wind speed, the temperature and the precipitation are interpolated to make the wind speed, the temperature and the precipitation respectively keep the same time sequence length with the passenger flow in the corresponding observation time period; wherein the wind speed is , the temperature is , and the precipitation is ; is the wind speed of the n th observation time window; is the temperature of the n th observation time window; is the precipitation of the n th observation time window; The , , and are input to the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow of each station.

4. A rail transit platform passenger flow prediction system, characterized in that, It comprises: The extraction module is configured to extract directed OD pairs from the entry and exit records of the automatic fare collection system based on the complete directed network; The first determination module is configured to determine the travel time of non-transfer and one-time transfer; wherein the travel time includes the time for passengers to walk to the platform, the average waiting time for non-transfer, the time for the train to stay at the platform, the average walking time for transfer, the average waiting time for transfer, and the time for passengers to walk from the platform to the exit gate; The second determination module is configured to determine the real-time position of the passenger according to the directed OD pair and the travel time; The third determination module is configured to determine the passenger flow of each platform in the target time period according to the real-time position of the passenger; The acquisition module is configured to acquire and process weather factors; wherein the weather factors include wind speed, temperature and precipitation; The construction module is configured to construct a CNN-BiLSTM-Attention passenger flow prediction model; The prediction module is configured to take the passenger flow of each platform in a target time period and weather factors as input variables, and use a CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow of each platform; The first determination module comprises: The first calculation unit is configured to calculate the travel time of non-transfer according to the following formula: ; wherein, is the time when passenger k swipes in at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k swipes out at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k swipes in at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k swipes out at station s on platform p during time slot (t, d) for non-transfer case; is the time when passenger k walks from the gate at station s to platform p on line or the time when passenger k walks from platform p to the gate at station s on line ; is the minimum time when passenger k waits for a train at platform p at station s on line for non-transfer case; is the time when train runs from station s to station s+ ; is the dwell time of train at station s; is the number of stations that train passes through; s is the index of station that passenger k passes through on line ; The second calculation unit is configured to calculate the travel time of transfer according to the following formula: ; Where t is the number of time slots in a day; d is the index of the day in a week; During the time slot (t,d) in the case of a transfer, passenger k swipes his card from the line. The time of departure from platform p at station s; During the time slot (t,d) when transferring, passenger k swipes their card to enter the line. The time at platform p in station s; For passenger k on the line during a transfer The shortest waiting time for a train at platform p in station s; The number of transfers for passengers; The average time spent on the transfer process; Let be the total number of routes traveled by passenger k; and let i be the index of all routes traveled by passenger k.

5. The rail transit platform passenger flow prediction system of claim 4, wherein, The extraction module comprises: The conversion unit is configured to convert a single card swiping record collected by the automatic fare collection system into a directed OD pair, group passenger records by ID number, sort them in time sequence and entry and exit state, move the entire list up one row and splice it with the original list, delete records with different ID numbers or mismatched entry and exit states, and extract OD pairs based on stations within a day; wherein each OD pair contains the departure station number and the destination station number of the passenger; The numbering unit is configured to renumber the platforms based on the complete directed network, in the format of "line + platform number"; The construction unit is configured to construct a complete directed subway network topology structure according to the transfer and non-transfer records; wherein the same line of the OD pair is non-transfer, and the different lines of the OD pair are transfer; The first acquisition unit is configured to acquire the number of stations passed by non-transfer records and the platform number, and determine the shortest path between OD pairs according to the complete directed subway network topology structure, to obtain the first shortest path; The second acquisition unit is configured to acquire the number of stations passed by transfer records and the platform number, and determine the shortest path between OD pairs according to the complete directed subway network topology structure, to obtain the second shortest path; The station slicing unit is configured to slice the stations passed by the transfer records, and the stations with the same line belong to a non-transfer sub-record, so as to divide one transfer OD pair into multiple non-transfer OD pairs; The extraction unit is used for correcting non-transfer OD pairs and multiple non-transfer OD pairs into directed OD pairs, and configuring subway line stations into a vector according to subway running directions, subtracting the sequence number of the departure station platform in the vector from the sequence number of the terminal station platform in the vector, if the difference is positive, the terminal station platform number and the departure station platform number are not changed; if the difference is negative, the terminal station platform number and the departure station platform number are changed into the opposite numbers respectively, and a directed OD pair is obtained.

6. The rail transit platform passenger flow prediction system of claim 4, wherein, The prediction module comprises: The third acquisition unit is used to acquire passenger flow data for transfer platforms within the target time period. ; For the line The passenger flow at platform p of station s during the nth observation time window; n is the total length of the time series; The interpolation unit is configured to interpolate the wind speed, the temperature and the precipitation, so that the wind speed, the temperature and the precipitation respectively maintain the same time sequence length as the passenger flow in the corresponding observation time period; wherein the wind speed is , the temperature is , and the precipitation is ; is the wind speed of the n th observation time window; is the temperature of the n th observation time window; is the precipitation of the n th observation time window; A prediction unit is configured to input the , , and to the CNN-BiLSTM-Attention passenger flow prediction model to predict the passenger flow of each station.

7. A computer device, characterized by The prediction method comprises the following steps:

8. A computer-readable storage medium, characterized in that, The prediction method comprises the following steps: A computer program is stored in the memory, and the computer program is executed by the processor to realize the steps of the rail transit station passenger flow prediction method in any one of claims 1-3.

Citation Information

Patent Citations

  • Public transportation passenger OD calculation method based on intelligent public transportation system data

    CN105788260A

  • Multi-source data driven urban rail transit train passenger capacity estimation method

    CN116777310A