Multi-view subspace learning crowd travel mode identification method and system based on dynamic and static feature fusion
Through the multi-view subspace learning method of dynamic and static features fusion, combined with mobile phone signaling data, OSM road network and public transportation data, the static and dynamic features of the travel chain are extracted and integrated, and the problem of insufficient identification result deviation and feature generalization ability in the existing technology is solved, and more accurate and stable travel mode recognition is achieved.
Patent Information
- Application Number
- CN202411763060.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-03
- Publication Date
- 2025-03-18
AI Technical Summary
When identifying the travel mode of people, the prior art does not fully consider the travel environment factors and the unique attributes of various transportation modes, resulting in deviations in the identification results. At the same time, the unified feature set lacks the ability to describe certain travel modes and the feature generalization ability is weak.
The multi-view subspace learning method of dynamic and static features is adopted to extract the static features of the travel chain through mobile phone signaling data, OSM road network and public transportation data, and the dynamic features of the trajectory are extracted using the LSTM model, fusion of static and dynamic features to capture the travel mode from multiple views.
It improves the accuracy and robustness of travel mode identification, can understand the characteristics of travel behavior more comprehensively, make up for the limitations of a single feature, and significantly improves the recognition effect.
Smart Images

Figure CN119649596A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to but is not limited to the field of big data processing technology, and in particular relates to a method and system for identifying crowd travel modes by multi-view subspace learning based on dynamic and static feature fusion. Background Art
[0002] In the era of urbanization, urban metropolitan areas are constantly expanding. For modernization construction, this is a sign of urban prosperity, but the growth of traffic has also brought tremendous pressure on urban space and infrastructure. In the past few decades, with the development of the Internet and big data era, the full adoption of mobile data, real-time traffic data and digital technology, scholars have increasingly tried to use big data and its technology to analyze urban dynamics, assist the flow of people in the city, and achieve the purpose of rationally utilizing urban public space.
[0003] Mobile phones have become an indispensable item in human life, and mobile phone signaling data has become a natural data source for recording human activities. When people send text messages, make phone calls, surf the Internet and other communication behaviors, they will generate data such as user identification codes, base station location codes, timestamps, etc., thus forming a huge amount of data. Taking Beijing as an example, the city's population of about 20 million will generate more than 6 billion mobile phone signaling data a day. These massive mobile phone signaling data record the travel information of urban residents in detail with the characteristics of spatiotemporal continuity, spatial integrity, and passive collection. Through this travel information, people's residence, travel distance, cross-regional travel and other states can be calculated, reflecting the flow of residents in urban space, and providing a basis for the optimization of urban basic transportation facilities and urban public transportation layout.
[0004] With the rapid development of urban transportation networks, residents' travel behavior has become more free, and it has become very complicated to understand residents' travel patterns. By analyzing residents' travel behavior and travel chain patterns, we can provide a scientific basis for the distribution and planning of transportation resources. At the same time, crowd travel pattern analysis can also be used for commercial purposes to provide consumers with convenient travel and life services.
[0005] Traditional crowd travel pattern analysis is mainly in the form of questionnaire surveys, which directly face the survey subjects to obtain their daily traffic travel conditions, and then integrate the survey results to analyze the travel patterns of residents. This method has a long data acquisition cycle, high cost, poor timeliness, and text data has certain ambiguity. In recent years, researchers have used positioning technology to obtain residents' travel data and then analyze crowd travel patterns. For example, Mao et al. analyzed the spatiotemporal patterns of urban residents' travel based on floating car data and POI data; Yao et al. used GPS data to mine users' travel patterns and identify transfer points for travel modes; Zeng et al. proposed the TaaS method to process GPS trajectory data and identified three modes of transportation. In 2000, Bolla et al. used mobile phone signaling data for the first time based on mobile phone signal base stations to evaluate the average vehicle density and flow of roads; subsequently, White et al. also applied mobile phone signaling data to the study of traffic flow information analysis such as traffic flow and traffic density; and Zhai et al., Shi et al., Fu et al. also used mobile phone signaling data to conduct in-depth research on mobile phone user behavior. In China, Ran Bin et al. proposed a research plan to combine mobile phone signaling with geospatial data, and put forward suggestions for urban planning through the spatial distribution of population activities. Yingna et al., Cao et al., Fu et al. also analyzed the population mobility and commuting behavior in the study area through mobile phone signaling data. The above research shows that positioning data such as vehicle GPS and mobile phone signaling are increasingly widely used in crowd travel pattern mining, bringing new data sources to crowd travel pattern research.
[0006] At the same time, researchers have also begun to use machine learning methods to identify residents' travel patterns. Yang et al. used the SVM model to extract residents' travel characteristics from GPS data and clustered them to identify residents' travel methods. Li used a decision tree to extract residents' travel trajectories from mobile phone signaling data, and identified people's travel methods based on the speed, time, distance and other features extracted from the trajectories. Therefore, different machine learning methods can be used according to different purposes to explore the connection between residents' travel characteristics and travel methods, so as to improve the accuracy of travel method identification.
[0007] In view of the above analysis, the technical problems that need to be solved urgently in the prior art are:
[0008] In existing travel mode recognition research, travel modes are mainly identified by extracting basic features (such as speed, time, distance, etc.) from residents' trajectory behaviors through various positioning data. However, this method does not fully consider the travel traffic environment factors and the unique attributes of various modes of transportation. For example, buses and subways usually follow fixed routes, while private cars or taxis have more flexible route choices. The travel time distribution characteristics of different modes of transportation (such as commuting patterns during peak hours) will also show differences. These factors may affect the effective identification of travel modes, resulting in biased recognition results.
[0009] At the same time, existing research methods mainly identify residents' travel modes by constructing a unified feature set and applying a multi-classification model. However, the unified feature set lacks the ability to describe certain travel modes and has weak feature generalization capabilities, which requires the machine learning model to have higher complexity to reduce the impact of irrelevant features in the identification of specific travel modes. Therefore, how to construct travel features and improve the generalization ability of machine learning models is the key to accurately identifying people's travel patterns. Summary of the invention
[0010] In view of the problems existing in the prior art, the present invention provides a method and system for identifying crowd travel modes by multi-view subspace learning with dynamic and static feature fusion.
[0011] The present invention is implemented as follows: a method for identifying crowd travel modes by multi-view subspace learning with dynamic and static features fused, characterized in that the method for identifying crowd travel modes by multi-view subspace learning with dynamic and static features fused specifically comprises:
[0012] S1: Preprocess the original signaling data and clean up invalid data;
[0013] S2: Extract the travel trajectory of each user and handle the abnormal situations of ping-pong data and drift data that may appear;
[0014] S3: After obtaining the trajectory data of a single user in the sample time period, segment the trajectory data and extract the single trip chain trajectory;
[0015] S4: Combine multiple data sources such as mobile phone signaling data, OSM road network and public transportation data to extract static features of the travel chain such as travel behavior and travel traffic;
[0016] S5: Use LSTM model to extract time series features and model the dynamic characteristics of travel trajectory;
[0017] S6: Fusion of static and dynamic features to capture travel patterns from multiple views.
[0018] Further, in S1, the original mobile phone signaling data is associated with the base station data to obtain the longitude and latitude information of each signaling data, and the location of the mobile phone is estimated by determining the longitude and latitude of the geographical location of the base station to which the mobile phone is connected using the COO positioning method. The specific preprocessing content for a single mobile phone signaling data record mainly includes the following:
[0019] (1) Remove the records containing special characters '#', '*', and '^' in the imis field of the original data;
[0020] (2) Remove records where the imsi, lac_id, and cell_id fields are empty;
[0021] (3) Convert the timestamp to the year-month-day-hour-minute "yyyyMMddHHmmss" format;
[0022] (4) The longitude and latitude coordinates of the associated base station laci are concatenated through the lac_id and cell_id fields.
[0023] Furthermore, S2 extracts all the travel points of the user within the time period of sample data collection based on the user's unique identification code IMSI as the group number, groups all records with the same IMSI into one group, and arranges them in ascending order according to the timestamps corresponding to the points; for the trajectory data of the same user, the continuity of the trajectory points is determined group by group, and if there is "ping-pong data" with the same base station and the time difference is less than the threshold, the redundant trajectory points are deleted; for the drift data, the speed between the trajectory points is calculated, and if it exceeds the threshold or meets the drift condition, the abnormal trajectory points are removed. The data structure of the mobile phone user's travel points after processing is as follows:
[0024] Traj={(Lon1,Lat1,T1),(Lon2,Lat2,T2)…(Lon n ,Lat n ,T n )} (1)
[0025] Where Traj represents the trajectory sequence of a single mobile phone user’s travel, Lon is the longitude of the trajectory point, Lat is the latitude of the trajectory point, and T is the time when the trajectory point is recorded.
[0026] Further, in S3, after obtaining the trajectory data of a single user in a sample time period, the trajectory data is segmented to extract a single travel chain trajectory, and the single travel chain of the resident is extracted by using the stay point as the switching point of the travel mode. In combination with the sliding window method, the trajectory data array of a single resident's travel is first obtained, and whether it is a stop point is determined according to the set stay condition. For the first trajectory point determined to be a stay condition, it is set as one end of the sliding window, and the window size is expanded by rolling judgment to the subsequent trajectory points until the last trajectory point that meets the stay condition is reached and the window is closed. After identifying the trajectory segments where the residents stay for a long time, these trajectory segments are cut out from the entire trajectory sequence, and multiple user single travel chains will be obtained after the cutout.
[0027] Furthermore, in the travel behavior characteristics of S4, five behavior characteristic elements, namely, travel distance, average travel speed, 90% percentile speed, median speed, and travel time period, are extracted from the trajectory as the main distinguishing factors of different travel modes.
[0028] (1) Travel distance
[0029] The "urban road non-linear coefficient" is used to calculate a more reasonable travel distance between two locations in the city. The corresponding calculation formula for this process is as follows:
[0030]
[0031] D i =2×d i ×θ(3)
[0032] Among them, d i is the calculated distance between the two base stations, R is the radius of the earth, and are the dimension values of the two base stations respectively, and are the longitude values of the two base stations respectively, and θ is the urban road travel distance coefficient;
[0033] (2) Travel speed
[0034] The average and median travel speeds can be calculated using the following formula:
[0035]
[0036] where v avg is the average travel speed, d i is the travel distance, T start and T end are the start and end times of the trip, is the median speed when the data points are odd numbers, and are the two median speeds when the data points are even. For the 90% percentile speed, we first need to calculate the speed between each adjacent trajectory point and the time period it takes. The speeds are sorted from small to large as v(1), v(2), …, v(n-1). The corresponding time periods are Δt(1), Δt(2), …, Δt(n-1). The time proportion of each speed is calculated:
[0037]
[0038] Among them, w i is the time proportion of the i-th speed, Δt i For the i-th period, calculate the cumulative time percentage and find the value that makes P j ≈90% speed:
[0039]
[0040] v 90% =v (j) ,in
[0041] Where j represents the index of the trajectory whose cumulative time reaches or exceeds 90%, P j represents the cumulative time percentage of the jth speed segment;
[0042] (3) Travel time
[0043] The present invention divides a day into multiple time periods. The division of time periods is based on people's typical activity patterns and traffic conditions in a day. When analyzing travel trajectories, if a travel trajectory is completely within a certain time period, then the corresponding travel period is the time period. If the travel trajectory spans multiple time periods, the time period with the longest occupancy time is used as the representative time period of the trip. After determining the time period to which the travel trajectory belongs, the present invention will number the time periods starting from the night time period from 0 to indicate the time period characteristics of the travel trajectory;
[0044] (4) Travel matching characteristics
[0045] According to the extracted mobile phone signaling trajectory, the trajectory similarity is calculated between it and the trajectory of public transportation as the travel matching feature of the mobile phone signaling trajectory. For a determined travel trajectory, combined with the average distance between urban base stations, all bus routes and subway routes in the buffer zone with the starting point of the trajectory as the center radius and the average distance between base stations are searched, and the trajectory similarity with multiple public transportation routes is calculated, and the value with the largest similarity is selected as the travel matching degree of the public transportation category corresponding to the trajectory. In the process of calculating the trajectory similarity, the starting point must be determined first. For the mobile phone signaling travel trajectory, its first trajectory point is selected as the starting point, and the point closest to the starting point of the mobile phone signaling trajectory in the subway or bus route is calculated by spatial distance as the starting point. Secondly, considering that the points of the mobile phone signaling trajectory are relatively sparse, and the public transportation route is a line element, the present invention takes the turning point that appears when the route turns and changes lanes as the basis for point selection, selects points from the public transportation route, and combines the Levenshtein distance and the DFS search algorithm to calculate the similarity between the potential travel trajectory and the potential transfer public transportation route.
[0046] Furthermore, in the above S4, in the travel traffic characteristics, the traffic infrastructure is evaluated based on indicators such as the number of public transportation stations, the coverage rate of public transportation lines, the road network density index, the road intersection density, and the road network density. The present invention takes the longitude and latitude coordinates of the base station corresponding to the travel trajectory point as the center of the circle and the average interval between base stations in the city as the radius to construct the traffic area of the trajectory point, and calculates the above infrastructure indicators as the travel traffic characteristics of the trajectory point:
[0047] (1) Number of public transportation stations
[0048] Public transportation stations are divided into bus stations and subway stations. The present invention will respectively calculate the number of all subway stations and bus stations in the transportation area corresponding to the base station;
[0049] (2) Public transportation line coverage
[0050] Public transportation lines are divided into subway lines and bus lines. ArcGIS is used to calculate the total length of all subway and bus lines in the trajectory point traffic area, and then compared with the total length of the road network in the area, and finally the public transportation line coverage rate of the area is obtained. The calculation method is as follows:
[0051]
[0052] Where k is the type of public transportation, which can be divided into two categories: subway and bus. k Represents the route length of the corresponding public transportation type, L i is the total length of the road network in the traffic area of the i-th trajectory point;
[0053] (3) Road network density index
[0054] The road network density is calculated as follows:
[0055]
[0056] Where L i is the total length of the road network in the traffic area of the ith trajectory point, S i is the total area of the traffic area of the ith trajectory point;
[0057] (4) Road intersection density
[0058] The calculation method of road intersection density is as follows:
[0059]
[0060] Among them, S i is the total area of the traffic area of the ith trajectory point, N k is the number of road intersections in the traffic area of the i-th trajectory point.
[0061] Furthermore, in S5, for each point in the trajectory, relative displacement, trajectory point acceleration, trajectory point velocity, and trajectory point time interval are extracted as dynamic features of the trajectory, and the entire trajectory data is regarded as a time series sample, including trajectory data points of multiple time steps. For each trajectory point i, a 4-dimensional vector is obtained:
[0062] P i =[d i ,a i ,v i ,t i ] (14)
[0063] where d i is the relative displacement, a i is the acceleration, v i is the velocity of the trajectory point, t i is the time interval, and the input sequence dimension of the entire trajectory is:
[0064] T i =[P1,P2,P3,P4....P n ] (15)
[0065] For the LSTM structure, in this task, only the features of the motion trajectory need to be extracted. Unsupervised learning of the prediction task is adopted. The model receives the trajectory point feature input in sequence through LSTM, gradually updates the hidden state, and predicts the trajectory point features of the next time step based on the hidden state. In each training round (epoch), the model processes all trajectory data, gradually accumulates the time step loss of each trajectory, and finally calculates the average loss to optimize the model parameters. The loss calculation formula is as follows:
[0066]
[0067] Where n is the number of trajectories, and n-1 means there are n-1 predictions in the trajectory, each predicting the next point. is the predicted value of the next point, P t+1 is the true value;
[0068] For the output layer, the average pooling layer is used to average the output feature vector in the time dimension and convert it into a vector of fixed length to facilitate subsequent fusion with static features:
[0069]
[0070] Where n is the total number of time steps and h is the feature vector.
[0071] Furthermore, S6, based on the static and dynamic features extracted in the previous steps, mainly divides them into three views, namely, travel behavior feature view, travel traffic feature view, and dynamic feature view, and uses a multi-view subspace clustering method to analyze the travel mode in the trajectory data. A feature-based anchor point selection strategy is adopted to obtain the self-expression matrix of each view through anchor point and subspace clustering, and then the self-expression matrices are merged into a bipartite graph. Finally, spectral clustering is performed on the bipartite graph to generate a clustering result.
[0072] Another object of the present invention is to provide a crowd travel mode recognition system based on multi-view subspace learning with dynamic and static feature fusion, the system specifically comprising:
[0073] The data processing module pre-processes the original signaling data, including data cleaning, trajectory extraction, and travel chain extraction;
[0074] Static feature extraction module, used to extract static features of the travel chain, such as travel behavior and travel traffic;
[0075] The dynamic feature extraction module uses the LSTM model to extract time series features and model the dynamic features of travel trajectories;
[0076] Feature fusion module, which is used to fuse static and dynamic features to capture travel patterns from multiple views.
[0077] In combination with the above technical solutions and the technical problems solved, the advantages and positive effects of the technical solutions to be protected by the present invention are as follows:
[0078] First, combine multi-source data to build features: Traditional travel mode identification methods usually rely only on behavioral features in trajectory data, such as speed, time, and distance. However, this method ignores the traffic environment factors of residents' travel and the inherent traffic attributes of different transportation modes, which will affect the effective identification of travel modes and lead to deviations or erroneous identification results. In order to overcome this limitation, the present invention combines mobile phone signaling data, road network data, and public transportation data to extract more comprehensive features. Mobile phone signaling positioning data has a wide coverage, a high user ownership rate, and can continuously reflect the travel trajectory of the crowd. Therefore, the present invention uses mobile phone signaling data to extract the travel trajectory of the crowd. Using OSM road network data and public transportation data, the traffic environment factors of the travel path are extracted, including the density of the road network, the number of intersections, the distribution of public transportation stations, etc. These features can help to better understand the differences between different traffic modes. At the same time, combined with trajectory data and public transportation data, the matching degree of the user's travel trajectory with the travel route of specific public transportation tools such as buses and subways is identified to better judge the possibility of the trajectory traveling by public transportation.
[0079] Fusion of static and dynamic features: Researchers usually use static or dynamic single features to identify travel modes, but using dynamic features or static features alone will have limitations in the identification of certain travel modes. For example, static features can well describe the inherent characteristics of certain modes of transportation, but lack the capture of the time pattern of travel behavior. Dynamic features can reflect the changing laws of time and help capture complex travel behaviors such as peak traffic patterns. By fusing these two types of features, the model can model travel modes in both spatial and temporal dimensions, thereby improving the accuracy and robustness of travel mode identification.
[0080] Therefore, in addition to extracting static features such as travel behavior and traffic, the present invention also extracts dynamic time series features of the trajectory from the trajectory segment through the long short-term memory network, effectively capturing and constructing dynamic changes in the travel trajectory. These dynamic changes often reflect the changing patterns of individual travel modes in different time periods. Finally, through the fusion of dynamic features and static features, the characteristics of travel behavior can be fully understood from different dimensions, the limitations of a single feature can be compensated, and the accuracy and stability of travel mode recognition can be improved.
[0081] Multi-view subspace identification of travel modes: This invention uses multi-view subspace clustering technology to combine travel behavior, travel traffic and dynamic characteristics to comprehensively extract travel mode information from multiple perspectives. Through adaptive weights and anchor selection strategies, features from different sources are effectively fused to enhance the expressiveness and recognition accuracy of features. Multi-view fusion can more accurately capture complex travel modes, reduce data redundancy and noise, and significantly improve the accuracy of travel mode identification.
[0082] Second, technical problems of existing technologies:
[0083] 1. Data quality and reliability issues:
[0084] In traditional crowd travel mode identification technology, mobile phone signaling data is difficult to accurately describe travel trajectories due to problems such as noise, missing values, and ping-pong data, which affects the accuracy of travel mode identification.
[0085] 2. Insufficient utilization of static and dynamic features:
[0086] Existing methods usually focus on the analysis of static features (such as travel distance, time period, etc.), and ignore the dynamic changing characteristics of trajectory data, such as speed, acceleration, etc., resulting in inaccurate judgment of travel mode.
[0087] 3. Limited multi-view data integration capabilities:
[0088] There is a lack of effective modeling methods for the fusion of multi-source data (such as road networks and public transportation data) and trajectory data. Traditional methods find it difficult to fully utilize the data characteristics of each view, resulting in insufficient ability to identify complex travel behaviors.
[0089] 4. Single clustering and identification method:
[0090] Existing methods mostly rely on a single model or view for classification, which is unable to capture the multi-level description of travel modes from different feature views, limiting the accuracy and scope of applicability of travel mode identification.
[0091] Significant technological advancements in technical solutions:
[0092] 1. Efficient data cleaning and preprocessing:
[0093] The present invention designs a special cleaning algorithm, which can remove invalid information, ping-pong data and drift data in the signaling data, ensure the quality and reliability of the trajectory data, and lay a solid foundation for subsequent analysis.
[0094] 2. Innovative method of fusion of dynamic and static features:
[0095] The present invention not only extracts static features such as travel behavior and traffic characteristics, but also extracts the temporal dynamic features of the trajectory through the LSTM model, combining the static and dynamic features to significantly improve the accuracy of travel mode identification.
[0096] 3. Multi-view subspace learning method:
[0097] By dividing static and dynamic features into different views and using multi-view subspace clustering method to fuse the data of each view, it is possible to capture complex travel patterns more comprehensively and improve the clustering effect and robustness of the model.
[0098] 4. Introduce public transportation characteristics analysis:
[0099] The present invention combines public transportation data and road network characteristics, and designs traffic characteristic indicators such as public transportation line coverage, road network density, etc., which provides strong support for identifying travel modes based on public transportation.
[0100] 5. Intelligent travel mode identification:
[0101] Using spectral clustering technology to classify the fused multi-view data can accurately capture the diversity and details of people's travel methods and improve the ability to identify complex travel behaviors.
[0102] 6. Significant industrial application value:
[0103] The present invention can be applied to scenarios such as urban planning, public transportation optimization, and traffic behavior analysis. By accurately identifying people's travel modes, the level of intelligent traffic management can be improved and the construction of smart cities can be promoted.
[0104] Technical value in industrial applications:
[0105] 1. Improve traffic planning accuracy:
[0106] The present invention can provide more accurate travel mode identification results, and assist city managers in optimizing public transportation route planning and transportation infrastructure layout.
[0107] 2. Support the construction of smart transportation systems:
[0108] By accurately analyzing travel behavior, the present invention provides important data support for smart transportation applications such as traffic flow prediction and shared transportation optimization.
[0109] 3. Reduce data collection costs:
[0110] By efficiently integrating signaling data, road network data and public transportation data, the present invention avoids reliance on traditional high-cost questionnaires or dedicated equipment and has greater economy and scalability.
[0111] 4. Enhance user experience:
[0112] For public transportation travelers, the present invention can be used for real-time travel mode recommendations and route optimization, providing users with more convenient and efficient travel services.
[0113] Second, the technical solution of the present invention fills the technical gap in the industry at home and abroad:
[0114] Improvements have been made to the problem that multi-view subspace clustering in travel mode identification is sensitive to initial conditions. In the anchor point selection operation of multi-view subspace clustering, the initial point obtained each time will be different because the clustering method relies on the randomly selected initial center point. When the data set is large and complex, the initial selected cluster center deviates greatly from the distribution of the data, and the final clustering result will cause deviation from the true distribution. In response to this problem, the present invention proposes to integrate multi-view information into a unified graph matrix (Formula 18), in which the sample eigenvalues within the same travel mode category are usually similar, while the eigenvalues between different categories are significantly different. Utilizing this feature, representative anchor points are effectively extracted by combining the eigenvalues of each sample and according to the total eigenvalue difference (Formula 21). At the same time, a consistent bipartite graph (Formula 23) is constructed by merging the self-expression matrix of each view (Formula 22) as a whole, and the similarity graph between samples is directly processed on the graph for clustering, avoiding the dependence on the initial center point generated by finding the initial cluster center in the original data space, thereby eliminating the uncertainty caused by random initialization and improving the accuracy and stability of travel mode identification under diverse traffic modes. BRIEF DESCRIPTION OF THE DRAWINGS
[0115] Figure 1 It is a flow chart of a method for identifying travel modes of a crowd by multi-view subspace learning with dynamic and static feature fusion provided by an embodiment of the present invention;
[0116] Figure 2 It is a technical flow chart of a method for identifying travel modes of a crowd by multi-view subspace learning with dynamic and static feature fusion provided by an embodiment of the present invention;
[0117] Figure 3 It is a module diagram of a crowd travel mode recognition system using multi-view subspace learning with dynamic and static feature fusion provided by an embodiment of the present invention;
[0118] Figure 4 It is the subway similarity probability distribution density provided by the embodiment of the present invention. DETAILED DESCRIPTION
[0119] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0120] like Figure 1 , Figure 2 As shown, the embodiment of the present invention provides a crowd travel mode recognition method LSTM-AMSC (Long Short-Term Memory with Anchor-based Multi-View Subspace Clustering) based on multi-view subspace learning with dynamic and static features fusion, and the method specifically includes:
[0121] S1: Preprocess the original signaling data and clean up invalid data;
[0122] S2: Extract the travel trajectory of each user and handle the abnormal situations of ping-pong data and drift data that may appear;
[0123] S3: After obtaining the trajectory data of a single user in the sample time period, segment the trajectory data and extract the single trip chain trajectory;
[0124] S4: Combine multiple data sources such as mobile phone signaling data, OSM road network and public transportation data to extract static features of the travel chain such as travel behavior and travel traffic;
[0125] S5: Use LSTM model to extract time series features and model the dynamic characteristics of travel trajectory;
[0126] S6: Fusion of static and dynamic features to capture travel patterns from multiple views.
[0127] Some parameters of the original mobile phone signaling data include timestamp, international mobile user identity code, area location code, cell identification code, mobile phone number, network identifier, network parameter indicator and other fields. The specific definitions are as follows:
[0128] timestamp: timestamp, indicating the time of recording. This timestamp is a Unix timestamp, which indicates the number of seconds that have passed since January 1, 1970 (midnight UTC / GMT), ignoring leap seconds;
[0129] IMSI: International Mobile Subscriber Identity, which is a unique identifier for a specific user in a mobile network.
[0130] lac_id: Location Area Code, which identifies the area in the mobile network and consists of multiple base stations;
[0131] cell_id: Cell Identity, used to identify a cell in a mobile network, that is, the area covered by a base station;
[0132] Phone: mobile phone number, indicating the number of the mobile phone associated with the base station;
[0133] nid: Network Identifier, used to identify a specific network;
[0134] npid: Network parameter symbol.
[0135] In order to locate the mobile phone signaling data, it is necessary to associate the original mobile phone signaling data with the base station data to obtain the longitude and latitude information of each signaling data. The COO positioning method is used to estimate the location of the mobile phone by determining the longitude and latitude of the geographical location of the base station to which the mobile phone is connected.
[0136] In S1, due to the fact that the base station may have data transmission loss, poor network and other conditions when working, this will lead to invalid redundant data, including duplicate records and missing records. This will have a negative impact on the extraction of the trajectory, resulting in inaccurate or incomplete trajectory information. Therefore, before performing trajectory extraction, it is necessary to pre-process the original signaling data to clean up invalid data and ensure that the trajectory information finally extracted is accurate, complete and reliable.
[0137] The specific preprocessing contents for a single mobile phone signaling data record mainly include the following:
[0138] (1) Remove the records containing special characters '#', '*', and '^' in the imis field of the original data;
[0139] (2) Remove records where the imsi, lac_id, and cell_id fields are empty;
[0140] (3) Convert the timestamp to the year-month-day-hour-minute "yyyyMMddHHmmss" format;
[0141] (4) The longitude and latitude coordinates of the associated base station laci are concatenated through the lac_id and cell_id fields.
[0142] In order to extract the travel trajectory of each user, S2 extracts all the travel points of the user within the time period of sample data collection according to the user's unique identification code IMSI as the group number, groups all records with the same IMSI into one group, and arranges them in ascending time order according to the timestamps corresponding to the points.
[0143] Combined with the abnormal phenomena encountered during actual signaling collection, abnormal situations of ping-pong data and drift data may appear in the preliminary trajectory record. The generation of ping-pong data comes from the fact that when the mobile phone user is located in the overlapping area of the coverage of two base stations, when the signals of the two base stations fluctuate, the user may switch between the two base stations continuously, resulting in erroneous movement misjudgment in the preliminary trajectory record. As for drift data, it is generated due to the protection optimization mechanism of the base station itself. When the load of the base station is too high, the mobile phone user may be switched to a base station that is farther away but has a lower load for communication, which may cause a huge offset in the longitude and latitude in the trajectory record in a short period of time. Therefore, in order to ensure the accuracy of the trajectory data, these abnormal data must be properly processed before further analysis and application.
[0144] For the trajectory data of the same user, the continuity of the trajectory points is determined group by group. If there is "ping-pong data" with the same base station and a time difference less than the threshold, the redundant trajectory points are deleted; for drift data, the speed between trajectory points is calculated. If it exceeds the threshold or meets the drift condition, the abnormal trajectory point is removed. The data structure of the mobile phone user's travel point after processing is as follows:
[0145] Traj={(Lon1,Lat1,T1),(Lon2,Lat2,T2)…(Lon n ,Lat n ,T n )} (1)
[0146] Where Traj represents the trajectory sequence of a single mobile phone user’s travel, Lon is the longitude of the trajectory point, Lat is the latitude of the trajectory point, and T is the time when the trajectory point is recorded.
[0147] Said S3, after obtaining the trajectory data of a single user in the sample time period, segments the trajectory data and extracts the single travel chain trajectory. In real life, residents' travel behavior in a day is complex, accompanied by constant changes in travel modes. The present invention extracts the residents' single travel chain by using the stay point as the switching point of the travel mode. Regarding the residents' travel process, residents often stay in one area for a long time after a long-distance trip. For example, in the morning, residents take public transportation or drive to the workplace and stay in the office area for a long time, and travel to other places after work.
[0148] The residence status of residents is determined by setting a distance threshold, that is, when the distance of the previous travel point is less than the distance threshold, the user is determined to be motionless. The present invention combines the sliding window method to extract travel segments. The sliding window is a common method for extracting continuous subsequences from a data sequence. By setting a fixed-size window, the sliding window method can gradually slide along the data sequence, moving only one step or a specified step length each time, and extracting different parts of the sequence for analysis. First, the trajectory data array of a single resident's travel is obtained, and whether it is a stop point is determined according to the set residence condition. For the first trajectory point judged as a stop condition, it is set as one end of the sliding window, and the subsequent trajectory points are continuously rolled to determine the expansion of the window size, until the last trajectory point that meets the residence condition is reached and the window is closed. After identifying the trajectory segments where residents reside for a long time, these trajectory segments are cut out from the entire trajectory sequence, and after cutting out, multiple user single travel chains will be obtained.
[0149] With the development of urban transportation systems, the travel behavior of urban residents has become more complex, and the travel mode choices have become more diversified. For most studies that only extract travel behavior features from mobile phone signaling data, it is difficult to fully describe the travel characteristics of a specific travel mode used by a resident. Therefore, the embodiment of the present invention will effectively utilize multi-source data to extract static and dynamic features from it to comprehensively identify the travel mode of the crowd.
[0150] In the above S4, in the travel behavior characteristics, five behavioral characteristic elements, namely, travel distance, average travel speed, 90% percentile speed, median speed, and travel time, are extracted from the trajectory as the main distinguishing elements of different travel modes. The travel distance can reflect the length of the distance that the travel mode usually commutes in a travel chain trajectory. For travel modes such as subways and buses, the travel distance is usually longer, while walking travel modes usually do not have too long travel distances. The average travel speed can reflect the macro speed of a travel trajectory, and the average speed reflected for different travel modes will be significantly different. Many documents select percentile speed as an indicator to describe the state of motion. The present invention selects 90% percentile speed as the highest speed indicator of the trajectory, which can more accurately reflect the typical driving speed characteristics and avoid being disturbed by abnormal values or emergencies. The 90% percentile speed means that 90% of the driving speeds in the trajectory are lower than or equal to this value, and only 10% of the speeds are higher than this value. This indicator can reflect the maximum speed that the travel mode can reach in 90% of the time, effectively filter out some abnormally fluctuating extreme speeds, and thus more truly reflect the regularity of the driving speed. The median speed can more effectively reflect the typical travel speed level. Compared with the average speed, it is not affected by extreme values such as short pauses or acceleration. The travel time records the specific time period of the day in which the travel trajectory is located. For the same travel mode, the speed at different time periods in a day will be significantly different. For example, the average speed of taking a bus during the noon period will be significantly lower than the average speed during the evening peak.
[0151] (1) Travel distance
[0152] For travel distance, the mobile phone signaling data reflects the geometric straight-line distance between two base stations. The present invention uses the Harversine formula to calculate the spherical distance between two points on the earth's surface. However, due to the influence of urban roads, the calculation result is inconsistent with the actual travel distance through urban roads. Therefore, the present invention uses the "urban road non-linear coefficient" to calculate a more reasonable travel distance between two locations in the city. The calculation formula corresponding to this process is as follows:
[0153]
[0154] D i =2×d i ×θ(3)
[0155] Among them, d i is the calculated distance between the two base stations, R is the radius of the earth, and are the dimension values of the two base stations respectively, and are the longitude values of the two base stations respectively, and θ is the urban road travel distance coefficient.
[0156] (2) Travel speed
[0157] The average and median travel speeds can be calculated using the following formula:
[0158]
[0159] where v avg is the average travel speed, d i is the travel distance, T start and T end are the start and end times of the trip, is the median speed when the data points are odd numbers, and are the two median speeds when the data points are even.
[0160] For the 90% percentile speed, we first need to calculate the speed between each adjacent trajectory point and the time period it takes. The speeds are sorted from small to large as v(1), v(2), ..., v(n-1), and the corresponding time periods are Δt(1), Δt(2), ..., Δt(n-1). Calculate the time percentage of each speed:
[0161]
[0162] Among them, w i is the time proportion of the i-th speed, Δt i is the i-th period of time.
[0163] Calculate the cumulative time percentage and find the value that makes P j ≈90% speed:
[0164]
[0165] v 90% =v (j) ,in
[0166] Where j represents the index of the trajectory whose cumulative time reaches or exceeds 90%, P j Indicates the cumulative time percentage of the j-th speed.
[0167] (3) Travel time
[0168] The present invention divides a day into multiple time periods. The division of time periods is based on people's typical activity patterns and traffic conditions in a day. For specific time period intervals, see Table 1. When analyzing travel trajectories, if a travel trajectory is completely within a certain time period, then the corresponding travel period is the time period. If the travel trajectory spans multiple time periods, the time period with the longest occupancy time is used as the representative time period of the trip. After determining the time period to which the travel trajectory belongs, the present invention will number the time period starting from the night time period from 0 to indicate the time period characteristics of the travel trajectory.
[0169] Table 1 Time interval comparison table
[0170]
[0171] (4) Travel matching characteristics
[0172] For public transportation, it operates along fixed routes. According to the extracted mobile phone signaling trajectory, the trajectory similarity is calculated between it and the trajectory of public transportation, which is used as the travel matching feature of the mobile phone signaling trajectory.
[0173] For a determined travel trajectory, combined with the average distance between city base stations, search for all bus routes and subway routes within the buffer zone with a center radius equal to the average distance between base stations, and calculate the trajectory similarity with multiple public transportation lines. The value with the largest similarity is selected as the travel matching degree of the public transportation category corresponding to the trajectory.
[0174] In the process of calculating trajectory similarity, the starting point must be determined first. For the mobile phone signaling travel trajectory, the first trajectory point is selected as the starting point, and the point closest to the starting point of the mobile phone signaling trajectory in the subway or bus route is calculated by spatial distance as the starting point. Secondly, considering that the points of the mobile phone signaling trajectory are relatively sparse, and the public transportation route is a line element, the present invention takes the turning point that appears when the route turns and changes lanes as the basis for selecting points, and selects points from the public transportation route. Considering that for the same public transportation travel trajectory, residents can choose to transfer to different transfer lines, the present invention combines the Levenshtein
[17] distance and the DFS search algorithm to calculate the similarity between the potential travel trajectory and the potential transfer public transportation line. The Levenshtein distance is usually used to compare the similarity of two sequences, and the difference between the two sequences is calculated by the minimum number of edit distance insertion, deletion, and replacement operations. Combined with DFS, all potential transfer lines are searched for all trajectory points in the trajectory, and the similarity of the new transfer line is calculated. Finally, the travel segment with the largest similarity is selected as its trajectory similarity.
[0175] The specific calculation process of Levenshtein similarity is as follows:
[0176] Considering the insertion, deletion, and replacement operations between trajectory segments and the difference in segment length, the traditional Levenshtein distance is expanded and adjusted. The process is as follows:
[0177]
[0178] The edit distance between two trajectory segment sequences is recursively calculated by combining the length of the segment. Indicates that from the trajectory and The LS distance from the αth segment to the βth segment, l α is the length of the α segment in the segment sequence.
[0179] The similarity calculation formula is as follows:
[0180]
[0181] in For road section and Sequence similarity, numerator includes all deletion operations L d , insert operation L in and the replacement operation L re The corresponding section length. The denominator represents the trajectory and When the LS calculation result is close to 1, it means that the similarity between the two road sections is greater.
[0182] With the development of cities, the level of transportation infrastructure between different areas of the city will also serve as an important basis for residents' travel choices. In the above S4, the travel traffic characteristics, the transportation infrastructure will be evaluated based on indicators such as the number of public transportation stations, public transportation line coverage, road network density index, road intersection density, and road network density. For the setting of the traffic area, the present invention takes the latitude and longitude coordinates of the base station corresponding to the travel trajectory point as the center of the circle, and the average interval between base stations in the city as the radius, to construct the traffic area of the trajectory point, and calculate the above infrastructure indicators as the travel traffic characteristics of the trajectory point.
[0183] (1) Number of public transportation stations
[0184] Public transportation stops are divided into bus stops and subway stops. The present invention will respectively calculate the number of all subway stops and bus stops in the transportation area corresponding to the base station.
[0185] (2) Public transportation line coverage
[0186] Public transportation lines are divided into subway lines and bus lines. ArcGIS is used to calculate the total length of all subway and bus lines in the trajectory point traffic area, and then compared with the total length of the road network in the area, and finally the public transportation line coverage rate of the area is obtained. The calculation method is as follows:
[0187]
[0188] Where k is the type of public transportation, which can be divided into two categories: subway and bus. k Represents the route length of the corresponding public transportation type, L i is the total length of the road network in the traffic area of the i-th trajectory point.
[0189] (3) Road network density index
[0190] Road network density is the ratio of the total length of roads in a specific area to the area of the area. As an evaluation standard for the scale of urban development, road network density reflects the accessibility of urban blocks. Some studies have shown that blocks with high accessibility have wider road coverage and more compact blocks, which can promote residents to choose non-motorized vehicles for travel. At the same time, it can also affect the traffic flow and congestion in the area. Areas with higher road network density may have higher traffic capacity and are more suitable for medium and short distance travel modes such as bicycles or cars. The calculation method is as follows:
[0191]
[0192] Where L i is the total length of the road network in the traffic area of the ith trajectory point, S i is the total area of the traffic area of the ith trajectory point.
[0193] (4) Road intersection density
[0194] The intersection density is the ratio of the number of intersections in the trajectory point traffic area to the area of the trajectory point traffic area. The higher the intersection density, the smaller the block size and the more compact the road network. Areas with high intersection density usually have more road connectivity and diverse travel routes, increasing traffic flexibility and network accessibility. The calculation method is as follows:
[0195]
[0196] Among them, S i is the total area of the traffic area of the ith trajectory point, N k is the number of road intersections in the traffic area of the i-th trajectory point.
[0197] S5, using LSTM long short-term memory network to extract dynamic features of trajectory data. For urban travel trajectory data, its dynamic changes are relatively complex, and the speed and acceleration between trajectory points will be affected by the actual traffic environment. Extracting detailed dynamic features of the trajectory will reflect more dimensional and detailed dynamic change features, which can be used for further analysis or clustering tasks to improve the travel mode recognition effect.
[0198] For each point in the trajectory, the present invention mainly extracts relative displacement, trajectory point acceleration, trajectory point velocity, and trajectory point time interval as the dynamic characteristics of the trajectory, and regards the entire trajectory data as a time series sample, which contains trajectory data points of multiple time steps. For each trajectory point i, we get a 4-dimensional vector:
[0199] P i =[d i ,a i ,v i ,t i ] (14)
[0200] where d i is the relative displacement, a i is the acceleration, v i is the velocity of the trajectory point, t i is the time interval.
[0201] The input sequence dimension of the entire trajectory is:
[0202] T i =[P1,P2,P3,P4....P n ] (15)
[0203] The structure of LSTM is mainly composed of memory cells. Each memory cell is a gated structure used to control the flow of information to capture the time series dependency in the trajectory. The forget gate is used to determine the part of the memory of the previous time step to be forgotten, and the input gate determines which parts of the current input can be stored in the memory cell. The forget gate and the input gate can be used to update the memory cell of the previous step to obtain the current memory state. The output gate is used to control the output of the current hidden state.
[0204] In this task, we only need to extract the features of the motion trajectory and use unsupervised learning for prediction tasks. The model receives the trajectory point feature input in sequence through LSTM, gradually updates the hidden state, and predicts the trajectory point features of the next time step based on the hidden state. In each training round (epoch), the model processes all trajectory data, gradually accumulates the time step loss of each trajectory, and finally calculates the average loss to optimize the model parameters. The loss calculation formula is as follows:
[0205]
[0206] Where n is the number of trajectories, and n-1 means there are n-1 predictions in the trajectory, each predicting the next point. is the predicted value of the next point, P t+1 is the true value.
[0207] For the output layer, the average pooling layer is used to average the output feature vector in the time dimension and convert it into a vector of fixed length to facilitate subsequent fusion with static features.
[0208]
[0209] Where n is the total number of time steps and h is the feature vector.
[0210] In S6, after obtaining the above features, the present invention will use a multi-view subspace clustering method to analyze the travel mode in the trajectory data. Multi-view learning has been widely used in the fields of pattern recognition, feature selection and information processing. In the real world, many objects can be described from different perspectives. For example, web page content can be represented from different aspects such as text, pictures and hyperlinks, while images can be expressed from multiple perspectives such as color, contrast, lines and saturation. Multi-view learning uses the compatibility and complementarity of these multi-view information to enable the model to extract features and fuse information more accurately and comprehensively. For the task of travel mode identification, the present invention integrates multi-source and multi-angle features, and uses a multi-view subspace clustering method to unify features from different sources such as behavioral features, traffic features and dynamic features. Each feature view has its own independent self-expression matrix, and the importance of each view is balanced through adaptive weights. In this way, the impact of different features on travel modes can be combined to improve the accuracy of identification.
[0211] In the present invention, compared with the common multi-view subspace clustering method based on spectral clustering, the present invention adopts a feature-based anchor selection strategy. The self-expression matrix of each view is obtained by anchor point and subspace clustering, and then the self-expression matrix is merged into a bipartite graph. Finally, spectral clustering is performed on the bipartite graph to generate a clustering result.
[0212] In the present invention, based on the static and dynamic features extracted in the previous steps, they are mainly divided into three views, namely, travel behavior feature view, travel traffic feature view, and dynamic feature view, as shown in Table 2. Multi-view learning can combine different information from multiple views, each view brings different features, and provides a more comprehensive object description. The complementary information between views can help the model capture richer patterns.
[0213] Table 2 Feature view description table
[0214] View Name Data Source feature
[0215] Travel behavior, mobile phone signaling data, public transportation travel distance, average travel speed, 95% speed, median speed
[0216] Collect map data, travel time, bus route matching, subway route matching
[0217] Spend
[0218] Mobile phone signaling data for travel and transportation, the number of public transportation stops at the starting point of the urban road network, and the public transportation routes at the starting point
[0219] Collect map data, public transportation data coverage, starting point road network density index, starting point road intersection
[0220] Port density, starting point road network density
[0221] Dynamic features: time series features of mobile phone signaling data trajectory
[0222] picture
[0223] (1) Anchor point selection
[0224] First, concatenate all views together to build a large matrix X, where X i For the subview.
[0225] X=[X1,X2,X3](18)
[0226] The eigenvalues of samples in the same cluster are usually similar, while the eigenvalues of samples in different clusters are quite different. Using this feature, we can extract representative anchor points based on the difference in total eigenvalues. In order to avoid the loss of representativeness of the selected anchor points due to excessive thresholds of certain features, the eigenvalues should be normalized to the range of [0,1]. The normalization formula is as follows:
[0227]
[0228] Where X j represents the j-th feature of X.
[0229] After normalization, the sum of the eigenvalues of each sample is calculated:
[0230]
[0231] Where S x represents the characteristic sum of X, X j represents the j-th feature of X, and d is the total feature dimension.
[0232] The difference in eigenvalues between sample points that are close to each other is small, while the difference in eigenvalues between sample points that are far away is large.
[0233] Next, we iteratively select anchor points. When selecting a sample as an anchor point, samples that are closer to it will no longer be selected as anchor points. We use the following formula to iteratively select anchor points:
[0234]
[0235] from The sample with the largest value is selected as the anchor point, and then updated using the above formula until the number of selected anchor points reaches the specified number m.
[0236] (2) Optimization and convergence
[0237] The input of the overall algorithm includes the data source feature set The number of clusters is c, and the number of anchor points is m. First, set the initial self-expression matrix Uniform graph S, matrix F, and set the weight of each view to the unit matrix. The uniform graph is a local graph structure matrix used to integrate information from each view. Its purpose is to fuse the similarity relationships of each view into a single graph structure to better perform clustering tasks. Matrix F is a clustering label matrix used to represent the clustering results of the data.
[0238] Then the parameters will be optimized continuously until the convergence condition is reached. Through the staged optimization process, only one variable is optimized in each stage, and the other variables are fixed. In this way, the optimal solution of the objective function can be gradually approached.
[0239] (2.1) Optimizing the self-expression coefficient matrix
[0240] Fix all variables except the self-expression coefficient matrix Z, and use the quadratic programming problem to solve the objective function. For each view, solve Z separately to find the optimal Z value under the effective non-negative constraints and ensure that the constraints of each row are met. The objective function is as follows:
[0241]
[0242] Where v represents the number of views, X i represents the data matrix of the i-th view, Ai represents the i-th anchor matrix, Z i represents the coefficient of the self-expression matrix, S is the final fusion graph structure matrix, and w j is the weight coefficient of the jth view, G j is the similarity graph of the j-th view, Represents the Frobenius norm, which is used to measure the degree of difference of the matrix.
[0243] (2.2) Optimizing the feature matrix
[0244] Fixed variables w, Z, S, and optimized the feature matrix. The specific objective function is as follows:
[0245] minTr(F T L S F)(23)
[0246] Where L S is the Laplace matrix of the graph, and F is solved by eigenvalue decomposition. The eigendecomposition of the Laplace matrix will give the eigenvector corresponding to the smallest eigenvalue, and these eigenvectors are used to construct F. The left singular vector U and right singular vector V of F are decomposed using singular value decomposition SVD to obtain the optimal F value.
[0247] (2.3) Optimizing the Fusion Graph Structure Matrix
[0248] Fix other variables and optimize S. The specific objective function is:
[0249]
[0250] Where λ is a tuning parameter used to balance the weights of the two terms. To optimize S, the objective function is first decomposed into row-independent levels. This means that each row can be optimized independently, and the optimal value of each row is solved through quadratic programming, and the final S matrix is obtained after updating each row.
[0251] (2.4) Optimize the weight matrix
[0252] Fix other variables and optimize w. The specific objective function is as follows:
[0253]
[0254] Where Q is a matrix composed of the column vectors of each self-expression matrix connected vertically. At this time, the linear system problem is solved. The problem is optimized by the augmented Lagrangian method. The augmented Lagrangian method can satisfy the constraints w≥0 and W T = 1. Update w by gradually adjusting the Lagrange multiplier until the optimal solution is reached.
[0255] (2.5) Update λ
[0256] In order to achieve convergence of the optimization process and maintain the graph structure, we dynamically adjust the value of λ according to the number of clusters. When the number of connected components exceeds the specified number of clusters c, λ is halved (i.e., λ = λ / 2). When the number of connected components is less than c, λ is doubled (i.e., λ = λ × 2) to gradually approach the connected graph structure that satisfies the number of clusters.
[0257] like Figure 3 As shown, an embodiment of the present invention provides a crowd travel mode recognition system based on multi-view subspace learning with dynamic and static feature fusion, which specifically includes:
[0258] The data processing module pre-processes the original signaling data, including data cleaning, trajectory extraction, and travel chain extraction;
[0259] Static feature extraction module, used to extract static features of the travel chain, such as travel behavior and travel traffic;
[0260] The dynamic feature extraction module uses the LSTM model to extract time series features and model the dynamic features of travel trajectories;
[0261] Feature fusion module, which is used to fuse static and dynamic features to capture travel patterns from multiple views.
[0262] As a specific implementation case, about 11.2 million mobile phone signaling data from Shenyang on October 8, 2018 were selected to verify the effectiveness of the present invention and to further illustrate the specific implementation methods.
[0263] 1. Trajectory processing results
[0264] The experimental sample mobile phone signaling data information can be seen in Table 3:
[0265] Table 3 Parameter list of mobile phone signaling data
[0266]
[0267] Using the cleaning project described above, the original data is cleaned using Python's pandas library, and the COO method is used to concatenate the contents of the lac_id field and the cell_id field in the mobile phone signaling data and match them with the laci field in the base station data. The longitude and latitude information of the corresponding base station can be obtained from the base station data. Through an effective association and matching process, the accurate longitude and latitude information of the location of the mobile phone signaling data is obtained, as shown in Table 4:
[0268] Table 4 Partial parameter list of base station association data
[0269]
[0270] For the processed mobile phone signaling data obtained, based on the unique identification code of the IMSI user, all the trajectory travel points of each mobile phone user are grouped using the grouping method in the pandas library. Finally, for all the travel points in the group, the time ascending method is used on the timestamp field to obtain the travel sequence arranged in time order.
[0271] For the initially extracted trajectory data, the drift speed threshold is set as the maximum value of the traffic speed limit in the study area, and the distance threshold is the average distance between base stations in the area. The average distance between base stations can be directly calculated through ArcMap by summing the total distances of all base stations in the study area and their nearest base stations divided by the number of connected base stations.
[0272] The specific processing flow of ping-pong trajectory optimization is as follows:
[0273] 1) Extract preliminary trajectory data of the same user;
[0274] 2) Start judging from the earliest trajectory point one by one, and keep the records of the two consecutive trajectory points as a group;
[0275] 3) judging the trajectory points in the group obtained in 2), if the first trajectory point and the third trajectory point are the same base station and the time difference between the first trajectory point and the third trajectory point is less than a certain threshold, then judging that the trajectory of this part generates ping-pong data;
[0276] 4) Delete the record of the third track point and keep the first and second track points.
[0277] For drift data processing, speed detection is used for judgment. When the speed of several track points in the track increases sharply, it is considered to be a drift track. The processing flow is as follows:
[0278] 1) Extract preliminary trajectory data of the same user;
[0279] 2) Start judging from the earliest trajectory point one by one, and keep the records of the two consecutive trajectory points as a group;
[0280] 3) calculating the distance and time difference between the first trajectory point and the second trajectory point, and between the second trajectory point and the third trajectory point in the group obtained in step 2), and calculating their speeds respectively;
[0281] 4) If the speed is greater than the set speed threshold, or the distance from the second point to the third point is greater than the drift threshold and the distance between the first and second points is also greater than the drift threshold, and the distance from the first point to the third point is less than twice the drift threshold, the second point is eliminated.
[0282] After obtaining the optimized trajectory data, the maximum dwell distance is set to the average distance between base stations, and the trajectory segments are extracted using the method described above.
[0283] 2. Feature extraction results
[0284] 2.1 Static Features
[0285] (1) Travel behavior characteristics
[0286] Calculate the behavior characteristics of each trajectory in turn. For each trajectory, use the Harversine library to calculate the distance on the earth scale through the longitude and latitude of the two previous and next trajectory points, and multiply it by the road distance coefficient of 1.2. Finally, add the distances between all trajectory points to get the total length of the trajectory segment. The non-linear coefficient of the road here refers to the "Urban Road Traffic Planning and Design Specifications GB50220-95". The average non-linear coefficient of the urban road network is generally 1.15 to 1.2. The project uses the data source of the new first-tier cities, so the non-linear coefficient of the road is set to 1.2 in this project.
[0287] Based on the calculated distances between trajectory points, the travel time and travel speed between trajectory points are calculated using the timestamp differences between trajectory points. The median and quantile calculation methods provided in numpy are used to calculate the median speed and 90% speed corresponding to each trajectory.
[0288] (2) Travel characteristics
[0289] Through the OSM (OpenStreetMap) service provided by Google, we obtained the vector data of all the road networks in Shenyang. We also crawled the subway station and bus station data, subway and bus lines in Baidu Maps. We used ArcMap to perform spatial analysis on the vector data to obtain characteristic information such as the number of public transportation stations, public transportation line coverage, road network density indicators, road intersection density, and road network density.
[0290] Using the travel trajectory segments, extract the starting point and end point of each trajectory segment, and use its latitude and longitude information to import it into ArcMap as a point feature. Use the buffer analysis function in ArcMap to set a buffer area with a radius equal to the average distance between base stations for each trajectory point. Use the intersection tool and select the output category as point feature to extract the points where roads intersect. Then use the Identity tool to analyze and summarize the number of all intersection points, bus stops and subway station elements within the buffer radius. Similarly, overlay the road network line elements, public transportation line elements and buffers, and use geometric calculation summary and other functions to calculate the length of all line elements in each buffer. Based on the results of the above analysis, the corresponding traffic characteristic elements are calculated in combination with formulas (11)(12)(13).
[0291] (3) Travel matching characteristics
[0292] Combined with the Levenshtein similarity calculation method mentioned above, the calculation code of Levenshtein distance is designed using the dynamic programming method. At the same time, the overall algorithm is designed in combination with the DFS depth-first search method to obtain the maximum public transportation line matching degree under the consideration of transfer lines. The specific calculation process is as follows:
[0293] 1) Initialization: Search each trajectory from the starting point and initialize the maximum similarity to 0.
[0294] 2) Find nearby stations: For each trajectory point, search for stations within a circle with a radius equal to the average distance between base stations as possible transfer points.
[0295] 3) Generate a trajectory segment: Starting from the current station, obtain a fixed-length trajectory segment on the current line starting from the current trajectory point.
[0296] 4) Similarity calculation: call the weighted Levenshtein distance to calculate the similarity between the current trajectory segment and the line trajectory segment.
[0297] 5) Recursive calculation: If the trajectory has not been traversed completely, recursively search for the next trajectory point to accumulate the current maximum similarity value.
[0298] 6) Backtracking: When recursively returning, backtrack to the previous node to explore other possible line combinations.
[0299] 7) Update the maximum similarity: record the maximum similarity among all DFS paths.
[0300] Figure 4This is the probability distribution diagram of the similarity kernel density of subway trajectories with and without considering transfers. It can be seen from the figure that the maximum value of the result calculated without using the transfer method is 0.6, and most of the similarities are only concentrated in 0.1-0.2. The calculation method that takes transfers into account has a maximum value of 0.93, and the similarity is no longer concentrated in 0.2. One-third of the trajectories have a similarity greater than 0.5. This shows that compared with the similarity calculation method that does not consider transfers, the algorithm proposed in this invention calculates more trajectories of actual transfer trips.
[0301] 2.2 Dynamic Features
[0302] The LSTM network is used to train the trajectory data to extract its dynamic time series features. In view of the short time series of the mobile phone trajectory data, a single-layer LSTM structure is selected to improve the computational efficiency and reduce the risk of overfitting. The parameters of the LSTM ForgetGate, Input Gate, and Output Gate are initialized using normal distribution to avoid the problem of gradient vanishing or gradient exploding, and the default Sigmoid activation function is selected as the nonlinear transformation of the gate unit. The batch size is set to 64, which is selected to strike a balance between training efficiency and gradient stability. The optimizer uses Adam, the initial learning rate is set to the default value of 0.001, and the learning rate decay strategy is combined to achieve the coordination of convergence speed and model stability. To prevent overfitting, Dropout is applied in the LSTM layer, and L2 regularization is introduced in the fully connected layer. Considering that the model is only a single layer and the parameter scale is moderate, the weight decay coefficient is set to 0.01, which can effectively control the risk of overfitting and retain the model's flexible fitting ability to the training data.
[0303] Finally, the network outputs the hidden state vector of each time step, and after average pooling, a feature vector with a fixed length of 32 dimensions is obtained as the final trajectory feature representation.
[0304] 3. Travel mode identification results
[0305] 3.1 Multi-view Subspace Clustering
[0306] All the obtained features are normalized and concatenated as the feature vector of each trajectory, and the multi-view subspace is used to identify the specific travel category.
[0307] The anchor point selection of the trajectory is carried out according to the trajectory characteristics. The specific process is as follows:
[0308] 1) Concatenate the data of all views into one overall matrix where d i is the i-th view.
[0309] 2) Normalize each feature according to formula (19) to ensure that each feature has the same scale.
[0310] 3) Calculate the sum of the eigenvalues of each sample according to formula (20) and store the result in S x .
[0311] 4) Repeat the following steps until m anchor points are selected:
[0312] According to formula (21), from S x Select the point with the maximum value as the anchor point and record its index.
[0313] Update S x , to avoid interference of the selected anchor point with subsequent selections.
[0314] 5) Stop condition: When m anchor points are selected, the loop ends.
[0315] Finally, the output anchor graph set {A1, A2, A3, …, A m},in
[0316] Based on the selected anchor graph, the multi-view subspace clustering method is used to cluster the trajectories. For the clustering parameters, the number of clusters is set to c, the self-expression matrix Z, the unified graph S, the matrix F, and the view weight w are initialized, and the following specific process is performed:
[0317] Repeat the steps until convergence:
[0318] Update the self-expression matrix Z according to formula (22).
[0319] Repeat the following steps until the number of connected components of S is equal to the number of clusters c:
[0320] Update the unified graph S according to formula (23).
[0321] Update the matrix F according to formula (24).
[0322] Check the number of connected components of S:
[0323] If the number of connected components is greater than c, halve λ.
[0324] If the number of connected components is less than c, double λ.
[0325] Update the view weight w using formula (25).
[0326] Finally, the cluster label Y is obtained according to the connected components of S.
[0327] 3.2 Travel mode identification results
[0328] In order to comprehensively compare the recognition effect of the present invention, the present invention compares and analyzes the currently commonly used travel mode recognition method with LSTM-AMSC. Traditional methods usually extract behavioral features from trajectory data, such as speed, distance, time, etc., and use clustering algorithms to cluster the features to identify travel categories. At the same time, in order to highlight the advantages of multi-view subspace clustering in multi-source feature fusion, a set of experiments was designed to directly use the SVM clustering method that is more commonly used in trajectory classification tasks to perform cluster analysis on static features and dynamic features. The specific comparison of travel mode recognition results is shown in Table 5.
[0329] Table 5 Comparison of travel mode recognition results accuracy of different methods
[0330]
[0331]
[0332] From Table 5, we can see that the LSTM-AMSC method performs well in the recognition accuracy of the five travel modes, which is better than other methods. Compared with the recognition method that only uses behavioral features, the recognition effect of using multi-source features combined with SVM method and LSTM-AMSC method in bus and subway travel is particularly significant. In addition, the overall accuracy of the recognition method that only relies on behavioral features combined with SVM is lower than that of the multi-source features combined with SVM method, which reflects that the introduction of multi-source data such as public transportation and road network can provide richer and multi-dimensional feature support for travel mode recognition.
[0333] At the same time, by comparing the performance of LSTM-AMSC with the multi-source feature combined with SVM method, LSTM-AMSC showed significant accuracy advantages in the recognition of various travel modes. This shows that the recognition method that only uses a single feature set has limitations in describing certain travel modes and the generalization ability of features is weak. LSTM-AMSC can capture more complex patterns and significantly improve recognition performance by fusing features from different views.
[0334] Pseudo code of LSTM-AMSC algorithm:
[0335]
[0336]
[0337]
[0338] It should be noted that the embodiments of the present invention can be implemented by hardware, software, or a combination of software and hardware. The hardware part can be implemented using dedicated logic; the software part can be stored in a memory and executed by an appropriate instruction execution system, such as a microprocessor or dedicated design hardware. It can be understood by a person of ordinary skill in the art that the above-mentioned devices and methods can be implemented using computer executable instructions and / or contained in a processor control code, such as a carrier medium such as a disk, CD or DVD-ROM, a programmable memory such as a read-only memory (firmware), or a data carrier such as an optical or electronic signal carrier. Such code is provided on the carrier medium. The device and its modules of the present invention can be implemented by hardware circuits such as very large-scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, etc., or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc., can also be implemented by software executed by various types of processors, and can also be implemented by a combination of the above-mentioned hardware circuits and software, such as firmware.
[0339] The above description is only a specific implementation mode of the present invention, but the protection scope of the present invention is not limited thereto. Any modifications, equivalent substitutions and improvements made by any technician familiar with the technical field within the technical scope disclosed by the present invention and within the spirit and principle of the present invention should be covered by the protection scope of the present invention.
Claims
1. A crowd travel mode recognition method based on multi-view subspace learning with dynamic and static feature fusion, characterized in that: The following steps are involved: S1: Preprocess the original mobile phone signaling data, clean invalid data and associate base station information to obtain longitude and latitude; S2: Extract travel trajectory data based on the user's unique identification code and handle abnormal conditions of ping-pong data and drift data; S3: Segment the user trajectory data and extract the single trip chain trajectory; S4: Combine mobile phone signaling data, road network data and public transportation data to extract static characteristics of the travel chain, including travel behavior characteristics and travel traffic characteristics; S5: Use LSTM model to extract dynamic features of trajectory and model the time series pattern of travel trajectory; S6: Fusion of static and dynamic features, using multi-view subspace learning method to identify user travel mode.
2. The method according to claim 1, characterized in that The S1 includes the following preprocessing steps: Remove records containing special characters in mobile phone signaling data; Delete the records whose imsi, lac_id, and cell_id fields are empty; Convert timestamps to a standard format; The latitude and longitude coordinates of the base station are associated through the lac_id and cell_id fields to generate a complete travel record.
3. The method according to claim 1, characterized in that When extracting user trajectories in S2: Group by IMSI and arrange the trajectory points of the same user in ascending order according to timestamp; Delete ping-pong data, i.e. repeated trajectory points of the same base station with a time difference less than a set threshold; Drift data is eliminated. The speed between trajectory points is calculated. If the speed exceeds the threshold, it is determined as an abnormal point and deleted.
4. The method according to claim 1, characterized in that In S3, the stay point is used as the segmentation basis of the travel chain: Combined with the sliding window method, it is determined whether the trajectory point meets the residence condition and the residence point is set as the sliding window boundary; Single trip chains are identified based on the dwelling points, and long-term dwelling trajectory segments are extracted and cut out from the trajectory sequence to generate multiple single trip chains.
5. The method according to claim 1, characterized in that When S5 extracts dynamic features through the LSTM model: Extract the relative displacement, velocity, acceleration and time interval for each point of the trajectory data to form a time series sample; Use the LSTM model to gradually update the hidden state and predict the next trajectory point feature based on the hidden state; The hidden state vector of the time series is converted into a fixed-length vector through an average pooling layer as the dynamic feature of the trajectory.
6. The method according to claim 1, characterized in that When S6 fuses static features and dynamic features: The static features are divided into a travel behavior feature view and a travel traffic feature view; The self-expression matrix of each view is generated using the multi-view subspace clustering method; The self-expression matrix is merged into a bipartite graph, and the bipartite graph is spectrally clustered to output the user's travel mode category.
7. A crowd travel mode recognition system based on multi-view subspace learning with dynamic and static feature fusion, characterized by: The system includes: The data preprocessing module is used to clean the original mobile phone signaling data, remove invalid data, associate the base station information to obtain the longitude and latitude, and generate standardized trajectory data; A trajectory extraction module is used to extract the user's travel trajectory data according to the user's unique identification code, process the ping-pong data and drift data in the trajectory, and generate a continuous trajectory sequence; Feature extraction module, used to extract static features (including travel behavior features and traffic features) and dynamic features (including relative displacement, speed, acceleration and other time series features) from the trajectory; The multi-view learning module is used to fuse static and dynamic features and classify and identify travel modes through a multi-view subspace learning method.
8. The system according to claim 7, characterized in that The data preprocessing module comprises: The cleaning unit is used to remove signaling records containing special characters and delete records where imsi, lac_id, and cell_id are empty; An association unit, used to associate base station information through lac_id and cell_id fields to generate trajectory points with longitude and latitude; The formatting unit is used to convert the timestamp into a standard time format and organize it into a standardized trajectory data format.
9. The system according to claim 7, characterized in that The feature extraction module comprises: Static feature extraction unit, used to extract travel behavior features in the trajectory, including travel distance, speed, time period, etc., as well as traffic features such as the number of public transportation stations, line coverage, road network density, etc.; The dynamic feature extraction unit is used to extract the temporal dynamic features of the trajectory based on the LSTM model, including the relative displacement, acceleration, velocity and time interval of the trajectory points, and generate a time series feature vector.
10. The system according to claim 7, characterized in that The multi-view learning module includes: A view separation unit, used for dividing the extracted features into a travel behavior feature view, a travel traffic feature view and a dynamic feature view; The subspace clustering unit uses a multi-view subspace clustering method to generate the self-expression matrix of each view through an anchor point selection strategy; The fusion and classification unit merges the self-expression matrix into a bipartite graph, classifies the bipartite graph using the spectral clustering method, and outputs the user's travel mode category.
Citation Information
Cited By
Personnel whole process activity mode identification and description method based on mobile phone signaling data
CN120075745A
Car insurance behavior risk assessment method and device and computer equipment
CN120823058A