Target area prediction methods, apparatus, computer equipment and storage media

By processing historical passenger flow data of the target area through graph convolutional neural networks, time series and spatial features are extracted, which solves the problem of inaccuracy of traditional prediction methods and achieves more accurate passenger flow prediction.

CN117010537BActive Publication Date: 2026-11-17TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202210446386.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-26
Publication Date
2026-11-17
Estimated Expiration
2042-04-26

AI Technical Summary

Technical Problem

Traditional methods for predicting visitor traffic in target areas are not accurate enough.

Method used

A graph convolutional neural network-based approach is used to obtain historical passenger flow data for the target area, extract time-series passenger flow features and spatial features, and combine them with the current time slice to predict passenger flow.

Benefits of technology

It improved the accuracy of passenger flow forecasting and enhanced forecasting performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117010537B_ABST
    Figure CN117010537B_ABST
Patent Text Reader

Abstract

This application can be applied to the transportation field, relating to a target area prediction method, apparatus, computer equipment, storage medium, and computer program product. The method includes: obtaining time-series passenger flow features matching the target area based on acquired historical passenger flow data for each target area, the historical passenger flow data including passenger flow data for each historical time slice; performing graph convolution on the time-series passenger flow features to obtain graph convolution features matching the time-series passenger flow features; extracting features from the acquired geographic feature information matching the target area to obtain spatial features of the target area; and predicting passenger flow based on the current time slice, graph convolution features, and spatial features of the target area to obtain the passenger flow prediction result for each target area. This method can improve prediction performance and achieve accurate prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, computer device, storage medium, and computer program product for predicting target areas. Background Technology

[0002] With the development of computer technology, target area visitor flow prediction technology has emerged. Target area visitor flow refers to the number of people visiting a target area during a certain period, usually counted at time granularities such as minutes, minute intervals, or hours. For example, if the target area is a shopping mall, then the target area visitor flow refers to the number of people visiting the mall during a certain period.

[0003] In traditional technologies, the method for predicting passenger flow in a target area is to monitor passenger flow in the target area using video acquisition equipment, obtain monitored passenger flow data for the target area, and then use traditional models such as time series prediction models to predict passenger flow based on the monitored passenger flow data, thereby obtaining the predicted passenger flow results for the target area.

[0004] However, the inventors believe that traditional methods suffer from inaccurate predictions. Summary of the Invention

[0005] Therefore, it is necessary to provide a method, apparatus, computer device, computer-readable storage medium, and computer program product capable of accurately predicting target areas, addressing the aforementioned technical problems.

[0006] Firstly, this application provides a target area prediction method. The method includes:

[0007] Based on the historical passenger flow data of each target area, the time series passenger flow characteristics matching the target area are obtained. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment.

[0008] Graph convolution is performed on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features;

[0009] Feature extraction is performed on the geographic feature information that matches the acquired target area to obtain the spatial features of the target area;

[0010] Based on the current time slice, graph convolution features, and spatial features of the target area, passenger flow prediction is performed to obtain the passenger flow prediction results for each target area.

[0011] Secondly, this application also provides a target area prediction device. The device includes:

[0012] The feature acquisition module is used to obtain the time series passenger flow features matching the target area based on the historical passenger flow data of each target area. The historical passenger flow data includes the passenger flow data of the target area in each historical time slice.

[0013] The graph convolution module is used to perform graph convolution on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features.

[0014] The processing module is used to extract features from the geographic feature information that matches the acquired target area to obtain the spatial features of the target area;

[0015] The prediction module is used to predict passenger flow based on the current time slice, graph convolution features, and spatial features of the target area, and obtain the passenger flow prediction results for each target area.

[0016] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to perform the following steps:

[0017] Based on the historical passenger flow data of each target area, the time series passenger flow characteristics matching the target area are obtained. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment.

[0018] Graph convolution is performed on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features;

[0019] Feature extraction is performed on the geographic feature information that matches the acquired target area to obtain the spatial features of the target area;

[0020] Based on the current time slice, graph convolution features, and spatial features of the target area, passenger flow prediction is performed to obtain the passenger flow prediction results for each target area.

[0021] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, performs the following steps:

[0022] Based on the historical passenger flow data of each target area, the time series passenger flow characteristics matching the target area are obtained. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment.

[0023] Graph convolution is performed on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features;

[0024] Feature extraction is performed on the geographic feature information that matches the acquired target area to obtain the spatial features of the target area;

[0025] Based on the current time slice, graph convolution features, and spatial features of the target area, passenger flow prediction is performed to obtain the passenger flow prediction results for each target area.

[0026] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, performs the following steps:

[0027] Based on the historical passenger flow data of each target area, the time series passenger flow characteristics matching the target area are obtained. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment.

[0028] Graph convolution is performed on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features;

[0029] Feature extraction is performed on the geographic feature information that matches the acquired target area to obtain the spatial features of the target area;

[0030] Based on the current time slice, graph convolution features, and spatial features of the target area, passenger flow prediction is performed to obtain the passenger flow prediction results for each target area.

[0031] The aforementioned target area prediction method, apparatus, computer equipment, storage medium, and computer program product first obtain time-series passenger flow characteristics matching the target area based on the acquired historical passenger flow data for each target area. Then, a graph convolutional neural network is applied to passenger flow prediction. By performing graph convolution on the time-series passenger flow characteristics, graph convolutional features matching the time-series passenger flow characteristics can be obtained. By extracting features from the acquired geographical feature information matching the target area, spatial features of the target area can be obtained. Furthermore, by combining rich features such as the current time slice, graph convolutional features, and target area spatial features, passenger flow prediction can be performed to obtain the passenger flow prediction results for each target area. The entire process, by applying graph convolutional neural networks to passenger flow prediction and utilizing rich features for passenger flow prediction, can improve prediction performance and achieve accurate prediction. Attached Figure Description

[0032] Figure 1 This is an application environment diagram of the target region prediction method in one embodiment;

[0033] Figure 2 This is a flowchart illustrating a target region prediction method in one embodiment;

[0034] Figure 3This is an application scenario diagram of the target region prediction method in one embodiment;

[0035] Figure 4 This is a schematic diagram illustrating passenger flow prediction based on a pre-trained passenger flow prediction model in one embodiment.

[0036] Figure 5 This is a flowchart illustrating the target region prediction method in another embodiment;

[0037] Figure 6 This is a structural block diagram of a target area prediction device in one embodiment;

[0038] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0039] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0040] The target area prediction method provided in this application embodiment can be applied to, for example... Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104 or placed in the cloud or on other servers. Server 104, based on the historical passenger flow data of each target area, obtains the time-series passenger flow characteristics matching the target area. The historical passenger flow data includes passenger flow data of the target area in each historical time slice. It performs graph convolution on the time-series passenger flow characteristics to obtain graph convolution features matching the time-series passenger flow characteristics. It extracts features from the geographical feature information matching the target area to obtain the spatial features of the target area. Based on the current time slice, the graph convolution features, and the spatial features of the target area, it performs passenger flow prediction to obtain the passenger flow prediction results for each target area. The passenger flow prediction results for each target area are then pushed to the terminal 102 matching the target area. Terminal 102 can be, but is not limited to, various desktop computers, laptops, smartphones, tablets, IoT devices, portable wearable devices, and aircraft. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart vehicle devices, etc. Portable wearable devices can include smartwatches, smart bracelets, head-mounted devices, etc. Server 104 can be implemented using a standalone server or a server cluster consisting of multiple servers, or it can be a node on a blockchain.

[0041] In one embodiment, such as Figure 2As shown, a target area prediction method is provided, which is then applied to... Figure 1 Taking server 104 as an example, the following steps are included:

[0042] Step 202: Based on the historical passenger flow data of each target area, obtain the time series passenger flow characteristics that match the target area. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment.

[0043] The target area refers to the region where visitor traffic needs to be predicted, and can be set as needed. For example, the target area could specifically be a shopping mall or a tourist attraction. Historical visitor traffic data refers to the visitor traffic data for each target area in each historical time segment within the statistical period. The length of the statistical period can be set as needed; for example, the statistical period could be the past month or the past two months.

[0044] Historical time slices refer to time segments obtained by dividing a statistical period into smaller segments. The method of dividing these time slices can be customized as needed. For example, a historical time slice could be a segment divided into hours within a statistical period, resulting in 24 time slices per day and 168 time slices per week. Alternatively, a historical time slice could be a segment divided into 20-minute intervals within a statistical period, resulting in 72 time slices per day and 504 time slices per week.

[0045] For example, when the statistical period is the past two months, the target area is shopping malls, and the historical time slices are time segments divided into hourly units, the historical customer flow data refers to the customer flow data of each shopping mall in 24 time slices per day within the past two months.

[0046] Among them, the time-series passenger flow characteristics refer to the passenger flow characteristics of each target area that match the time series. Here, the time series corresponds to the time period length, which can be set as needed. For example, the time series can specifically refer to the nearest neighbor sequence with a time slice as the time period length, and the corresponding nearest neighbor sequence passenger flow characteristics refer to the passenger flow of several time slices adjacent to the current time slice. For example, if the time slice is a time segment obtained by dividing the time into hours, and the current time slice is the 13th time slice of April 22, 2022 (corresponding to the time segment of 12:00-12:59), then the nearest neighbor sequence passenger flow characteristics can specifically refer to the passenger flow of the 12th time slice of April 22, 2022 (corresponding to the time segment of 11:00-11:59), the 11th time slice (corresponding to the time segment of 10:00-10:59), and so on.

[0047] For example, a time series can specifically refer to a daily sequence with a time period of days. The corresponding daily sequence passenger flow characteristics refer to the passenger flow of time slices at the same time on several days corresponding to the current time slice. For instance, if a time slice is a segment of time divided into hours, and the current time slice is the 13th time slice of April 22, 2022 (corresponding to the time segment 12:00-12:59), then the daily sequence passenger flow characteristics can specifically refer to the passenger flow of the 13th time slice of April 21, 2022, the 13th time slice of April 20, 2022, and so on.

[0048] For example, a time series can specifically refer to a weekly series with a time period of one week. The corresponding weekly series passenger flow characteristics refer to the passenger flow of several time slices with the same date attribute and the same time corresponding to the current time slice. For example, the date attribute here can specifically be a holiday, a day of the week, etc., which are not specifically limited in this embodiment. To further illustrate, if the date attribute is a day of the week, the time slice is a time segment obtained by dividing the time in hours, and the current time slice is the 13th time slice of April 22, 2022 (Friday) (the corresponding time segment is 12:00-12:59), then the weekly series passenger flow characteristics can specifically refer to the passenger flow of the 13th time slice of April 15, 2022 (i.e., last Friday), the 13th time slice of April 8, 2022 (i.e., the Friday before last), etc.

[0049] It should be noted that the length of the time slices corresponding to different time series passenger flow data is the same. The specific number of time slices corresponding to the aforementioned time slices can be set as needed. For different passenger flow characteristics, the specific number of time slices can be the same or different. For example, the passenger flow characteristic of a nearest-neighbor series can be the passenger flow of the 5 time slices adjacent to the current time slice; the passenger flow characteristic of a daily series can be the passenger flow of the time slices at the same time within the last 6 days corresponding to the current time slice; and the passenger flow characteristic of a weekly series can be the passenger flow of the 4 time slices with the same date attribute and at the same time corresponding to the current time slice.

[0050] Specifically, the server will obtain the location trajectory data matching each target device and the spatial basic information of each target area. Based on the location trajectory data and spatial basic information, it will count the historical passenger flow data of each target area. Then, based on the obtained historical passenger flow data of each target area, the current time slice, and the time subsequence type and the number of time slices corresponding to each time subsequence, it will obtain the time series passenger flow characteristics matching the target area.

[0051] It should be noted that there are at least two types of time subsequences. The time difference between time slices corresponding to different time subsequences meets a preset period, and the number of time slices can be set as needed. For example, if the time subsequence is a nearest neighbor sequence, the time difference between the corresponding time slices is one time slice; if the time subsequence is a daily sequence, the time difference between the corresponding time slices is one day; and if the time subsequence is a weekly sequence, the time difference between the corresponding time slices is one week. The time series passenger flow characteristics can be standardized data. The standardization method can be standard deviation standardization, maximum-minimum standardization, etc., which are not specifically limited in this embodiment.

[0052] The positioning trajectory data consists of the target device's positioning trajectory ordered by time. Each positioning trajectory includes one or more spatial positioning points, which are positioning information matching the target device, including the positioning location and the positioning timestamp. For example, a spatial positioning point can specifically refer to the information generated when the target device requests positioning through an application, including the positioning location at the time of the request (specifically, the positioning longitude and latitude) and the positioning timestamp. For instance, the positioning trajectory data consists of the spatial positioning points obtained each time the mobile terminal requests positioning through the application. For example, if the mobile terminal requests positioning four times in a day through the application, and the spatial positioning points are (x1, y1, 12:00), (x2, y2, 13:00), (x3, y3, 15:00), and (x4, y4, 18:00), then the positioning trajectory data can be [(x1, y1, 12:00), (x2, y2, 13:00), (x3, y3, 15:00), (x4, y4, 18:00)]. Spatial basic information is used to characterize the spatial location of a target region. For example, spatial basic information can specifically refer to the spatial coordinate string information of the outline surrounding the target region.

[0053] Step 204: Perform graph convolution on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features.

[0054] Graph convolution, in particular, refers to a deep learning network applicable to non-Euclidean spaces such as target regions, used to capture the spatial similarity between target regions. When using graph convolution to capture the spatial similarity between target regions, each target region is a node in the graph structure. The features used in graph convolution include: time-series passenger flow features for each target region and structural features between target regions. Specifically, for each target region as a node in the graph structure, it has corresponding time-series passenger flow features as node features. The structural features between target regions are used to characterize the structural relationships between them, serving as graph structure features. For example, the structural features between target regions are specifically an adjacency matrix representing the structural relationships between target regions. This adjacency matrix can be obtained based on the distance between each target region or based on the historical passenger flow curve of each target region. Graph convolution is used to capture the spatial similarity between target regions. Target regions that are geographically close or have similar trends (for example, similar historical passenger flow curves) will have similar time-series passenger flow features that are incorporated into the graph convolution. Therefore, during graph convolution, the spatial similarity between target regions can be approximately determined by utilizing the time-series passenger flow features of multiple layers of neighbors of each target region, resulting in graph convolution features that match the time-series passenger flow features. Specifically, the time-series passenger flow features include at least two types of time-subseries passenger flow features. After obtaining the time-series passenger flow features, the server performs graph convolution on at least two types of time-subseries passenger flow features based on the adjacency matrix matching the target regions, obtaining graph convolution features that match each type of time-subseries passenger flow feature.

[0055] Step 206: Extract features from the geographic feature information that matches the target area to obtain the spatial features of the target area.

[0056] Geographic feature information refers to information characterizing the geographic features of a target area, including geographic feature data matching each target area. For example, geographic feature information can specifically refer to the job and residence characteristics matching each target area, i.e., the work and residence characteristics within a first distance threshold centered on the target area. For instance, job and residence characteristics can include the number of residents, the number of working residents, the number of residents in each age group, and the number of working residents in each age group. These job and residence characteristics can be obtained through data mining of location trajectory data. Another example is geographic feature information that can include point-of-interest (POI) characteristics matching each target area, i.e., the POI characteristics within a second distance threshold centered on the target area. POIs are meaningful information points on a map, such as schools, shopping malls, hospitals, office buildings, residential areas, bridges, and parks. For instance, POI characteristics can include the number of POIs in residential areas, shopping malls, commercial buildings, and industrial parks. It should be noted that the first and second distance thresholds can be set as needed, and can be the same or different.

[0057] Specifically, the server standardizes the geographic feature information matching the target area, and then extracts features from the standardized geographic feature information using convolution to obtain the spatial features of the target area. The standardization process can be standard deviation standardization, maximum-minimum standardization, etc., and this embodiment does not specify a particular method. Feature extraction from geographic feature information aims to further extract the features contained within the geographic feature information, i.e., the spatial features of the target area, so as to combine these spatial features to achieve rich feature prediction of passenger flow. For example, feature extraction can be achieved by using convolution on the geographic feature information, encoding the geographic feature information into spatial features of the target area.

[0058] Step 208: Based on the current time slice, graph convolution features, and target area spatial features, predict passenger flow to obtain passenger flow prediction results for each target area.

[0059] The current time slice refers to the time slice that matches the current moment. For example, when dividing time in hours, if the current moment is 8:15 AM on Tuesday, then the current time slice is from 8:00 AM to 9:00 AM on Tuesday.

[0060] Specifically, the server determines the time-slice features corresponding to the current time slice, determines the time series weights based on the time-slice features, and performs a weighted summation of the graph convolution features that match each time-subsequence passenger flow feature in the graph convolution features to obtain the spatial passenger flow features. The spatial passenger flow features are then combined with the spatial features of the target area to predict passenger flow and obtain the passenger flow prediction results for each target area.

[0061] The aforementioned target area prediction method first obtains the time-series passenger flow characteristics matching the target area based on the historical passenger flow data of each target area. Then, it applies a graph convolutional neural network to passenger flow prediction. By performing graph convolution on the time-series passenger flow characteristics, it can obtain graph convolutional features that match the time-series passenger flow characteristics. By extracting features from the geographical feature information matching the target area, it can obtain the spatial features of the target area. Then, by combining the current time slice, graph convolutional features, and target area spatial features, it can predict passenger flow and obtain the passenger flow prediction results for each target area. The entire process, by applying graph convolutional neural networks to passenger flow prediction and utilizing rich features for passenger flow prediction, can improve prediction performance and achieve accurate prediction.

[0062] In one embodiment, the time-series passenger flow features include at least two types of time-subseries passenger flow features, where the time slices corresponding to each time-subseries passenger flow feature have the same length, and the time difference between the time slices corresponding to each time-subseries passenger flow feature meets a preset period. In this case, graph convolution is performed on the time-series passenger flow features to obtain graph convolution features that match the time-series passenger flow features, including:

[0063] Based on the adjacency matrix matching the target region, graph convolution is performed on at least two time series passenger flow features to obtain the graph convolution features matching each time series passenger flow feature.

[0064] The adjacency matrix is ​​used to characterize the structural relationships between target areas. Time-series passenger flow features include at least two types of time-series passenger flow features. For example, time-series passenger flow features can include nearest-neighbor series passenger flow features and daily series passenger flow features. In the nearest-neighbor series passenger flow features, the time difference between different time slices is one time slice, and in the daily series passenger flow features, the time difference between different time slices is one day. For example, if a time slice is a time segment divided in hours, and the current time slice is the 13th time slice on April 22, 2022 (corresponding to the time segment 12:00-12:59), then the passenger flow characteristics of the nearest neighbor sequence can specifically refer to the passenger flow of the 12th time slice (corresponding to the time segment 11:00-11:59) and the 11th time slice (corresponding to the time segment 10:00-10:59) on April 22, 2022. The passenger flow characteristics of the day sequence can specifically refer to the passenger flow of the 13th time slice on April 21, 2022 and the 13th time slice on April 20, 2022.

[0065] For example, time-series passenger flow features can include nearest-neighbor time-series passenger flow features and weekly time-series passenger flow features. In the weekly time-series passenger flow features, the time difference between different time slices is one week. For instance, if a time slice is a segment of time divided in hours, and the current time slice is the 13th time slice of April 22, 2022 (corresponding to the time segment 12:00-12:59), and the date attribute is a day of the week, then the nearest-neighbor time-series passenger flow features could specifically refer to the passenger flow of the 12th time slice (corresponding to the time segment 11:00-11:59) and the 11th time slice (corresponding to the time segment 10:00-10:59) on April 22, 2022. Similarly, the weekly time-series passenger flow features could specifically refer to the passenger flow of the 13th time slice of April 15, 2022 (last Friday) and the 13th time slice of April 8, 2022 (the Friday before last).

[0066] For example, time-series passenger flow characteristics can include daily and weekly passenger flow characteristics. For instance, if a time slice is a segment of time divided into hours, and the current time slice is the 13th time slice of April 22, 2022 (corresponding to the time segment 12:00-12:59), and the date attribute is a day of the week, the daily passenger flow characteristics could specifically refer to the passenger flow of the 13th time slice of April 21, 2022, the 13th time slice of April 20, 2022, etc., while the weekly passenger flow characteristics could specifically refer to the passenger flow of the 13th time slice of April 15, 2022 (last Friday), the 13th time slice of April 8, 2022 (the Friday before last), etc.

[0067] For example, time series passenger flow characteristics can include nearest neighbor series passenger flow characteristics, daily series passenger flow characteristics, and weekly series passenger flow characteristics. For example, if a time slice is a time segment divided in hours, and the current time slice is the 13th time slice of April 22, 2022 (corresponding to the time segment 12:00-12:59), and the date attribute is the day of the week, then the passenger flow characteristics of the nearest neighbor sequence can specifically refer to the passenger flow of the 12th time slice (corresponding to the time segment 11:00-11:59) and the 11th time slice (corresponding to the time segment 10:00-10:59) of April 22, 2022. The passenger flow characteristics of the day sequence can specifically refer to the passenger flow of the 13th time slice of April 21, 2022 and the 13th time slice of April 20, 2022. The passenger flow characteristics of the week sequence can specifically refer to the passenger flow of the 13th time slice of April 15, 2022 (i.e., last Friday) and the 13th time slice of April 8, 2022 (i.e., the Friday before last).

[0068] Specifically, the server uses pre-trained graph convolutional layers to perform graph convolution on at least two time-series passenger flow features based on the adjacency matrix matching the target region. This yields graph convolutional features matching each time-series passenger flow feature. Performing graph convolution on at least two time-series passenger flow features means using each time-series passenger flow feature as a node feature of the target region and performing graph convolution based on the adjacency matrix matching the target matrix to capture spatial similarity matching the time-series passenger flow features. The input to the pre-trained graph convolutional layers is the passenger flow feature for each time-series.

[0069] It should be noted that this embodiment does not restrict the structure of the trained graph convolutional layer. For example, the number of layers L in the trained graph convolutional layer can be set as needed, and is a hyperparameter of the trained graph convolutional layer. For example, each layer in the trained graph convolutional layer can be in the form of a naive graph convolutional module, and the corresponding graph convolution processing formula for the trained graph convolutional layer is:

[0070] H (l) =σ(H (l-1) W (l)0 +AH (l-1) W (l)1 )

[0071] Among them, H (l) and H (l-1) These refer to the l-th and (l-1)-th layers in the trained graph convolutional layers, respectively, where the (l-1)-th layer serves as the input to the l-th layer. (l)0 and W (l)1This refers to the parameter tensor in the trained graph convolutional layer, which can be obtained during the training of the graph convolutional layer. A is the adjacency matrix matching the target region, and σ is the activation function. In this embodiment, the activation function is not specifically limited, as long as it can achieve the corresponding function. For example, the activation function can be ReLU (Rectified Linear Activation Function). The input of the first layer in each trained graph convolutional layer is the passenger flow feature of each time subsequence, and the output of the last layer is the graph convolutional feature that matches the passenger flow feature of the time subsequence.

[0072] In this embodiment, by performing graph convolution on at least two time series passenger flow features based on the adjacency matrix that matches the target area, the spatial similarity between passenger flow in each target area can be captured through graph convolution, and graph convolution features matching each time series passenger flow feature can be obtained. In this way, more accurate prediction can be made using graph convolution features.

[0073] In one embodiment, before performing graph convolution on at least two time-series passenger flow features based on the obtained adjacency matrix matching the target region to obtain the graph convolution features matching each time-series passenger flow feature, the method further includes:

[0074] Get the distance between any two target regions;

[0075] The adjacency matrix matching the target region is obtained based on the regional distance.

[0076] Specifically, the server will obtain the regional distance between any two target regions based on the spatial information of the target region, normalize the regional distance to obtain the normalized distance matrix between the target regions, and use the normalized distance matrix as the adjacency matrix that matches the target regions.

[0077] In one embodiment, the method for obtaining the regional distance between any two target regions based on the spatial basic information of the target region can be as follows: first, obtain the outline of the target region based on the spatial basic information of the target region, then determine the center point corresponding to the outline of the target region, and finally use the distance between the center points corresponding to the outlines of the two target regions as the regional distance between the two target regions.

[0078] In one embodiment, the method of obtaining the regional distance between any two target areas based on the spatial basic information of the target area can also be: based on the spatial coordinates in the spatial basic information of the target area, calculate the nearest spatial coordinate distance between the two target areas, and use the nearest spatial coordinate distance as the regional distance between the two target areas.

[0079] In this embodiment, by obtaining the regional distance between any two target areas, an adjacency matrix representing the relationship between the target areas can be obtained based on the regional distance. In turn, the adjacency matrix can be used to capture the spatial similarity between the passenger flow of the target areas.

[0080] In one embodiment, before performing graph convolution on at least two time-series passenger flow features based on the obtained adjacency matrix matching the target region to obtain the graph convolution features matching each time-series passenger flow feature, the method further includes:

[0081] Based on the historical passenger flow data of each target area, a matching historical passenger flow curve is obtained for each target area.

[0082] The adjacency matrix matching the target area is obtained based on the historical passenger flow curve.

[0083] The historical passenger flow curve refers to a curve that characterizes changes in historical passenger flow. For example, the historical passenger flow curve can specifically include the average passenger flow for each statistical time segment within a statistical period. These statistical time segments can be set as needed; for instance, they can be time segments divided into hours, such as 24 time segments from 0:00 to 23:00. To illustrate, the historical passenger flow curve can specifically include the average passenger flow for each time segment within a statistical period, divided into hours.

[0084] Specifically, the server calculates the average passenger flow for each target area in each statistical time segment based on historical passenger flow data. Based on the average passenger flow for each statistical time segment, it plots a matching historical passenger flow curve for each target area. Then, it evaluates the similarity between any two target areas based on these historical passenger flow curves, obtaining a similarity evaluation index. Finally, it constructs an adjacency matrix matching the target areas based on the similarity evaluation index between each pair of target areas. The similarity evaluation index can specifically be a correlation coefficient. The method for evaluating the similarity between any two target areas based on historical passenger flow curves can be as follows: based on the average passenger flow for each time segment in the historical passenger flow curve, it obtains an array of historical passenger flow curves to be evaluated, and then calculates the correlation coefficient between the two historical passenger flow curves based on this array.

[0085] In this embodiment, by using historical passenger flow data of each target area, a matching historical passenger flow curve is obtained for each target area. Based on the historical passenger flow curve, an adjacency matrix representing the relationship between target areas can be obtained. That is, the trend is used to represent the relationship between target areas, and the adjacency matrix can be used to capture the spatial similarity between passenger flows of target areas.

[0086] In one embodiment, based on the current time slice, graph convolutional features, and spatial features of the target area, passenger flow prediction is performed, resulting in the following passenger flow prediction results for each target area:

[0087] Determine the time slice characteristics corresponding to the current time slice;

[0088] Spatial passenger flow characteristics are obtained based on time slice features and graph convolution features;

[0089] By combining the spatial passenger flow characteristics and the target area spatial characteristics, the passenger flow characteristics to be predicted are obtained.

[0090] Convolution is performed on the features of the passenger flow to be predicted to obtain the passenger flow prediction results for each target area.

[0091] The time slice feature is used to characterize the temporal features of the current time slice. For example, the time slice feature can specifically be a feature that characterizes the position of the current time slice within a week. For instance, the time slice feature can be a one-hot encoding that characterizes the position of the current time slice within a week.

[0092] Specifically, the position of the current time slice within a week is unique. For example, if time slices are divided by hours, there are a total of 24 * 7 = 168 time slices in a week. Each of these 168 time slices has a unique position within the week, corresponding to different time periods. Therefore, the server can perform feature encoding on the current time slice based on its position within the week to obtain the corresponding time slice feature. This time slice feature accurately represents the temporal characteristics of the current time slice. Since different time slices correspond to different time periods, the importance of time subsequences varies for different time periods. For example, for weekday working hours, the nearest neighbor sequence passenger flow feature and the daily sequence passenger flow feature may be more important when predicting passenger flow. Conversely, for holidays, the weekly sequence passenger flow feature may be more important when predicting passenger flow. Therefore, the server can obtain the corresponding time series weights by convolving the time slice features to determine the importance of each time subsequence corresponding to the current time slice. Based on the time series weights, the server can perform weighted summation of the graph convolution features that match the passenger flow features of each time subsequence in the graph convolution features. Under the condition of fully considering the time features of the current time slice, the corresponding spatial passenger flow features can be obtained.

[0093] Specifically, after obtaining the spatial passenger flow characteristics, to obtain richer passenger flow characteristics for prediction, the server concatenates the spatial passenger flow characteristics and the target area spatial characteristics. Taking full account of the geographical features surrounding the target area, the server combines the target area spatial characteristics and the spatial passenger flow characteristics obtained based on the geographical features to obtain the passenger flow characteristics to be predicted. Then, by convolving the passenger flow characteristics to be predicted, the passenger flow prediction results for each target area can be obtained. The server can use a pre-trained first fully connected layer to convolve the passenger flow characteristics to be predicted. It should be noted that the pre-trained first fully connected layer can be pre-trained as needed; this embodiment does not specifically limit the number of fully connected layers in the first fully connected layer. For example, the first fully connected layer can be one fully connected layer or at least two fully connected layers.

[0094] Specifically, the time slice feature can be a one-hot encoding of the current time slice's position within a week. In one-hot encoding, the position value corresponding to the current time slice is set to 1, and the position values ​​not corresponding to the current time slice are set to 0, thus identifying the current time slice's position within a week. For example, if time slices are divided in hours, there are a total of 24 * 7 = 168 time slices in a week. If the current time is 8:00 AM on Tuesday, the current time slice is the 32nd time slice in the week. The time slice feature obtained after one-hot encoding is an array of length 168, with the position at index 32 having a value of 1 and the remaining positions having values ​​of 0.

[0095] In this embodiment, by determining the time slice features corresponding to the current time slice, spatial passenger flow features can be obtained based on the time slice features and graph convolution features. Then, by splicing the spatial passenger flow features and the spatial features of the target area, a passenger flow feature to be predicted combining multiple features can be obtained. Thus, by convolving the passenger flow feature to be predicted, passenger flow can be predicted using rich features, and passenger flow prediction results for each target area can be obtained.

[0096] In one embodiment, spatial passenger flow features are obtained based on time-slice features and graph convolution features, including:

[0097] Convolution is performed on the time-slice features to obtain the time-series weights;

[0098] Based on time series weights, the spatial passenger flow features are obtained by weighted summation of the graph convolution features that match each time series passenger flow feature in the graph convolution features.

[0099] Specifically, the server can process the time-slice features using a pre-trained second fully connected layer and a normalized exponential function (softmax) to obtain time-series weights. This determines the importance of each time subsequence corresponding to the current time slice. Based on the weights of each time subsequence in the time-series weights, the graph convolutional features matching each time subsequence's passenger flow feature in the graph convolutional features are weighted and summed. This yields the spatial passenger flow features while fully considering the temporal characteristics of the current time slice. It should be noted that the sum of the weights of each time subsequence in the time-series weights is 1. The pre-trained second fully connected layer can be pre-trained as needed; this embodiment does not specify the number of fully connected layers in the second fully connected layer. For example, the second fully connected layer can be one fully connected layer or at least two fully connected layers.

[0100] For example, since different time slices correspond to different time periods, the importance of time subsequences will vary for different time periods. For instance, during weekday working hours, when predicting passenger flow, the nearest neighbor sequence passenger flow features and the daily sequence passenger flow features may be more important, and their weights will be greater than the weekly sequence. Similarly, during holidays, when predicting passenger flow, the weekly sequence passenger flow features may be more important, and their weights will be greater than the nearest neighbor sequence and the daily sequence. In this embodiment, by convolving the time slice features, time series weights can be obtained while fully considering the time features of the current time slice. Then, based on these time series weights, the corresponding graph convolution features matching each time subsequence passenger flow feature in the graph convolution features can be weighted and summed to obtain the spatial passenger flow features.

[0101] In one embodiment, before obtaining the time-series passenger flow characteristics matching the target area based on the acquired historical passenger flow data for each target area, the method further includes:

[0102] Based on the acquired location trajectory data matching each target device, the corresponding work and residence area information for each target device is determined.

[0103] Based on location trajectory data, work and residence area information, and the spatial basic information of each target area, historical passenger flow data for each target area is statistically analyzed.

[0104] Among them, the work-residence area refers to the work area and residence area that each target device matches, and the work-residence area information refers to the location information of the work area and residence area that each target device matches.

[0105] Specifically, the server extracts the corresponding work-residence area information for each target device based on the acquired location trajectory data. Then, based on this information and the spatial baseline information of each target area, it analyzes the spatial positioning points in the location trajectory data to calculate historical passenger flow data for each target area. Specifically, when extracting the corresponding work-residence area information for each target device, the server performs weighted clustering of the spatial positioning points in the location trajectory data based on preset work and residence time periods. The cluster center with the highest weight during the work period is designated as the workplace, and the cluster center with the highest weight during the residence time period is designated as the residence, thus obtaining the corresponding work-residence area information for each target device.

[0106] Furthermore, weighted clustering of spatial positioning points in the positioning trajectory data based on preset work and residence time periods refers to dividing each day into multiple weighted time periods and setting different work attribute weights and residence attribute weights for each weighted time period. Spatial positioning points in the positioning trajectory data are then clustered based on the preset work and residence time periods to obtain work location cluster sets and residence location cluster sets. Based on the work attribute weights and residence attribute weights corresponding to the positioning time of each work location in the work location cluster set, a clustering weight score is calculated for each work location cluster. Similarly, based on the work attribute weights and residence attribute weights corresponding to the positioning time of each residence in the residence location cluster set, a clustering weight score is calculated for each residence location cluster. Finally, based on the clustering weight scores, each work location in the work location cluster set and each residence in the residence location cluster set are sorted.

[0107] Specifically, if the weighted time period corresponds to a preset working time period, the weight of the working attribute is greater than the weight of the residential attribute; conversely, if the weighted time period corresponds to a preset residential time period, the weight of the residential attribute is greater than the weight of the working attribute. The preset working and residential time periods can be set as needed. For example, the working time period could be from 9:00 AM to 6:00 PM, and the residential time period could be from 8:00 PM to 8:00 AM the following morning.

[0108] In this embodiment, by mining the work-residence area information that matches each target device based on the obtained location trajectory data, the historical passenger flow data of each target area can be statistically analyzed based on the location trajectory data, work-residence area information, and the obtained spatial basic information of each target area.

[0109] It should be noted that the inventors believe that while methods of monitoring visitor flow in target areas based on smart hardware or video surveillance are relatively accurate, they suffer from drawbacks such as high hardware setup and maintenance costs, and the inability to further correlate visitor information with only the number of people monitored. In this embodiment, however, historical visitor flow data for each target area is statistically analyzed using the location trajectory data matched to each target device. Monitoring can be achieved based on the location actively reported by users when requesting location during the use of the target devices. This method is cost-effective, requiring no hardware setup or maintenance costs in the target area. Furthermore, the visiting target devices can obtain rich information through de-identified anonymous identifiers, enabling accurate prediction and helping the target area to understand the patterns of visitor flow.

[0110] In one embodiment, based on location trajectory data, residential and work area information, and the acquired spatial basic information of each target area, the historical passenger flow data for each target area is statistically analyzed, including:

[0111] Based on information about work and residence areas and basic spatial information, spatial query analysis is performed on spatial positioning points in the positioning trajectory data;

[0112] When it is determined that there is a target spatial positioning point in the target area to be counted and the corresponding work and residence area information that matches the target spatial positioning point is not in the target area to be counted, the status of the target device with the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted.

[0113] Based on the target device status of each location timestamp, historical passenger flow data for each target area is statistically analyzed.

[0114] Spatial query analysis refers to checking whether spatial positioning points in the location trajectory data match the action of entering the target area. The target area to be analyzed refers to the area where historical passenger flow data needs to be collected. The area identifier is used to uniquely identify the target area to be analyzed.

[0115] Specifically, when starting to collect historical passenger flow data for each target area, the server initializes the target device status of each target device to a preset value. This allows for subsequent statistical analysis of historical passenger flow data for each target area based on changes in the target device status. After initializing the target device status, the server performs spatial query analysis on spatial positioning points in the location trajectory data based on residential area information and spatial infrastructure information. If the coordinates of a spatial positioning point are within the range corresponding to the spatial infrastructure information of the target area to be counted, and the residential area information matching that spatial positioning point is not within the target area to be counted, then that spatial positioning point is considered a target spatial positioning point. This means that the target device matching the target spatial positioning point has visited the target area to be counted, and the target device status of the location timestamp matching the target spatial positioning point is changed to the area identifier of the target area to be counted. After completing the spatial query analysis of all location trajectory data, the target device status of each target device at each location timestamp can be obtained. Therefore, historical passenger flow data for each target area can be collected based on the target device status at each location timestamp. The preset values ​​can be set as needed.

[0116] Specifically, when calculating historical passenger flow data for each target area based on the target device status of each location timestamp, for each historical time slice, the server determines the historical location timestamp corresponding to the historical time slice, obtains the target device status of the historical location timestamp, and determines whether the target device matching the historical location timestamp has visited the target area in the historical time slice based on the target device status of the historical location timestamp and the target device status of the corresponding previous timestamp, thereby calculating the historical passenger flow data for each target area.

[0117] Specifically, if the target device status at the previous timestamp is the same as the target device status at a historical positioning timestamp, it means the target device is within the target area and is not included in the statistics. If the target device status at the previous timestamp is different from the target device status at a historical positioning timestamp, then the corresponding statistics are performed based on the target device status at the historical positioning timestamp, i.e., the area identifier of the target area to be counted. It should be noted that if, during the statistics process, it is found that the target device status still indicates that it is within a certain target area after midnight of one day, the target device status will be automatically reset to the preset value. That is, at midnight, even if there are no more spatial positioning points indicating that the target device has left the target area, it is automatically considered that the target device has left the target area.

[0118] For example, the server can pre-create a passenger flow table N to count historical passenger flow data for each target area. Specifically, the passenger flow table can be a hash table, where the key is the area identifier of the target area, and the value N[K] is an array of length T, where T is the number of historical time slices to be counted. That is, N[m][t_index] represents the passenger flow of the target area with area identifier m in the t_index historical time slice. For each target area m and each time slice t_index, N[m][t_index] is initialized to 0. When the statistics begin, the server first initializes the target device status s of each target device to a preset value (null). For each spatial positioning point in the positioning trajectory data, a spatial query analysis is performed. If the coordinates of the spatial positioning point are within the range corresponding to the basic spatial information of the target area to be counted, and the work-residence area information that matches the spatial positioning point is not in the target area to be counted, then the spatial positioning point is considered a target spatial positioning point. That is, the target device that matches the target spatial positioning point has visited the target area to be counted. The target device status of the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted.

[0119] After completing the spatial query analysis of all location trajectory data, the server updates the traffic table N based on the target device status of each location timestamp to statistically analyze the historical passenger flow data for each target area. For each historical time slice, the server determines the historical location timestamp corresponding to the historical time slice, obtains the target device status of the historical location timestamp, and determines whether the target device matching the historical location timestamp has visited the target area in the historical time slice based on the target device status of the historical location timestamp and the target device status of the corresponding previous timestamp. If the target device status of the previous timestamp is the same as the target device status of the historical location timestamp, it means that the target device is in the target area and is not counted. If the target device status of the previous timestamp is different from the target device status of the historical location timestamp, then the corresponding statistics are performed based on the target device status of the historical location timestamp, i.e., the area identifier of the target area to be counted, N[m][t_index] = N[m][t_index] + 1, where m is the area identifier of the target area to be counted and t_index is the historical time slice in which passenger flow is being counted.

[0120] In this embodiment, by performing spatial query analysis on spatial positioning points in the positioning trajectory data based on work and residence area information and spatial basic information, the target device status of the positioning timestamp matching each spatial positioning point can be determined. Then, based on the target device status of each positioning timestamp, the historical passenger flow data of each target area can be statistically analyzed.

[0121] In one embodiment, such as Figure 3 As shown in the figure, the target area prediction of this application is illustrated by an application scenario diagram. The spatial basic information is the target area outline data, the geographic feature information includes point of interest data, and the work-residence area information is the work-residence data.

[0122] Specifically, the server will determine the corresponding work and residence data for each target device based on the location trajectory data matched with each target device. Based on the work and residence data and the outline data of the target area, the server will perform spatial query analysis on the spatial positioning points in the location trajectory data. When it is determined that there is a target spatial positioning point in the target area to be counted and the work and residence area corresponding to the work and residence data matched with the target spatial positioning point is not in the target area to be counted, the status of the target device with the location timestamp matched with the target spatial positioning point will be changed to the area identifier of the target area to be counted. Based on the status of the target device with each location timestamp, the server will count the historical passenger flow data of each target area, that is, obtain the historical passenger flow table through passenger flow monitoring.

[0123] After obtaining historical passenger flow data for each target area, the server can combine the historical passenger flow table with surrounding geographical features (including work and residence data and points of interest data) to predict passenger flow. By combining the historical passenger flow table with surrounding geographical features, it is possible to use rich features to predict passenger flow, improve prediction performance, and achieve accurate prediction. At this point, the server will obtain the time-series passenger flow features matching the target area based on the historical passenger flow data of each target area. The time-series passenger flow features include at least two time sub-series passenger flow features. Based on the adjacency matrix matching the target area, graph convolution is performed on the at least two time sub-series passenger flow features respectively to obtain the graph convolution features matching each time sub-series passenger flow feature. Feature extraction is performed on the geographical feature information matching the target area to obtain the spatial features of the target area. The time slice features corresponding to the current time slice are determined. The time slice features are convolved to obtain the time series weights. Based on the time series weights, the graph convolution features matching each time sub-series passenger flow feature in the graph convolution features are weighted and summed to obtain the spatial passenger flow features. The spatial passenger flow features and the target area spatial features are concatenated to obtain the passenger flow features to be predicted. The passenger flow features to be predicted are convolved to obtain the passenger flow prediction results for each target area.

[0124] Furthermore, such as Figure 4 As shown, the above passenger flow prediction can be achieved based on a pre-trained passenger flow prediction model, which includes an input layer, a graph convolutional layer, and an output layer.

[0125] The input layer of this passenger flow prediction model includes three types of time-series passenger flow features (specifically, nearest-neighbor sequence passenger flow features, daily sequence passenger flow features, and weekly sequence passenger flow features), time-slice features, and geographic feature information. For each time-series passenger flow feature, each selected time slice is a tensor of size M*1, where M is the number of target areas, and the corresponding value is the passenger flow of that target area in that time slice. By concatenating multiple selected time slices sequentially, an input tensor matching the passenger flow features of the sequence is formed, with a size of T*M*1, where T is the number of time slices selected in the sequence. For the time-slice features, it is a one-hot encoding of the current time slice's position within a week. The geographic feature information is an array concatenated from the standardized geographic features surrounding each target area. The arrays of each target area are combined into a global tensor of size M*F, where M is the number of target areas, and F is the dimension of the geographic feature information.

[0126] The graph convolutional layer in this passenger flow prediction model aims to capture the spatial similarity between passenger flows in different target areas. It assumes that target areas with similar locations (represented by regional distance) or trends (represented by historical passenger flow curves) will have similar passenger flow sequences. These sequences are processed by a graph convolutional layer with L layers, where L is a hyperparameter of the passenger flow prediction model. The graph convolutional layer can approximate the spatial similarity between target areas by utilizing the time-series passenger flow features of multiple neighboring areas, thus obtaining graph convolutional features that match the time-series passenger flow characteristics. For example, each layer in the graph convolutional layer can be in the form of a naive graph convolutional module, and the corresponding graph convolutional processing formula used by the graph convolutional layer is:

[0127] H (l) =σ(H (l-1) W (l)0 +AH (l-1) W (l)1 )

[0128] Among them, H (l( and H (l-1) These refer to the l-th and (l-1)-th layers in the graph convolutional layer, respectively, where the (l-1)-th layer serves as the input to the l-th layer. (l)0 and W (l)1 This refers to the parameter tensor in the graph convolutional layer, which can be obtained during training. A is the adjacency matrix matching the target region, and σ is the activation function. In this embodiment, the activation function is not specifically limited, as long as it can achieve the corresponding function. For example, the activation function can be ReLU. The input of the first layer in the graph convolutional layer is the passenger flow feature of each time subsequence, and the output of the last layer is the graph convolutional feature that matches the passenger flow feature of the time subsequence.

[0129] To further illustrate, each layer in the graph convolutional layer can specifically be a spatiotemporal graph convolutional neural network, an attention-temporal graph convolutional network, or other graph convolutional neural networks; this embodiment does not impose specific limitations here. However, it should be noted that regardless of the form of the graph convolutional module used in each layer of the graph convolutional layer, an adjacency matrix needs to be defined. The adjacency matrix is ​​used to represent the structural relationships between target regions, and can be obtained based on the regional distance between target regions or the historical passenger flow curves that match each target region.

[0130] In the output layer of this passenger flow prediction model, after the time-slice features are input into the model and processed by a fully connected layer and softmax, time-series weights are output. These weights include the weights of each time subsequence (the sum of the weights of each time subsequence is 1). Based on these weights, the importance of each time subsequence corresponding to the current time slice can be determined. The nearest neighbor sequence passenger flow features, daily sequence passenger flow features, and weekly sequence passenger flow features each enter a graph convolutional layer. At the output layer, three tensors of size M*H are obtained, where H is the dimension of the final output of the graph convolutional layer, and M is the number of target regions. These three tensors undergo attention processing, and the attention weights are the time-series weights. By weighted summing of the graph convolutional features matching each time subsequence passenger flow feature in the graph convolutional features based on these time-sequence weights, a spatial passenger flow feature of size M*H can be obtained while fully considering the temporal features of the current time slice. After geographic feature information is input into the passenger flow prediction model, it is processed by a fully connected layer, outputting target area spatial features of size M*FH (where FH is a custom output dimension of the target area spatial features). After obtaining the spatial passenger flow features and target area spatial features, to obtain richer passenger flow features for prediction, the output layer concatenates the spatial passenger flow features and target area spatial features to obtain the passenger flow features to be predicted (size M*(FH+H)). The fully connected layer then processes these passenger flow features to obtain the passenger flow prediction results for each target area. The size of the passenger flow prediction result for each target area is (M*T). output ), where T output The number of time slices to be predicted.

[0131] In training the passenger flow prediction model, a loss function can be calculated by comparing the predicted passenger flow with the actual passenger flow. The model can then be optimized based on this loss function to obtain a trained passenger flow prediction model. Furthermore, L2 Loss (mean squared error loss function) can be used as the loss function, and the passenger flow prediction model can be trained using gradient learning or other optimization algorithms. This embodiment does not impose specific limitations here; for example, the Adam optimization algorithm can be used as the model's learning and optimization algorithm.

[0132] Furthermore, the inventors believe that the target area prediction method involved in this application realizes the monitoring of passenger flow in a target area within several time slots of a day based on low-cost data such as location trajectory data and work and residence data, without the need for target area operation, to obtain historical passenger flow data for each target area, and based on the historical passenger flow data, to construct a graph convolutional neural network model that integrates surrounding geographical feature information, thereby realizing the prediction of passenger flow in the target area for several future time periods.

[0133] Furthermore, for the sample data (specifically, passenger flow data for various target areas within a city), the inventors used hours as the time unit, employed a three-layer naive graph convolution module, and used the trend correlation coefficient obtained from the historical passenger flow curves of the target area as the adjacency matrix. Geographical feature information was also integrated for passenger flow prediction. The prediction results show that, compared to traditional time series prediction or machine learning models such as autoregressive moving average models and extreme gradient boosting models, the passenger flow prediction model provided in this embodiment demonstrates improved prediction performance. Using root mean square error (RMSE) as the evaluation metric, a comparison of prediction performance is shown in Table 1. RMSE is a commonly used measure of the difference between numerical values ​​and is frequently used in regression models as an evaluation metric. For the same dataset, a smaller RMSE value indicates a lower model error and better model performance.

[0134] Table 1

[0135] Model Root mean square error HA (Time Series Model) 117.98 ARIMA (Autoregressive Moving Average Model) 99.53 XGBoost (Extreme Gradient Boosting Model) 91.76 Image convolution, unblended surrounding geographic features 83.21 Image convolution, fusion of surrounding geographical features 79.32

[0136] In one embodiment, such as Figure 5 As shown in the diagram, the target area prediction method of this application is illustrated by a flowchart. The target area prediction method specifically includes the following steps:

[0137] Step 502: Based on the acquired location trajectory data matching each target device, determine the corresponding work and residence area information for each target device.

[0138] Specifically, the server will perform weighted clustering of spatial positioning points in the location trajectory data matched by each target device based on preset working and living time periods. The cluster center with the highest weight during the working time period will be taken as the workplace, and the cluster center with the highest weight during the living time period will be taken as the residence, thus obtaining the work-residence area information matched by each target device.

[0139] Step 504: Based on the work and residence area information and spatial basic information, perform spatial query analysis on the spatial positioning points in the positioning trajectory data.

[0140] Specifically, the server will determine whether the spatial positioning point in the positioning trajectory data matches the action of entering the target area based on the work and residence area information and spatial basic information, that is, whether the spatial positioning point matches the passenger flow to the target area.

[0141] Step 506: When it is determined that there is a target spatial positioning point in the target area to be counted and the work-residence area information that matches the target spatial positioning point is not in the target area to be counted, the status of the target device with the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted.

[0142] Specifically, if the coordinates of a spatial location point are within the range of the basic spatial information of the target area to be counted, and the residential area corresponding to the residential area information matched by the spatial location point is not within the target area to be counted, then the spatial location point is considered a target spatial location point. That is, the target device matched by the target spatial location point has a visit behavior in the target area to be counted, and the status of the target device with the location timestamp matched by the target spatial location point is changed to the area identifier of the target area to be counted.

[0143] Step 508: Based on the target device status of each location timestamp, calculate the historical passenger flow data for each target area.

[0144] Specifically, for each historical time slice, the server determines the historical location timestamp corresponding to the historical time slice, obtains the target device status of the historical location timestamp, and determines whether the target device matching the historical location timestamp has visited the target area in the historical time slice based on the target device status of the historical location timestamp and the target device status of the corresponding previous timestamp, thereby calculating the historical passenger flow data of each target area.

[0145] Step 510: Based on the historical passenger flow data of each target area, obtain the time series passenger flow characteristics that match the target area. The historical passenger flow data includes the passenger flow data of the target area in each historical time slice, and the time series passenger flow characteristics include at least two time sub-series passenger flow characteristics.

[0146] Specifically, the server will obtain the time series passenger flow characteristics matching the target area based on the historical passenger flow data of each target area, the current time slice, the type of time subsequence matching the time series, and the number of time slices corresponding to each time subsequence. The time subsequence type can be a nearest neighbor sequence, a daily sequence, a weekly sequence, etc.

[0147] Step 512: Based on the adjacency matrix matching the target region, perform graph convolution on at least two time series passenger flow features respectively to obtain the graph convolution feature matching each time series passenger flow feature.

[0148] The adjacency matrix is ​​a matrix that represents the structural relationships between target areas. This matrix can be obtained based on the distance between each target area or based on the historical passenger flow curve of each target area. Graph convolution is used to capture the spatial similarity between target areas. Target areas that are geographically close or have similar trends (for example, similar historical passenger flow curves) will have similar time-series passenger flow characteristics that are incorporated into the graph convolution. Therefore, during graph convolution, the spatial similarity between target areas can be approximately determined by utilizing the time-series passenger flow characteristics of multiple layers of neighbors of each target area, resulting in graph convolution features that match the time-series passenger flow characteristics.

[0149] Specifically, the server will perform graph convolution on at least two time series passenger flow features based on the adjacency matrix that matches the target area. By utilizing the time series passenger flow features of the multi-layer neighbors of each target area, the spatial similarity between target areas will be determined, and graph convolution features matching each time series passenger flow feature will be obtained.

[0150] Step 514: Extract features from the geographic feature information that matches the target area to obtain the spatial features of the target area.

[0151] Specifically, the server standardizes the geographic feature information that matches the target area, and then extracts features from the standardized geographic feature information by convolution to obtain the spatial features of the target area.

[0152] Step 516: Determine the time slice features corresponding to the current time slice.

[0153] Specifically, the server can perform feature encoding on the current time slice based on its position within a week to obtain the time slice feature corresponding to the current time slice. This time slice feature can accurately represent the time characteristics of the current time slice.

[0154] Step 518: Convolve the time slice features to obtain the time series weights.

[0155] Specifically, after obtaining the time-slice features, since different time slices correspond to different time periods, and the importance of time subsequences varies across different time periods, the server can obtain the corresponding time series weights by convolving the time-slice features to determine the importance of each time subsequence corresponding to the current time slice.

[0156] Step 520: Based on the time series weights, perform a weighted summation of the graph convolutional features that match each time series passenger flow feature in the graph convolutional features to obtain the spatial passenger flow features.

[0157] Specifically, the server performs a weighted summation of the graph convolutional features that match each time-series passenger flow feature in the graph convolutional features based on time-series weights. This allows it to obtain the corresponding spatial passenger flow features while fully considering the temporal features of the current time slice.

[0158] Step 522: Combine the spatial passenger flow characteristics and the target area spatial characteristics to obtain the passenger flow characteristics to be predicted.

[0159] Specifically, after obtaining the spatial passenger flow characteristics, in order to obtain richer passenger flow characteristics for prediction, the server will splice the spatial passenger flow characteristics and the target area spatial characteristics. Taking full account of the geographical features around the target area, the server combines the target area spatial features and spatial passenger flow characteristics obtained based on the geographical features to obtain the passenger flow characteristics to be predicted.

[0160] Step 524: Convolve the features of the passenger flow to be predicted to obtain the passenger flow prediction results for each target area.

[0161] Specifically, by convolving the features of the passenger flow to be predicted, passenger flow prediction can be achieved, and the passenger flow prediction results for each target area can be obtained.

[0162] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0163] Based on the same inventive concept, this application also provides a target region prediction apparatus for implementing the target region prediction method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more target region prediction apparatus embodiments provided below can be found in the limitations of the target region prediction method described above, and will not be repeated here.

[0164] In one embodiment, such as Figure 6 As shown, a target region prediction device is provided, including: a feature acquisition module 602, a graph convolution module 604, a processing module 606, and a prediction module 608, wherein:

[0165] The feature acquisition module 602 is used to obtain the time series passenger flow features matching the target area based on the historical passenger flow data of each target area. The historical passenger flow data includes the passenger flow data of the target area in each historical time slice.

[0166] Graph convolution module 604 is used to perform graph convolution on time series passenger flow features to obtain graph convolution features that match the time series passenger flow features.

[0167] The processing module 606 is used to extract features from the geographic feature information that matches the acquired target area to obtain the spatial features of the target area.

[0168] The prediction module 608 is used to predict passenger flow based on the current time slice, graph convolution features, and spatial features of the target area, and obtain the passenger flow prediction result for each target area.

[0169] The aforementioned target area prediction device first obtains the time-series passenger flow characteristics matching the target area based on the historical passenger flow data of each target area. Then, it applies a graph convolutional neural network to passenger flow prediction. By performing graph convolution on the time-series passenger flow characteristics, it can obtain graph convolutional features that match the time-series passenger flow characteristics. By extracting features from the geographical feature information matching the target area, it can obtain the spatial features of the target area. Furthermore, by combining rich features such as the current time slice, graph convolutional features, and target area spatial features, it can predict passenger flow and obtain the passenger flow prediction results for each target area. The entire process, by applying a graph convolutional neural network to passenger flow prediction and utilizing rich features for passenger flow prediction, can improve prediction performance and achieve accurate prediction.

[0170] In one embodiment, the time series passenger flow features include at least two time sub-series passenger flow features, each time sub-series passenger flow feature corresponds to the same length of time slice, and the time difference between the time slices corresponding to each time sub-series passenger flow feature meets a preset period. The graph convolution module is also used to perform graph convolution on at least two time sub-series passenger flow features based on the adjacency matrix that matches the target region, to obtain the graph convolution feature that matches each time sub-series passenger flow feature.

[0171] In one embodiment, the graph convolution module is also used to obtain the region distance between any two target regions, and to obtain the adjacency matrix that matches the target regions based on the region distance.

[0172] In one embodiment, the graph convolution module is also used to obtain the historical passenger flow curve that matches each target area based on the historical passenger flow data of each target area, and to obtain the adjacency matrix that matches the target area based on the historical passenger flow curve.

[0173] In one embodiment, the prediction module is further configured to determine the time slice features corresponding to the current time slice, obtain spatial passenger flow features based on the time slice features and graph convolution features, splice the spatial passenger flow features and target area spatial features to obtain passenger flow features to be predicted, and perform convolution on the passenger flow features to be predicted to obtain passenger flow prediction results for each target area.

[0174] In one embodiment, the prediction module is further configured to convolve the time slice features to obtain time series weights, and based on the time series weights, to perform a weighted summation of the graph convolution features that match each time subsequence passenger flow feature in the graph convolution features to obtain spatial passenger flow features.

[0175] In one embodiment, the feature acquisition module is further configured to determine the corresponding residential and work area information of each target device based on the acquired location trajectory data matching each target device, and to calculate the historical passenger flow data of each target area based on the location trajectory data, the residential and work area information, and the acquired spatial basic information of each target area.

[0176] In one embodiment, the feature acquisition module is further used to perform spatial query analysis on spatial positioning points in the positioning trajectory data based on work-residence area information and spatial basic information. When it is determined that there is a target spatial positioning point in the target area to be counted and the work-residence area corresponding to the work-residence area information that matches the target spatial positioning point is not in the target area to be counted, the target device status of the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted, and the historical passenger flow data of each target area is counted according to the target device status of each positioning timestamp.

[0177] Each module in the aforementioned target area prediction device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0178] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 7 As shown, this computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operating system and computer programs stored in the non-volatile storage media. The database stores data such as historical passenger flow data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communication with external terminals via a network connection. When executed by the processor, the computer program implements a target area prediction method.

[0179] Those skilled in the art will understand that Figure 7 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0180] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.

[0181] In one embodiment, a computer-readable storage medium is provided storing a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0182] In one embodiment, a computer program product or computer program is provided, the computer program product or computer program including computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and executes the computer instructions, causing the computer device to perform the steps in the above method embodiments.

[0183] It should be noted that the information (including but not limited to geographic feature information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0184] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0185] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0186] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A target area prediction method, characterized in that, The method includes: Based on the historical passenger flow data of each target area, the time series passenger flow characteristics matching the target area are obtained. The historical passenger flow data includes the passenger flow data of the target area in each historical time segment. Graph convolution is performed on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features; Feature extraction is performed on the geographic feature information that matches the acquired target area to obtain the spatial features of the target area; Determine the time slice characteristics corresponding to the current time slice; Convolution is performed on the time slice features to obtain the time series weights; Based on the weight of each time subsequence in the time series weights, the graph convolution features that match the passenger flow features of each time subsequence in the graph convolution features are weighted and summed to obtain the spatial passenger flow features. By combining the spatial passenger flow characteristics and the target area spatial characteristics, the passenger flow characteristics to be predicted are obtained. The passenger flow features to be predicted are convolved to obtain the passenger flow prediction results for each target area.

2. The method according to claim 1, characterized in that, The time series passenger flow feature includes at least two time sub-series passenger flow features, the time slices corresponding to each time sub-series passenger flow feature have the same length, and the time difference between the time slices corresponding to each time sub-series passenger flow feature satisfies a preset period. The step of performing graph convolution on the time-series passenger flow features to obtain graph convolution features matching the time-series passenger flow features includes: Based on the adjacency matrix matching the target region, graph convolution is performed on the at least two time series passenger flow features respectively to obtain the graph convolution features matching each time series passenger flow feature.

3. The method according to claim 2, characterized in that, Before performing graph convolution on the at least two time-series passenger flow features based on the obtained adjacency matrix matching the target region to obtain the graph convolution features matching each time-series passenger flow feature, the method further includes: Get the distance between any two target regions; Based on the regional distance, an adjacency matrix matching the target region is obtained.

4. The method according to claim 2, characterized in that, Before performing graph convolution on at least two time-series passenger flow features based on the obtained adjacency matrix matching the target region to obtain the graph convolution features matching each time-series passenger flow feature, the method further includes: Based on the historical passenger flow data of each target area, a matching historical passenger flow curve is obtained for each target area. Based on the historical passenger flow curve, an adjacency matrix matching the target area is obtained.

5. The method according to claim 1, characterized in that, Before obtaining the time-series passenger flow characteristics matching the target area based on the acquired historical passenger flow data for each target area, the process also includes: Based on the acquired location trajectory data matching each target device, the work and residence area information matching each target device is determined; Based on the location trajectory data, the work-residence area information, and the spatial basic information of each target area, historical passenger flow data for each target area is statistically analyzed.

6. The method according to claim 5, characterized in that, The step of calculating historical passenger flow data for each target area based on the positioning trajectory data, the work-residence area information, and the obtained spatial basic information of each target area includes: Based on the work-residence area information and the spatial basic information, spatial query analysis is performed on the spatial positioning points in the positioning trajectory data; When it is determined that there is a target spatial positioning point in the target area to be counted and the work-residence area information corresponding to the target spatial positioning point is not in the target area to be counted, the target device status of the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted. Based on the target device status of each location timestamp, historical passenger flow data for each target area is statistically analyzed.

7. A target area prediction device, characterized in that, The device includes: The feature acquisition module is used to obtain the time series passenger flow features matching the target area based on the historical passenger flow data of each target area. The historical passenger flow data includes the passenger flow data of the target area in each historical time slice. The graph convolution module is used to perform graph convolution on the time series passenger flow features to obtain graph convolution features that match the time series passenger flow features. The processing module is used to extract features from the geographic feature information that matches the acquired target area to obtain the spatial features of the target area; The prediction module is used to determine the time-slice features corresponding to the current time slice, perform convolution on the time-slice features to obtain time-series weights, and, based on the weights of each time subsequence in the time-series weights, perform weighted summation on the graph convolution features that match the passenger flow features of each time subsequence in the graph convolution features to obtain spatial passenger flow features. The spatial passenger flow features and the target area spatial features are concatenated to obtain the passenger flow features to be predicted. The passenger flow features to be predicted are then convolved to obtain the passenger flow prediction results for each target area.

8. The apparatus according to claim 7, characterized in that, The time series passenger flow features include at least two time sub-series passenger flow features, each time sub-series passenger flow feature corresponds to the same time slice length, and the time difference between the time slices corresponding to each time sub-series passenger flow feature satisfies a preset period. The graph convolution module is also used to perform graph convolution on the at least two time sub-series passenger flow features based on the adjacency matrix that matches the target region, to obtain the graph convolution feature that matches each time sub-series passenger flow feature.

9. The apparatus according to claim 8, characterized in that, The graph convolution module is also used to obtain the regional distance between any two target regions, and to obtain the adjacency matrix that matches the target regions based on the regional distance.

10. The apparatus according to claim 8, characterized in that, The graph convolution module is also used to obtain the historical passenger flow curve that matches each target area based on the historical passenger flow data of each target area, and to obtain the adjacency matrix that matches the target area based on the historical passenger flow curve.

11. The apparatus according to claim 7, characterized in that, The feature acquisition module is also used to determine the work-residence area information that matches each target device based on the acquired location trajectory data, and to count the historical passenger flow data of each target area based on the location trajectory data, the work-residence area information and the acquired spatial basic information of each target area.

12. The apparatus according to claim 11, characterized in that, The feature acquisition module is also used to perform spatial query analysis on the spatial positioning points in the positioning trajectory data based on the work-residence area information and the spatial basic information. When it is determined that there is a target spatial positioning point in the target area to be counted and the work-residence area corresponding to the work-residence area information that matches the target spatial positioning point is not in the target area to be counted, the target device status of the positioning timestamp that matches the target spatial positioning point is changed to the area identifier of the target area to be counted. Based on the target device status of each positioning timestamp, the historical passenger flow data of each target area is counted.

13. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

14. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

15. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Deep learning-based space-time long-short-term urban pedestrian volume prediction method

    CN110414747A

  • Railway passenger station passenger flow volume prediction method and system, electronic equipment and storage medium

    CN111178598A

  • Feature recognition method for different travel activities based on mobile phone positioning data

    CN112215666A

  • Passenger flow prediction method and system and computer readable storage medium

    CN113077090A