Time prediction model training method, time prediction method and device

By a method of obtaining route feature sets and combining road segment features and actual arrival time, a variational autoencoder is used to perform vector fitting, which solves the problem of insufficient accuracy of estimated arrival time in the prior art, and achieves higher accuracy prediction.

CN116957014BActive Publication Date: 2025-08-05TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210375350.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-11
Publication Date
2025-08-05
Estimated Expiration
2042-04-11

AI Technical Summary

Technical Problem

The existing predicted arrival time algorithms rely on manual experience or only use overall features, resulting in insufficient prediction accuracy, especially when road segment characteristics change.

Method used

By obtaining the route feature set of route samples, the first route feature vector is extracted and dimensional conversion is performed, time prediction is performed based on the road segment feature information and actual arrival time, vector fit is used by a variational autoencoder, and the time prediction model parameters are corrected.

Benefits of technology

It improves the prediction accuracy of the estimated arrival time, enhances the accuracy of the time prediction model and the acquisition accuracy of the route feature vector.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116957014B_ABST
    Figure CN116957014B_ABST
Patent Text Reader

Abstract

The present invention discloses a time prediction model training method, a time prediction method and a device. After extracting the first route feature vector of a route feature set, the first route feature vector is dimensionally converted to obtain a second route feature vector. Time prediction is performed based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and the second route feature vector is vector-fitted to obtain a route reconstruction feature vector. Then, a time prediction loss value is obtained based on the estimated arrival time and the actual arrival time, and a reconstruction loss value is obtained based on the route reconstruction feature vector and all road section feature information. Then, the parameters of the time prediction model are corrected based on the time prediction loss value and the reconstruction loss value. The embodiment of the present invention can improve the prediction accuracy of the estimated arrival time. The present invention can be widely used in information processing technologies in various scenarios such as cloud technology, artificial intelligence, smart transportation, and assisted driving.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information processing technology, and in particular to a time prediction model training method, a time prediction method and a device. Background Art

[0002] Currently, the most commonly used algorithms for Estimated Time of Arrival (ETA) include rule-based segment-by-segment accumulation, tree-based machine learning, and deep model-based machine learning. The rule-based segment-by-segment accumulation method primarily relies on rules set by human experience, but these rules often have poor coverage and result in low ETA prediction accuracy. Both tree-based and deep model-based machine learning methods utilize only the actual time of arrival (ATA) of the entire route as supervisory information, which can also lead to inaccurate ETA predictions. Summary of the Invention

[0003] The following is a summary of the subject matter described in detail herein. This summary is not intended to limit the scope of the claims.

[0004] The embodiments of the present invention provide a time prediction model training method, a time prediction method and a device, which can improve the prediction accuracy of the estimated arrival time.

[0005] In one aspect, an embodiment of the present invention provides a time prediction model training method, comprising the following steps:

[0006] Obtaining a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes an actual arrival time of the route sample and road segment feature information upon arrival at each of the road segment samples;

[0007] extracting a first route feature vector from the route feature set using a time prediction model, performing dimension conversion on the first route feature vector to obtain a second route feature vector, performing time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and obtaining a time prediction loss value based on the estimated arrival time and the actual arrival time;

[0008] Performing vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtaining a reconstruction loss value based on the route reconstruction feature vector and all the road segment feature information;

[0009] The parameters of the time prediction model are modified according to the time prediction loss value and the reconstruction loss value.

[0010] On the other hand, an embodiment of the present invention further provides a time prediction method, comprising the following steps:

[0011] Obtain route characteristics of the route to be estimated;

[0012] Inputting the route characteristics into a time prediction model to obtain an estimated arrival time;

[0013] The time prediction model is trained by the time prediction model training method as described above.

[0014] On the other hand, an embodiment of the present invention further provides a time prediction model training device, comprising:

[0015] A sample acquisition unit, configured to acquire a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes the actual arrival time of the route sample and the road segment feature information upon arrival at each of the road segment samples;

[0016] a first loss value calculation unit, configured to extract a first route feature vector from the route feature set using a time prediction model, perform dimension conversion on the first route feature vector to obtain a second route feature vector, perform time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and obtain a time prediction loss value based on the estimated arrival time and the actual arrival time;

[0017] a second loss value calculation unit, configured to perform vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtain a reconstruction loss value based on the route reconstruction feature vector and all the road segment feature information;

[0018] A parameter correction unit is used to correct the parameters of the time prediction model according to the time prediction loss value and the reconstruction loss value.

[0019] Optionally, the second route feature vector includes the first route feature latent variable and the route feature variance; and the parameter correction unit is further configured to:

[0020] Obtaining a normal distribution loss value according to the first route characteristic latent variable and the route characteristic variance;

[0021] The parameters of the time prediction model are modified according to the normal distribution loss value, the time prediction loss value and the reconstruction loss value.

[0022] Optionally, the first loss value calculation unit is further configured to:

[0023] Acquire first deviation information between the estimated arrival time and the actual arrival time;

[0024] A time prediction loss value is calculated based on the first deviation information.

[0025] Optionally, the route reconstruction feature vector includes a road segment reconstruction feature vector of each road segment sample; and the second loss value calculation unit is further configured to:

[0026] Acquire second deviation information between the road section reconstruction feature vector and the road section feature information;

[0027] A reconstruction loss value is calculated based on the second deviation information.

[0028] Optionally, the time prediction model includes a feature vector generation network; and the first loss value calculation unit is further used to:

[0029] Converting the route feature set into a route feature matrix;

[0030] The route feature matrix is vectorized by the feature vector generation network to obtain a first route feature vector of the route feature set.

[0031] Optionally, the time prediction model includes a variational autoencoder, and the variational autoencoder includes an encoder; the first loss value calculation unit is further used to:

[0032] Performing dimension conversion on the first route feature vector by the encoder in the variational autoencoder to obtain a second route feature vector, wherein the number of dimensions of the second route feature vector is smaller than the number of dimensions of the first route feature vector.

[0033] Optionally, the time prediction model includes a variational autoencoder, and the variational autoencoder includes a decoder; and the second loss value calculation unit is further used to:

[0034] Performing vector fitting on the second route feature vector through the decoder in the variational autoencoder to obtain a route reconstruction feature vector, wherein the number of dimensions of the route reconstruction feature vector is equal to the number of dimensions of the first route feature vector.

[0035] Optionally, the time prediction model includes an arrival time estimation network, the second route feature vector includes a first route feature latent variable; and the first loss value calculation unit is further configured to:

[0036] combining the first route feature vector and the first route feature latent variable into a target input parameter;

[0037] The arrival time estimation network performs time prediction on the target input parameters to obtain an estimated arrival time.

[0038] On the other hand, an embodiment of the present invention further provides a time prediction device, comprising:

[0039] A route acquisition unit, used to acquire route features of the route to be estimated;

[0040] A time prediction unit, configured to input the route characteristics into a time prediction model to obtain an estimated arrival time;

[0041] Wherein, the time prediction model is obtained by training using the time prediction model training device as described above.

[0042] Optionally, the route to be estimated includes at least one road section, the route features include road section features of each of the road sections, and the time prediction model includes a feature vector generation network, a variational autoencoder, and an arrival time estimation network;

[0043] The time prediction unit is further configured to:

[0044] Performing vectorization processing on all the road segment features through the feature vector generation network to obtain a third route feature vector;

[0045] Performing dimension conversion on the third route feature vector by the variational autoencoder to obtain a second route feature latent variable;

[0046] The third route feature vector and the second route feature latent variable are input into the arrival time estimation network for time prediction to obtain an estimated arrival time.

[0047] Optionally, the time prediction device further includes:

[0048] a generating unit, configured to generate recommended content according to the estimated arrival time;

[0049] The sending unit is configured to send the recommended content to a terminal.

[0050] On the other hand, an embodiment of the present invention further provides an electronic device, including:

[0051] at least one processor;

[0052] at least one memory for storing at least one program;

[0053] When at least one of the programs is executed by at least one of the processors, the time prediction model training method as described above is implemented, or the time prediction method as described above is implemented.

[0054] On the other hand, an embodiment of the present invention also provides a computer-readable storage medium, which stores a program executable by a processor. When the program executable by the processor is executed by the processor, it is used to implement the time prediction model training method as described above, or to implement the time prediction method as described above.

[0055] On the other hand, an embodiment of the present invention also provides a computer program product, including a computer program or computer instructions, wherein the computer program or the computer instructions are stored in a computer-readable storage medium, and the processor of a computer device reads the computer program or the computer instructions from the computer-readable storage medium, and the processor executes the computer program or the computer instructions, so that the computer device executes the time prediction model training method as described above, or executes the time prediction method as described above.

[0056] The embodiments of the present invention include at least the following beneficial effects: after extracting the first route feature vector of the route feature set, the first route feature vector is dimensionally converted to obtain a second route feature vector, time prediction is performed based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and vector fitting is performed on the second route feature vector to obtain a route reconstruction feature vector. At this time, the segment feature information when arriving at each segment sample is used as label information for adjusting the route reconstruction feature vector, which can improve the accuracy of obtaining the second route feature vector and enhance the accuracy of the time prediction model. In addition, the actual arrival time of the route sample is used as label information for adjusting the estimated arrival time, which can improve the accuracy of obtaining the first route feature vector and the second route feature vector. Therefore, when time prediction is performed based on the first route feature vector and the second route feature vector to obtain the estimated arrival time, the accuracy of the prediction of the estimated arrival time can be improved. That is, by using the actual arrival time of the route sample and the segment feature information when arriving at each segment sample as label information for training the time prediction model, the accuracy of the time prediction model in predicting the estimated arrival time can be improved.

[0057] Other features and advantages of the present invention will be described in the following description, and in part will become apparent from the description, or will be understood by practicing the present invention. The purposes and other advantages of the present invention can be realized and obtained by the structures particularly pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] The accompanying drawings are used to provide a further understanding of the technical solution of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the technical solution of the present invention and do not constitute a limitation to the technical solution of the present invention.

[0059] Figure 1is a schematic diagram of an implementation environment provided by an embodiment of the present invention;

[0060] Figure 2 is a schematic diagram of another implementation environment provided by an embodiment of the present invention;

[0061] Figure 3 This is a flow chart of a time prediction model training method provided by an embodiment of the present invention;

[0062] Figure 4 1 is a schematic diagram of a model structure of a time prediction model provided by an embodiment of the present invention;

[0063] Figure 5 1 is a schematic diagram of the model structure of another time prediction model provided by an embodiment of the present invention;

[0064] Figure 6 is a flow chart of a time prediction method provided by an embodiment of the present invention;

[0065] Figure 7 1 is a schematic diagram of the model structure of another time prediction model provided by an embodiment of the present invention;

[0066] Figure 8 This is a complete flow chart of the time prediction model training method provided by an embodiment of the present invention;

[0067] Figure 9 This is a complete flow chart of the time prediction method provided by an embodiment of the present invention;

[0068] Figure 10 is a schematic diagram of recommended content provided by a specific example of the present invention;

[0069] Figure 11 is a schematic diagram of a time prediction model training device provided by an embodiment of the present invention;

[0070] Figure 12 is a schematic diagram of a time prediction device provided by an embodiment of the present invention;

[0071] Figure 13 is a schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0072] The present invention will be further described below with reference to the accompanying drawings and specific embodiments. The described embodiments should not be considered as limiting the present invention, and all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0073] In the following description, reference is made to “some embodiments”, which describes a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0074] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which the present invention pertains. The terms used herein are for the purpose of describing embodiments of the present invention only and are not intended to limit the present invention.

[0075] Before further explaining the embodiments of the present invention in detail, the nouns and terms involved in the embodiments of the present invention are explained. The nouns and terms involved in the embodiments of the present invention are subject to the following interpretations.

[0076] 1) Estimated Time of Arrival (ETA) is a basic function in map software. Its function is to give the time required to complete a route based on a route and departure time on the map.

[0077] 2) A route is a complete line connecting a starting point and an end point in a map application. In real-world scenarios, the length of a route can range from one kilometer to several dozen kilometers.

[0078] 3) Links: These are used to construct routes. Routes can be represented as sequences of links. In map data, roads are divided into segments, ranging in length from tens of meters to several kilometers. Each segment is called a link and is assigned a globally unique link identifier (ID). This ID can be an integer (int) or a string. Therefore, a route on a map is a sequence of all the links in that route.

[0079] 4) Actual Time of Arrival (ATA): The actual arrival time of a route can be extracted from the historical data of the map service. Therefore, this data can be used as supervision information to train the machine learning algorithm and obtain model parameters.

[0080] 5) Request time, departure time, and transit time: The request time is the time when the navigation request is initiated, the departure time is the time when the route departs from the starting point, and the transit time is the time when the route actually reaches a certain road section. In one example, if the route departs within a short period of time after initiating the navigation request, the request time can be considered the departure time. In another example, if the navigation request is initiated for a future time, for example, a request is made at 8:00 a.m. on Monday for navigation information departing at 10:00 a.m. on Monday, then 8:00 a.m. on Monday is the request time, and 10:00 a.m. on Monday is the departure time. In another example, assuming departure at 10:00 a.m. and arrival at the 10th road section along the route at 10:30 a.m., the transit time for the 10th road section is 10:30 a.m.

[0081] 6) Historical classic speeds are the speeds mined for each road segment based on all historical trajectory information. This represents a historical average speed. For example, if historical classic speeds are mined for each road segment on a weekly basis and at a 5-minute granularity, 2016 historical classic speeds can be mined for each road segment (7 × 24 × 12 = 2016). This means the average speed every 5 minutes from Monday to Sunday can be obtained.

[0082] 7) A variational autoencoder is a neural network model that can generate a set of low-dimensional, decoupled features by fitting itself. A variational autoencoder typically consists of an encoder and a decoder. The encoder transforms the input information into a set of low-dimensional vectors, while the decoder fits the original input information based on these low-dimensional vectors. A variational autoencoder requires not only that the decoder accurately fit the original input information but also that the low-dimensional vectors output by the encoder follow a standard normal distribution as closely as possible.

[0083] 8) Artificial Intelligence (AI) refers to the theories, methods, techniques, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, to perceive the environment, acquire knowledge, and use that knowledge to achieve optimal results. In other words, AI is a comprehensive field within computer science that seeks to understand the essence of intelligence and produce new intelligent machines that can respond in a manner similar to human intelligence. AI also studies the design principles and implementation methods of various intelligent machines, enabling them to possess the capabilities of perception, reasoning, and decision-making. AI technology is an interdisciplinary discipline encompassing a wide range of fields, encompassing both hardware and software technologies. Foundational AI technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, speech processing, natural language processing, and machine learning / deep learning. With the research and advancement of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned driving, autonomous driving, drones, robots, smart medical care, smart customer service, etc. It is believed that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.

[0084] 9) Machine Learning (ML) is a multidisciplinary field that encompasses probability theory, statistics, approximation theory, convex analysis, and algorithmic complexity theory. It specifically studies how computers can simulate or implement human learning behaviors to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is at the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications span all areas of AI. Machine learning and deep learning typically include techniques such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and self-learning.

[0085] 10) Cloud technology refers to a hosting technology that unifies hardware, software, and network resources within a wide or local area network (WAN) to enable data computing, storage, processing, and sharing. Cloud technology is a general term for network, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model. It can form a resource pool for on-demand, flexible and convenient use. Cloud computing technology will become a crucial support. Backend services for technical network systems, such as video websites, image websites, e-commerce platforms, and numerous portals, require extensive computing and storage resources. With the rapid development and application of the internet industry, every item will likely have its own unique identification mark, requiring transmission to backend systems for logical processing. Data of varying levels will be processed separately, and data from all industries will require a strong system backend, which can only be achieved through cloud computing.

[0086] 11) Big data refers to collections of data that cannot be captured, managed, and processed within a specific timeframe using conventional software tools. These are massive, rapidly growing, and diverse information assets that require new processing models to enhance decision-making, insight discovery, and process optimization. With the advent of the cloud era, big data has attracted increasing attention. Big data requires specialized technologies to efficiently process large amounts of time-sensitive data. Technologies suitable for big data include massively parallel processing databases, data mining, distributed file systems, distributed databases, cloud computing platforms, the internet, and scalable storage systems.

[0087] 12) Blockchain is a new application model for computer technologies, including distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks generated using cryptographic methods. Each block contains information about a batch of online transactions, used to verify the validity of this information (to prevent counterfeiting) and generate the next block. Blockchain can include an underlying blockchain platform, a platform product and service layer, and an application service layer. The underlying blockchain platform can include processing modules such as user management, basic services, and smart contracts. The user management module is responsible for managing the identity information of all blockchain participants, including maintaining public and private key generation (account management), key management, and maintaining the correspondence between users' real identities and blockchain addresses (authority management). It also oversees and audits transactions involving certain real identities, providing risk control rule configuration (risk control auditing), with authorization. The basic service module, deployed on all blockchain nodes, verifies the validity of business requests and, after reaching consensus on valid requests, records them in storage. For a new business request, the basic service first adapts and parses the interface and performs authentication processing (interface adaptation). It then encrypts the business information using a consensus algorithm (consensus management). After encryption, the encrypted business information is transmitted completely and consistently to the shared ledger (network communication) and recorded and stored. The smart contract module is responsible for contract registration, issuance, contract triggering, and contract execution. Developers can define contract logic in a programming language and publish it to the blockchain (contract registration). Based on the contract terms, key execution is triggered by calling keys or other events to complete the contract logic. It also provides contract upgrade and cancellation capabilities. The platform product and service layer provides the basic capabilities and implementation framework for typical applications. Developers can build on these basic capabilities and overlay business features to complete the blockchain implementation of business logic. The application service layer provides application services based on blockchain solutions to business participants for use.

[0088] 13) Intelligent Traffic System (ITS), also known as Intelligent Transportation System, effectively integrates advanced science and technology (information technology, computer technology, data communication technology, sensor technology, electronic control technology, automatic control theory, operations research, artificial intelligence, etc.) into transportation, service control and vehicle manufacturing, strengthening the connection between vehicles, roads and users, thereby forming an integrated transportation system that ensures safety, improves efficiency, improves the environment and saves energy.

[0089] 14) Intelligent Vehicle Infrastructure Cooperative Systems (IVICS), also known as VICS, are a development direction of Intelligent Transportation Systems (ITS). IVICS utilizes advanced wireless communications and next-generation internet technologies to implement dynamic, real-time information exchange between vehicles and roads. Based on the collection and integration of dynamic traffic information across time and space, IVICS conducts active vehicle safety control and collaborative road management. This fully realizes effective coordination between people, vehicles, and roads, ensuring traffic safety and improving traffic efficiency, thereby creating a safe, efficient, and environmentally friendly road transportation system.

[0090] Currently, in the field of estimated arrival time, the most commonly used algorithms include rule-based segment-by-segment accumulation methods, tree model-based machine learning methods, and deep model-based machine learning methods.

[0091] Rule-based segment-by-segment accumulation relies on human experience. It estimates the travel time for each segment based on its length, speed, and traffic light conditions. This is then combined with the travel time at each intersection to create the total travel time for the entire route. However, this method often relies too heavily on rules set by human experience, which often lack comprehensive coverage, resulting in low ETA accuracy.

[0092] The tree-based machine learning method no longer estimates each section of the route. Instead, it first extracts the characteristics of the entire route, such as the total distance, the average speed at the time of departure, the total number of traffic lights along the entire route, the percentage of congested mileage along the entire route, etc. These characteristics are then input into the tree-based machine learning algorithm for training. However, this method only considers the overall characteristics of the route and ignores the characteristics of each section. In a real environment, extreme congestion on a certain section of the route can have a huge impact on the arrival time of the entire route. Therefore, when only considering the overall characteristics, the accuracy of the estimated arrival time will be affected. In addition, this method only uses the actual arrival time as supervisory information for training, which makes model training difficult, and the model's accuracy no longer improves after reaching a certain level.

[0093] Deep model-based machine learning methods input the characteristics of the entire route into a deep neural network, train the deep model end-to-end using a backpropagation algorithm, and then use the trained deep model to predict the estimated arrival time. This method is more flexible and more adaptable to data than tree-based machine learning methods, but it only uses actual arrival times as supervisory information for training the deep model, making model training difficult. Furthermore, once the model's accuracy reaches a certain level, it no longer improves. Due to this limited model accuracy, the estimated arrival time prediction accuracy may be low.

[0094] In order to improve the prediction accuracy of the estimated arrival time, the embodiment of the present invention provides a time prediction model training method, a time prediction method, a time prediction model training device, a time prediction device, an electronic device, a computer-readable storage medium and a computer program product, by obtaining a route feature set of a route sample, and after extracting a first route feature vector of the route feature set, performing dimension conversion on the first route feature vector to obtain a second route feature vector, performing time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and performing vector fitting on the second route feature vector to obtain a route reconstruction feature vector. At this time, the road section feature information when arriving at each road section sample is used as the adjustment The label information of the reconstructed feature vector of the entire route can improve the accuracy of obtaining the second route feature vector and enhance the accuracy of the time prediction model. In addition, using the actual arrival time of the route sample as the label information for adjusting the estimated arrival time can improve the accuracy of obtaining the first route feature vector and the second route feature vector. Therefore, when the estimated arrival time is obtained by time prediction based on the first route feature vector and the second route feature vector, the accuracy of the prediction of the estimated arrival time can be improved. That is to say, by using the actual arrival time of the route sample and the section feature information when arriving at each section sample as the label information for training the time prediction model, the accuracy of the time prediction model in predicting the estimated arrival time can be improved.

[0095] The solutions provided by the embodiments of the present invention involve technologies such as artificial intelligence machine learning, and are specifically described through the following embodiments.

[0096] Figure 1 This is a schematic diagram of an implementation environment provided by an embodiment of the present invention. Figure 1 The implementation environment includes a first terminal 101 and a first server 102. The first terminal 101 and the first server 102 are directly or indirectly connected via wired or wireless communication. The first terminal 101 and the first server 102 may be nodes in a blockchain, which is not specifically limited in this embodiment.

[0097] The first terminal 101 may include but is not limited to a mobile phone, a computer, an intelligent voice interaction device, a smart home appliance, a vehicle terminal, an aircraft, etc. Optionally, the first terminal 101 may be installed with an application for route navigation, through which a route query request may be initiated and route query results may be displayed.

[0098] The first terminal 101 has at least functions such as initiating requests and displaying results. For example, it can send a route query request to the first server 102 in response to a query for a route, and after receiving the route query result fed back by the first server 102 based on the route query request, it can display the route query result.

[0099] The first server 102 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms.

[0100] The first server 102 has at least the functions of training a time prediction model and predicting an estimated arrival time using the trained time prediction model. For example, the first server 102 can use the time prediction model to perform time prediction and feature fitting on the route feature information of the route sample to obtain an estimated arrival time and a route reconstruction feature vector. The first server 102 then uses the segment feature information when arriving at each segment sample as label information for adjusting the route reconstruction feature vector, and uses the actual arrival time of the route sample as label information for adjusting the estimated arrival time to modify the parameters of the time prediction model, thereby training the time prediction model. For another example, the first server 102 can predict the estimated arrival time of the destination point based on a route query request for the destination point from the first terminal 101 and the trained time prediction model. After the estimated arrival time is predicted, the estimated arrival time is sent to the first terminal 101, so that the first terminal 101 displays the route query result to the destination point based on the estimated arrival time.

[0101] Reference Figure 1As shown, in an application scenario, it is assumed that the first terminal 101 is a vehicle-mounted terminal, and the first terminal 101 is installed with an application for route navigation (such as map software, etc.). In response to the driver navigating to the destination through the application, the first terminal 101 sends a route query request including the current location, destination and current time to the first server 102; in response to receiving the route query request, the first server 102 determines the target estimated route based on the current location and destination, and then inputs the route features of the current time and the target estimated route into a trained time prediction model for time prediction processing to obtain an estimated arrival time of the target estimated route, and then sends the target estimated route and estimated arrival time to the first terminal 101; in response to receiving the target estimated route and estimated arrival time, the first terminal 101 displays the target estimated route and estimated arrival time. In the process of training the time prediction model, the first server 102 first obtains the route feature set of the route sample and extracts the first route feature vector of the route feature set. Then, the first route feature vector is dimensionally converted to obtain the second route feature vector. Time prediction is performed based on the first route feature vector and the second route feature vector to obtain the estimated arrival time, and the second route feature vector is vector fitted to obtain the route reconstruction feature vector. Then, the section feature information when arriving at each section sample is used as the label information for adjusting the route reconstruction feature vector, and the actual arrival time of the route sample is used as the label information for adjusting the estimated arrival time, to correct the parameters of the time prediction model and realize the training of the time prediction model.

[0102] Figure 2 This is a schematic diagram of another implementation environment provided by an embodiment of the present invention. Figure 2 The implementation environment includes a second terminal 201, a third terminal 202, and a second server 203, wherein the number of third terminals 202 can be multiple. The second server 203 is directly or indirectly connected to the second terminal 201 and the third terminal 202 respectively through wired or wireless communication. The second terminal 201, the third terminal 202, and the second server 203 can be nodes in the blockchain, which is not specifically limited in this embodiment.

[0103] The second terminal 201 and the third terminal 202 may include, but are not limited to, mobile phones, computers, intelligent voice interaction devices, smart home appliances, vehicle-mounted terminals, aircraft, etc. Optionally, the second terminal 201 may be installed with a first application for requesting services, and the third terminal 202 may be installed with a second application for allocating services. The second terminal 201 may initiate a service request to the second server 203 through the first application, and the third terminal 202 may receive the service allocated by the second server 203 through the second application.

[0104] The second terminal 201 has at least the function of initiating a service request. For example, it can send a service order to the second server 203 in response to a service request, so that the second server 203 allocates the corresponding service content to the appropriate third terminal 202 according to the service order.

[0105] The third terminal 202 has at least the function of receiving service content, for example, it can receive the service content sent by the second server 203 and display the target location of the second terminal 201 that initiates the service request and the target route to the target location according to the service content.

[0106] The second server 203 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms.

[0107] The second server 203 has at least the functions of training a time prediction model and using the trained time prediction model to predict an estimated arrival time. For example, the time prediction model can be used to perform time prediction and feature fitting on the route feature information of route samples to obtain an estimated arrival time and a route reconstruction feature vector. The time prediction model parameters can then be modified using the segment feature information upon arrival at each segment sample as label information for adjusting the route reconstruction feature vector, and the actual arrival time of the route sample as label information for adjusting the estimated arrival time, thereby training the time prediction model. For another example, the time prediction model can be used to predict the estimated arrival time from the location of each third terminal 202 to the location of the second terminal 201 based on the service order from the second terminal 201, the location of each third terminal 202, and the trained time prediction model. After the estimated arrival time corresponding to each third terminal 202 is predicted, the corresponding service content is assigned to the third terminal 202 with the smallest estimated arrival time, so that the third terminal 202 displays the target location of the second terminal 201 and the target route to the target location according to the service content.

[0108] Reference Figure 2As shown, in one application scenario, it is assumed that the second terminal 201 and the third terminal 202 are both smartphones, wherein the second terminal 201 is installed with a first application for requesting services (e.g., a customer version of a food delivery app, etc.), and the third terminal 202 is installed with a second application for allocating services (e.g., a delivery driver version of a food delivery app, etc.). In response to a customer placing a food delivery order through the first application, the second terminal 201 sends a service request including the current time, the customer's location, and the order details to the second server 203. In response to receiving the service request, the second server 203 determines multiple target estimated routes based on the customer's location and the locations of each third terminal 202. The second server 203 then inputs the current time and the route features of each target estimated route into a trained time prediction model for time prediction processing, obtaining an estimated arrival time for each target estimated route. The third terminal 202 with the smallest estimated arrival time is then determined as the target terminal, and the order details and customer location are sent to the target terminal. In response to receiving the order details and customer location, the target terminal displays the customer's location and the target route to the customer's location. In the process of training the time prediction model, the second server 203 first obtains the route feature set of the route sample and extracts the first route feature vector of the route feature set. Then, the first route feature vector is dimensionally converted to obtain the second route feature vector. Time prediction is performed based on the first route feature vector and the second route feature vector to obtain the estimated arrival time, and the second route feature vector is vector fitted to obtain the route reconstruction feature vector. Then, the section feature information when arriving at each section sample is used as the label information for adjusting the route reconstruction feature vector, and the actual arrival time of the route sample is used as the label information for adjusting the estimated arrival time, to correct the parameters of the time prediction model and realize the training of the time prediction model.

[0109] It should be noted that in various specific embodiments of the present invention, when it comes to the need to perform relevant processing based on data related to the characteristics of the target object, such as the target object attribute information or attribute information set, the permission or consent of the target object will be obtained first, and the collection, use and processing of such data will comply with the relevant laws, regulations and standards of the relevant countries and regions. In addition, when the embodiment of the present invention needs to obtain the attribute information of the target object, it will obtain the separate permission or consent of the target object through a pop-up window or jump to a confirmation page. After clearly obtaining the separate permission or consent of the target object, the necessary target object-related data for the normal operation of the embodiment of the present invention will be obtained.

[0110] The embodiments of the present invention can be applied to various scenarios that require prediction of estimated arrival time, including but not limited to time prediction scenarios in the fields of map navigation, smart transportation, assisted driving, etc.

[0111] Figure 3 This is a flow chart of a time prediction model training method provided by an embodiment of the present invention, which can be executed by a server. Figure 3 The time prediction model training method includes but is not limited to steps 110 to 140.

[0112] Step 110: Obtain a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes the actual arrival time of the route sample and the road segment feature information when arriving at each road segment sample.

[0113] It should be noted that route samples can be obtained from all historical navigation information or from all historical trajectory data during the use of a map application, and this is not specifically limited here. Each route sample includes the route sample's starting point, the route sample's end point, and the various road segment samples that constitute the route sample. A route sample includes at least one road segment sample. When a route sample includes only one road segment sample, the route sample is the road segment sample, and the route feature set of the route sample is the road segment feature set of the road segment sample. When a route sample includes multiple road segment samples, the route sample can be represented by a sequence of all of these road segment samples, and the route feature set of the route sample includes the road segment feature sets of all of these road segment samples. The road segment samples in a route sample can be divided according to intersections (e.g., the route portion between adjacent intersections is considered a road segment), according to the number of lanes contained in the corresponding road (e.g., a continuous route with a constant number of lanes is considered a road segment), or according to road grade (e.g., a continuous route with a constant road grade is considered a road segment), and this is not specifically limited here.

[0114] In one possible implementation, when obtaining the route feature set of a route sample, all historical data of the route sample can be extracted from the historical navigation information or historical trajectory data, such as the historical departure time, the sequence of the road segment samples of the route sample, the road segment feature information when arriving at each road segment sample, and the historical actual arrival time of completing the entire route sample. The route feature set of the route sample includes the road segment feature set of all road segment samples corresponding to the route sample, and the road segment feature set of the road segment sample can include the basic attribute features of the road segment sample, the historical classic speed features corresponding to the historical departure time, and the road condition features corresponding to the historical departure time. The basic attribute features of the road segment sample can include the mileage, road grade, road width, number of traffic lights, etc. of the road segment sample; the historical classic speed features corresponding to the historical departure time can include the corresponding historical classic speed and the standard deviation of the historical classic speed, etc. For example, assuming that from T0-30min to T0+30 min (T0 is the historical departure time), the historical classic speed and the standard deviation of the historical classic speed are counted with a statistical granularity of 5 minutes, and 12 historical classic speeds and 12 standard deviations of the historical classic speed can be obtained; the road condition characteristics corresponding to the historical departure time can include historical real-time traffic flow and historical real-time vehicle speed, etc. For example, assuming that in the time period from T0-30min to T0 (T0 is the historical departure time), the historical real-time traffic flow and the historical real-time speed of the vehicle are counted with a statistical granularity of 5 minutes, 6 historical real-time traffic flows and 6 historical real-time vehicle speeds can be obtained. Therefore, when obtaining the route feature set of the route sample, assuming that the route sample includes M road section samples, and a k-dimensional feature information can be obtained for each road section sample, then the route feature set of the obtained route sample can be an M*k feature matrix, where M and k are both integers greater than 0.

[0115] In one possible implementation, the road section characteristic information upon arrival at the road section sample may be the road section characteristic information upon arrival at the starting position of the road section sample, the road section characteristic information upon arrival at the midpoint position of the road section sample, or the road section characteristic information upon arrival at the end position of the road section sample. It may be appropriately selected based on the actual application situation and is not specifically limited here. It should be noted that the road section characteristic information upon arrival at the road section sample may be information after vectorization. The road section characteristic information upon arrival at the road section sample may include road condition information upon arrival at the road section sample, average real-time speed upon arrival at the road section sample, and average historical classic speed upon arrival at the road section sample, etc., wherein the average real-time speed may be calculated by arithmetic average or harmonic average, which is not specifically limited here. Since route samples are composed of road section samples, the road section feature information when arriving at different road section samples will affect the accurate prediction of the estimated arrival time. Therefore, by using the road section feature information when arriving at each road section sample as label information to adjust the parameters of the time prediction model, the time prediction model can improve the accuracy of extracting the route feature vector of the route sample and enhance the accuracy of the time prediction model, thereby improving the prediction accuracy of the estimated arrival time.

[0116] In one possible implementation, in addition to including the actual arrival time of a route sample and the road segment characteristics upon arrival at each road segment sample, the label information may also include the total mileage of the route sample, the percentage of highways along the route, and the total congested mileage. By expanding the label information used as supervisory information for training the time prediction model, the accuracy of the time prediction model's extraction of route feature vectors for the route samples can be effectively improved, as can the precision of the time prediction model, thereby improving the accuracy of the estimated arrival time prediction. It should be noted that the label information can be a true value vector extracted manually or via a neural network model, and the choice can be appropriate based on the actual application, without specific limitation herein.

[0117] Step 120: Extract the first route feature vector of the route feature set through the time prediction model, perform dimension conversion on the first route feature vector to obtain the second route feature vector, perform time prediction based on the first route feature vector and the second route feature vector to obtain the estimated arrival time, and obtain the time prediction loss value based on the estimated arrival time and the actual arrival time.

[0118] In this step, since the route feature set and label information of the route sample are obtained in step 110, the first route feature vector of the route feature set can be extracted through the time prediction model, and then the first route feature vector is dimensionally converted to obtain the second route feature vector. Then, time prediction is performed based on the first route feature vector and the second route feature vector to obtain the estimated arrival time. After the estimated arrival time is predicted, the time prediction loss value is obtained based on the estimated arrival time and the actual arrival time, so that the subsequent steps can use the time prediction loss value to correct the parameters of the time prediction model to realize the training of the time prediction model.

[0119] In one possible implementation, the time prediction model may include: Figure 4 The model structure shown in Figure 4 In the embodiment, the time prediction model may include a feature vector generation network, a feature encoding network, and an arrival time estimation network. Therefore, when executing step 120, the first route feature vector of the route feature set can be first extracted through the feature vector generation network, and then the first route feature vector is dimensionally transformed through the feature encoding network to obtain a second route feature vector. The first route feature vector and the second route feature vector are then input into the arrival time estimation network for time prediction to obtain an estimated arrival time. After obtaining the estimated arrival time, the difference between the estimated arrival time and the actual arrival time is calculated, and then the time prediction loss value is obtained based on the difference.

[0120] Step 130: Perform vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtain a reconstruction loss value based on the route reconstruction feature vector and feature information of all road sections.

[0121] In this step, since the label information including the road section feature information when arriving at each road section sample is obtained in step 110, and the second route feature vector is obtained in step 120, the second route feature vector can be firstly vector fitted to obtain the route reconstruction feature vector, and then the reconstruction loss value can be obtained based on the route reconstruction feature vector and all the road section feature information, so that the reconstruction loss value can be used in the subsequent steps to correct the parameters of the time prediction model and realize the training of the time prediction model.

[0122] In one possible implementation, the time prediction model may include: Figure 5 The model structure shown in Figure 5In the case where the time prediction model includes a feature vector generation network, a feature encoding network and an arrival time estimation network, the time prediction model may also include a feature decoding network. Therefore, after the first route feature vector is dimensionally transformed by the feature encoding network to obtain a second route feature vector, the second route feature vector can be vector fitted by the feature decoding network to obtain a route reconstruction feature vector, and then the reconstruction loss value is obtained based on the route reconstruction feature vector and the feature information of all road sections.

[0123] Step 140: Modify the parameters of the time prediction model according to the time prediction loss value and the reconstruction loss value.

[0124] In this step, since the time prediction loss value is obtained in step 120 and the reconstruction loss value is obtained in step 130, the parameters of the time prediction model can be corrected according to the time prediction loss value and the reconstruction loss value to achieve training of the time prediction model.

[0125] In one possible implementation, the time prediction loss value and the reconstruction loss value can be used to perform end-to-end backpropagation on the time prediction model, and the parameters of the feature vector generation network, feature encoding network, arrival time estimation network and feature decoding network in the time prediction model can be corrected, thereby realizing the training of the time prediction model.

[0126] In this embodiment, through the time prediction model training method including the preceding steps 110 to 140, after extracting a first route feature vector from a route feature set, the first route feature vector is dimensionally transformed to obtain a second route feature vector, time prediction is performed based on the first and second route feature vectors to obtain an estimated arrival time, and vector fitting is performed on the second route feature vector to obtain a route reconstruction feature vector. In this case, using the segment feature information upon arrival at each road segment sample as label information for adjusting the route reconstruction feature vector can improve the accuracy of obtaining the second route feature vector and enhance the precision of the time prediction model. In addition, using the actual arrival time of the route sample as label information for adjusting the estimated arrival time can improve the accuracy of obtaining the first and second route feature vectors. Therefore, when time prediction is performed based on the first and second route feature vectors to obtain an estimated arrival time, the accuracy of the estimated arrival time prediction can be improved. In other words, by using the actual arrival time of the route sample and the segment feature information upon arrival at each road segment sample as label information for training the time prediction model, the accuracy of the time prediction model in predicting the estimated arrival time can be improved.

[0127] In one possible embodiment, when the second route feature vector includes the first route feature latent variable and the route feature variance, when the parameters of the time prediction model are corrected according to the time prediction loss value and the reconstruction loss value, a normally distributed loss value can be first obtained according to the first route feature latent variable and the route feature variance, and then the parameters of the time prediction model are corrected according to the normally distributed loss value, the time prediction loss value, and the reconstruction loss value. A latent variable refers to a parameter that cannot be directly observed but has an impact on the state of the system and the observable output information. The first route feature latent variable can be the mean of the first route feature vector, the route feature variance can be the variance of the first route feature vector, and the normally distributed loss value is used to characterize the extent to which the first route feature latent variable and the route feature variance follow a standard normal distribution. In general, it can be assumed that the route feature set obeys a standard normal distribution. Therefore, the first route feature vector extracted from the route feature set and the second route feature vector obtained by dimensionality conversion should also obey a standard normal distribution. In order to accurately correct the parameters of the time prediction model, the normal distribution obeyed by the second route feature vector can be determined based on the first route feature latent variable and the route feature variance. Then, a normal distribution loss value is obtained based on the normal distribution obeyed by the second route feature vector and the standard normal distribution. Then, the difference between the distribution of the route feature set and the distribution of the second route feature vector can be determined based on the normal distribution loss value. Then, the parameters of the time prediction model can be corrected based on the difference, so that the first route feature latent variable and the route feature variance are more obedient to the standard normal distribution. In other words, the difference between the distribution of the route feature set and the distribution of the second route feature vector is made smaller, thereby improving the accuracy of the time prediction model in extracting the second route feature vector, so that when time prediction is performed based on the first route feature vector and the second route feature vector in subsequent steps, a more accurate estimated arrival time can be obtained.

[0128] In a possible implementation, when obtaining a normal distribution loss value based on the first route characteristic latent variable and the route characteristic variance, the normal distribution loss value can be obtained according to the following formula (1):

[0129] loss1=∑(μ 2 +σ 2 -logσ 2 -1) (1)

[0130] In formula (1), loss1 is the normal distribution loss value, μ is the first route characteristic latent variable, σ 2 is the route feature variance, and the summation symbol ∑ represents the summation of all first route feature latent variables and the corresponding route feature variances.

[0131] In one possible embodiment, the normal distribution loss value, the time prediction loss value, and the reconstruction loss value can each have a corresponding weight. The weight of the normal distribution loss value, the weight of the time prediction loss value, and the weight of the reconstruction loss value can all be determined based on prior knowledge. Different weights reflect the importance of different loss values when training the time prediction model. For example, assuming that the weight of the time prediction loss value is the largest, it means that the time prediction loss value is more important when training the time prediction model. Among them, the reconstruction loss value can train the time prediction model's extraction accuracy for the route reconstruction feature vector, the second route feature vector, and the first route feature vector, the normal distribution loss value can train the time prediction model's extraction accuracy for the second route feature vector and the first route feature vector, and the time prediction loss value can train the time prediction model's extraction accuracy for the second route feature vector and the first route feature vector, as well as the prediction accuracy for the estimated arrival time. Therefore, through the combined effect of the normal distribution loss value, the time prediction loss value, and the reconstruction loss value, effective training of the time prediction model can be achieved, thereby improving the accuracy of the time prediction model, and further improving the time prediction model's prediction accuracy for the estimated arrival time.

[0132] In one possible implementation, when obtaining a predicted time loss value based on an estimated arrival time and an actual arrival time, first deviation information between the estimated arrival time and the actual arrival time may be obtained, and then the predicted time loss value may be calculated based on the first deviation information. The first deviation information may be the difference between the estimated arrival time and the actual arrival time, and the predicted time loss value may be the squared loss or the absolute value of the loss between the estimated arrival time and the actual arrival time. These can be appropriately selected based on actual application circumstances and are not specifically limited herein.

[0133] In a possible implementation, when the time prediction loss value is the square loss between the estimated arrival time and the actual arrival time, the time prediction loss value can be calculated using the following formula (2):

[0134] loss2=-(ETA-ATA) 2 (2)

[0135] In formula (2), loss2 is the time prediction loss value, ETA is the estimated arrival time, and ATA is the actual arrival time.

[0136] In a possible implementation, when the time prediction loss value is the absolute value loss between the estimated arrival time and the actual arrival time, the time prediction loss value can be calculated using the following formula (3):

[0137] loss2=-|ETA-ATA| (3)

[0138] In formula (3), loss2 is the time prediction loss value, ETA is the estimated arrival time, and ATA is the actual arrival time.

[0139] In one possible embodiment, when a route reconstruction feature vector includes a segment reconstruction feature vector for each road segment sample, when obtaining a reconstruction loss value based on the route reconstruction feature vector and all segment feature information, second deviation information between the segment reconstruction feature vector and the segment feature information can be first obtained, and then the reconstruction loss value can be calculated based on the second deviation information. Since a route sample is composed of segment samples, the route feature set of the route sample includes the segment feature sets of all segment samples corresponding to the route sample. Therefore, the route reconstruction feature vector obtained based on the route feature set of the route sample will include the segment reconstruction feature vector of each segment sample. Since the label information used to train the time prediction model includes the segment feature information when reaching each segment sample, the segment reconstruction feature vector will include content corresponding to the segment feature information. Therefore, the second deviation information between the segment reconstruction feature vector and the segment feature information can be first calculated, and then the reconstruction loss value can be calculated based on the second deviation information.

[0140] It should be noted that the reconstruction loss value is used to represent the difference between the first route feature vector after dimensional conversion and vector fitting and the original first route feature vector. Since the dimensional conversion and vector fitting process of the first route feature vector produces a second route feature vector, and the second route feature vector is one of the input parameters used to predict the estimated arrival time, using the reconstruction loss value to train the time prediction model can improve the time prediction model's accuracy in extracting the second route feature vector, thereby improving the time prediction model's accuracy in predicting the estimated arrival time.

[0141] It should be noted that the second deviation information can be the difference between the road section reconstruction feature vector and the road section feature information, and the reconstruction loss value can be the square loss or absolute value loss between the road section reconstruction feature vector and the road section feature information, etc. It can be appropriately selected according to the actual application situation and is not specifically limited here.

[0142] In a possible implementation, when the reconstruction loss value is the square loss between the road segment reconstruction feature vector and the road segment feature information, the reconstruction loss value can be calculated using the following formula (4):

[0143] loss4=-(x 重建 -x 路段特征 ) 2 (4)

[0144] In formula (4), loss4 is the reconstruction loss value, x重建 Reconstruct the feature vector for the road segment, x 路段特征 It is the road segment feature information.

[0145] In a possible implementation, when the reconstruction loss value is the absolute value loss between the road segment reconstruction feature vector and the road segment feature information, the reconstruction loss value can be calculated using the following formula (5):

[0146] loss4=-|x 重建 -x 路段特征 | (5)

[0147] In formula (5), loss4 is the reconstruction loss value, x 重建 Reconstruct the feature vector for the road segment, x 路段特征 It is the road segment feature information.

[0148] In one possible embodiment, when the time prediction model includes a feature vector generation network, when extracting the first route feature vector of the route feature set through the time prediction model, the route feature set can be first converted into a route feature matrix, and then the route feature matrix can be vectorized by the feature vector generation network to obtain the first route feature vector of the route feature set. The feature vector generation network can be any network structure applicable to sequence problems, such as a recurrent neural network (RNN), a convolutional neural network (CNN), or a neural network based on an attention mechanism, etc., which can be appropriately selected according to the actual application situation and is not specifically limited here. Since the feature vector generation network is a network structure applicable to sequence problems, when using the feature vector generation network to vectorize the route feature set, the route feature set can be first converted into a route feature matrix, so that the route feature set can adapt to the processing process of the feature vector generation network, thereby improving the accuracy of the feature vector generation network in vectorizing the route feature set, thereby improving the accuracy of the time prediction model in extracting the first route feature vector, which is conducive to the subsequent steps of predicting a more accurate estimated arrival time based on a more accurate first route feature vector. It should be noted that the first route feature vector output by the feature vector generation network can be a one-dimensional feature vector or a feature array, wherein the number of elements of the first route feature vector is determined according to the number of elements of the route feature set. For example, the number of elements of the first route feature vector can be 100 or 200, etc., which is not specifically limited here.

[0149] In one possible embodiment, when the time prediction model includes a variational autoencoder and the variational autoencoder includes an encoder, when performing a dimension conversion on a first route feature vector to obtain a second route feature vector, the first route feature vector may be dimensionally converted by the encoder in the variational autoencoder to obtain the second route feature vector, wherein the number of dimensions of the second route feature vector is smaller than the number of dimensions of the first route feature vector. The encoder in the variational autoencoder can be any network structure suitable for fixed-length vectors, such as a fully connected network, and can be appropriately selected based on actual application circumstances, without specific limitation herein. A fixed-length vector refers to a vector with a fixed number of elements. It should be noted that the goal of the encoder in the variational autoencoder is to convert the input information into a set of low-dimensional vectors. Therefore, when the encoder in the variational autoencoder performs dimension conversion on the first route feature vector, a second route feature vector with a smaller number of dimensions than the first route feature vector can be obtained. By reducing the number of dimensions to reduce the number of feature vectors, the training speed of the model can be accelerated, thereby improving the efficiency of model training, and making the second route feature vector obey the standard normal distribution as much as possible, so as to provide a data basis for the fitting processing of the second route feature vector in subsequent steps.

[0150] In one possible embodiment, when the time prediction model includes a variational autoencoder and the variational autoencoder includes a decoder, when performing vector fitting on the second route feature vector to obtain a route reconstruction feature vector, the decoder in the variational autoencoder can perform vector fitting on the second route feature vector to obtain a route reconstruction feature vector, wherein the number of dimensions of the route reconstruction feature vector is equal to the number of dimensions of the first route feature vector. The decoder in the variational autoencoder can be any network structure suitable for fixed-length vectors, such as a fully connected network, etc., and can be appropriately selected according to the actual application situation, and is not specifically limited here. It should be noted that the goal of the decoder in the variational autoencoder is to fit the original input information based on the low-dimensional vector output by the encoder. Therefore, when performing vector fitting on the second route feature vector by the decoder in the variational autoencoder, it is necessary to obtain a route reconstruction feature vector with a number of dimensions equal to the number of dimensions of the first route feature vector, so that the subsequent steps can obtain the reconstruction loss value for training the time prediction model based on the route reconstruction feature vector.

[0151] In one possible embodiment, when the time prediction model includes an arrival time estimation network and the second route feature vector includes a first route feature latent variable, when performing time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, the first route feature vector and the first route feature latent variable can be first combined into a target input parameter, and then the target input parameter can be time predicted by the arrival time estimation network to obtain the estimated arrival time. The arrival time estimation network can be any network structure suitable for fixed-length vectors, such as a fully connected network or a deep factorization machine (Deep Factorization Machine, Deep FM) that can be used to filter out cross-features. It can be appropriately selected according to the actual application situation and is not specifically limited here. It should be noted that since the first route feature latent variable can be the mean of the first route feature vector, the first route feature vector and the first route feature latent variable can be first combined into a target input parameter, so that the arrival time estimation network can predict the estimated arrival time based on more abundant input parameters, thereby improving the accuracy of the arrival time estimation network in predicting the estimated arrival time.

[0152] Reference Figure 6 As shown, Figure 6 1 is a flow chart of a time prediction method provided by an embodiment of the present invention, which can be executed by a server. Figure 6 , the time prediction method includes but is not limited to step 610 and step 620.

[0153] Step 610: Obtain route features of the route to be estimated.

[0154] It should be noted that the server can determine the estimated route from the starting point to the terminal location based on the map data based on the starting point location and the terminal location sent by the terminal. For example, when the target user enters a starting point identifier and an end point identifier, such as a place name, in a route navigation application on the terminal, the terminal can determine the specific location of the starting point and the specific location of the end point based on the identifiers. The terminal can then send the starting point location and the terminal location to the server. After the server receives the starting point location and the terminal location, the server can determine the estimated route based on the starting point location, the terminal location, and the map data, and obtain corresponding route features based on the estimated route and the map data. Alternatively, when the target user enters a starting point identifier and an end point identifier, such as a place name, in a route navigation application on the terminal, the terminal can determine the specific location of the starting point and the specific location of the end point based on the identifiers. The estimated route can then be determined based on the starting point location, the terminal location, and the map data. The terminal can then send the estimated route to the server. After the server receives the estimated route, the server can obtain corresponding route features based on the estimated route and the map data.

[0155] It should be noted that, since the route to be estimated is composed of various road sections, the route characteristics of the route to be estimated may include the road section characteristics of all road sections corresponding to the route to be estimated, wherein the road section characteristics may include the basic attribute characteristics of the road section, the classic speed characteristics corresponding to the current departure time, and the road condition characteristics corresponding to the current departure time, etc., wherein the basic attribute characteristics of the road section may include the mileage of the road section, the road grade, the road width, the number of traffic lights, etc.; the classic speed characteristics corresponding to the current departure time may include the corresponding classic speed and the standard deviation of the classic speed, etc. For example, assuming that at T1-30min In the time period from T1-30min to T1+30min (T1 is the current departure time), the classic speed and the standard deviation of the classic speed are counted with a statistical granularity of 5 minutes, and 12 classic speeds and 12 standard deviations of the classic speed can be obtained; the road condition characteristics corresponding to the current departure time may include the current real-time traffic flow and the current real-time speed of the vehicle. For example, assuming that in the time period from T1-30min to T1 (T1 is the current departure time), the current real-time traffic flow and the current real-time speed of the vehicle are counted with a statistical granularity of 5 minutes, 6 current real-time traffic flows and 6 current real-time speeds of the vehicle can be obtained.

[0156] Step 620: Input the route features into the time prediction model to obtain an estimated arrival time; wherein the time prediction model is trained using a time prediction model training method.

[0157] In this step, since the route features of the route to be estimated have been obtained in step 610, and the time prediction model has been trained using the previous time prediction model training method, the route features can be input into the time prediction model for time prediction to obtain the estimated arrival time after completing the route to be estimated. It should be noted that since the route features of the route to be estimated include multiple types of feature information, such as basic attribute features of each road segment, classic speed features corresponding to each road segment at the current departure time, and road condition features corresponding to each road segment at the current departure time, in order to make the route features of the route to be estimated adaptable to the processing process of the time prediction model, the route features of the route to be estimated can first be converted into an M*k feature matrix, where M is the number of road segments included in the route to be estimated, k is the number of dimensions of each road segment, and both M and k are integers greater than 0. Then, the M*k feature matrix is input into the time prediction model for time prediction. Since the time prediction model has been trained through the previous time prediction model training method, the time prediction model can have good accuracy, and the predicted estimated arrival time is relatively accurate. Therefore, using the time prediction model trained by the previous time prediction model training method to predict the estimated arrival time of the estimated route can obtain more accurate prediction results, which is conducive to improving the user experience.

[0158] In one possible embodiment, when the route to be estimated includes at least one road segment, the route features include segment features of each road segment, and the time prediction model includes a feature vector generator network, a variational autoencoder, and an arrival time estimation network, when inputting the route features into the time prediction model to obtain an estimated arrival time, all the segment features can first be vectorized using the feature vector generator network to obtain a third route feature vector. The third route feature vector can then be dimensionally transformed using the variational autoencoder to obtain a second route feature latent variable. The third route feature vector and the second route feature latent variable are then input into the arrival time estimation network for time prediction to obtain an estimated arrival time. The second route feature latent variable obtained by dimensionally transforming the third route feature vector using the variational autoencoder is the mean of the third route feature vector. Therefore, when the third route feature vector and the second route feature latent variable are input together into the arrival time estimation network for time prediction, the arrival time estimation network can predict the estimated arrival time based on a richer set of input parameters, thereby improving the accuracy of the arrival time prediction network's estimated arrival time.

[0159] It should be noted that the third route feature vector output by the feature vector generation network can be a one-dimensional feature vector or feature array. The number of elements in the third route feature vector is determined by the number of elements in all the route segment features. For example, the number of elements in the third route feature vector can be 100 or 200, etc., and is not specifically limited here. In addition, the number of dimensions of the second route feature latent variable is smaller than the number of dimensions of the third route feature vector.

[0160] In one possible embodiment, after the estimated arrival time of the route to be estimated is predicted, the time prediction method may further include, but is not limited to, the following steps: first generating recommended content based on the estimated arrival time, and then sending the recommended content to the terminal. Assuming that the time prediction method is executed in response to the driver navigating to the destination point through the terminal, after the estimated arrival time of the route to be estimated is predicted, the server may first generate recommended content based on the estimated arrival time, wherein the recommended content may, for example, include the navigation route to the destination point and the estimated arrival time to the destination point. Then, the server may send the recommended content to the terminal. After the terminal receives the recommended content, the terminal may display the corresponding navigation route to the destination point and the estimated arrival time to the destination point based on the recommended content, so that the driver can make reasonable itinerary arrangements based on the recommended content displayed on the terminal. In addition, assuming that the time prediction method is executed in response to the allocation of an order, for each deliveryman in the same geographical area (for example, a geographical area with a radius of 1 kilometer), the server will execute the time prediction method accordingly to predict the estimated arrival time of each deliveryman at the customer's location. After the estimated arrival time corresponding to each deliveryman is predicted, the server can select the one with the smallest value among these estimated arrival times as the target estimated arrival time, and assign the corresponding order to the deliveryman corresponding to the target estimated arrival time. At this time, the server can first generate recommendation content based on the target estimated arrival time, wherein the recommendation content can, for example, include the navigation route to the customer's location and the estimated arrival time to the customer's location (i.e., the target estimated arrival time). Then, the server sends the recommendation content to the deliveryman's terminal. After the deliveryman's terminal receives the recommendation content, the deliveryman's terminal can display the navigation route to the customer's location and the estimated arrival time to the customer's location based on the recommendation content, so that the deliveryman can make reasonable delivery arrangements based on the recommendation content displayed on the terminal.

[0161] The following fully illustrates the principles of the time prediction model training method and the time prediction method provided by the embodiments of the present invention with some specific examples.

[0162] Reference Figure 7 and Figure 8 As shown, Figure 7The schematic diagram of the model structure of the time prediction model provided by the embodiment of the present invention is shown in FIG. Figure 7 In

[15] , the time prediction model includes a feature vector generation network, an encoder, a decoder, and an arrival time estimation network, where the encoder and decoder constitute a variational autoencoder. Figure 8 This is a complete flow chart of the time prediction model training method provided by an embodiment of the present invention. The time prediction model training method specifically includes the following steps 810 to 890.

[0163] Step 810: Obtain a road segment feature set of multiple road segment samples constituting a route sample.

[0164] In this step, a set of road segment features for multiple road segment samples constituting the route sample can be obtained through historical map data. The road segment feature information may include road condition information upon arrival at the road segment sample, average real-time speed upon arrival at the road segment sample, and average historical classic speed upon arrival at the road segment sample. The road segment feature information may be information in vector form; the actual arrival time upon completing the route sample is a historical time data; the road segment feature set may include basic attribute features of the road segment sample, historical classic speed features corresponding to the historical departure time, and road condition features corresponding to the historical departure time. The basic attribute features of the road segment sample may include the mileage, road grade, road width, and number of traffic lights of the road segment sample; the historical classic speed features corresponding to the historical departure time may include the corresponding historical classic speed and the standard deviation of the historical classic speed; and the road condition features corresponding to the historical departure time may include historical real-time traffic volume and historical real-time vehicle speed.

[0165] Step 820: Extract feature vectors from the road segment feature set based on manual experience to obtain a full route feature vector used as label information.

[0166] In this step, the full route feature vector includes the total mileage of the route sample, the percentage of highways along the entire route, the total congested mileage, and the segment feature information upon arrival at each segment sample. It should be noted that the segment feature information upon arrival at different segment samples will affect the accurate prediction of the estimated arrival time for the route sample. Therefore, by using the segment feature information upon arrival at each segment sample as label information for training the time prediction model, the time prediction model can improve the accuracy of extracting the route feature vector for the route sample and enhance the precision of the time prediction model, thereby improving the accuracy of the estimated arrival time prediction.

[0167] Step 830: Obtain the historical actual arrival time of the route sample and use the historical actual arrival time as label information.

[0168] In this step, the historical actual arrival times of route samples can be obtained from historical map data. By using the historical actual arrival times of route samples as label information for training the time prediction model, the accuracy of the estimated arrival time prediction can be improved.

[0169] It should be noted that step 830 can be executed synchronously with step 810 or with step 820 , and can be appropriately selected according to actual application conditions, which is not specifically limited here.

[0170] Step 840: Convert all road segment feature sets into a feature matrix, and input the feature matrix into a feature vector generation network for vectorization processing to obtain a first route feature vector.

[0171] In this step, the feature vector generation network can be any network structure suitable for sequence problems, such as a recurrent neural network, a convolutional neural network, or a neural network based on an attention mechanism. When using the feature vector generation network to vectorize all road section feature sets, all road section feature sets are first converted into feature matrices and then input into the feature vector generation network for vectorization. This can enable these road section feature sets to adapt to the processing process of the feature vector generation network, improve the accuracy of the feature vector generation network in vectorizing these road section feature sets, thereby improving the accuracy of the time prediction model in extracting the first route feature vector, which is beneficial for subsequent steps to obtain a more accurate estimated arrival time based on a more accurate first route feature vector prediction.

[0172] Step 850: Input the first route feature vector into the encoder for dimension conversion to obtain the first route feature latent variable and route feature variance.

[0173] In this step, the number of dimensions of the first route feature latent variable and the route feature variance is equal, and the number of dimensions of the first route feature latent variable and the route feature variance is smaller than the number of dimensions of the first route feature vector.

[0174] Step 860: Input the first route feature latent variable and the route feature variance into the decoder for vector fitting to obtain the road segment reconstruction feature vector of each road segment sample.

[0175] In this step, the number of dimensions of the segment reconstruction feature vector is equal to the number of dimensions of the first route feature vector.

[0176] Step 870: Input the first route feature latent variable and the first route feature vector into the arrival time estimation network for time prediction to obtain the estimated arrival time.

[0177] It should be noted that the first route feature latent variable is the mean of the first route feature vector. By combining the first route feature vector and the first route feature latent variable into target input parameters and inputting them into the arrival time estimation network, the arrival time estimation network can predict the estimated arrival time based on richer input parameters, thereby improving the prediction accuracy of the arrival time estimation network for the estimated arrival time.

[0178] It should be noted that step 870 may be executed synchronously with step 860 or not, and may be appropriately selected according to actual application conditions, which is not specifically limited here.

[0179] Step 880: Obtain a time prediction loss value based on the estimated arrival time and the historical actual arrival time, obtain a reconstruction loss value based on the segment reconstruction feature vector of each segment sample and the full route feature vector, and obtain a normal distribution loss value based on the first route feature latent variable and the route feature variance.

[0180] In this step, the time prediction loss value can train the time prediction model's extraction accuracy for the first route feature latent variable and the first route feature vector, as well as the prediction accuracy for the estimated arrival time. The reconstruction loss value can train the time prediction model's extraction accuracy for the section reconstruction feature vector, the first route feature latent variable and the route feature variance, and the first route feature vector of each section sample. The normal distribution loss value can train the time prediction model's extraction accuracy for the first route feature vector, the first route feature latent variable and the route feature variance. Therefore, through the joint action of the normal distribution loss value, the time prediction loss value and the reconstruction loss value, effective training of the time prediction model can be achieved, thereby improving the accuracy of the time prediction model, and further improving the time prediction model's prediction accuracy for the estimated arrival time.

[0181] Step 890: Modify the parameters of the time prediction model according to the normal distribution loss value, the time prediction loss value and the reconstruction loss value.

[0182] In this step, since the time prediction loss value, reconstruction loss value and normal distribution loss value are obtained in step 880, the time prediction loss value, reconstruction loss value and normal distribution loss value can be used to perform end-to-end backpropagation on the time prediction model, and the parameters of the feature vector generation network, encoder, decoder and arrival time estimation network in the time prediction model can be corrected, thereby realizing the training of the time prediction model.

[0183] Through the time prediction model training method including the previous steps 810 to 890, after extracting the first route feature vector of all road section feature sets, the first route feature vector is dimensionally transformed to obtain the first route feature latent variable and the route feature variance, time prediction is performed based on the first route feature vector and the first route feature latent variable to obtain the estimated arrival time, and the first route feature latent variable and the route feature variance are vector-fitted to obtain the road section reconstruction feature vector of each road section sample. At this time, the full route feature vector including the road section feature information when arriving at each road section sample is used as the label information for adjusting the road section reconstruction feature vector, which can improve the first route feature latent variable. The accuracy of variable acquisition and the accuracy of the time prediction model are enhanced. In addition, using the historical actual arrival time of the route samples as label information for adjusting the estimated arrival time can improve the accuracy of acquiring the first route feature vector and the first route feature latent variable. Therefore, when the estimated arrival time is obtained by time prediction based on the first route feature vector and the first route feature latent variable, the accuracy of the estimated arrival time can be improved. In other words, by using the historical actual arrival time of the route samples and the segment feature information when arriving at each segment sample as label information for training the time prediction model, the accuracy of the time prediction model for predicting the estimated arrival time can be improved. In addition, it can be understood that the full route feature vector used as label information extracted by manual processing is relatively accurate and rich in the dimensions it covers. If the label information extracted by manual experience can be used as supervision information to train the time prediction model, the accuracy of the time prediction model can be effectively enhanced. However, in the current solution, there is no effective way to introduce manual experience into the neural network model. However, in step 720 of this embodiment, the full route feature vector of the road segment feature set is extracted based on manual experience, and the full route feature vector is used as label information for training the time prediction model. This can not only effectively enhance the accuracy of the time prediction model, but also provide a way to intervene in model training with manual experience, thereby solving the technical defect of the current solution that cannot effectively use manual experience to train the neural network model.

[0184] Reference Figure 9 As shown, Figure 9 This is a complete flow chart of the time prediction method provided by an embodiment of the present invention. The time prediction method specifically includes the following steps 910 to 940.

[0185] Step 910: Obtain route features of multiple routes to be estimated.

[0186] In this step, the server can determine multiple estimated routes from the starting position to the terminal position based on the starting position and terminal position sent by the terminal and the map data, and determine the route characteristics of each estimated route based on the starting position, terminal position and map data.

[0187] Step 920: Input the route features of each route to be estimated into the time prediction model to obtain the estimated arrival time of each route to be estimated.

[0188] It should be noted that the time prediction model in this step is trained using the previous time prediction model training method. That is, the time prediction model in this step includes a trained feature vector generation network, an encoder, a decoder, and an arrival time estimation network. Therefore, in this step, for each route to be estimated, when inputting the route features of the route to be estimated into the time prediction model to obtain the estimated arrival time, the route features of the route to be estimated can be first vectorized by the feature vector generation network to obtain a third route feature vector, and then the third route feature vector is dimensionally transformed by the encoder to obtain a second route feature latent variable, and then the third route feature vector and the second route feature latent variable are input into the arrival time estimation network for time prediction to obtain the estimated arrival time.

[0189] Step 930: Generate recommended content based on each route to be estimated and the estimated arrival time of each route to be estimated.

[0190] In this step, since the estimated arrival time of each route to be estimated is obtained in step 920, corresponding recommended content can be generated based on each route to be estimated and its corresponding estimated arrival time, so that the recommended content can be sent to the terminal for display in subsequent steps, thereby facilitating the user to select a suitable route based on the recommended content.

[0191] Step 940: Send the recommended content to the terminal.

[0192] In this step, since the recommended content is generated in step 930, the recommended content can be sent to the terminal so that the terminal can display the recommended content, thereby facilitating the user to select a suitable route based on the recommended content. Figure 10 As shown, Figure 10This is a schematic diagram of the recommended content provided by a specific example. When a user queries the route from the starting location to the target location through the map software in the terminal, the map software in the terminal will send the starting location and target location determined by the user to the server. After the server receives the starting location and target location, the server will first determine multiple candidate routes from the starting location to the target location based on the map data, the starting location and the target location. Then, the server uses the previous time prediction method to predict the estimated arrival time of each candidate route. After the server completes the prediction of the estimated arrival time of each candidate route, the server selects the three target estimated arrival times with the best time among these estimated arrival times based on the shortest arrival time strategy, and generates recommended content based on these three target estimated arrival times and their corresponding candidate routes. Then, the server sends the recommended content to the terminal. When the terminal receives the recommended content, it displays the following: Figure 10 The schematic diagram of the recommended content shown in Figure 10 , the recommendations include the first candidate route 1001, the second candidate route 1002 and the third candidate route 1003 from the same starting point to the same target point. The estimated arrival time for the first candidate route 1001 is 44 minutes, the estimated arrival time for the second candidate route 1002 is 48 minutes, and the estimated arrival time for the third candidate route 1003 is 46 minutes. Therefore, users can choose a suitable candidate route according to their itinerary.

[0193] The following is an actual example to illustrate the application scenario of the embodiment of the present invention.

[0194] Scene 1

[0195] The time prediction method provided by the embodiment of the present invention can be applied to navigation scenarios. Specifically, a device such as a smartphone or an in-vehicle terminal responds to the driver's navigation request and sends the driver's current location and target location to the server. After the server receives the driver's current location and target location, it first determines several candidate routes based on the driver's current location and target location. Then, based on the time prediction model trained by the previous time prediction model training method, the previous time prediction method is used to predict the estimated arrival time of each candidate route. Then, based on these estimated arrival times, the target candidate route with the shortest arrival time is selected, and the target candidate route is provided to the driver through a device such as a smartphone or an in-vehicle terminal, so that the driver can navigate according to the target candidate route. In addition, after entering the navigation state, at regular intervals, the server can use the driver's current real-time location as the new starting point and use the previous time prediction method to continuously predict the estimated arrival time of the remaining distance, thereby facilitating the driver to arrange his or her itinerary reasonably.

[0196] Scene 2

[0197] The time prediction method provided by the embodiment of the present invention can also be applied to the business district recommendation scenario. Specifically, the server can randomly select any target location according to the user's current location, and then use the previous time prediction method to predict the estimated arrival time from the user's current location to each target location based on the time prediction model trained by the previous time prediction model training method. Then, based on these estimated arrival times, the isochronous reachable circles are determined from these target locations, such as a half-hour reachable circle, a one-hour reachable circle, etc., and then, the relevant content of the isochronous reachable circle (such as isochronous reachable business district information, etc.) is provided to the user through the terminal, so as to facilitate the user to understand the various business district information within his living radius.

[0198] Scene 3

[0199] The time prediction method provided by the embodiment of the present invention can also be applied to commodity delivery scenarios. Specifically, the server can use the previous time prediction method to predict the estimated arrival time of each delivery person at the customer's location based on information such as the customer's current location, the merchant's location, and the current location of each delivery person, based on the time prediction model trained by the previous time prediction model training method. Then, based on these estimated arrival times, the delivery person with the shortest arrival time is selected, and the takeaway order is assigned to the delivery person with the shortest arrival time, so as to better assign orders to the delivery person and improve the delivery efficiency of the delivery person.

[0200] Scene 4

[0201] The time prediction method provided by the embodiment of the present invention can also be applied to taxi-hailing scenarios. Specifically, the server can use the previous time prediction method to predict the estimated arrival time of each driver at the passenger's location based on the current location of the passenger and the current location of each driver, based on the time prediction model trained by the previous time prediction model training method, and then select the driver with the shortest arrival time based on these estimated arrival times, and assign the ride order to the driver with the shortest arrival time, so as to better arrange drivers to accept orders and improve passenger transport efficiency.

[0202] Scene 5

[0203] The time prediction method provided by the embodiment of the present invention can also be applied to information push scenarios. Specifically, before the user requests a travel route, the server pre-predicts the user's estimated arrival time at the target location at the corresponding travel time based on the user's current location, historical travel time, and historical travel destination, based on the time prediction model trained by the previous time prediction model training method, and uses the previous time prediction method, and pushes relevant travel recommendation information to the user in advance based on the estimated arrival time, so that the user can estimate the travel time and arrange the itinerary in advance, thereby enhancing the user's usage experience.

[0204] It will be appreciated that, although the various steps in the above-mentioned various flow charts are shown in sequence according to the indication of the arrows, these steps are not necessarily performed in sequence according to the order indicated by the arrows. Unless clearly stated in the present embodiment, the execution of these steps does not have strict order restrictions, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the above-mentioned flow charts can include multiple steps or multiple stages, and these steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of the steps or stages in other steps or other steps.

[0205] Reference Figure 11 The embodiment of the present invention further discloses a time prediction model training device. The time prediction model training device 1100 can implement the time prediction model training method of the previous embodiment. The time prediction model training device 1100 includes:

[0206] The sample acquisition unit 1101 is configured to acquire a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes the actual arrival time of the route sample and the road segment feature information when arriving at each road segment sample;

[0207] A first loss value calculation unit 1102 is configured to extract a first route feature vector from a route feature set using a time prediction model, perform dimension conversion on the first route feature vector to obtain a second route feature vector, perform time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and obtain a time prediction loss value based on the estimated arrival time and the actual arrival time;

[0208] A second loss value calculation unit 1103 is configured to perform vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtain a reconstruction loss value based on the route reconstruction feature vector and feature information of all road sections;

[0209] The parameter correction unit 1104 is used to correct the parameters of the time prediction model according to the time prediction loss value and the reconstruction loss value.

[0210] In one embodiment, the second route feature vector includes the first route feature latent variable and the route feature variance; the parameter correction unit 1104 is further configured to:

[0211] Obtaining a normally distributed loss value according to the first route feature latent variable and the route feature variance;

[0212] The parameters of the time prediction model are modified according to the normal distribution loss value, the time prediction loss value and the reconstruction loss value.

[0213] In one embodiment, the first loss value calculation unit 1102 is further configured to:

[0214] Obtain first deviation information between the estimated arrival time and the actual arrival time;

[0215] A time prediction loss value is calculated based on the first deviation information.

[0216] In one embodiment, the route reconstruction feature vector includes a road segment reconstruction feature vector of each road segment sample; the second loss value calculation unit 1103 is further configured to:

[0217] Obtaining second deviation information between the road section reconstruction feature vector and the road section feature information;

[0218] A reconstruction loss value is calculated based on the second deviation information.

[0219] In one embodiment, the time prediction model includes a feature vector generation network; the first loss value calculation unit 1102 is further configured to:

[0220] Converting the route feature set into a route feature matrix;

[0221] The route feature matrix is vectorized through a feature vector generation network to obtain the first route feature vector of the route feature set.

[0222] In one embodiment, the time prediction model includes a variational autoencoder, which includes an encoder; the first loss value calculation unit 1102 is further configured to:

[0223] The encoder in the variational autoencoder performs dimension conversion on the first route feature vector to obtain a second route feature vector, wherein the number of dimensions of the second route feature vector is smaller than the number of dimensions of the first route feature vector.

[0224] In one embodiment, the time prediction model includes a variational autoencoder, which includes a decoder; and the second loss value calculation unit 1103 is further configured to:

[0225] Vector fitting is performed on the second route feature vector through a decoder in the variational autoencoder to obtain a route reconstruction feature vector, wherein the number of dimensions of the route reconstruction feature vector is equal to the number of dimensions of the first route feature vector.

[0226] In one embodiment, the time prediction model includes an arrival time estimation network, and the second route feature vector includes a first route feature latent variable; the first loss value calculation unit 1102 is further configured to:

[0227] Combining the first route feature vector and the first route feature latent variable into a target input parameter;

[0228] The arrival time estimation network is used to predict the time of the target input parameters and obtain the estimated arrival time.

[0229] It should be noted that since the time prediction model training device 1100 of this embodiment can implement the time prediction model training method described in the previous embodiment, the time prediction model training device 1100 of this embodiment and the time prediction model training method described in the previous embodiment have the same technical principles and the same beneficial effects. In order to avoid repetition, they will not be repeated here.

[0230] Reference Figure 12 The embodiment of the present invention further discloses a time prediction device. The time prediction device 1200 can implement the time prediction method of the previous embodiment. The time prediction device 1200 includes:

[0231] The route acquisition unit 1201 is used to acquire route features of the route to be estimated;

[0232] The time prediction unit 1202 is used to input the route characteristics into the time prediction model to obtain the estimated arrival time;

[0233] The time prediction model is obtained by training using the time prediction model training device 1100 as described above.

[0234] In one embodiment, the route to be estimated includes at least one road segment, the route features include road segment features of each road segment, and the time prediction model includes a feature vector generation network, a variational autoencoder, and an arrival time estimation network;

[0235] The time prediction unit 1202 is further configured to:

[0236] All road segment features are vectorized through a feature vector generation network to obtain a third route feature vector;

[0237] The third route feature vector is transformed into a dimension by a variational autoencoder to obtain the second route feature latent variable;

[0238] The third route feature vector and the second route feature latent variable are input into the arrival time estimation network for time prediction to obtain the estimated arrival time.

[0239] In one embodiment, the time prediction device 1200 further includes:

[0240] A generating unit, configured to generate recommended content based on the estimated arrival time;

[0241] The sending unit is configured to send the recommended content to the terminal.

[0242] It should be noted that since the time prediction device 1200 of this embodiment can implement the time prediction method described in the previous embodiment, the time prediction device 1200 of this embodiment and the time prediction method described in the previous embodiment have the same technical principles and the same beneficial effects. In order to avoid repetition, they will not be repeated here.

[0243] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, i.e., they may be located in one place or distributed across multiple network units. Some or all of the modules may be selected based on actual needs to achieve the objectives of this embodiment.

[0244] Reference Figure 13 The embodiment of the present invention further discloses an electronic device, the electronic device 1300 including:

[0245] at least one processor 1301;

[0246] At least one memory 1302, configured to store at least one program;

[0247] When at least one program is executed by at least one processor 1301, the time prediction model training method described above is implemented, or the time prediction method described above is implemented.

[0248] An embodiment of the present invention also discloses a computer-readable storage medium, which stores a program executable by a processor. When the program executable by the processor is executed by the processor, it is used to implement the time prediction model training method described above, or to implement the time prediction method described above.

[0249] An embodiment of the present invention also discloses a computer program product, including a computer program or computer instructions, which are stored in a computer-readable storage medium. A processor of a computer device reads the computer program or computer instructions from the computer-readable storage medium, and the processor executes the computer program or computer instructions, so that the computer device executes the time prediction model training method as described above, or executes the time prediction method as described above.

[0250] The terms "first," "second," "third," "fourth," and the like (if any) in the description of the present invention and the accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a particular order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of the present invention described herein can, for example, be implemented in orders other than those illustrated or described herein. In addition, the terms "including" and "having," and any variations thereof, are intended to cover non-exclusive inclusions, e.g., a process, method, system, product, or apparatus comprising a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0251] It should be understood that in the present invention, "at least one (item)" refers to one or more, and "plurality" refers to two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can represent: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following items" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

[0252] In the several embodiments provided by the present invention, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0253] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0254] In addition, the functional units in the various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0255] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, and other media that can store program code.

[0256] The step numbers in the above method embodiment are only provided for the convenience of explanation and do not limit the order of the steps. The execution order of each step in the embodiment can be adaptively adjusted according to the understanding of those skilled in the art.

Claims

1. A time prediction model training method, characterized in that: The following steps are involved: Obtaining a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes an actual arrival time of the route sample and road segment feature information upon arrival at each of the road segment samples; extracting a first route feature vector from the route feature set using a time prediction model, performing dimension conversion on the first route feature vector to obtain a second route feature vector, performing time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and obtaining a time prediction loss value based on the estimated arrival time and the actual arrival time; Performing vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtaining a reconstruction loss value based on the route reconstruction feature vector and all the road segment feature information; The parameters of the time prediction model are modified according to the time prediction loss value and the reconstruction loss value.

2. The time prediction model training method according to claim 1, characterized in that: The second route feature vector includes the first route feature latent variable and the route feature variance; The modifying of the parameters of the time prediction model according to the time prediction loss value and the reconstruction loss value includes: Obtaining a normal distribution loss value according to the first route characteristic latent variable and the route characteristic variance; The parameters of the time prediction model are modified according to the normal distribution loss value, the time prediction loss value and the reconstruction loss value.

3. The time prediction model training method according to claim 1, characterized in that: The obtaining of the time prediction loss value according to the estimated arrival time and the actual arrival time includes: Acquire first deviation information between the estimated arrival time and the actual arrival time; A time prediction loss value is calculated based on the first deviation information.

4. The time prediction model training method according to claim 1, characterized in that: The route reconstruction feature vector includes a road segment reconstruction feature vector of each road segment sample; and obtaining a reconstruction loss value based on the route reconstruction feature vector and all the road segment feature information includes: Acquire second deviation information between the road section reconstruction feature vector and the road section feature information; A reconstruction loss value is calculated based on the second deviation information.

5. The time prediction model training method according to claim 1, characterized in that: The time prediction model includes a feature vector generation network; The extracting the first route feature vector of the route feature set by using a time prediction model includes: Converting the route feature set into a route feature matrix; The route feature matrix is vectorized by the feature vector generation network to obtain a first route feature vector of the route feature set.

6. The time prediction model training method according to claim 1, characterized in that: The time prediction model includes a variational autoencoder, and the variational autoencoder includes an encoder; the dimension conversion of the first route feature vector to obtain the second route feature vector includes: The encoder in the variational autoencoder performs dimension conversion on the first route feature vector to obtain a second route feature vector, wherein the number of dimensions of the second route feature vector is smaller than the number of dimensions of the first route feature vector.

7. The time prediction model training method according to claim 1, characterized in that: The time prediction model includes a variational autoencoder, and the variational autoencoder includes a decoder; performing vector fitting on the second route feature vector to obtain a route reconstruction feature vector includes: Performing vector fitting on the second route feature vector through the decoder in the variational autoencoder to obtain a route reconstruction feature vector, wherein the number of dimensions of the route reconstruction feature vector is equal to the number of dimensions of the first route feature vector.

8. The time prediction model training method according to claim 1, characterized in that: The time prediction model includes an arrival time estimation network, and the second route feature vector includes a first route feature latent variable; The performing time prediction according to the first route feature vector and the second route feature vector to obtain an estimated arrival time includes: combining the first route feature vector and the first route feature latent variable into a target input parameter; The arrival time estimation network performs time prediction on the target input parameters to obtain an estimated arrival time.

9. A time prediction method, characterized in that: The following steps are involved: Obtain route characteristics of the route to be estimated; Inputting the route characteristics into a time prediction model to obtain an estimated arrival time; Wherein, the time prediction model is obtained by training the time prediction model training method described in any one of claims 1 to 8.

10. The time prediction method according to claim 9, characterized in that: The route to be estimated includes at least one road section, the route features include road section features of each of the road sections, and the time prediction model includes a feature vector generation network, a variational autoencoder, and an arrival time estimation network; Inputting the route features into a time prediction model to obtain an estimated arrival time includes: Performing vectorization processing on all the road segment features through the feature vector generation network to obtain a third route feature vector; Performing dimension conversion on the third route feature vector by the variational autoencoder to obtain a second route feature latent variable; The third route feature vector and the second route feature latent variable are input into the arrival time estimation network for time prediction to obtain an estimated arrival time.

11. The time prediction method according to claim 9 or 10, characterized in that: The time prediction method further includes: generating recommended content based on the estimated arrival time; The recommended content is sent to the terminal.

12. A time prediction model training device, characterized in that: include: A sample acquisition unit, configured to acquire a route feature set and label information of a route sample, wherein the route sample includes at least one road segment sample, and the label information includes the actual arrival time of the route sample and the road segment feature information upon arrival at each of the road segment samples; a first loss value calculation unit, configured to extract a first route feature vector from the route feature set using a time prediction model, perform dimension conversion on the first route feature vector to obtain a second route feature vector, perform time prediction based on the first route feature vector and the second route feature vector to obtain an estimated arrival time, and obtain a time prediction loss value based on the estimated arrival time and the actual arrival time; a second loss value calculation unit, configured to perform vector fitting on the second route feature vector to obtain a route reconstruction feature vector, and obtain a reconstruction loss value based on the route reconstruction feature vector and all the road segment feature information; A parameter correction unit is used to correct the parameters of the time prediction model according to the time prediction loss value and the reconstruction loss value.

13. An electronic device, characterized in that: include: at least one processor; at least one memory for storing at least one program; When at least one of the programs is executed by at least one of the processors, the time prediction model training method as described in any one of claims 1 to 8 is implemented, or the time prediction method as described in any one of claims 9 to 11 is implemented.

14. A computer-readable storage medium, characterized in that A processor-executable program is stored therein, and when the processor-executable program is executed by the processor, it is used to implement the time prediction model training method as described in any one of claims 1 to 8, or to implement the time prediction method as described in any one of claims 9 to 11.

15. A computer program product comprising a computer program or computer instructions, characterized in that The computer program or the computer instructions are stored in a computer-readable storage medium, the processor of the computer device reads the computer program or the computer instructions from the computer-readable storage medium, and the processor executes the computer program or the computer instructions, so that the computer device executes the time prediction model training method as described in any one of claims 1 to 8, or executes the time prediction method as described in any one of claims 9 to 11.

Citation Information

Patent Citations

  • Method and device for estimating arrival time

    CN111582559A

  • Method and device for determining estimated arrival time, equipment and storage medium

    CN113902427A