Passenger flow prediction model training method and passenger flow prediction method and device

By training deep learning models, using historical passenger flow information to predict passenger flow information in the time period to be predicted, the problem of insufficient passenger flow prediction accuracy in the existing technology is solved, and higher prediction accuracy is achieved.

CN113657934BActive Publication Date: 2025-02-25JINGDONG CITY BEIJING DIGITS TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202110937200.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-08-16
Publication Date
2025-02-25
Estimated Expiration
2041-08-16

AI Technical Summary

Technical Problem

It is difficult for the existing technology to effectively predict the laws and changes of passenger flow, especially during special periods such as holidays, which leads to insufficient prediction accuracy.

Method used

By obtaining historical passenger flow information and real passenger flow information in the time period to be predicted, deep learning models (such as convolutional neural networks and graph convolutional networks) are trained to predict passenger flow. This method uses techniques such as time sliding windows and adjacency matrix to improve the training accuracy and prediction accuracy of the model.

Benefits of technology

The passenger flow information for the time period to be predicted through historical passenger flow information is realized, and the prediction accuracy is improved, especially during special periods such as holidays.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113657934B_ABST
    Figure CN113657934B_ABST
Patent Text Reader

Abstract

The present disclosure provides a training method for a passenger flow prediction model and a passenger flow prediction method and device, and relates to the field of artificial intelligence technology including deep learning. The specific implementation method includes: obtaining training samples corresponding to target locations in a region, wherein the training samples include historical passenger flow information and actual passenger flow information for a time period to be predicted, and the historical passenger flow information and the actual passenger flow information are the input and target output of the passenger flow prediction model, respectively; according to the input and target output in the training samples, the passenger flow prediction model is trained to obtain a trained passenger flow prediction model. The present disclosure can realize the training of a passenger flow prediction model, so that the trained model can predict the passenger flow information for a time period to be predicted through historical passenger flow information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, specifically to the field of artificial intelligence technology including deep learning, and especially to a training method for a passenger flow prediction model and a passenger flow prediction method and device. Background Art

[0002] With the diversification of life, more and more people choose to travel at various times, such as traveling in scenic spots, shopping in commercial areas, etc.

[0003] There may be various locations in a region, such as scenic spots in a scenic area or shops in a commercial area. The passenger flow in these areas often has regularities. For example, the passenger flow during holidays is significantly higher than that during normal times. In related technologies, passenger flow can be predicted based on these regularities. Summary of the invention

[0004] Provided are a training method, device, electronic device and storage medium for a passenger flow prediction model, and a passenger flow prediction method, device, electronic device and storage medium.

[0005] According to the first aspect, a training method for a passenger flow prediction model is provided, comprising: obtaining training samples corresponding to target locations in an area, wherein the training samples include historical passenger flow information and actual passenger flow information for a time period to be predicted, the historical passenger flow information and the actual passenger flow information being the input and target output of the passenger flow prediction model, respectively; training the passenger flow prediction model according to the input and target output in the training samples to obtain a trained passenger flow prediction model.

[0006] According to the second aspect, a method for training a passenger flow prediction model is provided, including: the method adopts the passenger flow prediction model obtained in the first aspect.

[0007] According to the third aspect, a passenger flow prediction device is provided, comprising: an acquisition unit, configured to acquire training samples corresponding to target locations in an area, wherein the training samples include historical passenger flow information and actual passenger flow information for a time period to be predicted, the historical passenger flow information and the actual passenger flow information being input and target output of a passenger flow prediction model, respectively; a training unit, configured to train the passenger flow prediction model according to the input and target output in the training samples to obtain a trained passenger flow prediction model.

[0008] According to a fourth aspect, a passenger flow prediction device is provided, including: the device adopts the passenger flow prediction model obtained in the third aspect.

[0009] According to the fifth aspect, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method of any embodiment of the method of the first aspect or the second aspect.

[0010] According to a fifth aspect, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause a computer to execute a method according to any embodiment of the method of the first aspect or the second aspect.

[0011] According to a sixth aspect, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the method according to any embodiment of the method of the first aspect or the second aspect.

[0012] According to the scheme disclosed in the present invention, a passenger flow prediction model can be trained to enable the trained model to predict the passenger flow information of a time period to be predicted based on historical passenger flow information. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] Other features, objects and advantages of the present disclosure will become more apparent from the detailed description of non-limiting embodiments made with reference to the following drawings:

[0014] Figure 1 is an exemplary system architecture diagram in which some embodiments of the present disclosure may be applied;

[0015] Figure 2 is a flow chart of an embodiment of a method for training a passenger flow prediction model according to the present disclosure;

[0016] Figure 3 is a schematic diagram of an application scenario of the training method of the passenger flow prediction model according to the present disclosure;

[0017] Figure 4 is a flow chart of another embodiment of a method for predicting passenger flow according to the present disclosure;

[0018] Figure 5 is a structural schematic diagram of an embodiment of a training device for a passenger flow prediction model according to the present disclosure;

[0019] Figure 6 It is a block diagram of an electronic device for implementing the training method of the passenger flow prediction model of the embodiment of the present disclosure and a block diagram of an electronic device for the passenger flow prediction method. DETAILED DESCRIPTION

[0020] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0021] In the technical solution disclosed herein, the acquisition, storage and application of user personal information involved all comply with the provisions of relevant laws and regulations, take necessary confidentiality measures, and do not violate public order and good morals.

[0022] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present disclosure may be combined with each other. The present disclosure will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0023] Figure 1 An exemplary system architecture 100 is shown to which an embodiment of the method for training a passenger flow prediction model and predicting passenger flow or the apparatus for training a passenger flow prediction model and predicting passenger flow of the present disclosure can be applied.

[0024] like Figure 1 As shown, the system architecture 100 may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a medium for communication links between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0025] Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, 103, such as video applications, live broadcast applications, instant messaging tools, email clients, social platform software, etc.

[0026] The terminal devices 101, 102, 103 here can be hardware or software. When the terminal devices 101, 102, 103 are hardware, they can be various electronic devices with display screens, including but not limited to smart phones, tablet computers, e-book readers, laptop portable computers and desktop computers, etc. When the terminal devices 101, 102, 103 are software, they can be installed in the electronic devices listed above. It can be implemented as multiple software or software modules (for example, multiple software or software modules for providing distributed services), or it can be implemented as a single software or software module. No specific limitation is made here.

[0027] The server 105 may be a server that provides various services, such as a background server that provides support for the terminal devices 101, 102, and 103. The background server may analyze and process the received training samples and other data, and feed back the processing results (such as the trained passenger flow prediction model) to the terminal device.

[0028] It should be noted that the passenger flow prediction model training method and passenger flow prediction method provided in the embodiments of the present disclosure can be executed by the server 105 or the terminal devices 101, 102, 103. Accordingly, the passenger flow prediction model training device and passenger flow prediction device can be set in the server 105 or the terminal devices 101, 102, 103.

[0029] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

[0030] Continue to refer Figure 2 , shows a process 200 of an embodiment of a method for training a passenger flow prediction model according to the present disclosure. The method for training a passenger flow prediction model comprises the following steps:

[0031] Step 201, obtaining training samples corresponding to target locations in the region, wherein the training samples include historical passenger flow information and actual passenger flow information for the time period to be predicted, and the historical passenger flow information and actual passenger flow information are respectively the input and target output of the passenger flow prediction model.

[0032] In this embodiment, the training method of the passenger flow prediction model runs on the execution subject (for example Figure 1 The server or terminal device shown in the figure can obtain the training samples corresponding to the target location in the area. The training samples include historical passenger flow information and real passenger flow information of the time period to be predicted, wherein the historical passenger flow information can be used as the input of the passenger flow prediction model, and the real passenger flow information of the time period to be predicted can be used as the target output of the passenger flow prediction model, that is, real data. Historical passenger flow feature information refers to the passenger flow related information of a historical time period. The passenger flow information of the time period to be predicted refers to the passenger flow related information of a certain time period, and the above-mentioned certain time period can be a time period that has already occurred or a time period in the future. Passenger flow related information can refer to the passenger flow itself. Alternatively, passenger flow related information can also refer to the information obtained after the passenger flow has been processed by a preset process. For example, the preset process here can refer to processing using a preset model, formula or multiplying by a preset coefficient, etc.

[0033] The training sample corresponding to the target location refers to: the historical passenger flow information and the actual passenger flow information of the time period to be predicted in the training sample are data obtained from the target location, such as the passenger flow of the target location, or data obtained from the target location after preset processing.

[0034] Step 202: Train the passenger flow prediction model according to the input and target output in the training samples to obtain a trained passenger flow prediction model.

[0035] In this embodiment, the execution subject can train the passenger flow prediction model to be trained according to the input and target output in the training sample, so as to obtain the trained passenger flow prediction model. Specifically, the execution subject can input the historical passenger flow information as input into the passenger flow prediction model to be trained for forward propagation, so as to obtain the passenger flow information of the time period to be predicted output by the passenger flow prediction model to be trained, that is, the prediction result. The execution subject can determine the loss value using the prediction result and the target output, and use the loss value for reverse propagation, so as to obtain the trained passenger flow prediction model.

[0036] In practice, the passenger flow prediction model can be various deep learning models, such as convolutional neural networks.

[0037] The method provided by the above-mentioned embodiment of the present disclosure can realize the training of the passenger flow prediction model, so that the trained model can predict the passenger flow information of the time period to be predicted based on the historical passenger flow information.

[0038] Continue to see Figure 3 , Figure 3 FIG. 1 is a schematic diagram of an application scenario of the training method of the passenger flow prediction model according to this embodiment. Figure 3 In the application scenario, the execution subject 301 obtains the training sample 302 corresponding to the target location in the region, wherein the training sample 302 includes the historical passenger flow information and the real passenger flow information of the time period to be predicted, and the historical passenger flow information and the real passenger flow information are the input and target output of the passenger flow prediction model respectively. The execution subject 301 trains the passenger flow prediction model according to the input and target output in the training sample 302 to obtain the trained passenger flow prediction model 303.

[0039] In some optional implementations of any embodiment of the present disclosure, the above-mentioned training of the passenger flow prediction model based on the input and target output in the training samples may include: obtaining a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein the function expression includes parameters to be assigned and parameters to be adjusted; determining the parameter value of the target location based on the distance between the target location and other locations, wherein the parameter value is used to assign values ​​to the parameters to be assigned; and performing training in the passenger flow prediction model according to the parameter value to adjust the parameters to be adjusted in the function expression.

[0040] In these optional implementations, the above function expression may include not only parameters to be adjusted, but also parameters that need to be assigned values ​​in each forward propagation process.

[0041] In practice, the execution entity may determine the parameter value of the target location based on the distance between the target location and other locations other than the target location in various ways. For example, the execution entity may input the distance into a specified model to obtain the parameter value output from the model. The model may predict the parameter value of the target location based on the distance between the target location and other locations.

[0042] In practice, the above distance may refer to the distance between the target location and other locations in the road network, such as the shortest distance, or may refer to the straight-line distance.

[0043] These implementations can accurately determine the parameter values ​​to be assigned to the parameters to be assigned in the function expression according to the distance between the target location and other locations, thereby improving the accuracy of training.

[0044] Optionally, the passenger flow prediction model can be a graph convolutional network, and the adjacency matrix of the graph convolutional network is the parameter to be assigned; the above-mentioned determination of the parameter value of the target location based on the distance between the target location and other locations may include: determining the adjacency matrix value input into the graph convolutional network during forward propagation of training according to the inverse of the distance between the target location and other locations, wherein the inverse is used to indicate the passenger flow correlation between the target location and other locations; and determining the parameter value of the target location according to the adjacency matrix value.

[0045] In these optional implementations, the execution subject may determine the reciprocal of the distance between the other locations and the target location. Furthermore, the execution subject may determine the adjacency matrix value input to the graph convolutional network during forward propagation of training based on the reciprocal. The larger the reciprocal, the greater the passenger flow correlation may be.

[0046] The other location may be any location other than the target location in the above region. In addition, the other location may also be a location adjacent to the target location. For example, the execution subject determines multiple other locations in order from near to far from the target location, and the adjacent location is a location among the multiple other locations.

[0047] The execution subject may determine the adjacency matrix value input to the graph convolutional network during the forward propagation of the training according to the inverse in various ways. For example, the execution subject may directly use the inverse as the adjacency matrix value. Alternatively, the execution subject may perform a specified process on the inverse and use the specified process result as the adjacency matrix value. The specified process may refer to various processes, such as inputting a pre-trained model or formula.

[0048] The execution subject may determine the parameter value of the target location according to the adjacency matrix value in various ways. For example, the execution subject may directly use the adjacency matrix value as the parameter value of the target location. Alternatively, the execution subject may input the adjacency matrix value into a preset model to obtain the parameter value output from the model. The preset model here may predict the parameter value of the target location through the adjacency matrix value corresponding to the target location.

[0049] Optionally, the passenger flow prediction model includes multiple processing layers; obtaining a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model includes: determining the function expression of the mapping relationship between the input and output of a processing layer in multiple processing layers; summarizing the function expressions of each processing layer in the multiple processing layers to obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein there is a residual connection between adjacent processing layers in the multiple processing layers.

[0050] In practice, the distance between the target location i and other locations j can be d i,j In this implementation, the parameters of the processing layer of the graph convolutional network are marked as s, and the adjacency matrix is ​​also the parameter to be assigned A. s (i, j) can be the inverse of the distance, that is, A s (i, j) = 1 / d i,j The input of the lth processing layer in the graph convolutional network That is the output of the l-1th processing layer, which can be specifically expressed as:

[0051]

[0052] Among them, GCN s () refers to the processing function of the processing layer, refers to the input of the l-1th layer, σ is the activation function, is the parameter to be adjusted in the lth layer. Ds=diag(A s +I). s is the Laplacian matrix of the static graph structure, D s is a diagonal matrix, the D s The elements of each row are the sum of the elements in the adjacency matrix, which is D i,i =∑ j A s (i, j).

[0053] Specifically, A s It can be expressed as I can be expressed as D s Expressed as Then D i.i for

[0054] The n here can refer to the nth location (for example, the nth location in a region). The graph convolutional network can include three convolutional layers. The final output of the three convolutional layers is also the final output of the graph convolutional network, which can be:

[0055]

[0056] in, Refers to the final output of the model. Refers to the input of the first convolutional layer.

[0057] In addition, if the connection between adjacent processing layers is a residual connection, then the above It can be expressed as:

[0058]

[0059] Accordingly, It can be expressed as:

[0060]

[0061] Output of the passenger flow prediction model It can be expressed as

[0062] These implementation methods can improve the correlation between the passenger flow of each scenic spot during the training process, and further improve the accuracy of training.

[0063] In some optional implementations of any embodiment of the present disclosure, the historical passenger flow information includes at least one of the following information features: a proximity feature and a periodic feature, and the information feature is obtained from the historical passenger flow data using a time sliding window.

[0064] In these optional implementations, historical passenger flow information is the input of the passenger flow prediction model during training and prediction, that is, the input of the first layer (first processing layer) of the passenger flow prediction model. Proximity features refer to features that are adjacent in time, such as at least two adjacent features. For example, taking 5 minutes as the sampling time period, we want to predict the passenger flow information from 8:16 to 8:20 (the time period to be predicted) on a certain day. The proximity feature can refer to the passenger flow information of the target location in the three time periods of 8:00-8:05, 8:06-8:10, and 8:11-8:15 in the morning of that day. Accordingly, the sliding step size of the time sliding window can be the above-mentioned sampling length, that is, 5 minutes. The above-mentioned execution body starts sliding from 8 o'clock to obtain the above-mentioned three time periods respectively.

[0065] The periodic feature refers to the process of obtaining the time period to be predicted after a preset period has passed from the historical time period, so as to predict the passenger flow information of the time period to be predicted. For example, the passenger flow information of the following two historical time periods is determined: 8:00-8:05 am on a certain day, and 8:00-8:05 am on the day after this day. The passenger flow information of these two historical time periods is used to predict the passenger flow information of 8:00-8:05 am on the third or fourth day. Accordingly, the sliding step size of the time sliding window can also be 5 minutes, and the time interval for obtaining the time window can be one day.

[0066] The trend feature may refer to obtaining the time period to be predicted after a relatively long period (the period is longer than the preset period corresponding to the above periodic feature) to predict the passenger flow information of the time period to be predicted. For example, determine the passenger flow information of the following three historical time periods: 9:05 am on Monday of the first week of a month, 9:00-9:05 am on Monday of the second week of this month, and 9:00-9:05 am on Monday of the third week of this month. Use the passenger flow information of these three historical time periods to predict the passenger flow information of 9:00-9:05 am on Monday of the fourth week (or fifth week). Correspondingly, the sliding step size of the time sliding window can also be 5 minutes, and the time interval for obtaining the time window can be one week or one month.

[0067] Further references Figure 4 , which shows a process 400 of another embodiment of a method for training a passenger flow prediction model. The process 400 includes the following steps:

[0068] Step 401, obtaining training samples corresponding to target locations in the region, wherein the training samples include historical passenger flow information and actual passenger flow information of the time period to be predicted, and the historical passenger flow information and actual passenger flow information are respectively the input and target output of the passenger flow prediction model.

[0069] Step 402, obtain a function expression indicating a mapping relationship between an input and an output of a passenger flow prediction model, wherein the function expression includes parameters to be adjusted, the parameters to be adjusted include a head entity of a first location and a tail entity of a second location, the target location is the first location or the second location, and in the function expression, the first location and the second location are used to indicate the possibility of passenger flow transferring from the first location to the second location.

[0070] In this embodiment, the training method of the passenger flow prediction model runs on the execution subject (for example Figure 1 The server or terminal device shown in the figure can obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model. The function expression includes the parameters to be adjusted, that is, the weights that need to be optimized through training. Specifically, the above-mentioned execution subject learns the head entity value and the tail entity value through training. In this way, during the training process, the model can learn the possibility of passenger flow transfer between locations.

[0071] The parameter to be adjusted may include a head entity of the first location, or a tail entity of the second location. The target location may be the first location, or the target location may be the second location.

[0072] In practice, a head entity value and a tail entity value can be obtained for each location. The execution subject or other electronic device can use various models to generate head entity values ​​and tail entity values ​​for the location, such as an embedding layer (embedding), that is, an embedding network, or other deep neural networks. Specifically, the execution subject or other electronic device can input the ID of the location into the model to obtain the head entity value and tail entity value output from the model.

[0073] Step 403, performing back propagation in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression to obtain a trained passenger flow prediction model.

[0074] In this embodiment, the above-mentioned execution subject can adjust the parameters to be adjusted through back propagation, and then obtain the trained passenger flow prediction model.

[0075] This embodiment can learn the passenger flow attraction relationship between locations through training, so that when using the model for prediction, the passenger flow correlation between locations can be referred to to improve the accuracy of the prediction.

[0076] Optionally, the passenger flow prediction model is a graph convolutional network, and the function expression of the graph convolutional network includes an adjacency matrix, the adjacency matrix is ​​the multiplication result of the head entity and the tail entity, and the adjacency matrix indicates the possibility.

[0077] In these optional implementations, the passenger flow prediction model may be a graph convolutional network (GCN). In the case where the passenger flow prediction model is a graph convolutional network, the function expression indicating the mapping relationship between the input and output of the passenger flow prediction model may include an adjacency matrix.

[0078] The adjacency matrix may be the product of the head entity and the tail entity, and the product indicates the possibility of the passenger flow transferring from the first location to the second location.

[0079] Optionally, the passenger flow prediction model includes multiple processing layers; obtaining a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model includes: determining the function expression of the mapping relationship between the input and output of a processing layer in multiple processing layers; summarizing the function expressions of each processing layer in the multiple processing layers to obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein there is a residual connection between adjacent processing layers in the multiple processing layers.

[0080] Specifically, the head entity of the first location i can be represented as E s , the tail entity of the second location j can be represented as E e , where s represents the head entity and e represents the tail entity. For the relevant parameters of the processing layer in this implementation, all are marked as d. The probability value indicating the possibility of the passenger flow transferring from the first location i to the second location j is the multiplication result of the head entity and the tail entity. Specifically, it can be expressed as The adjacency matrix (also known as the adaptive matrix) in the function expression can be expressed as the above multiplication result Input of the lth processing layer in the graph convolutional network That is the output of the l-1th processing layer, which can be specifically expressed as:

[0081]

[0082] Among them, GCN d () refers to the processing function of the processing layer, refers to the input of the l-1th layer, σ is the activation function, is the parameter to be adjusted in the lth layer. Dd=diag(A d +I). d is the Laplacian matrix of the static graph structure, D d is a diagonal matrix, the D d The elements of each row are the sum of the elements in the adjacency matrix, which is D i,i =∑ j A d (i, j).

[0083] Specifically, A d It can be expressed as I can be expressed as D d Expressed as Then D i,i for

[0084] The n here can refer to the nth location (for example, the nth location in a region). The graph convolutional network can include three convolutional layers. The final output of the three convolutional layers is also the final output of the graph convolutional network, which can be:

[0085]

[0086] in, refers to the final output of the model, Refers to the input of the first convolutional layer.

[0087] In addition, if the connection between adjacent processing layers is a residual connection, then the above It can be expressed as:

[0088]

[0089] Accordingly, It can be expressed as:

[0090]

[0091] Output of the passenger flow prediction model It can be expressed as

[0092] These implementation methods can reflect the passenger flow attraction between locations through the adjacency matrix and realize the accurate training process of the model.

[0093] In some optional implementations of any embodiment of the present disclosure, the above-mentioned training of the passenger flow prediction model based on the input and target output in the training samples may include: obtaining a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein the function expression includes parameters to be adjusted, the parameters to be adjusted include a head entity of the first place and a tail entity of the second place, the target place is the first place or the second place, and in the function expression, the first place and the second place are used to indicate the possibility of passenger flow transferring from the first place to the second place; performing back propagation in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression.

[0094] In addition, the passenger flow prediction model is a graph convolutional network, and the adjacency matrix is ​​the parameter to be assigned; the above-mentioned training of the passenger flow prediction model according to the input and target output in the training sample can also include: obtaining a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein the function expression includes the parameter to be assigned and the parameter to be adjusted; determining the parameter value of the target location based on the distance between the target location and other locations, wherein the parameter value is used to assign the parameter to be assigned; and training is performed in the passenger flow prediction model according to the parameter value to adjust the parameter to be adjusted in the function expression.

[0095] Specifically, the output of the passenger flow prediction model is It can be expressed as

[0096] The present disclosure also provides a method for predicting passenger flow, wherein the method adopts a passenger flow prediction model obtained in any one of the above embodiments.

[0097] This embodiment may use a passenger flow prediction model to predict passenger flow information of a target location or other locations (eg, locations whose distance from the target location does not exceed a preset distance threshold).

[0098] Further references Figure 5 As an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of training a passenger flow prediction model. Figure 2 Corresponding to the method embodiment shown in FIG. 1 , in addition to the features described below, the device embodiment may also include Figure 2 The device can be applied to various electronic devices.

[0099] like Figure 5 As shown, the training device 500 of the passenger flow prediction model of this embodiment includes: an acquisition unit 501 and a training unit 502. The acquisition unit 501 is configured to acquire training samples corresponding to target locations in a region, wherein the training samples include historical passenger flow information and real passenger flow information of a time period to be predicted, and the historical passenger flow information and the real passenger flow information are input and target output of the passenger flow prediction model respectively; the training unit 502 is configured to train the passenger flow prediction model according to the input and target output in the training samples to obtain a trained passenger flow prediction model.

[0100] In this embodiment, the specific processing of the acquisition unit 501 and the training unit 502 of the passenger flow prediction model training device 500 and the technical effects thereof can be referred to respectively. Figure 2 The relevant descriptions of step 201 and step 202 in the corresponding embodiment are not repeated here.

[0101] In some optional implementations of this embodiment, the training unit is further configured to perform training on the passenger flow prediction model according to the input and target output in the training sample in the following manner: obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein the function expression includes parameters to be adjusted, the parameters to be adjusted include a head entity of the first place and a tail entity of the second place, the target place is the first place or the second place, and in the function expression, the first place and the second place are used to indicate the possibility of passenger flow transferring from the first place to the second place; perform back propagation in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression.

[0102] In some optional implementations of this embodiment, the passenger flow prediction model is a graph convolutional network, and the function expression of the graph convolutional network includes an adjacency matrix, which is the multiplication result of the head entity and the tail entity, and the adjacency matrix indicates the possibility.

[0103] In some optional implementations of this embodiment, the training unit is further configured to perform training on the passenger flow prediction model according to the input and target output in the training sample in the following manner: obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein the function expression includes parameters to be assigned and parameters to be adjusted; determine the parameter value of the target location based on the distance between the target location and other locations, wherein the parameter value is used to assign values ​​to the parameters to be assigned; and perform training in the passenger flow prediction model according to the parameter value to adjust the parameters to be adjusted in the function expression.

[0104] In some optional implementations of this embodiment, the passenger flow prediction model is a graph convolutional network, and the adjacency matrix of the graph convolutional network is a parameter to be assigned; the training unit is further configured to execute in the following manner: according to the inverse of the distance between the target location and other locations, determine the adjacency matrix value input into the graph convolutional network during the forward propagation of training, wherein the inverse is used to indicate the passenger flow correlation between the target location and other locations; and determine the parameter value of the target location based on the adjacency matrix value.

[0105] In some optional implementations of this embodiment, the passenger flow prediction model includes multiple processing layers; the training unit is further configured to execute the following method to obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model: determine the function expression of the mapping relationship between the input and output of a processing layer in multiple processing layers; summarize the function expressions of each processing layer in the multiple processing layers to obtain a function expression indicating the mapping relationship between the input and output of the passenger flow prediction model, wherein there is a residual connection between adjacent processing layers in the multiple processing layers.

[0106] In some optional implementations of this embodiment, the historical passenger flow information includes at least one of the following information features: a proximity feature and a periodic feature, and the information feature is obtained from the historical passenger flow data using a time sliding window.

[0107] The present disclosure also provides a passenger flow prediction device, which adopts a passenger flow prediction model obtained by any embodiment of the passenger flow prediction model training method.

[0108] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium and a computer program product.

[0109] like Figure 6 , is a block diagram of an electronic device for a training method of a passenger flow prediction model according to an embodiment of the present disclosure and a block diagram of an electronic device for a passenger flow prediction method. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.

[0110] like Figure 6 As shown, the electronic device includes: one or more processors 601, a memory 602, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. The various components are interconnected using different buses and can be installed on a common mainboard or installed in other ways as needed. The processor can process instructions executed in the electronic device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In other embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple electronic devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 6 A processor 601 is taken as an example.

[0111] The memory 602 is a non-transitory computer-readable storage medium provided by the present disclosure. The memory stores instructions executable by at least one processor to enable at least one processor to execute the training method of the passenger flow prediction model and the passenger flow prediction method provided by the present disclosure. The non-transitory computer-readable storage medium of the present disclosure stores computer instructions, which are used to enable a computer to execute the training method of the passenger flow prediction model and the passenger flow prediction method provided by the present disclosure.

[0112] The memory 602 is a non-transient computer-readable storage medium that can be used to store non-transient software programs, non-transient computer executable programs and modules, such as the training method of the passenger flow prediction model or the passenger flow prediction method in the embodiment of the present disclosure. The program instructions / modules (for example, the attached Figure 5 The processor 601 executes various functional applications and data processing of the server by running the non-transient software programs, instructions and modules stored in the memory 602, that is, the training method of the passenger flow prediction model or the passenger flow prediction method in the above method embodiment is implemented.

[0113] The memory 602 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and application programs required for at least one function; the data storage area may store data created based on the use of the training electronic device of the passenger flow prediction model or the passenger flow prediction electronic device, etc. In addition, the memory 602 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory 602 may optionally include a memory remotely arranged relative to the processor 601, and these remote memories may be connected to the training electronic device of the passenger flow prediction model or the passenger flow prediction electronic device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0114] The electronic device of the passenger flow prediction model training method or passenger flow prediction method may further include: an input device 603 and an output device 604. The processor 601, the memory 602, the input device 603 and the output device 604 may be connected via a bus or other means. Figure 6 The example of connecting through bus is taken in the following.

[0115] The input device 603 can receive input digital or character information, and generate key signal input related to user settings and function control of the electronic device for training the passenger flow prediction model or the electronic device for predicting passenger flow, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator bar, one or more mouse buttons, a trackball, a joystick, and other input devices. The output device 604 may include a display device, an auxiliary lighting device (e.g., an LED), and a tactile feedback device (e.g., a vibration motor), etc. The display device may include, but is not limited to, a liquid crystal display (LCD), a light emitting diode (LED) display, and a plasma display. In some embodiments, the display device may be a touch screen.

[0116] Various implementations of the systems and techniques described herein can be realized in digital electronic circuit systems, integrated circuit systems, dedicated ASICs (application specific integrated circuits), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0117] These computer programs (also referred to as programs, software, software applications, or code) include machine instructions for programmable processors and can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, device, and / or means (e.g., disk, optical disk, memory, programmable logic device (PLD)) for providing machine instructions and / or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal for providing machine instructions and / or data to a programmable processor.

[0118] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0119] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0120] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship between the client and the server is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services ("Virtual Private Server", or "VPS" for short). The server may also be a server of a distributed system, or a server combined with a blockchain.

[0121] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0122] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The units described may also be set in a processor, for example, it may be described as: a processor includes an acquisition unit and a training unit. The names of these units do not constitute a limitation on the units themselves in some cases, for example, the acquisition unit may also be described as a "unit for acquiring training samples corresponding to target locations in an area".

[0123] As another aspect, the present disclosure further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by the device, the device: obtains training samples corresponding to target locations in the region, wherein the training samples include historical passenger flow information and real passenger flow information for the time period to be predicted, and the historical passenger flow information and the real passenger flow information are respectively the input and target output of the passenger flow prediction model; trains the passenger flow prediction model according to the input and target output in the training samples to obtain the trained passenger flow prediction model.

[0124] As another aspect, the present disclosure further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by the device, the device: adopts the passenger flow prediction model obtained in the training method of the above passenger flow prediction model.

[0125] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the present disclosure is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above invention concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other.

Claims

1. A method for training a passenger flow prediction model, the method comprising: Acquire training samples corresponding to the target location in the region, wherein the training samples include historical passenger flow information and real passenger flow information of the time period to be predicted, and the historical passenger flow information and the real passenger flow information are respectively the input and target output of the passenger flow prediction model; Training the passenger flow prediction model according to the input and target output in the training samples to obtain a trained passenger flow prediction model; Among them, the output of the passenger flow prediction model is , and training the passenger flow prediction model according to the input and target output in the training sample, including: Get the input and output of the passenger flow prediction model A function expression of a mapping relationship between the first and second locations, wherein the function expression includes parameters to be adjusted and an adjacency matrix, the parameters to be adjusted include a head entity of a first location and a tail entity of a second location, the ID of the location is input into the model, and a head entity value and a tail entity value output from the model are obtained, the target location is the first location or the second location, in the function expression, the first location and the second location are used to indicate the possibility of passenger flow transferring from the first location to the second location, the adjacency matrix is ​​the multiplication result of the head entity and the tail entity, and the adjacency matrix indicates the possibility; back propagation is performed in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression; Get the input and output of the passenger flow prediction model A function expression of a mapping relationship between the two, wherein the function expression includes parameters to be assigned and parameters to be adjusted; Determine a parameter value of the target location based on the distance between the target location and other locations, wherein the parameter value is used to assign a value to the parameter to be assigned; According to the parameter value, training is performed in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression.

2. The method according to claim 1, wherein: The passenger flow prediction model is a graph convolutional network; The determining of the parameter value of the target location based on the distance between the target location and other locations includes: Determining, according to the reciprocal of the distance between the target location and the other locations, an adjacency matrix value input into the graph convolution network during the forward propagation of the training, wherein the reciprocal is used to indicate the passenger flow correlation between the target location and the other locations, and the adjacency matrix is ​​the parameter to be assigned; According to the adjacency matrix value, the parameter value of the target location is determined.

3. The method according to any one of claims 1-2, wherein: The passenger flow prediction model includes multiple processing layers; The obtaining of a function expression indicating a mapping relationship between an input and an output of the passenger flow prediction model comprises: Determine a function expression of a mapping relationship between an input and an output of a processing layer in the plurality of processing layers; The function expressions of each processing layer in the multiple processing layers are summarized to obtain a function expression indicating a mapping relationship between an input and an output of the passenger flow prediction model, wherein a residual connection exists between adjacent processing layers in the multiple processing layers.

4. The method according to claim 1, wherein: The historical passenger flow information includes at least one of the following information features: proximity feature and periodic feature, and the information feature is obtained from the historical passenger flow data using a time sliding window.

5. A method for predicting passenger flow, wherein: The method adopts the passenger flow prediction model obtained in any one of claims 1-4.

6. A training device for a passenger flow prediction model, the device comprising: An acquisition unit is configured to acquire training samples corresponding to a target location in a region, wherein the training samples include historical passenger flow information and real passenger flow information of a time period to be predicted, and the historical passenger flow information and the real passenger flow information are input and target output of a passenger flow prediction model, respectively; A training unit is configured to train the passenger flow prediction model according to the input and target output in the training sample to obtain a trained passenger flow prediction model; Among them, the output of the passenger flow prediction model is , and the training unit is further configured to perform the training of the passenger flow prediction model according to the input and target output in the training samples in the following manner: Get the input and output of the passenger flow prediction model A function expression of a mapping relationship between, wherein the function expression includes parameters to be adjusted and an adjacency matrix, the parameters to be adjusted include a head entity of a first location and a tail entity of a second location, the ID of the location is input into the model, and a head entity value and a tail entity value output from the model are obtained, the target location is the first location or the second location, in the function expression, the first location and the second location are used to indicate the possibility of passenger flow transferring from the first location to the second location, the adjacency matrix is ​​the multiplication result of the head entity and the tail entity, and the adjacency matrix indicates the possibility; back propagation is performed in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression; Get the input and output of the passenger flow prediction model A function expression of a mapping relationship between the two, wherein the function expression includes parameters to be assigned and parameters to be adjusted; Determine a parameter value of the target location based on the distance between the target location and other locations, wherein the parameter value is used to assign a value to the parameter to be assigned; According to the parameter value, training is performed in the passenger flow prediction model to adjust the parameters to be adjusted in the function expression.

7. A passenger flow prediction device, wherein: The device adopts the passenger flow prediction model obtained in claim 6.

8. An electronic device comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 5.

9. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-5.

Citation Information

Patent Citations

  • Short-term subway passenger flow prediction method and system and electronic device

    CN110866649A

  • Urban traffic pattern mining method based on data fusion and knowledge graph embedding

    CN111932026A

  • Urban area passenger flow volume prediction method based on mobile phone signaling data

    CN112200351A