A method, system, medium and device for predicting rail passenger flow in a large city

By constructing an integrated feature set of 'node-location-passenger flow' and a spatiotemporal multi-graph model, the problems of single data dimension and incomplete application functions in urban rail transit are solved, and accurate passenger flow prediction and planning decision support are achieved.

CN122114296APending Publication Date: 2026-05-29SHENZHEN NAT HIGH-TECH IND INNOVATION CENT
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHENZHEN NAT HIGH-TECH IND INNOVATION CENT
Filing Date
2026-04-28
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Existing urban rail transit passenger flow forecasting technologies suffer from problems such as limited data dimensions and incomplete application functions in large cities. They are unable to accurately capture the driving effect of the built environment on passenger flow and lack the ability to quickly analyze the passenger flow benefits of planned lines.

Method used

Collect multi-source data, including passenger flow data, built environment data, and network topology data, construct an integrated feature set of 'node-location-passenger flow', classify stations using clustering algorithms, build a differentiated prediction model, combine spatiotemporal multi-graph model to predict OD passenger flow, and generate passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes.

Benefits of technology

It achieves a comprehensive characterization of passenger flow generation and distribution, improves the adaptability and accuracy of the prediction model, and can output passenger flow benefit analysis of planned routes and passenger flow improvement strategies for existing routes, forming a complete closed loop from prediction to application.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122114296A_ABST
    Figure CN122114296A_ABST
Patent Text Reader

Abstract

The application discloses a kind of big city rail passenger flow prediction method, system, medium and equipment, comprising the following steps: collecting multi-source data;Extract the core features in multi-source data, generate integrated feature set based on core features;Based on integrated feature set, clustering algorithm is used to classify stations, and prediction model is constructed for different types of stations, integrated feature set is input into prediction model, and station passenger flow prediction result is output;OD pair in urban rail is regarded as independent graph node, and spatiotemporal multi-graph model is constructed, integrated feature set is input into spatiotemporal multi-graph model, and OD passenger flow prediction result is output, and planning route passenger flow benefit analysis strategy and existing route passenger flow improvement strategy are generated based on station passenger flow prediction result and OD passenger flow prediction result. Make the method not only output prediction result, can directly support planning decision and operation improvement, form complete closed loop from prediction to application.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

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

[0002] Urban rail transit passenger flow forecasting is a crucial foundation for rail planning and operation management. With the accelerating urbanization process in my country, the rail networks of megacities are becoming increasingly dense, and passenger flow continues to grow, placing higher demands on the accuracy and applicability of passenger flow forecasting. Currently, in megacities where the built-up environment is relatively stable, there are two main core needs: first, the passenger flow benefits of planned rail lines in the near term need to be accurately analyzed; second, the passenger flow shortcomings of existing lines and stations need to be effectively diagnosed and improved.

[0003] Existing passenger flow forecasting technologies are mainly divided into three categories: statistical model-based methods, machine learning-based methods, and network topology-based analysis methods. Machine learning-based methods primarily rely on historical passenger flow data and employ time-series algorithms such as ARIMA, LSTM, and GRU for forecasting. Network topology-based methods construct rail network models and extract topological features such as node degree and betweenness centrality to assist in passenger flow analysis. However, these methods have the following shortcomings when applied to mature rail network scenarios in megacities: First, the data dimensions are relatively limited. Existing methods are mostly limited to historical passenger flow data and time characteristics, failing to effectively integrate data on the built environment around the station, making it difficult to accurately capture the intrinsic driving force of the built environment on passenger flow generation.

[0004] Second, the application functionality is incomplete. Existing technology can only output passenger flow forecast results and lacks the ability to quickly analyze the passenger flow benefits of planned routes. Summary of the Invention

[0005] In order to overcome the shortcomings of existing technologies, such as limited data dimensions and incomplete application functions.

[0006] Firstly, a method for predicting urban rail passenger flow includes the following steps: Collect multi-source data, including passenger flow data, built environment data, and network topology data; extract core features from the multi-source data, and generate an integrated feature set based on the core features; Based on the integrated feature set, a clustering algorithm is used to classify stations. Prediction models are built for different types of stations. The integrated feature set is input into the prediction model, and the station passenger flow prediction results are output. The OD pairs in the urban rail are used as independent graph nodes to build a spatiotemporal multi-graph model. The integrated feature set is input into the spatiotemporal multi-graph model, and the OD passenger flow prediction results are output. By combining time-based projections and network dynamics, the station and OD passenger flow forecasts are integrated and double-verified. Based on the integrated forecast results, passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes are generated.

[0007] Optionally, passenger flow data in the multi-source data includes station passenger flow data and OD passenger flow data obtained from historical databases.

[0008] Optionally, the built environment data includes building data, transportation data, and supporting facilities data within the 300-meter, 500-meter, and 800-meter buffer zones around the station.

[0009] Optionally, network topology data includes line operating years, site opening time, line connection relationships, interval length, and network topology indicators.

[0010] Optionally, the clustering algorithm is the K-means++ algorithm, combined with the silhouette coefficient method to determine the number of clusters, and the stations are divided into one or more types such as hub type, commuter type, leisure type, suburban type, and transfer type. The clustering results are adjusted by manual verification to generate station type labels.

[0011] Optionally, the SHAP algorithm can be introduced into the prediction model to quantify the feature contribution and positive and negative impact of the integrated feature set and station prediction results, and output the feature importance ranking and visualization interpretation results.

[0012] Optionally, the passenger flow benefit analysis strategy for planned routes includes assessing the average daily passenger flow, peak passenger flow, OD passenger flow distribution, and transfer demand with the existing network of the planned routes; comparing and analyzing the passenger flow contribution of different stations on the planned routes; identifying core passenger flow stations and potential stations; and optimizing station connection schemes and connecting facility configurations based on the visualization interpretation results. The improvement strategy for existing routes includes diagnosing the causes of passenger flow bottlenecks based on the visualization interpretation results and OD passenger flow prediction results; formulating improvement measures based on the causes of passenger flow bottlenecks; converting the improvement measures into characteristic parameter adjustments; inputting them into the prediction model for simulation testing; and outputting the quantified improvement results.

[0013] Secondly, the present invention provides a prediction system for urban rail passenger flow, comprising: The data acquisition module is used to collect multi-source data, including passenger flow data, built environment data, and network topology data; extract core features from the multi-source data, and generate an integrated feature set based on the core features; The result prediction module is used to classify stations based on the integrated feature set using a clustering algorithm, construct prediction models for different types of stations, input the integrated feature set into the prediction model, and output the station passenger flow prediction results; it also constructs a spatiotemporal multi-graph model by treating OD pairs within the urban rail as independent graph nodes, inputs the integrated feature set into the spatiotemporal multi-graph model, and outputs the OD passenger flow prediction results.

[0014] The strategy generation module combines time-based projections with network dynamics, integrates station and OD passenger flow forecasts and performs dual verification, and generates passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes based on the integrated forecast results.

[0015] Thirdly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method of the first aspect.

[0016] Fourthly, the present invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; When a processor executes a program stored in memory, it implements the steps of the method described in the first aspect.

[0017] The beneficial effects of this invention are as follows: This application constructs an integrated feature set of "node-location-passenger flow," achieving deep integration of three types of features: network topology, built environment, and passenger flow time sequence. This breaks through the limitations of the single data dimension in existing technologies, enabling the prediction model to more comprehensively capture the inherent mechanisms of passenger flow generation and distribution. Clustering algorithms are used to classify stations, achieving differentiated modeling for different types of stations, avoiding the accuracy loss caused by the traditional "one-size-fits-all" modeling method, and improving the adaptability of the prediction model. OD pairs are used as independent graph nodes to construct a spatiotemporal multi-graph model, innovatively solving the problem of insufficient spatiotemporal correlation characterization in OD passenger flow prediction, making OD passenger flow prediction results more accurate and maintaining logical consistency with station passenger flow prediction results. The invention generates passenger flow benefit analysis strategies for planned routes and passenger flow improvement testing strategies for existing routes, enabling this method not only to output prediction results but also to directly support planning decisions and operational improvements, forming a complete closed loop from prediction to application. Attached Figure Description

[0018] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0019] Figure 1 This is a flowchart of the present invention; Figure 2 This is another flowchart of the present invention. Detailed Implementation

[0020] The following will clearly and completely describe the concept, specific structure, and technical effects of the present invention in conjunction with embodiments and accompanying drawings, so as to fully understand the purpose, features, and effects of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, not all of them. Other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are all within the scope of protection of the present invention. Furthermore, all connections / linkages involved in the patent do not simply refer to direct contact between components, but rather to the ability to form a better connection structure by adding or reducing connecting accessories according to specific implementation conditions. The various technical features in this invention can be combined interactively without contradicting each other.

[0021] This invention provides a method for predicting urban rail passenger flow, comprising the following steps: S1. Collect multi-source data, including passenger flow data, built environment data, and network topology data; extract core features from the multi-source data, and generate an integrated feature set based on the core features; S2. Based on the integrated feature set, a clustering algorithm is used to classify stations. Prediction models are built for different types of stations. The integrated feature set is input into the prediction model, and the station passenger flow prediction results are output. The OD pairs in the urban rail are used as independent graph nodes to build a spatiotemporal multi-graph model. The integrated feature set is input into the spatiotemporal multi-graph model, and the OD passenger flow prediction results are output. S3. Combining time projection and network dynamic changes, the station and OD passenger flow prediction results are integrated and double-verified. Based on the integrated prediction results, a passenger flow benefit analysis strategy for planned routes and a passenger flow improvement strategy for existing routes are generated.

[0022] In this context, OD stands for Origin-Destination. O (Origin): the starting point of the journey, i.e., the station where the passenger begins their trip; D (Destination): the ending point of the journey, i.e., the station where the passenger ends their trip. An OD pair refers to a pairing of a specific origin station and a specific destination station, used to represent the passenger flow relationship between these two stations. Passenger flow data refers to a set of data reflecting the characteristics and distribution patterns of passenger travel behavior in urban rail transit systems, including passenger entry and exit information, travel routes, and travel times. It is the core foundational data for rail transit operation management and passenger flow forecasting. Built Environment Data refers to a set of data describing the characteristics of the man-made physical environment in a city, including land use, transportation facilities, and functional support facilities, reflecting the physical form and functional layout of urban space. Network Topology Data refers to a set of data describing the structural characteristics of the urban rail transit network, including line connections, station spatial locations, and network connectivity, reflecting the physical form and structural characteristics of the rail network.

[0023] Specifically, firstly, by collecting multi-source data (passenger flow data, built environment data, and network topology data), the limitations of traditional methods that rely solely on historical passenger flow data are overcome. These three types of data reflect different aspects of the rail transit system: passenger flow data characterizes the historical patterns of travel demand, built environment data reveals the driving effect of land use around stations on passenger flow, and network topology data depicts the impact of the rail network structure on passenger flow distribution.

[0024] Secondly, core features are extracted from the aforementioned multi-source data to construct an integrated feature set of "node-location-passenger flow". The "node" feature originates from network topology data, reflecting the station's structural location within the rail network; the "location" feature originates from built environment data, reflecting the intensity and mix of land use around the station; and the "passenger flow" feature originates from historical passenger flow data, reflecting the scale and temporal distribution of travel demand at the station. The integration of these three features forms a complete characterization of the station's passenger flow.

[0025] Secondly, a clustering algorithm is used to classify stations based on the integrated feature set. Since the passenger flow formation mechanisms and evolution patterns of different types of stations (such as hub stations, commuter stations, and tourist stations) differ significantly, clustering groups stations with similar characteristics into one category, laying the foundation for subsequent differentiated modeling. For each type of station, a hybrid prediction model is constructed, inputting the integrated feature set into the model and outputting the passenger flow prediction results for that type of station.

[0026] Simultaneously, OD pairs are treated as independent graph nodes, and a spatiotemporal multi-graph model is constructed. OD pairs represent travel relationships between two stations, and traditional methods struggle to effectively model their spatiotemporal correlation characteristics. By constructing a spatiotemporal multi-graph model, the spatial relationships (spatial graph), temporal relationships (temporal graph), and travel destination relationships (OD relationship graph) of OD pairs are modeled in a unified manner. An integrated feature set and OD time-series data are input, and OD passenger flow prediction results are output.

[0027] Finally, based on the station passenger flow forecast results and the OD passenger flow forecast results, two types of application strategies are generated: one is the passenger flow benefit analysis strategy for planned lines, which is used to evaluate the expected passenger flow level of newly built lines; the other is the passenger flow improvement test strategy for existing lines, which is used to diagnose the passenger flow shortcomings of existing lines and test the effectiveness of improvement measures.

[0028] This application constructs an integrated feature set of "node-location-passenger flow," achieving deep integration of three types of features: network topology, built environment, and passenger flow temporal sequence. This overcomes the limitations of existing technologies with their single data dimension, enabling the prediction model to more comprehensively capture the intrinsic mechanisms of passenger flow generation and distribution. Clustering algorithms are used to classify stations, enabling differentiated modeling for different station types and avoiding the accuracy loss caused by traditional "one-size-fits-all" modeling methods, thus improving the adaptability of the prediction model. Od-origin pairs are used as independent graph nodes to construct a spatiotemporal multi-graph model, innovatively solving the problem of insufficient spatiotemporal correlation characterization in OD passenger flow prediction, making OD passenger flow prediction results more accurate and maintaining logical consistency with station passenger flow prediction results. The application generates passenger flow benefit analysis strategies for planned routes and passenger flow improvement testing strategies for existing routes, enabling the method to output three types of structured results. These include not only prediction results but also passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes, directly supporting planning decisions and operational improvements, forming a complete closed loop from prediction to application.

[0029] Furthermore, based on travel distance and combined with station type labels, OD pairs are categorized into commuter, leisure, transfer, and long-distance cross-regional types, providing a basis for differentiated feature extraction. Treating OD pairs as independent graph nodes, a spatiotemporal multi-graph model is constructed. ST-MGNN (Spatiotemporal Multi-Graph Neural Network) is used to extract differentiated spatiotemporal features, achieving accurate prediction of the entire network's OD passenger flow matrix while considering both categorized features and spatiotemporal correlation characterization. The spatiotemporal multi-graph model includes three sub-graphs: a spatial graph, a temporal graph, and an OD relationship graph. The spatial graph uses OD pairs as nodes, with edge weights representing the spatial distance between the origin and destination stations and the strength of the line association. The temporal graph uses OD pair time-series data as nodes, with edge weights representing the correlation of OD passenger flow in adjacent time periods. The OD relationship graph uses OD pairs as nodes, with edge weights representing the similarity of travel purposes and the consistency of transfer paths for the OD pairs. A time-series multi-graph sequence is generated by year to construct the spatiotemporal multi-graph, treating OD pairs as independent graph nodes, and constructing the spatial graph, temporal graph, and OD relationship graph. Figure 1 This approach integrates spatiotemporal multi-graph data and uses the ST-MGNN model to capture the spatiotemporal linkage and typological features of OD pairs, overcoming the shortcomings of existing OD prediction technologies that rely on interpolation and lack spatiotemporal correlation characterization. ST-MGNN can accurately adapt to the evolutionary patterns of different types of OD pairs, significantly improving the accuracy of OD passenger flow matrix prediction and filling the gap in network-wide OD collaborative prediction. The ST-MGNN model includes graph convolutional layers, temporal convolutional layers, and a fusion output layer. The graph convolutional layers extract features from three types of subgraphs, capturing the spatial dependence, temporal correlation, and relational coupling characteristics of OD pairs; the temporal convolutional layers extract the annual and quarterly evolution patterns of OD passenger flow, adapting to medium- and long-term prediction needs; the fusion output layer uses an attention mechanism to weightedly fuse the features of the three types of subgraphs and temporal features, outputting the OD passenger flow prediction results, fully leveraging the adaptability of ST-MGNN to multiple spatiotemporal features. Training datasets were constructed separately for each OD type, inputting spatiotemporal multi-graph features and temporal passenger flow features. ST-MGNN model parameters (graph convolution kernel size, temporal convolution window, attention weight coefficient, number of iterations) were set, and the model was trained using the Adam adaptive moment estimation optimizer and the root mean square error (RMSE) loss function. Parameters were adjusted using a validation set to ensure the adaptability and prediction accuracy of ST-MGNN for different OD types. Core spatiotemporal features of different OD types were extracted from the intermediate layer output of the ST-MGNN model, such as the peak-hour temporal stability of commuter ODs, the holiday fluctuation characteristics of leisure ODs, and the route correlation sensitivity of transfer ODs. This provides support for the interpretation of prediction results and operational decisions, enhancing the feature mining value of ST-MGNN.

[0030] Furthermore, based on station passenger flow forecasts and OD passenger flow forecasts, strategies for analyzing the passenger flow benefits of planned routes and improving passenger flow on existing routes are generated. Specifically, this includes combining time-based projections and network dynamics, integrating station and OD passenger flow forecasts, and ensuring accuracy through dual verification. Applications are developed around two core needs: first, short-term passenger flow benefit analysis for planned routes; and second, passenger flow improvement and testing for existing routes / stations, forming a complete application loop. Dual verification includes historical backtesting verification and logical consistency verification. Historical backtesting verification uses historical data for cross-year forecasts, comparing them with actual passenger flow data, and using mean absolute error (MAE), root mean square error (RMSE), and prediction accuracy as evaluation indicators to verify model accuracy. For low-accuracy types (such as suburban stations and long-distance cross-regional ODs), additional samples and features are added, and model parameters are iteratively optimized. Logical consistency verification combines the passenger flow evolution patterns of megacities and the operational characteristics of rail networks to verify the consistency between forecast results and urban development planning and passenger flow supply and demand balance, correcting extreme deviations and ensuring that the results can support planning and operational decisions.

[0031] In some embodiments, passenger flow data in multi-source data includes station passenger flow data and OD passenger flow data obtained from historical databases.

[0032] Specifically, station entry and exit passenger flow data reflects the total passenger flow of a single station and forms the basis for station-level predictions; OD (Original Departure) passenger flow data reflects the travel relationships between stations and forms the basis for OD-level predictions. These two types of data complement and verify each other, together constituting a complete passenger flow information system. The inclusion of both station-level and OD-level passenger flow data enables this method to predict and verify passenger flow from two dimensions, improving the logical consistency of the prediction results.

[0033] Furthermore, historical passenger flow data for rail stations in major cities was collected, covering daily, monthly, and annual periods, as well as weekdays, weekends, and holidays. Od / destination (OD) passenger flow data (including fields such as origin and destination stations, travel volume, and travel time) was sourced from the historical database of the rail operation management system. The data covers three time granularities: daily, monthly, and annual, and three date types: weekdays, weekends, and holidays. Daily data is used to capture short-term fluctuations, monthly data reflects seasonal changes, and annual data reveals long-term trends; the distinction between weekdays, weekends, and holidays identifies differences in passenger flow patterns across different date types. This multi-time-dimensional and multi-date-type coverage ensures the comprehensiveness and representativeness of passenger flow data. Covering daily, monthly, and annual time granularities allows the model to simultaneously learn short-term fluctuations, seasonal changes, and long-term trends in passenger flow, improving the accuracy of medium- and long-term predictions. The date types are clearly distinguished. By classifying weekdays, weekends, and holidays, the model can identify the differences in passenger flow patterns under different date types, avoiding prediction bias caused by mixing different passenger flow patterns together.

[0034] In some embodiments, the built environment data includes building data, transportation data, and supporting facilities data within a 300-meter, 500-meter, and 800-meter buffer zone around the station.

[0035] Specifically, in terms of spatial scale, three buffer radii are set: 300 meters, 500 meters, and 800 meters. 300 meters corresponds to a 5-minute walk, primarily influencing the station's direct passenger flow attraction; 500 meters corresponds to a 10-minute walk, representing the station's core service area; and 800 meters corresponds to a 15-minute walk, covering the station's secondary service area. Through multi-scale analysis, the differentiated impacts of the built environment on passenger flow within different distance ranges can be identified.

[0036] Multi-scale buffer settings enable the model to capture the differentiated impacts of the built environment on passenger flow within different spatial ranges. For example, public transport connections within 300 meters have a significant impact on short-distance travel, while commercial facilities within 800 meters have a more significant impact on non-commuter travel. The collection of building-related data allows the model to identify the fundamental impact of land use structure on passenger flow; for example, densely populated residential areas generate commuter traffic, while densely populated commercial areas attract leisure traffic. The collection of transportation-related data allows the model to quantify the enhancing or constraining effects of connectivity conditions on passenger flow; for example, stations with high bus stop density tend to have larger passenger volumes. The collection of supporting facility data allows the model to capture the attraction effect of functional agglomeration on passenger flow; for example, stations with a high density of commercial points of interest (POIs) experience significant passenger flow growth during holidays. The integrated use of these three types of data forms a complete characterization of the built environment, providing a rich information foundation for subsequent feature selection and model training.

[0037] Furthermore, data on buffer zones of 300 meters, 500 meters, and 800 meters around the station were obtained through historical building databases and map APIs. Building data included building type, building area and percentage, and building density; transportation data included the number and density of bus stops, the number of bus routes, and distance to bus hubs; and supporting infrastructure data included the number and density of commercial, residential, and office points of interest (POIs). Based on the station's latitude and longitude and the rail network topology, the station's location indicators (distance from the city center and distance from the sub-center) were quantified.

[0038] In some embodiments, network topology data includes line operating years, site opening time, line connection relationships, interval length, and network topology indicators.

[0039] Specifically, at the basic topology data level, data such as the operational years of the lines, station opening dates, line connectivity, and section lengths are collected. The operational years of a line reflect its maturity; lines with longer operating histories generally have more stable passenger flow. Station opening dates reflect the station's service history; newly opened stations often experience faster passenger growth. Line connectivity depicts the network's connectivity structure. Section lengths affect passengers' travel time and transfer choices. Collecting basic topology data allows the model to consider the impact of network evolution on passenger flow, such as the redistribution of passenger flow caused by the opening of new lines and the commissioning of new stations.

[0040] Furthermore, network topology metrics are calculated based on network topology, and include node degree, betweenness centrality, proximity centrality, and path association strength. Node degree: The number of lines directly connected to a station, reflecting the station's connectivity. Calculating node degree allows the model to identify passenger flow agglomeration effects at transfer stations, which typically have higher passenger flow volumes. Betweenness centrality: The number of shortest paths through a station, reflecting the station's function as a transfer hub in the network. Calculating betweenness centrality allows the model to quantify a station's transfer function in the network; stations with high betweenness centrality are often important transfer hubs.

[0041] Proximity centrality: The reciprocal of the average distance from a station to all other stations, reflecting the station's accessibility. Calculating proximity centrality allows the model to assess a station's network accessibility; stations with high accessibility are more likely to attract passenger flow. Line association strength: The degree of association between a station and a specific line, reflecting the station's importance within the line. Calculating line association strength allows the model to identify a station's functional positioning within a specific line; for example, line terminus stations often have unique passenger flow characteristics. These indicators are calculated using graph theory methods, quantifying the station's structural location and functional role within the network.

[0042] In some embodiments, the clustering algorithm is the K-means++ algorithm, combined with the silhouette coefficient method to determine the number of clusters, and the stations are divided into one or more types such as hub type, commuter type, leisure type, suburban type, and transfer type. The clustering results are adjusted by manual verification to generate station type labels.

[0043] Specifically, the K-means++ algorithm is used. This algorithm is an optimization of the traditional K-means algorithm. By improving the selection strategy of initial cluster centers, it makes the initial cluster centers as dispersed as possible, avoiding the problem of traditional K-means getting trapped in local optima due to improper selection of initial centers, thus improving the stability and reliability of clustering.

[0044] The silhouette coefficient method was used to determine the number of clusters. The silhouette coefficient combines intra-cluster cohesion and inter-cluster separation, and its value ranges from [-1, 1]. A larger value indicates a better clustering effect. By calculating the silhouette coefficient under different K values, the K with the largest coefficient was selected as the optimal number of clusters, avoiding the arbitrariness of subjectively setting the number of clusters.

[0045] In applying the clustering results, stations are categorized into hub-type, commuter-type, leisure-type, suburban-type, and transfer-type stations. Hub-type stations are where multiple lines converge, handling a large volume of transfer passengers. Commuter-oriented stations are located in areas primarily occupied by residential and office buildings, with significant passenger flow during morning and evening rush hours. Leisure-oriented stations are surrounded by dense commercial and tourist facilities, experiencing significant passenger flow growth during holidays. Suburban stations are located on the city's outskirts, with relatively small passenger volumes but high growth potential. Transfer-oriented stations primarily function as line transfer stations, with fewer inbound and outbound passengers but large transfer passenger volumes. Finally, the clustering results are adjusted through manual verification combined with operational scenarios. Machine learning clustering may contain biases that do not match reality. Manual verification by operations personnel, combined with practical operational experience, fine-tunes the clustering results to generate the final station type labels, ensuring the practicality and interpretability of the classification results.

[0046] Furthermore, the core features of the three dimensions of "node-location-passenger flow" are integrated, and the variance filtering method is used to remove redundant features, retaining core features (such as betweenness centrality, 800-meter commercial building density, average annual passenger flow, and peak passenger flow ratio) as clustering inputs to ensure that the clustering is based on the integrated feature logic. The K-means++ algorithm (optimizing the selection of initial cluster centers and improving clustering stability) is used, combined with the silhouette coefficient method to determine the optimal number of clusters, classifying stations into hub type, commuter type, leisure type, suburban type, and transfer type. The clustering results are adjusted through manual verification (in combination with actual operation scenarios) to generate station type labels, laying the foundation for categorized modeling. The K-means++ algorithm is used to optimize the initial cluster centers, and stations are accurately classified based on the multi-dimensional features of "node-location-passenger flow", abandoning the simple classification or "one-size-fits-all" modeling methods of existing technologies.

[0047] In some embodiments, the SHAP algorithm is introduced into the prediction model to quantify the feature contribution and positive / negative impact of the integrated feature set and station prediction results, and output the feature importance ranking and visualization interpretation results.

[0048] Specifically, feature contribution metric quantification involves inputting the integrated feature set and station prediction results into the SHAP algorithm. The algorithm calculates a SHAP value for each feature of each sample. For example, for passenger flow prediction at a station, the SHAP value for the density of commercial buildings within 800 meters is +0.3, indicating that this feature increases the predicted passenger flow by 0.3 standardized units; while the SHAP value for distance from the city center is -0.2, indicating that this feature decreases the predicted passenger flow by 0.2 standardized units. Feature contribution metric quantification makes previously uninterpretable machine learning models transparent, enabling explicit answers to the question "why this value is predicted," greatly enhancing the model's credibility and acceptability.

[0049] Feature importance ranking is achieved by averaging the absolute values ​​of the SHAP values ​​of all features across all samples, resulting in a global feature importance ranking. Features with larger absolute SHAP values ​​have a greater average impact on the prediction results, thus generating a feature importance ranking and identifying the most critical factors affecting passenger flow. Feature importance ranking helps operations personnel identify key factors influencing passenger flow, providing clear guidance for resource allocation and optimization, and avoiding blind improvements.

[0050] Visual interpretation. The SHAP algorithm can generate various visualization charts, such as feature importance bar charts, SHAP value distribution charts, and feature dependency graphs, which intuitively show how and to what extent each feature affects the prediction results. Visual interpretation of results allows complex model analysis results to be presented in an intuitive chart format, making it easier to explain and communicate to non-technical personnel (such as planning decision-makers and operations managers).

[0051] Furthermore, the prediction model is a weighted ensemble prediction model of Random Forest (RF) and XGBoost. RF focuses on handling high-dimensional features and suppressing overfitting, adapting to coupled scenarios with multi-dimensional features of "node-location-passenger flow". Combining RF and XGBoost hybrid modeling, it balances the advantages of high-dimensional feature processing capabilities and nonlinear fitting, improving the prediction accuracy of different types of stations such as hub-type and commuter-type stations by more than 25% compared to traditional models, and is suitable for medium- and long-term prediction needs. XGBoost focuses on capturing nonlinear correlations and threshold effects between features, making up for the shortcomings of RF in fitting complex interactive features. Modeling is performed separately according to station type. The integrated feature set of "node-location-passenger flow" for the corresponding type of station is input, and the preliminary prediction results are output. For model training, historical data was used to divide the training, validation, and test sets in a 7:2:1 ratio. RF parameters (number of decision trees, tree depth, feature sampling ratio) and XGBOOST parameters (learning rate, tree depth, number of iterations, regularization coefficient) were set, and a grid search method was used to optimize the parameters. Mean squared error (MSE) was used as the loss function, and an early stopping mechanism was employed to prevent overfitting. The ensemble weights of the two models were dynamically adjusted based on the validation set accuracy to output the optimal prediction model. The input features and prediction results of the prediction model were then imported into the SHAP algorithm. The SHAP value quantified the contribution and positive / negative impact of each feature on the station passenger flow prediction results, generating a feature importance ranking and a visual interpretation chart. This invention focuses on exploring the threshold effect of built environment characteristics (e.g., after the density of commercial buildings within 800 meters reaches a certain threshold, the growth rate of passenger flow at stations slows down significantly). This provides a basis for site selection of planned lines and station locations, passenger flow benefit assessment, and precise diagnosis of the causes of passenger flow shortcomings in existing stations (e.g., insufficient connecting facilities and weak commercial facilities). It also provides a precise basis for operational optimization and supporting planning. This invention innovatively constructs an integrated feature system of "node-location-passenger flow," integrating three types of features: network topology, multi-scale built environment, and passenger flow temporal sequence. It breaks through the limitations of existing technologies that extract features in isolation, accurately depicting the synergistic relationship among the three. At the same time, the SHAP algorithm is used to explore the nonlinear influence and threshold effect of the built environment on passenger flow, providing clear physical meaning support for the prediction results and solving the problem of insufficient feature mining in existing technologies. The RF+XGBoost hybrid model ensures prediction accuracy, and the SHAP algorithm is used to realize the quantification of feature contribution and the mining of threshold effect, solving the "black box" problem of traditional machine learning. The ST-MGNN model simultaneously extracts OD-typed spatiotemporal features, forming a closed loop of "precise prediction - feature interpretation - decision guidance." Compared to existing technologies that only output prediction results, this invention can provide a clear basis for operational optimization and has greater practical value.

[0052] In some embodiments, the passenger flow benefit analysis strategy for planned routes includes assessing the average daily passenger flow, peak passenger flow, OD passenger flow distribution, and transfer demand with the existing network of the planned routes; comparing and analyzing the passenger flow contribution of different stations on the planned routes; identifying core passenger flow stations and potential stations; and optimizing station connection schemes and connection facility configurations based on the visualization interpretation results. The improvement strategy for existing routes includes diagnosing the causes of passenger flow bottlenecks based on the visualization interpretation results and OD passenger flow prediction results; formulating improvement measures based on the causes of passenger flow bottlenecks; converting the improvement measures into characteristic parameter adjustments; inputting them into the prediction model for simulation testing; and outputting the quantified improvement results.

[0053] Specifically, the average daily passenger flow assessment predicts the average daily passenger volume after the planned line is completed, and is a basic indicator for measuring the overall effectiveness of the line. The peak passenger flow assessment predicts the passenger volume during the morning and evening peak hours, and is used to determine the line's capacity pressure and service level during peak periods.

[0054] OD Passenger Flow Distribution Assessment: This analyzes the passenger flow distribution of relevant OD pairs along the planned route, identifies major passenger flow directions and OD intensity, and provides a basis for capacity allocation. Transfer Demand Assessment: This predicts the transfer passenger flow between the planned route and the existing network, identifies major transfer stations and transfer directions, and provides a basis for transfer station design. Core passenger flow stations are those with high passenger flow contribution and play a decisive role in the overall passenger flow of the route; their service capacity needs to be prioritized. Potential stations are those with low current passenger flow contribution but high growth potential; passenger flow can be increased through optimized connections and improved facilities. Based on the visualization interpretation results, the connection design between stations and surrounding transportation is optimized in a targeted manner, such as adding bus connection routes and optimizing pedestrian walkways. Based on the passenger flow forecast scale and characteristics analysis, connection facilities such as bicycle parking, taxi stands, and P+R parking lots are rationally allocated. Multi-dimensional passenger flow assessment comprehensively measures the passenger flow benefits of the planned route from multiple perspectives, including average daily passenger flow, peak passenger flow, OD distribution, and transfer demand, avoiding the one-sidedness of single-indicator evaluation and providing comprehensive information support for planning decisions. Visual interpretation of the results is introduced to analyze the characteristic contribution of stations with shortcomings. For example, if the predicted passenger flow of a station is lower than the actual expectation, SHAP analysis reveals that the SHAP value of the station's "300-meter bus stop density" characteristic is negative and has a large absolute value, indicating that insufficient bus connections are the main factor leading to the low passenger flow.

[0055] This study introduces an OD (Original Department) passenger flow analysis structure to analyze the passenger flow characteristics of OD pairs related to stations with shortcomings. For example, among the OD pairs related to this station, the peak passenger flow of commuter ODs is lower than expected, indicating a deficiency in the station's commuter function. Targeted improvement measures are formulated based on the diagnostic results, avoiding resource waste and ineffective investment, and ensuring that limited operational resources are used where they are most critical. The improvement measures are transformed into characteristic parameters, adjusted, and then input into the model for testing. This allows for prediction of the effects before actual implementation, reducing trial-and-error costs and implementation risks. The formation of a "diagnosis-improvement-testing" closed loop shifts the passenger flow improvement work on existing lines from experience-driven to data-driven, enhancing the scientific rigor and effectiveness of the improvement work. It fills the gap in existing technologies that "can only predict, not improve," enabling this method not only to identify problems but also to propose solutions and verify their effectiveness, forming a complete decision support capability.

[0056] Furthermore, by combining SHAP analysis (visualized interpretation results) with ST-MGNN feature extraction results (OD passenger flow prediction results), the core causes of insufficient passenger flow are accurately identified, such as insufficient bus connection stations within a 300-meter radius, weak commercial facilities, and low node centrality. Based on the causes of passenger flow shortcomings, targeted improvement plans are proposed, such as adding bus connection stations, optimizing commercial facilities around stations, and adjusting operating hours. The causes of passenger flow shortcomings are converted into a passenger flow shortcomings diagnostic report. Based on the passenger flow shortcomings diagnostic report, improvement measures are output, and the improvement measures are tested to output passenger flow test results. The results are presented in structured tables and visual charts (passenger flow distribution map, feature impact map, and improvement effect comparison map), fully supporting rail planning and operation optimization decisions, and fully demonstrating the application value of the "node-location-passenger flow" system and ST-MGNN collaborative modeling.

[0057] This invention provides a system for predicting urban rail passenger flow, comprising: The data acquisition module is used to collect multi-source data, including passenger flow data, built environment data, and network topology data; extract core features from the multi-source data, and generate an integrated feature set based on the core features; The result prediction module is used to classify stations based on the integrated feature set using a clustering algorithm, construct prediction models for different types of stations, input the integrated feature set into the prediction model, and output the station passenger flow prediction results; it also constructs a spatiotemporal multi-graph model by treating OD pairs within the urban rail as independent graph nodes, inputs the integrated feature set into the spatiotemporal multi-graph model, and outputs the OD passenger flow prediction results.

[0058] The strategy generation module is used to generate future route planning strategies and existing route improvement strategies based on station passenger flow forecast results and OD passenger flow forecast results.

[0059] The present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a method for predicting urban rail passenger flow.

[0060] This invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; The steps of a processor to implement a method for predicting urban rail passenger flow when executing a program stored in memory.

[0061] The above is a detailed description of the preferred embodiments of the present invention. However, the present invention is not limited to the embodiments described. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention. All such equivalent modifications or substitutions are included within the scope defined by the claims of this application.

Claims

1. A method for predicting urban rail passenger flow, characterized in that, Includes the following steps: Collect multi-source data, including passenger flow data, built environment data, and network topology data; extract core features from the multi-source data, and generate an integrated feature set based on the core features; Based on the integrated feature set, a clustering algorithm is used to classify stations. Prediction models are built for different types of stations. The integrated feature set is input into the prediction model, and the station passenger flow prediction results are output. The OD pairs in the urban rail are used as independent graph nodes to build a spatiotemporal multi-graph model. The integrated feature set is input into the spatiotemporal multi-graph model, and the OD passenger flow prediction results are output. By combining time-based projections and network dynamics, the station and OD passenger flow forecasts are integrated and double-verified. Based on the integrated forecast results, passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes are generated.

2. The method for predicting urban rail passenger flow according to claim 1, characterized in that, Passenger flow data in multi-source data includes station passenger flow data and OD passenger flow data obtained from historical databases.

3. The method for predicting urban rail passenger flow according to claim 1, characterized in that, The built environment data includes building data, transportation data, and supporting facilities data within the 300-meter, 500-meter, and 800-meter buffer zones around the station.

4. The method for predicting urban rail passenger flow according to claim 1, characterized in that, Network topology data includes the years of operation of the lines, the opening time of the stations, the connection relationships of the lines, the length of the sections, and network topology indicators.

5. The method for predicting urban rail passenger flow according to claim 1, characterized in that, The clustering algorithm is the K-means++ algorithm, which is combined with the silhouette coefficient method to determine the number of clusters. The stations are divided into one or more types, such as hub type, commuter type, leisure type, suburban type, and transfer type. The clustering results are adjusted by manual verification to generate station type labels.

6. The method for predicting urban rail passenger flow according to claim 1, characterized in that, The SHAP algorithm is introduced into the prediction model to quantify the feature contribution and positive / negative impact of the integrated feature set and station prediction results, and output the feature importance ranking and visualization interpretation results.

7. The method for predicting urban rail passenger flow according to claim 6, characterized in that, The passenger flow benefit analysis strategy for planned routes includes assessing the average daily passenger flow, peak passenger flow, OD passenger flow distribution and transfer demand with the existing network of the planned routes, comparing and analyzing the passenger flow contribution of different stations on the planned routes, identifying core passenger flow stations and potential stations, and optimizing station connection schemes and connection facility configurations by combining the results of visualization interpretation. The existing route improvement strategy includes diagnosing the causes of passenger flow bottlenecks based on the results of visualization interpretation and OD passenger flow forecasts, formulating improvement measures based on the causes of passenger flow bottlenecks, converting the improvement measures into characteristic parameter adjustments, inputting them into the prediction model for simulation testing, and outputting the quantified improvement results.

8. A predictive system for urban rail passenger flow, characterized in that, include: The data acquisition module is used to collect multi-source data, including passenger flow data, built environment data, and network topology data. Extract core features from multi-source data and generate an integrated feature set based on these core features; The result prediction module is used to classify stations based on the integrated feature set using a clustering algorithm, build prediction models for different types of stations, input the integrated feature set into the prediction model, and output the station passenger flow prediction results; it also uses OD pairs in the urban rail transit as independent graph nodes to build a spatiotemporal multi-graph model, inputs the integrated feature set into the spatiotemporal multi-graph model, and outputs the OD passenger flow prediction results. The strategy generation module combines time-based projections with network dynamics, integrates station and OD passenger flow forecasts and performs dual verification, and generates passenger flow benefit analysis strategies for planned routes and passenger flow improvement strategies for existing routes based on the integrated forecast results.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-7.

10. An electronic device, characterized in that, It includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, when executing a program stored in memory, implements the steps of the method according to any one of claims 1-7.