Order distribution method, device and electronic equipment
By establishing a scenario model and probability matching algorithm based on historical orders, intelligently allocate orders, solve the "desert city" problem in logistics, improve operational efficiency and reduce economic losses.
Patent Information
- Application Number
- CN202011493172.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-16
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2040-12-16
AI Technical Summary
It is difficult for existing logistics technology to avoid the formation of "desert cities" in truck freight at the overall level. As a result, vehicles cannot find connecting orders or have to wait when entering "desert cities", causing economic losses.
By obtaining the order and vehicle information to be matched on the day, a scenario model is established based on historical shipping order information, the probability model is used to calculate the expected probability of each scenario, and vehicles and orders are matched according to the expected value to achieve intelligent allocation of orders to reduce vehicle entry. Desert City' probability.
It effectively reduces the probability of vehicles entering the "desert city", avoids economic losses caused by waiting or empty driving, and improves the overall efficiency of logistics operations.
Smart Images

Figure CN114638565B
Abstract
Description
Technical Field
[0001] The present application relates to the field of logistics technology, and more specifically, to an order distribution method, device and electronic equipment. Background Art
[0002] At present, in the field of logistics, especially in the field of truck freight, there is a concept of "desert city", which has a great impact on freight. "Desert city" can be simply understood as a city where the incoming volume is far greater than the outgoing volume. If a vehicle delivers goods to a "desert city", it will not only fail to make a profit, but also incur a loss. Moreover, "desert city" is not fixed. It is very likely that some cities will become "desert cities" or disappear due to changes in seasonal climate and other factors. If a vehicle delivers goods to a "desert city", it is very likely that the vehicle will have to leave the city empty-handed because it has not found a subsequent connection order in the city. In this case, the greater the cost of empty driving, the greater the loss of the carrier. In addition, even if some vehicles find a connection order in the city, the delivery time of the connection order is a few days later, which causes the vehicle to wait in place. During this period, the suspension of the vehicle will also bring certain losses.
[0003] At present, in the process of allocating orders for vehicles, we can only consider the perspective of a single vehicle and prevent the vehicle from entering the "desert city". We cannot consider how to prevent vehicles from entering the desert city as a whole. Therefore, how to avoid the occurrence of this problem has become an urgent problem to be solved. Summary of the invention
[0004] The main purpose of this application is to provide an order allocation method and device to solve the problem of how to prevent vehicles from entering desert cities as a whole.
[0005] In order to achieve the above-mentioned purpose, according to the first aspect of the present application, an order allocation method is provided, including: obtaining at least one order information to be matched on the same day and at least one vehicle information to be matched; obtaining the shipping order information of M regions in the past N days, and establishing N scenarios according to the shipping order information of each day in the N days, each scenario including the shipping order information of the M regions in one day, wherein M and N are positive integers greater than zero; determining the expected probability of each scenario in the N scenarios occurring on a preset date according to a probability model, wherein the probability model is based on the shipping order information of the M regions in the past N days. A model is established based on the information to determine the probability of occurrence of N historical scenarios on a preset date; using constraints, at least one to-be-matched vehicle information, at least one to-be-matched order information on the day and the shipment order information in N scenarios are matched, and all matching schemes are traversed; the expected value of each matching scheme is calculated, and the expected value is the sum of the expected benefits of all to-be-matched vehicles in the matching scheme, where the expected benefit of the to-be-matched vehicle = the expectation on the day + the subsequent expectation × the expected probability of the scenario where the shipment order is located; the order allocation result is obtained according to the matching relationship between the to-be-matched vehicle and the to-be-allocated order in the matching scheme with the largest expected value.
[0006] Optionally, the method for calculating the expectation for the day includes: obtaining the price of the order to be matched on the day and the idle running cost of the vehicle for the first order, wherein the idle running cost of the vehicle for the first order corresponds to the order to be matched on the day; determining the expectation for the day based on the difference between the price of the order to be matched on the day and the idle running cost of the vehicle for the first order; the method for calculating the subsequent expectation includes: obtaining the price of the shipping order and the idle running cost of the vehicle for the second order, wherein the idle running cost of the vehicle for the second order corresponds to the shipping order; determining the subsequent expectation based on the difference between the shipping order price and the idle running cost of the second order.
[0007] Optionally, before determining the expected probability of each of the N scenarios occurring on a preset date according to the probability model, the method further includes: establishing a probability model according to the distance relationship between each scenario and the preset date in the time dimension and / or cycle dimension.
[0008] Optionally, in the time dimension, the expected probability of the scene occurring is inversely correlated with the number of days between the actual occurrence date of the scene and the preset date.
[0009] Optionally, under the period dimension, the expected probability of the scenario occurring is positively correlated with the number of days between the actual occurrence date of the scenario within the period and the preset date.
[0010] Optionally, the constraint conditions include any one of the following items or a combination thereof: each of the orders to be matched on the same day and / or the shipping orders is matched with at most one vehicle to be matched in one matching scheme; each vehicle to be matched is matched with at most any two of the orders to be matched on the same day and / or the shipping orders in one matching scheme; when the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the order to be matched on the same day, the vehicle to be matched cannot be matched with the order to be matched on the same day; when the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the shipping order, the vehicle to be matched cannot be matched with the shipping order.
[0011] Optionally, determining the expected probability of each scene occurring on a preset date according to the probability model includes: determining the occurrence probabilities of the N scenes on the preset date according to the probability model; and regularizing the N occurrence probabilities to obtain expected probabilities of the N scenes.
[0012] In order to achieve the above-mentioned purpose, according to the second aspect of the present application, an order distribution device is provided, the device comprising: a to-be-matched information acquisition module, used to acquire at least one to-be-matched order information of the day and at least one to-be-matched vehicle information; a scenario establishment module, used to acquire the shipment order information of M regions in N days in history, and establish N scenarios according to the shipment order information of each day in the N days, each scenario including the shipment order information of the M regions in one day, wherein M and N are positive integers greater than zero; an expected probability calculation module, used to determine the expected probability of each of the N scenarios occurring on a preset date according to a probability model, the probability model being a probability model of the shipment order information of the M regions in N days in history. A model is established based on the shipment order information to determine the probability of occurrence of N historical scenarios on a preset date; an order matching module is used to match at least one to-be-matched vehicle information, at least one to-be-matched order information on the same day and the shipment order information in N scenarios by using constraints, and traverse all matching schemes; an expected value calculation module is used to calculate the expected value of each matching scheme, and the expected value is the sum of the expected benefits of all to-be-matched vehicles in the matching scheme, where the expected benefit of the to-be-matched vehicle = the expectation on the same day + the subsequent expectation × the expected probability of the scenario where the shipment order is located; an order allocation module is used to obtain the order allocation result according to the matching relationship between the to-be-matched vehicle and the to-be-allocated order in the matching scheme with the largest expected value.
[0013] In order to achieve the above-mentioned purpose, according to the third aspect of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the order allocation method described in any one of the above-mentioned first aspects.
[0014] In order to achieve the above-mentioned purpose, according to the fourth aspect of the present application, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor executes the order allocation method described in any one of the above-mentioned first aspects.
[0015] In the embodiment of the present application, a corresponding scenario can be established based on historical order information, and multiple order matching schemes can be established for all vehicles using the orders to be matched on the day and the virtual orders in the scenario. After that, the expected revenue of each vehicle is calculated based on the specific conditions of the vehicle in each order matching scheme, and the expected value of each order matching scheme is obtained, and the order matching scheme with the largest expected value is used to allocate the actual generated orders to the vehicle. This method can reduce the probability of vehicles entering desert cities as a whole, and avoid too many vehicles entering the same place or area, causing the emergence of desert cities. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings constituting a part of this application are used to provide a further understanding of this application, so that other features, purposes and advantages of this application become more obvious. The schematic embodiment drawings and their descriptions of this application are used to explain this application and do not constitute an improper limitation on this application. In the drawings:
[0017] Figure 1 is a flow chart of an order allocation method provided according to an embodiment of the present application;
[0018] Figure 2 It is a schematic diagram of a probability model established according to an embodiment of the present application according to the distance relationship between each scene and a preset date in the time dimension;
[0019] Figure 3 It is a schematic diagram of a probability model established according to an embodiment of the present application according to the distance relationship between each scene and a preset date in a period dimension;
[0020] Figure 4 It is a schematic diagram of a probability model established according to an embodiment of the present application according to the relationship between each scene and a preset date in terms of time dimension and cycle dimension;
[0021] Figure 5 It is a block diagram of a composition of an order distribution device provided according to an embodiment of the present application;
[0022] Figure 6 is a schematic diagram of an electronic device provided according to an embodiment of the present application. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present application described here. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0025] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0026] According to an embodiment of the present application, an order allocation method is provided, such as Figure 1 As shown, the method comprises the following steps:
[0027] S101. Obtain at least one order information to be matched on the same day and at least one vehicle information to be matched. As an exemplary embodiment, the order information to be matched on the same day and the vehicle information to be matched can be directly obtained from a preset order distribution system or storage device, wherein the order information to be matched on the same day and the vehicle information to be matched include various information required to complete subsequent matching, such as the loading place, loading time, unloading place, unloading time, order price and other information of the order to be matched on the same day; another example is the vehicle positioning information, vehicle model and other information of the vehicle to be matched. Optionally, the order to be matched on the same day can be an order with a loading time of the same day.
[0028] S102. Obtain the shipping order information of M regions in N days in history, and establish N scenarios according to the shipping order information of each day in N days. Each scenario includes the shipping order information of the M regions in one day, where M and N are positive integers greater than zero. As an exemplary embodiment, a region refers to an artificially demarcated area such as a city or an administrative area, and the M regions can be selected from all cities or administrative areas across the country, or multiple cities or administrative areas selected by humans, such as multiple cities or administrative areas with historical shipping order data currently available.
[0029] After determining the M regions, the historical shipment order information of these regions for N days can be obtained from the order distribution system or storage device. In this embodiment, the shipment order information can include various relevant information such as shipping price, loading place, unloading place, loading time, and delivery time, so that subsequent matching work can be completed; as for which historical days are selected as the N days in history, there is no limitation in this embodiment, and all historical data can be selected, or part of the continuous or discontinuous historical data can be selected, which can complete the subsequent prediction work; relatively speaking, the more historical data used, that is, the larger N is, the more guaranteed the final result is.
[0030] Later, N scenarios are established according to the shipping orders of each day in N days, and each scenario contains the shipping order information of M regions in one day.
[0031] For example, suppose the current date is August 25, 2020.
[0032] Then the historical shipment order data for N days before August 25, 2020 can be obtained. For the convenience of explanation, only Jiuquan City and Jinchang City are taken as M regions (i.e. 2 regions), and only the historical data for three days from August 20 to 22, 2020 is assumed for explanation.
[0033] Three scenarios are created based on the shipping orders for each of the three days;
[0034] For example, on August 20, 2020, Jiuquan City has a shipment order A, but Jinchang City has no shipment order. Then the corresponding scenario can be established as follows:
[0035] Scenario 1 (the scenario corresponding to August 20, 2020):
[0036] Jiuquan City, Order A: from Jiuquan City to Dunhuang City, the order price is 1,000 yuan;
[0037] It should be noted that the scenario can be created in the form of a list. In addition, the order information in the above scenario is only for the convenience of explanation. In practice, more information can be included when creating the scenario, even all the information of the shipping order.
[0038] Here is information for two other scenarios:
[0039] On August 21, 2020, there is one shipment order in Jiuquan City and two shipment orders in Jinchang City. Then the corresponding scenario can be established as follows:
[0040] Scenario 2 (the scenario corresponding to August 21, 2020):
[0041] Jiuquan City, Order B: From Jiuquan City to Jiayuguan City, the order price is 100 yuan;
[0042] Jinchang City, Order C: From Jinchang City to Wuwei City, the order price is 200 yuan;
[0043] Jinchang City, Order D: From Jinchang City to Wuwei City, the order price is 200 yuan;
[0044] On August 22, 2020, Jiuquan City has two shipment orders, and Jinchang City has no shipment orders. Then the corresponding scenario can be established as follows:
[0045] Scenario 3 (the scenario corresponding to August 22, 2020):
[0046] Jiuquan City, Order E: from Jiuquan City to Jiayuguan City, the order price is 100 yuan;
[0047] Jiuquan City, Order F: from Jiuquan City to Jiayuguan City, the order price is 100 yuan;
[0048] The above example establishes three scenarios based on the shipment orders for each of the three days from August 20 to 22, 2020. Each scenario contains the shipment order information for the two cities of Jiuquan and Jinchang within one day.
[0049] S103. Determine the expected probability of each of the N scenarios occurring on a preset date according to a probability model. The probability model is a model established based on N days of historical shipping order information of M regions for determining the probability of occurrence of N historical scenarios on a preset date.
[0050] Since orders of the same route and the same price may appear repeatedly, and the scenario not only contains various information of a single order, but also contains the relationship between each order, the scenario is used as the basis here to establish a probability model using the relationship between the date corresponding to the scenario and the preset date. After that, the probability of the scene can be obtained by inputting the probability model using the date or time corresponding to the scenario. Probability models that already exist in the prior art, such as uniform distribution probability models, can also be directly used here. The preset date in this solution is the day after the current day, that is, tomorrow.
[0051] After obtaining the occurrence probability of each of the N scenarios on the preset date, the N occurrence probabilities can be regularized to obtain the expected probabilities of each of the N scenarios, so that the sum of the expected probabilities of the N scenarios can be guaranteed to be 1.
[0052] Assume that the probability of scene 1 is 0.07, the probability of scene 2 is 0.23, and the probability of scene 3 is 0.6. Then after regularization, the expected probability of scene 1 is 0.078, the expected probability of scene 2 is 0.256, and the expected probability of scene 3 is 0.666.
[0053] S104. Using the constraint conditions, at least one vehicle information to be matched, at least one order information to be matched on the same day, and the shipping order information in N scenarios are matched, and all matching schemes are traversed. As an exemplary embodiment, the so-called constraint conditions can be conditions that prevent logical errors from occurring in the matching process. This ensures that the matching of the vehicle to be matched, the order to be matched on the same day, and the orders in N scenarios can be matched normally. As an optional embodiment, the constraint conditions can be preset in advance, and the specific constraint conditions can include any one or any combination of the following conditions:
[0054] Each order to be matched and / or shipping order of the day can be matched with at most one vehicle to be matched in one matching solution;
[0055] Each vehicle to be matched can be matched with at most any two of the orders to be matched and / or the delivery orders of the day in a matching solution;
[0056] If the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the order to be matched on the same day, the vehicle to be matched cannot be matched with the order to be matched on the same day;
[0057] When the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the shipment order, the vehicle to be matched cannot be matched with the shipment order; it should be noted that during the matching process, the loading time of the shipment order is the time point corresponding to the preset date. For example, since the shipment order was originally a historical order, its historical loading time cannot be used directly and needs to be adjusted to the corresponding time point of the preset date; such as the historical loading time of the shipment order is 10:00 on January 20, 2020, assuming the preset date is July 16, 2020, then the loading time of the shipment order is 10:00 on July 16, 2020.
[0058] Since there are many descriptions and methods of using constraints in the prior art of order allocation, for example, how to use the order loading time and the current vehicle location information to determine whether the vehicle can arrive at the order loading place before the order loading time, or use the vehicle's current order loading time and the vehicle's previous order unloading place and unloading completion time to determine whether the vehicle can arrive at the current order loading place before the current order loading time, etc. In addition, the constraints in this embodiment can directly use the prior art, and will not be repeated in this embodiment.
[0059] Since the vehicles to be matched, the orders to be matched on the day, the orders in N scenarios, and the various information required for completing their matching have been obtained, the vehicles can be matched with the orders to be matched on the day and / or the orders in N scenarios.
[0060] Assume that
[0061] There are 2 vehicles to be matched, vehicle 1 and vehicle 2;
[0062] There are 2 orders to be matched on that day, Order 1 and Order 2;
[0063] There are 6 shipping orders in N scenarios, from order A to order F;
[0064] As shown in the following table
[0065]
[0066] During the matching process, any matching method is acceptable as long as it does not violate the constraints, until all vehicles to be matched are matched and a matching solution is obtained.
[0067] For example, first select a vehicle from the vehicles that have not yet been matched, such as Vehicle 1, then select an order according to the constraints, such as Order 1, and then select an order according to the constraints, such as Order A. Later, no order can be selected according to the constraints. At this point, Vehicle 1-Order 1-Order A forms a matching relationship (in reality, according to the matching results, Vehicle 1 can complete Order A after completing Order 1 in the later stage).
[0068] Then select one from the vehicles that have not been matched yet. Since there is only one vehicle 2 left, only this vehicle can be selected (if there are other vehicles, they can be selected randomly). Then select an order according to the constraints, such as Order 2. Then select another order according to the constraints, such as Order B. No more orders can be selected according to the constraints. So at this point, a matching relationship is formed between Vehicle 2-Order 2-Order B.
[0069] At this point, since there are no suitable vehicles to be matched, a matching plan can be formed, which can be called Plan 1. There are two matching relationships in the plan, vehicle 1-order 1-order A, vehicle 2-order 2-order B.
[0070] After that, you can repeat the above steps and get;
[0071] Plan 2: There are two matching results in the plan: vehicle 1-order 1-order A, and vehicle 2-order 2-order C.
[0072] Plan 3, there are two matching results in the plan, vehicle 1-order 1-order A, vehicle 2-order D (it should be noted that the matching result of vehicle 2-order D is acceptable as long as it does not violate the constraints, even if the vehicle does not match any order, as long as it does not violate the constraints).
[0073] Plan 4: There are two matching results in the plan, vehicle 1-order D, vehicle 2-order C.
[0074] Plan 5, ...
[0075] Until all matching solutions are traversed, that is, all relationships or combinations that can be matched.
[0076] It should be noted that there are many ways and methods in the prior art for matching vehicles and orders, and even for matching vehicles, orders and subsequent orders. There are also many methods for traversing these relationships or combinations, and even for traversing all solutions. If you want to speed up the process of such matching and traversal, you can also use existing methods or algorithms to achieve it, so I will not introduce them in detail here.
[0077] S105. Calculate the expected value of each matching solution, where the expected value is the sum of the expected benefits of all vehicles to be matched in the matching solution, where the expected benefit of the vehicle to be matched = the expectation for the day + the expectation for the subsequent period × the expected probability of the scenario where the delivery order is located.
[0078] Since multiple matching schemes have been obtained before, and the matching relationship between vehicles and orders in each matching scheme has been determined, the expected profit of each vehicle to be matched can be calculated based on the matching relationship in the scheme, and then the expected value of the scheme can be obtained.
[0079] Here, the expected revenue of a single to-be-matched vehicle = the expectation for the day + the expectation for the subsequent times × the expected probability of the scenario in which the delivery order is located. Among them, the expectation for the day = the price of the to-be-matched order for the day - the cost of the vehicle's first empty run, and the expectation for the subsequent times = the price of the delivery order - the cost of the vehicle's second empty run.
[0080] That is, the calculation method of the expectation for the day includes:
[0081] Get the price of the order to be matched on the day and the empty running cost of the first order received by the vehicle. The empty running cost of the first order received by the vehicle corresponds to the order to be matched on the day;
[0082] Determine the expectation for the day based on the difference between the price of the order to be matched on the day and the empty driving cost of the vehicle for the first order received;
[0083] The calculation method of subsequent expectations includes:
[0084] Obtain the shipping order price and the second order idle running cost of the vehicle, wherein the second order idle running cost of the vehicle corresponds to the shipping order;
[0085] The subsequent expectation is determined based on the difference between the shipping order price and the vehicle's second order idle driving cost.
[0086] The following is an example, and here the above scheme 1 is used for explanation.
[0087] In solution 1, the two matching relationships are vehicle 1-order 1-order A; vehicle 2-order 2-order B;
[0088] Here we first talk about the expected return of vehicle 1;
[0089] Since vehicle 1 can complete order 1 before completing order A, the daily expectation of vehicle 1 when completing order 1 can be calculated here;
[0090] Expected price for the day = the price of the order to be matched on the day - the cost of the vehicle running idle for the first order received;
[0091] The price of the order to be matched on that day is the order price of Order 1; assuming the price of Order 1 is 2,000 yuan, then the price of the order to be matched on that day is 2,000.
[0092] The cost of the vehicle's first idle driving when accepting an order is the cost incurred by the vehicle when it is idle when accepting an order. Since vehicle 1 is to accept order 1 here, it is the cost incurred by vehicle 1 when it is idle when accepting order 1. For example, the loading location of order 1 is city A, and the current city of vehicle 1 is city B, then the cost of the vehicle's first idle driving when accepting an order can be the cost incurred by vehicle 1 when it is idle from city B to city A. If the current location of the vehicle is the same as the loading location of the order, then the cost of the vehicle's first idle driving when accepting an order is 0. If it is assumed here that the current location of vehicle 1 is the same as the loading location of order 1, then the cost of the vehicle's first idle driving when accepting an order is 0.
[0093] Therefore, the expectation for the day = the price of the order to be matched on the day - the idle driving cost of the vehicle for the first order = 2000-0 = 2000.
[0094] It should be noted that the loading place of the order to be matched on that day is known, because the information of the order to be matched on that day has been obtained in the initial step, so it can be directly obtained from the information of the order to be matched on that day; similarly, the current location information of the vehicle to be matched is also known, because the information of the vehicle to be matched has been obtained in the initial step, so it can be directly obtained from the information of the vehicle to be matched;
[0095] In addition, there are many existing methods for calculating the cost of a vehicle running idle while accepting orders, and this is just an example.
[0096] Next, we will introduce the follow-up expectations, which are: the follow-up expectations = the shipping order price - the vehicle's second order idle driving cost;
[0097] Let’s continue to explain the matching relationship between vehicle 1-order 1-order A in solution 1. Here, the shipping order price is the order price of order A; assuming that the price of order A is 1,000 yuan, then the shipping order price here is 1,000.
[0098] The second idle driving cost of the vehicle is also the cost incurred by the vehicle when it accepts an order due to idle driving. However, since vehicle 1 is to accept order A, it is the cost incurred by vehicle 1 when it accepts order A due to idle driving. It should be noted here that vehicle 1 needs to complete order 1 before accepting order A, so the idle driving cost of the vehicle is the cost incurred when it runs idle from the unloading place of order 1 to the loading place of order A; if the unloading place of order 1 and the loading place of order A are at the same place, there is no need for the vehicle to run empty to accept order A, so the idle driving cost of the vehicle is 0.
[0099] If we assume here that the cost of the vehicle running idle when accepting an order is 400 yuan, then the subsequent expectation = shipping order price - the cost of the vehicle running idle for the second order = 1000-400 = 600.
[0100] Next, the expected probability of the scenario in which the shipping order is located;
[0101] Since the expected probabilities of N scenarios have been obtained before, they can be used directly here. The above example is used to illustrate. Three scenarios are provided in the above example, scenario 1, scenario 2 and scenario 3.
[0102] The expected probability of scenario 1 is 0.078. Scenario 1 includes order A, so the expected probability of the scenario where order A is shipped is 0.078.
[0103] Similarly,
[0104] The expected probability of scenario 2 is 0.256. Scenario 2 includes orders B, C, and D. Then the expected probability of the scenarios where the shipping orders of orders B, C, and D are located is 0.256.
[0105] The expected probability of scenario 3 is 0.666. Scenario 3 includes orders E and F. Therefore, the expected probability of the scenarios where the shipping orders of orders E and F are located is 0.666.
[0106] As shown in the following table
[0107]
[0108] After obtaining the above data, the expected profit of vehicle 1 = the expectation for the day + the subsequent expectation × the expected probability of the scenario in which the delivery order is located = 2000 + 600 × 0.078 = 2046.8.
[0109] In solution 1, the expected value of vehicle 2 can be calculated based on the second matching relationship, vehicle 2-order 2-order B, and its calculation process can also refer to the above method;
[0110] Assuming that the price of Order 2 is 1,500 yuan, and the loading location of Order 2 is not the same as the current location of Vehicle 2, then assuming that the first idle driving cost of Vehicle 2 to accept Order 2 is 500 yuan, then the daily expectation of Vehicle 2 in Plan 1 = 1,500-500 = 1,000.
[0111] Assuming that the unloading place of Order 2 and the loading place of Order B are at the same place, and assuming that the order price of Order B is 100 yuan, then the idle driving cost of Vehicle 2 for the second order of Order B is 0, then the subsequent expectation of Vehicle 2 in Plan 1 = 100-0 = 100.
[0112] After obtaining the above data, the expected profit of vehicle 2 = the expectation for the day + the subsequent expectation × the expected probability of the scenario in which the delivery order is located = 1000 + 100 × 0.256 = 1025.6.
[0113] The final expected value of plan 1 = the expected return of vehicle 1 + the expected return of vehicle 2 = 2046.8 + 1025.6 = 3072.4.
[0114] Similarly, the expected values of other subsequent solutions can also be obtained.
[0115] It should be noted here that due to different matching relationships, the current and subsequent expectations of the to-be-matched vehicle will change, and may even be negative, that is, the order price is not as high as the cost of the vehicle driving idle to receive orders. In addition, it is allowed for the to-be-matched vehicle to not match any order in the solution, because as long as it is logically allowed and does not violate the constraints, the matching relationship is acceptable. Similarly, it is also possible for the to-be-matched vehicle to not match the to-be-assigned order but directly match the order in the scenario.
[0116] S106. Obtain the order allocation result based on the matching relationship between the vehicles to be matched and the orders to be allocated in the matching solution with the largest expected value.
[0117] In this embodiment, the corresponding scenario can be established based on the historical order information, and multiple order matching schemes can be established for all vehicles using the orders to be matched on the day and the virtual orders in the scenario. After that, the expected revenue of each vehicle is calculated based on the specific conditions of the vehicle in each order matching scheme, and the expected value of each order matching scheme is obtained, and the order matching scheme with the largest expected value is used to allocate the actual generated orders to the vehicle. This method can reduce the probability of vehicles entering the desert city as a whole, and avoid too many vehicles entering the same place or area, causing the emergence of a desert city.
[0118] Since the expected values of multiple matching schemes have been obtained before, we only need to select the matching scheme with the largest expected value, and use the matching relationship between the to-be-matched vehicles in this matching scheme and the to-be-matched orders of the day as the actual order allocation result. After that, we only need to send the to-be-matched orders of the day to the drivers or carriers of the to-be-matched vehicles that match them according to this result. The drivers or carriers can then execute the to-be-matched orders of the day that are assigned to them according to the information received.
[0119] For example, Plan 1 is the matching plan with the largest expected value among all plans. The matching relationships in Plan 1 are Vehicle 1-Order 1-Order A, and Vehicle 2-Order 2-Order B. Then Order 1 can be assigned to Vehicle 1, and Order 2 can be assigned to Vehicle 2. Here we get the final order allocation result.
[0120] It should be noted here that the delivery orders in the scenario are generated based on historical order information and are virtual. Their role is to assist in the allocation of orders to be allocated based on historical situations, and thus to consider the overall situation, minimize the number of vehicles entering desert cities, and avoid too many vehicles entering the same place or area, causing the emergence of desert cities.
[0121] This embodiment provides a detailed description of the establishment of the model.
[0122] First of all, it should be noted that the model is obtained before the expected value of the matching solution is calculated, but its establishment is not limited to being performed before or after a certain step before the expected value of the matching solution is calculated; the probability model can also be established in advance. In addition, the model can also be established separately in an independent system or device, and then directly used by the system through acquisition.
[0123] As an exemplary embodiment, the method for establishing the model may be: establishing a probability model according to the distance between each scene and the preset date in the time dimension; or establishing a probability model according to the distance between each scene and the preset date in the period dimension; or establishing a probability model according to the distance between each scene and the preset date in the time dimension and the period dimension. Each case is described below:
[0124] 1. According to the relationship between each scene and the preset date in the time dimension, a probability model is established, and the occurrence probability of N scenes is obtained according to the probability model (it can also be understood as the probability of the occurrence or recurrence of N scenes on the preset date). Among them, under the time dimension, the expected probability of the scene's occurrence is inversely correlated with the number of days from the actual date of the scene's occurrence to the preset date. Specifically, the farther the scene's actual occurrence date is from the preset date, the lower the probability of occurrence; the closer the scene's actual occurrence date is to the preset date, the higher the probability of occurrence. Figure 2 As shown in the figure, the closer the actual occurrence date of the scene is to the preset date, the higher the probability of occurrence is. In the figure, since scene 2 is closer to the preset date than scene 1, the probability of occurrence of scene 2 is higher than that of scene 1.
[0125] 2. Establish a probability model based on the relationship between each scenario and the preset date in the cycle dimension, and obtain the probability of occurrence of N scenarios on the preset date based on the probability model. Among them, under the cycle dimension, the expected probability of occurrence of the scenario is positively correlated with the number of days from the actual occurrence date of the scenario in the cycle to the preset date. Specifically, the farther the position of the actual occurrence date of the scenario in the cycle is from the preset date, the lower the probability of occurrence; the closer the position of the actual occurrence date of the scenario in the cycle is to the preset date, the higher the probability of occurrence. It should be noted here that the cycle can be a week, month, quarter, year or other cycle, or a cycle such as the alternating time between the peak and off-season of logistics and freight. . Such as Figure 3 As shown, if scenario 2 and the preset date are both on Wednesday, and scenario 1 is on Sunday, from the periodic dimension, scenario 2 is closer to the preset date, while scenario 1 is farther away, so scenario 2 has a higher probability of occurring than scenario 1.
[0126] 3. According to the relationship between each scenario and the preset date in the time dimension and the cycle dimension, a probability model is established, and the occurrence probability of N scenarios on the preset date is obtained according to the probability model. It can be that the farther the actual occurrence date of the scenario is from the preset date, and the farther the position of the actual occurrence date of the scenario in the cycle is from the position of the preset date in the cycle, the lower the occurrence probability; the closer the actual occurrence date of the scenario is to the preset date, and the closer the position of the actual occurrence date of the scenario in the cycle is to the position of the preset date in the cycle, the higher the occurrence probability; such as Figure 4 As shown, by combining the time dimension and the period dimension, a probability model can be established to obtain the occurrence probability of scenario 2 and scenario 1.
[0127] Furthermore, a more specific model is given to illustrate the establishment of the third probability model mentioned above, as follows.
[0128] The probability model is established based on the distance between the scenario and the preset date in the time dimension and cycle dimension:
[0129] Among them, T x Indicates the value corresponding to scene x in the time dimension. This value increases as the difference in the number of days between the date of the scene and the preset date increases.
[0130] C x Indicates the value corresponding to scene x in the period dimension. This value can be set manually, such as Figure 4 As shown in the figure, the two scenarios involve a total of 4 cycles. Then, the C x is 0.9, which is one cycle of C x is 0.8, which is two cycles of C x is 0.7, which is three cycles of C xis 0.6, then finally C2=0.8, C1=0.6; this value can be directly obtained using historical data, such as The formula becomes, Among them, D0 represents the date of the preset date, D x Indicates the date of scene x. For example, since the difference between scene 1 and the preset date is 21 days, D0-D1=21; the difference between scene 2 and the preset date is 6 days, D0-D2=6.
[0131] According to an embodiment of the present application, there is also provided a method for implementing the above Figure 1 Method of order allocation means, such as Figure 5 As shown, the device comprises:
[0132] The to-be-matched information acquisition module 21 is used to acquire at least one to-be-matched order information and at least one to-be-matched vehicle information of the day.
[0133] The scenario establishment module 22 is used to obtain the shipping order information of M regions in N days in history, and establish N scenarios according to the shipping order information of each day in the N days. Each scenario includes the shipping order information of the M regions in one day, wherein M and N are positive integers greater than zero.
[0134] The expected probability calculation module 23 is used to determine the expected probability of each of the N scenarios occurring on a preset date based on a probability model, wherein the probability model is a model established based on the shipping order information of M regions over N historical days for determining the probability of occurrence of N historical scenarios on a preset date.
[0135] The order matching module 24 is used to match at least one vehicle information to be matched, at least one order information to be matched on the day and the shipping order information in N scenarios by using constraint conditions, and traverse all matching solutions.
[0136] The expected value calculation module 25 is used to calculate the expected value of each matching scheme, which is the sum of the expected benefits of all vehicles to be matched in the matching scheme, where the expected benefit of the vehicle to be matched = the expectation for the day + the subsequent expectation × the expected probability of the scenario where the shipping order is located.
[0137] The order allocation module 26 is used to obtain the order allocation result according to the matching relationship between the to-be-matched vehicle and the to-be-allocated order in the matching solution with the maximum expected value.
[0138] Furthermore, the expected value calculation module 25 can also be used to calculate the daily expectation. The specific method for calculating the daily expectation includes:
[0139] Get the price of the order to be matched on the day and the empty running cost of the first order received by the vehicle. The empty running cost of the first order received by the vehicle corresponds to the order to be matched on the day;
[0140] The expectation for the day is determined based on the difference between the price of the order to be matched on the day and the idle driving cost of the vehicle for the first order.
[0141] Furthermore, the expected value calculation module 25 can also be used for subsequent expected calculation. Specifically, the subsequent expected calculation method may include:
[0142] Obtain the shipping order price and the second order idle running cost of the vehicle, wherein the second order idle running cost of the vehicle corresponds to the shipping order;
[0143] The subsequent expected value is determined based on the difference between the shipping order price and the idle driving cost of the vehicle for the second order.
[0144] As an optional embodiment, the order classification device may further include: a model building module, used to establish a probability model based on the distance between each scenario and the preset date in the time dimension and / or cycle dimension, wherein, under the time dimension, the expected probability of the scenario occurring is negatively correlated with the number of days from the actual occurrence date of the scenario to the preset date; under the cycle dimension, the expected probability of the scenario occurring is positively correlated with the number of days from the actual occurrence date of the scenario within the cycle to the preset date.
[0145] As an optional embodiment, the constraint conditions include any one of the following items or a combination thereof: each of the orders to be matched on the day and / or the shipping orders is matched with at most one vehicle to be matched in a matching scheme; each vehicle to be matched is matched with at most any two of the orders to be matched on the day and / or the shipping orders in a matching scheme; when the vehicle to be matched cannot arrive at the corresponding loading location before the loading time of the order to be matched on the day, the vehicle to be matched cannot be matched with the order to be matched on the day; when the vehicle to be matched cannot arrive at the corresponding loading location before the loading time of the shipping order, the vehicle to be matched cannot be matched with the shipping order.
[0146] As an optional embodiment, the expected probability calculation module 23 is further used to determine the occurrence probabilities of the N scenarios on a preset date according to a probability model; and regularize the N occurrence probabilities to obtain the expected probabilities of the N scenarios.
[0147] Specifically, the specific process of each unit and module in the device of the embodiment of the present application to realize its function can be found in the relevant description in the method embodiment, which will not be repeated here.
[0148] According to an embodiment of the present application, a computer-readable storage medium is further provided, characterized in that the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the order allocation method in the above method embodiment.
[0149] Figure 6 is a structural block diagram of an optional electronic device according to an embodiment of the present application, such as Figure 6 As shown, it includes a processor 602, a communication interface 604, a memory 606 and a communication bus 608, wherein the processor 602, the communication interface 604 and the memory 606 communicate with each other through the communication bus 608, wherein,
[0150] Memory 606, used to store computer programs;
[0151] The processor 602 is used to implement the process steps of the order allocation method in the above embodiment when executing the computer program stored in the memory 606.
[0152] Optionally, in this embodiment, the communication bus may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 6 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0153] The communication interface is used for communication between the above electronic device and other devices.
[0154] The memory may include RAM, or may include non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0155] As an example, Figure 6 As shown, the memory 602 may include, but is not limited to, the functional modules in the order distribution device. In addition, it may also include, but is not limited to, other module units in the order distribution device, which will not be described in detail in this example.
[0156] The above-mentioned processor can be a general-purpose processor, which can include but not be limited to: CPU (Central Processing Unit), NP (Network Processor), etc.; it can also be DSP (Digital Signal Processing), ASIC (Application Specific Integrated Circuit), FPGA (Field-Programmable Gate Array) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0157] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, and this embodiment will not be described in detail here.
[0158] It can be understood by those skilled in the art that Figure 6 The structure shown is for illustration only. The device for implementing the above-mentioned order allocation method may be a terminal device, which may be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (Mobile Internet Devices, MID), a PAD, and other terminal devices. Figure 6 It does not limit the structure of the above electronic device. For example, the terminal device may also include Figure 6 More or fewer components (such as network interfaces, display devices, etc.) shown in, or having Figure 6 Different configurations shown.
[0159] A person of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing the hardware related to the terminal device through a program, and the program can be stored in a computer-readable storage medium, which can include: a flash drive, ROM, RAM, a magnetic disk or an optical disk, etc.
[0160] According to another aspect of the embodiment of the present application, a storage medium is also provided. Optionally, in this embodiment, the storage medium can be used to execute the program code of the order allocation method.
[0161] Optionally, in this embodiment, the storage medium may be located on at least one network device among a plurality of network devices in the network shown in the above embodiment.
[0162] Optionally, in this embodiment, the storage medium is configured to store program codes for executing the process steps of the order allocation method in the above embodiment.
[0163] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, which will not be described in detail in this embodiment.
[0164] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media that can store program codes, such as a USB flash drive, a ROM, a RAM, a mobile hard disk, a magnetic disk, or an optical disk.
[0165] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0166] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium. Based on this understanding, the technical solution of the present application, 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, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.
[0167] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0168] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, 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 through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0169] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution provided in this embodiment.
[0170] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0171] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. An order allocation method, characterized in that: The method comprises: Obtain at least one order information to be matched on the day and at least one vehicle information to be matched; Obtaining the shipping order information of M regions in N days in history, and establishing N scenarios according to the shipping order information of each day in the N days, each scenario including the shipping order information of the M regions in one day, wherein M and N are positive integers greater than zero; Determine the expected probability of each of the N scenarios occurring on a preset date according to a probability model, wherein the probability model is a model established based on the historical shipping order information of M regions over N days for determining the probability of occurrence of the N historical scenarios on a preset date; Using the constraint conditions, at least one to-be-matched vehicle information, at least one to-be-matched order information on the day, and the shipment order information in N scenarios are matched, and all matching solutions are traversed; Calculate the expected value of each matching solution, which is the sum of the expected benefits of all vehicles to be matched in the matching solution, where the expected benefit of the vehicle to be matched = the expectation for the day + the expectation for the subsequent period × the expected probability of the scenario where the delivery order is located; The order allocation result is obtained by matching the vehicles to be matched and the orders to be allocated in the matching solution with the largest expected value.
2. The order allocation method according to claim 1, characterized in that: The calculation method of the daily expectation includes: Obtaining the price of the order to be matched on the day and the idle running cost of the first order received by the vehicle, wherein the idle running cost of the first order received by the vehicle corresponds to the order to be matched on the day; Determine the expectation for the day based on the difference between the price of the order to be matched on the day and the idle driving cost of the first order received by the vehicle; The calculation method of the subsequent expectation includes: Obtaining a shipping order price and a second order-receiving idle running cost of the vehicle, wherein the second order-receiving idle running cost of the vehicle corresponds to the shipping order; The subsequent expectation is determined based on the difference between the shipping order price and the idle driving cost of the vehicle for the second order.
3. The order allocation method according to claim 1, characterized in that: Before determining the expected probability of each of the N scenarios occurring on a preset date according to the probability model, the method further includes: A probability model is established based on the distance between each scenario and the preset date in the time dimension and / or cycle dimension.
4. The order allocation method according to claim 3, characterized in that: In the time dimension, the expected probability of the scenario occurring is inversely correlated with the number of days between the actual occurrence date of the scenario and the preset date.
5. The order distribution method according to claim 3, characterized in that: Under the period dimension, the expected probability of the scenario occurring is positively correlated with the number of days between the actual occurrence date of the scenario within the period and the preset date.
6. The order distribution method according to claim 1, characterized in that: The constraints include any one or a combination of the following: Each of the orders to be matched on the day and / or the shipping orders can be matched with at most one vehicle to be matched in one matching solution; Each to-be-matched vehicle is matched with at most any two of the to-be-matched orders and / or the shipping orders of the day in one matching solution; If the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the order to be matched on the same day, the vehicle to be matched cannot be matched with the order to be matched on the same day; When the vehicle to be matched cannot arrive at the corresponding loading place before the loading time of the shipping order, the vehicle to be matched cannot be matched with the shipping order.
7. The order distribution method according to claim 1, characterized in that: Determining the expected probability of each scenario occurring on a preset date based on the probability model includes: Determine the occurrence probability of the N scenarios on a preset date according to a probability model; Regularize the N occurrence probabilities to obtain the expected probabilities of the N scenarios.
8. An order distribution device, characterized in that: The device comprises: A module for obtaining information to be matched, used to obtain at least one order information to be matched on the same day and at least one vehicle information to be matched; A scenario establishment module, used to obtain the shipping order information of M regions in N days in history, and establish N scenarios according to the shipping order information of each day in the N days, each scenario including the shipping order information of the M regions in one day, wherein M and N are positive integers greater than zero; An expected probability calculation module, used to determine the expected probability of each of the N scenarios occurring on a preset date according to a probability model, wherein the probability model is a model established based on the shipping order information of M regions in N days in history and used to determine the probability of occurrence of N scenarios in history on a preset date; An order matching module is used to match at least one to-be-matched vehicle information, at least one to-be-matched order information on the day, and the shipment order information in N scenarios using constraint conditions, and traverse all matching solutions; An expected value calculation module is used to calculate the expected value of each matching scheme, where the expected value is the sum of the expected benefits of all vehicles to be matched in the matching scheme, where the expected benefit of the vehicle to be matched = the expectation for the day + the expectation for the subsequent period × the expected probability of the scenario where the delivery order is located; The order allocation module is used to obtain the order allocation result according to the matching relationship between the vehicles to be matched and the orders to be allocated in the matching solution with the maximum expected value.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the order allocation method according to any one of claims 1 to 7.
10. An electronic device, characterized in that: include: at least one processor; And a memory communicatively connected to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor executes the order allocation method described in any one of claims 1-7.
Citation Information
Patent Citations
Order distribution method, order distribution system and computer readable storage medium
CN109635985A
Order distribution method, order distribution system and computer readable storage medium
CN109658203A
Intelligent order vehicle matching method, system and device
CN111932155A
Vehicle matching method and device, terminal and storage medium
CN111967750A
