Order distribution method, device, server and storage medium
By adding a confirmation identification based on the user equipment identification to the candidate carrier in the autonomous driving movable carrier system, and allocating orders according to status change requests, the problem of conflicts between orders and status changes is solved, resource waste is prevented, and allocation efficiency is improved. .
Patent Information
- Application Number
- CN202011070255.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-09-30
- Publication Date
- 2024-09-17
- Estimated Expiration
- 2040-09-30
AI Technical Summary
In the autonomous driving movable carrier system, conflicts are prone to occur between orders and status changes, resulting in a waste of user order resources.
By adding a pending identification generated based on the user equipment identification to the candidate carrier in the removable carrier resource pool, and allocating orders based on the received target carrier status change request and the pending identification, ensuring the accuracy and efficiency of order allocation.
It effectively avoids conflicts between orders and status changes, prevents the waste of user order resources, and improves the accuracy and efficiency of order allocation.
Smart Images

Figure CN112200449B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of automation technology, and in particular to an order distribution method, device, server and storage medium. Background Art
[0002] With the advancement of current automation technology, autonomous driving of movable carriers (for example, cars, robots with carrying capacity, or aircraft and other equipment with carrying capacity) is becoming more and more popular. Therefore, movable carriers based on autonomous driving will also exist as a mode of travel, that is, users send orders to the server through terminal devices (i.e., devices such as smartphones, tablets, personal computers or laptops), and the server allocates the orders.
[0003] However, since movable carriers are not equipped with drivers, each movable carrier can only passively receive orders. When receiving orders, the movable carrier may need to change its status for some reasons, which makes it very easy for conflicts to occur between orders and status changes, resulting in a waste of user order resources. Summary of the invention
[0004] The main purpose of the present invention is to provide an order allocation method, device, server and storage medium, aiming to solve the technical problem that conflicts between orders and status changes are prone to occur, causing waste of user order resources.
[0005] To achieve the above object, the present invention provides an order allocation method, which comprises the following steps:
[0006] When receiving an order sent by a user device, extracting a user device identifier and a current location from the order;
[0007] Selecting at least one to-be-selected removable carrier from a removable carrier resource pool according to the current position;
[0008] Adding a to-be-confirmed identifier for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identifier is generated based on the user equipment identifier;
[0009] An order is allocated to the target movable carrier according to a received state change request of the target movable carrier and a to-be-confirmed identifier of each movable carrier in the movable carrier resource pool.
[0010] Optionally, the to-be-confirmed identifier is generated based on the user device identifier and the order receiving time;
[0011] The step of allocating an order to the target removable carrier according to the received state change request of the target removable carrier and the to-be-confirmed identifiers of each removable carrier in the removable carrier resource pool comprises:
[0012] Upon receiving a state change request of a target removable carrier, determining whether the target removable carrier has multiple to-be-confirmed identifiers;
[0013] When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier;
[0014] When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0015] Optionally, the to-be-confirmed identifier is generated based on the user device identifier and the order receiving time;
[0016] After the step of adding a to-be-confirmed mark for the selected removable carrier in the removable carrier resource pool, the order allocation method further includes:
[0017] When receiving the carrier allocation instruction, taking the removable carrier with the to-be-determined identifier in the removable carrier resource pool as the removable carrier to be allocated;
[0018] Counting the number of first identifiers of each identifier to be determined;
[0019] Sort the to-be-confirmed identifiers in ascending order of the number of first identifiers to obtain a sorting result;
[0020] Traversing the to-be-determined identifiers according to the sorting result, and taking the traversed to-be-determined identifiers as the current identifiers;
[0021] Searching for a pending removable carrier having the current identifier from the removable carrier resource pool;
[0022] Obtain the number of second identifications of the identifications to be determined of each removable carrier to be determined;
[0023] Taking the undetermined removable carrier with the least number of the second identifications as the target removable carrier;
[0024] When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier;
[0025] When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0026] Optionally, before the step of adding a pending confirmation mark for the selected removable carrier in the removable carrier resource pool, the order allocation method further includes:
[0027] Obtaining the user device identification and order receiving time;
[0028] Formatting the user equipment identifier and order receiving time;
[0029] The formatted user device identifier and order receiving time are combined to obtain the information to be allocated;
[0030] The information to be allocated is saved in a preset storage area, and the storage address of the information to be allocated in the preset storage area is used as a to-be-confirmed identifier.
[0031] Optionally, the step of selecting at least one to-be-selected removable carrier from a removable carrier resource pool according to the current position includes:
[0032] Determining the straight-line distance between each movable carrier in the movable carrier resource pool and the current position;
[0033] The movable carrier whose straight-line distance is less than the preset distance threshold is used as the first movable carrier;
[0034] Acquiring the remaining energy amount of each first movable carrier;
[0035] searching, from the first movable carrier, a second movable carrier capable of completing the order according to the remaining energy amount;
[0036] Acquiring road condition information from each second movable carrier to the current position;
[0037] A to-be-selected movable carrier is selected from the second movable carrier according to the road condition information.
[0038] Optionally, before the step of selecting at least one to-be-selected movable carrier from a movable carrier resource pool according to the current position, the order allocation method further comprises:
[0039] Performing overall status detection on each movable carrier;
[0040] Determine whether the movable carrier that has passed the vehicle status detection is in a state where it can receive orders;
[0041] The removable carrier that is in the order-receiving state is added to the removable carrier resource pool.
[0042] Optionally, the step of performing overall status detection on each movable carrier includes:
[0043] Sending a detection instruction to each movable carrier, so that each movable carrier collects and feeds back status information of sensors on each component after receiving the detection instruction;
[0044] Performing state prediction based on state information fed back by each movable carrier to obtain a prediction result;
[0045] When the prediction result is that the state is normal, it is determined that the overall state detection of the movable carrier has passed.
[0046] In addition, to achieve the above-mentioned purpose, the present invention further provides an order distribution device, the order distribution device comprising:
[0047] A data extraction module, configured to extract a user device identifier and a current location from an order when receiving an order sent by a user device;
[0048] A carrier selection module, configured to select at least one to-be-selected movable carrier from a movable carrier resource pool according to the current position;
[0049] an identification adding module, configured to add a to-be-confirmed identification for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identification is generated based on the user equipment identification;
[0050] The order allocation module is used to allocate an order to the target movable carrier according to the to-be-confirmed identifier of each movable carrier in the movable carrier resource pool when receiving a state change request of the target movable carrier.
[0051] In addition, to achieve the above-mentioned purpose, the present invention also provides a server, which includes: a memory, a processor, and an order allocation program stored in the memory and executable on the processor, wherein the order allocation program is configured to implement the steps of the order allocation method described above.
[0052] In addition, to achieve the above-mentioned purpose, the present invention also provides a computer-readable storage medium, on which an order allocation program is stored, and when the order allocation program is executed by a processor, the steps of the order allocation method described above are implemented.
[0053] The present invention generates a to-be-confirmed identifier based on the user equipment identifier for a selected removable carrier in a removable carrier resource pool, allocates an order to the target removable carrier according to a state change request received from the target removable carrier and the to-be-confirmed identifiers of each removable carrier in the removable carrier resource pool, and can distinguish whether to allocate an order through the to-be-confirmed identifier of the target removable carrier, thereby avoiding conflicts between orders and state changes and preventing waste of user order resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 This is a flow chart of a first embodiment of an order allocation method of the present invention;
[0055] Figure 2 This is a flow chart of step S40 in the second embodiment of the order allocation method of the present invention;
[0056] Figure 3 This is a flow chart of the steps after step S30 in the third embodiment of the order allocation method of the present invention;
[0057] Figure 4 This is a flow chart of the steps before step S30 in the fourth embodiment of the order allocation method of the present invention;
[0058] Figure 5 This is a flow chart of step S20 in the fifth embodiment of the order allocation method of the present invention;
[0059] Figure 6 It is a structural block diagram of an embodiment of an order distribution device of the present invention;
[0060] Figure 7 It is a schematic diagram of the server structure of the hardware operating environment involved in the embodiment of the present invention.
[0061] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0062] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.
[0063] Reference Figure 1 , Figure 1 It is a flowchart of the first embodiment of the order allocation method of the present invention.
[0064] In a first embodiment, the order allocation method comprises the following steps:
[0065] S10: When receiving an order sent by a user device, extract the user device identifier and the current location from the order.
[0066] It should be noted that the executor of the method of this embodiment is the server. When a user needs to travel, he or she usually enters the current location and destination location of the travel on the application of his or her user device. The user device will obtain its own user device identifier and generate an order based on the user device identifier, current location and destination location. After the server receives the order from the user device, it can extract the user device identifier and current location from the order.
[0067] It is understandable that the current location and the destination location can usually be represented by information similar to longitude and latitude, and the user equipment identifier is a unique identifier used to identify the user equipment, which can be used to distinguish it from other user equipment, such as: International Mobile Equipment Identity (IMEI) or International Mobile Subscriber Identity (IMSI) and other identifiers, which are not limited in this embodiment.
[0068] In a specific implementation, the current position is the position of the movable carrier at the current moment, and the destination position is the position of the destination to which the movable carrier needs to go, wherein the current position and the destination position can usually be represented by information similar to longitude and latitude.
[0069] S20: selecting at least one to-be-selected movable carrier from a movable carrier resource pool according to the current position.
[0070] It should be understood that the movable carrier has many forms, such as automobiles, robots, aircraft and other carriers with mobility, and the present invention does not impose any specific limitation.
[0071] It is understandable that, for the movable carrier resource pool, in order to ensure that all the movable carriers therein can be assigned orders, in this embodiment, before step S20, an overall status detection may be performed on each movable carrier, and then a determination may be made as to whether the movable carriers that have passed the vehicle status detection are in a state ready to receive orders, and finally the movable carriers in a state ready to receive orders are added to the movable carrier resource pool. In other words, the movable carriers that can be added to the movable carrier resource pool have all passed the overall status detection and are in a state ready to receive orders.
[0072] It should be understood that in order to ensure the accuracy of the overall status detection, in this embodiment, when performing overall status detection on each movable carrier, a detection instruction can be first sent to each movable carrier, so that after each movable carrier receives the detection instruction, it collects and feeds back the status information of the sensors on each component, and then performs status prediction based on the status information fed back by each movable carrier to obtain a prediction result. Finally, when the prediction result is that the status is normal, it is determined that the overall status detection of the movable carrier has passed.
[0073] In a specific implementation, the sensors on each component of the movable carrier include but are not limited to: at least one of the sensors such as a gyroscope, an acceleration sensor, a radar and an image sensor. Since whether these sensors are normal will directly reflect whether the overall state of the movable carrier is normal, the state information detected by these sensors can be used to predict the state.
[0074] S30: adding a to-be-confirmed identifier for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identifier is generated based on the user equipment identifier.
[0075] It should be noted that a pending confirmation mark is added to the selected removable carrier in the removable carrier resource pool, and the server may implement the order concurrently, that is, there will be a situation where the pending confirmation marks generated by different user equipment marks are added to a selected removable carrier at the same time.
[0076] Assume that the server receives 5 different orders at the same time, corresponding to user equipment identification A, user equipment identification B, user equipment identification C, user equipment identification D and user equipment identification E respectively, and there are 7 removable carriers to be selected in the removable carrier resource pool, corresponding to removable carrier 1 to be selected, removable carrier 2 to be selected, removable carrier 3 to be selected, removable carrier 4 to be selected, removable carrier 5 to be selected, removable carrier 6 to be selected and removable carrier 7 to be selected respectively. For specific allocation, please refer to the following Table 1:
[0077] Removable carrier to be selected 1 User equipment identification A User equipment identification B User equipment identification C Removable carrier to be selected 2 User equipment identification B User equipment identification C Removable carrier to be selected 3 User equipment identification C User equipment identification D User equipment identification E Removable carrier to be selected 4 User equipment identification D User equipment identification E Removable carrier to be selected 5 User equipment identification E Removable carrier to be selected 6 User equipment identification C User equipment identification D Removable carrier to be selected 7 User equipment identification C
[0078] Table 1
[0079] According to Table 1, for the selected removable carrier 1, the user equipment identifiers added are user equipment identifier A, user equipment identifier B and user equipment identifier C; for the selected removable carrier 2, the user equipment identifiers added are user equipment identifier B and user equipment identifier C; for the selected removable carrier 3, the user equipment identifiers added are user equipment identifier C, user equipment identifier D and user equipment identifier E; for the selected removable carrier 4, the user equipment identifiers added are user equipment identifier D and user equipment identifier E; for the selected removable carrier 5, the user equipment identifier added is user equipment identifier E; for the selected removable carrier 6, the user equipment identifiers added are user equipment identifier C and user equipment identifier D; for the selected removable carrier 7, the user equipment identifier added is user equipment identifier C.
[0080] S40: allocating an order to the target movable carrier according to the received state change request of the target movable carrier and the pending confirmation identifiers of the movable carriers in the movable carrier resource pool.
[0081] It should be noted that the status change request is a request sent when the target movable carrier goes offline, that is, it is used to change the target movable carrier from a state in which it can receive orders to a state in which it stops receiving orders, or the target movable carrier needs to stop operating, or the original operating strategy is changed, thereby requiring status adjustment, etc. However, since the target movable carrier may have been added with a pending confirmation flag, orders can be allocated to the target movable carrier according to the pending confirmation flags of each movable carrier in the movable carrier resource pool.
[0082] Therefore, the pending confirmation mark can be used as the basis for allocating orders to the target removable carrier. When the pending confirmation mark is added to the target removable carrier, it can be determined that it has the possibility of being assigned an order. Specifically, an order can be allocated to the target removable carrier. Of course, if the target removable carrier has not been assigned an order, it can be determined that it has no possibility of being assigned an order, and the target removable carrier can be directly deleted from the removable carrier resource pool.
[0083] This embodiment adds a pending confirmation identifier generated based on the user device identifier to the selected removable carrier in the removable carrier resource pool, allocates an order to the target removable carrier according to the received state change request of the target removable carrier and the pending confirmation identifiers of each removable carrier in the removable carrier resource pool, and can determine whether to allocate an order through the pending confirmation identifier of the target removable carrier, thereby avoiding conflicts between orders and state changes and preventing waste of user order resources.
[0084] like Figure 2As shown, a second embodiment of the order allocation method of the present invention is proposed based on the first embodiment. In this embodiment, the to-be-confirmed identifier is generated based on the user device identifier and the order receiving time;
[0085] Step S40 specifically includes:
[0086] S41: upon receiving a state change request of a target removable carrier, determining whether the target removable carrier has a plurality of to-be-confirmed identifiers.
[0087] It should be noted that, according to the above examples, a removable carrier may have one identification to be confirmed or multiple identifications to be confirmed.
[0088] S42: When there is only one identification to be confirmed on the target removable carrier, the target removable carrier is assigned to the target user device corresponding to the identification to be confirmed on the target removable carrier, the target removable carrier is removed from the removable carrier resource pool, and the order corresponding to the target user device is sent to the target removable carrier.
[0089] It is understandable that when there is only one to-be-confirmed identifier for the target removable carrier, it can be determined that the target removable carrier can satisfy the order of the user device identifier corresponding to the to-be-confirmed identifier. Therefore, the target removable carrier can be directly assigned to the target user device corresponding to the to-be-confirmed identifier on the target removable carrier, the target removable carrier can be removed from the removable carrier resource pool, and the order corresponding to the target user device can be sent to the target removable carrier.
[0090] S43: When there are multiple to-be-confirmed identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the to-be-confirmed identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0091] In a specific implementation, the order receiving time is the time when the server receives the order.
[0092] It is understandable that for the target removable carrier, there are multiple pending confirmation identifiers, that is, the target removable carrier can satisfy the orders of user devices corresponding to multiple pending confirmation identifiers. In a specific implementation, the target removable carrier can randomly select an order of a user device corresponding to a pending confirmation identifier, but this may easily cause some users to wait too long. Therefore, in this embodiment, the pending confirmation identifier can be generated based on the user device identifier and the order receiving time, and the order receiving time can be determined according to the pending confirmation identifier. Therefore, the target user device identifier with the earliest order receiving time can be searched for in the pending confirmation identifier on the target removable carrier, the target removable carrier can be assigned to the target user device corresponding to the target user device identifier, the target removable carrier can be removed from the removable carrier resource pool, and the order corresponding to the target user device is sent to the target removable carrier.
[0093] This embodiment determines the allocation method of re-finalization according to the number of identifications to be confirmed of the target removable carrier. When the number of identifications is multiple, the target removable carrier is preferentially allocated to the target user device corresponding to the target user device identification with the earliest order reception time, thereby avoiding some users from waiting too long.
[0094] like Figure 3 As shown, a third embodiment of the order allocation method of the present invention is proposed based on the first embodiment. In this embodiment, the to-be-confirmed identifier is generated based on the user device identifier and the order receiving time;
[0095] After step S30, the order allocation method further includes:
[0096] S51: When a carrier allocation instruction is received, a removable carrier with a to-be-determined identifier in the removable carrier resource pool is used as a removable carrier to be allocated.
[0097] It should be noted that, generally speaking, the allocation of removable carriers is usually executed when the carrier allocation instruction is received. However, when the status change request of the target removable carrier is received, it is a relatively special case. If the order is not allocated to the target removable carrier in time, the target removable carrier will be directly offline, and the number of removable carriers that can meet user requirements will decrease. Therefore, it will be processed first. However, assuming that the status change request of the target removable carrier is not received, it is necessary to allocate the order when the carrier allocation instruction is received.
[0098] It is understandable that, for the removable carriers in the removable carrier resource pool, only the removable carriers with the to-be-determined identification can be understood as the removable carriers to be allocated. Therefore, when the carrier allocation instruction is received, the removable carriers with the to-be-determined identification in the removable carrier resource pool are regarded as the removable carriers to be allocated.
[0099] S52: Count the number of first identifiers of each identifier to be determined.
[0100] Since there are differences in the number of to-be-determined identifications added on different removable carriers to be selected, there will be differences in the number of to-be-determined identifications. Continuing with the data in Table 1 as an example, at this time, the number of first identifications of to-be-determined identifications corresponding to user equipment identification A is 1, the number of first identifications of to-be-determined identifications corresponding to user equipment identification B is 2, the number of first identifications of to-be-determined identifications corresponding to user equipment identification C is 5, the number of first identifications of to-be-determined identifications corresponding to user equipment identification D is 3, and the number of first identifications of to-be-determined identifications corresponding to user equipment identification E is 3.
[0101] S53: Sort the to-be-confirmed identifiers in ascending order of the number of first identifiers to obtain a sorting result.
[0102] It should be noted that the number of first identifiers can directly reflect the number of removable carriers that can be matched by the user equipment identifier corresponding to the identifier to be determined, in order to ensure that the identifier to be determined with a smaller number of removable carriers that can be matched is allocated first, thereby avoiding the situation where the user equipment identifiers corresponding to some identifiers to be determined cannot be allocated, for example: the identifier to be determined corresponding to user equipment identifier A only appears once, indicating that only the removable carrier 1 to be selected can meet its travel needs. If the identifier to be determined corresponding to user equipment identifier B is processed first, at this time, the removable carrier 1 to be selected may be allocated to the identifier to be determined corresponding to user equipment identifier B, and the identifier to be determined corresponding to user equipment identifier A cannot be matched, thereby causing the order of the user corresponding to user equipment identifier A to be directly invalid.
[0103] S54: Traverse the to-be-determined identifiers according to the sorting result, and use the traversed to-be-determined identifiers as current identifiers.
[0104] It can be understood that based on the data in Table 1, the sorting results are: the to-be-determined identifier corresponding to the user equipment identifier A, the to-be-determined identifier corresponding to the user equipment identifier B, the to-be-determined identifier corresponding to the user equipment identifier D, the to-be-determined identifier corresponding to the user equipment identifier E (the number of to-be-determined identifiers is the same as that of the to-be-determined identifiers corresponding to the user equipment identifier D, and the two can be randomly sorted) and the to-be-determined identifier corresponding to the user equipment identifier C.
[0105] S55: searching the removable carrier resource pool for a pending removable carrier having the current identifier.
[0106] It is understandable that, assuming that the current identifier is the identifier to be confirmed corresponding to the user equipment identifier E, at this time, the to-be-determined removable carriers with the current identifier can be determined as the to-be-selected removable carrier 4 and the to-be-selected removable carrier 5.
[0107] S56: Obtain the second identification quantity of the to-be-determined identification of each to-be-determined movable carrier.
[0108] In the specific implementation, it is continued to be assumed that the current identifier is the identifier to be confirmed corresponding to the user equipment identifier E. At this time, the second identifier number of the identifier to be determined of the removable carrier 4 to be selected is 2, and the second identifier number of the identifier to be determined of the removable carrier 5 to be selected is 1.
[0109] S57: The pending removable carrier with the least number of the second identifications is used as the target removable carrier.
[0110] It should be understood that, it is still assumed that the current identifier is the identifier to be determined corresponding to the user equipment identifier E. At this time, the to-be-determined removable carrier with the least number of second identifiers is the removable carrier to be selected 5.
[0111] S58: When there is only one to-be-confirmed identifier on the target removable carrier, the target removable carrier is assigned to the target user device corresponding to the to-be-confirmed identifier on the target removable carrier, the target removable carrier is removed from the removable carrier resource pool, and the order corresponding to the target user device is sent to the target removable carrier.
[0112] It is understandable that when there is only one to-be-confirmed identifier for the target removable carrier, it can be determined that the target removable carrier can satisfy the order of the user device identifier corresponding to the to-be-confirmed identifier. Therefore, the target removable carrier can be directly assigned to the target user device corresponding to the to-be-confirmed identifier on the target removable carrier, the target removable carrier can be removed from the removable carrier resource pool, and the order corresponding to the target user device can be sent to the target removable carrier.
[0113] S59: When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0114] In a specific implementation, the order receiving time is the time when the server receives the order.
[0115] It is understandable that for the target removable carrier, there are multiple pending confirmation identifiers, that is, the target removable carrier can satisfy the orders of user devices corresponding to multiple pending confirmation identifiers. In a specific implementation, the target removable carrier can randomly select an order of a user device corresponding to a pending confirmation identifier, but this may easily cause some users to wait too long. Therefore, in this embodiment, the pending confirmation identifier can be generated based on the user device identifier and the order receiving time, and the order receiving time can be determined according to the pending confirmation identifier. Therefore, the target user device identifier with the earliest order receiving time can be searched for in the pending confirmation identifier on the target removable carrier, the target removable carrier can be assigned to the target user device corresponding to the target user device identifier, the target removable carrier can be removed from the removable carrier resource pool, and the order corresponding to the target user device is sent to the target removable carrier.
[0116] like Figure 4 As shown, a fourth embodiment of the order allocation method of the present invention is proposed based on the second embodiment or the third embodiment. In this embodiment, before step S30, the order allocation method further includes:
[0117] S201: Obtain the user equipment identification and order receiving time.
[0118] S202: Formatting the user equipment identifier and order receiving time.
[0119] It should be noted that in order to ensure the consistency of subsequent data, in this embodiment, the user device identifier and order receipt time need to be formatted first, that is, the user device identifier and order receipt time need to be converted into a preset format first, for example: the order receipt time needs to be converted into the YY-MM-DD format.
[0120] S203: Joining the formatted user device identifier and the order receiving time to obtain information to be allocated.
[0121] It is understandable that after the formatted user device identification and order receipt time, they can be spliced to generate a to-be-allocated information, thereby saving storage space to a certain extent, and when reading information, there is no need to read data from two areas, thereby improving the data reading speed.
[0122] It should be understood that since the information to be allocated is composed of the formatted user device identifier and order receipt time, the information of the information to be allocated is relatively fixed, and the user device identifier and / or order receipt time can be directly extracted from the information to be allocated.
[0123] S204: Save the information to be allocated to a preset storage area, and use the storage address of the information to be allocated in the preset storage area as a to-be-confirmed identifier.
[0124] In a specific implementation, since the data volume of the information to be allocated is relatively large under normal circumstances, in this embodiment, the information to be allocated can be stored in a preset storage area, and the storage address of the information to be allocated in the preset storage area is used as the identifier to be determined, thereby simplifying the data volume of the identifier to be confirmed.
[0125] like Figure 5 As shown, a fifth embodiment of the order allocation method of the present invention is proposed based on the first embodiment, the second embodiment or the third embodiment. In this embodiment, step S20 specifically includes:
[0126] S21: Determine the straight-line distance between each movable carrier in the movable carrier resource pool and the current position.
[0127] It should be noted that, in order to facilitate the calculation of the straight-line distance between each movable carrier and the current position, in this embodiment, the current position of each movable carrier can be obtained first, and then the current position of each movable carrier and the current position can be respectively corresponded to the map, and then the straight-line distance between each movable carrier in the movable carrier resource pool and the current position can be calculated based on the map.
[0128] S22: The movable carrier whose straight-line distance is less than a preset distance threshold is used as a first movable carrier.
[0129] It is understandable that in order to ensure that the movable carrier used for order distribution is not too far away from the current position, thereby affecting the user experience, therefore, in this embodiment, the movable carrier whose straight-line distance is less than the preset distance threshold can be used as the first movable carrier.
[0130] S23: Obtain the remaining energy amount of each first movable carrier.
[0131] In a specific implementation, in order to avoid energy shortage when executing an order, in this embodiment, the remaining energy of each first movable carrier can be obtained. The remaining energy source can be remaining electricity, remaining gasoline, or remaining natural gas, etc., which is not limited in this embodiment.
[0132] S24: searching for a second movable carrier capable of completing the order from the first movable carriers according to the remaining energy amount.
[0133] To facilitate the determination of the second movable carrier that can complete the order, the total length of the routes of each first movable carrier from the current position to the current position, from the trigger position to the destination position, and from the destination position to the nearest energy replenishment point can be calculated, and the target energy source that needs to be consumed is determined based on the total length of each route. Each remaining energy source is compared with the target energy source, and the first movable carrier whose remaining energy source exceeds the target energy source is used as the second movable carrier that can complete the order.
[0134] S25: Obtaining road condition information from each second movable carrier to the current position.
[0135] In a specific implementation, the traffic condition information is information used to reflect congestion conditions.
[0136] S26: Selecting a candidate movable carrier from the second movable carrier according to the road condition information.
[0137] In order to avoid congestion when the second movable carrier travels to the current location, thereby causing the user to wait for a long time, in this embodiment, the road condition information from each second movable carrier to the current location can be obtained.
[0138] In addition, the embodiment of the present invention also provides an order distribution device, referring to Figure 6 , the order distribution device comprises:
[0139] The data extraction module 10 is used to extract the user device identifier and the current location from the order when receiving the order sent by the user device;
[0140] A carrier selection module 20, configured to select at least one to-be-selected movable carrier from a movable carrier resource pool according to the current position;
[0141] An identification adding module 30, configured to add a to-be-confirmed identification for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identification is generated based on the user equipment identification;
[0142] The order allocation module 40 is used to allocate an order to the target movable carrier according to the received state change request of the target movable carrier and the to-be-confirmed identifier of each movable carrier in the movable carrier resource pool.
[0143] This embodiment adopts the above scheme, by adding a pending confirmation identifier generated based on the user equipment identifier to the selected movable carrier in the movable carrier resource pool, and allocating an order to the target movable carrier according to the received status change request of the target movable carrier and the pending confirmation identifier of each movable carrier in the movable carrier resource pool. The pending confirmation identifier of the target movable carrier can be used to distinguish whether to allocate an order, thereby avoiding conflicts between orders and status changes and preventing waste of user order resources.
[0144] It should be noted that each module in the above-mentioned device can be used to implement each step in the above-mentioned method and achieve corresponding technical effects, which will not be described in detail in this embodiment.
[0145] Reference Figure 7 , Figure 7 The schematic diagram is a structural diagram of a server in a hardware operating environment involved in an embodiment of the present invention.
[0146] like Figure 7 As shown, the server may include: a processor 1001, such as a CPU, a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.
[0147] Those skilled in the art will understand that Figure 7 The structure shown in the figure does not constitute a limitation on the server, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0148] like Figure 7 As shown, the memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and an order distribution program.
[0149] exist Figure 7 In the server shown, the network interface 1004 is mainly used for data communication with the external network; the user interface 1003 is mainly used for receiving the user's input instructions; the removable carrier calls the order allocation program stored in the memory 1005 through the processor 1001, and performs the following operations:
[0150] When receiving an order sent by a user device, extracting a user device identifier and a current location from the order;
[0151] Selecting at least one to-be-selected removable carrier from a removable carrier resource pool according to the current position;
[0152] Adding a to-be-confirmed identifier for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identifier is generated based on the user equipment identifier;
[0153] An order is allocated to the target movable carrier according to a received state change request of the target movable carrier and a to-be-confirmed identifier of each movable carrier in the movable carrier resource pool.
[0154] Further, the to-be-confirmed identifier is generated based on the user equipment identifier and the order receiving time; the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0155] Upon receiving a state change request of a target removable carrier, determining whether the target removable carrier has multiple to-be-confirmed identifiers;
[0156] When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier;
[0157] When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0158] Further, the to-be-confirmed identifier is generated based on the user equipment identifier and the order receiving time; the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0159] When receiving the carrier allocation instruction, taking the removable carrier with the to-be-determined identifier in the removable carrier resource pool as the removable carrier to be allocated;
[0160] Counting the number of first identifiers of each identifier to be determined;
[0161] Sort the to-be-confirmed identifiers in ascending order of the number of first identifiers to obtain a sorting result;
[0162] Traversing the to-be-determined identifiers according to the sorting result, and taking the traversed to-be-determined identifiers as the current identifiers;
[0163] Searching for a pending removable carrier having the current identifier from the removable carrier resource pool;
[0164] Obtain the number of second identifications of the identifications to be determined of each removable carrier to be determined;
[0165] Taking the undetermined removable carrier with the least number of the second identifications as the target removable carrier;
[0166] When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier;
[0167] When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
[0168] Further, the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0169] Obtaining the user device identification and order receiving time;
[0170] Formatting the user equipment identifier and order receiving time;
[0171] The formatted user device identifier and order receiving time are combined to obtain the information to be allocated;
[0172] The information to be allocated is saved in a preset storage area, and the storage address of the information to be allocated in the preset storage area is used as a to-be-confirmed identifier.
[0173] Further, the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0174] Determining the straight-line distance between each movable carrier in the movable carrier resource pool and the current position;
[0175] The movable carrier whose straight-line distance is less than the preset distance threshold is used as the first movable carrier;
[0176] Acquiring the remaining energy amount of each first movable carrier;
[0177] searching, from the first movable carrier, a second movable carrier capable of completing the order according to the remaining energy amount;
[0178] Acquiring road condition information from each second movable carrier to the current position;
[0179] A to-be-selected movable carrier is selected from the second movable carrier according to the road condition information.
[0180] Further, the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0181] Performing overall status detection on each movable carrier;
[0182] Determine whether the movable carrier that has passed the vehicle status detection is in a state where it can receive orders;
[0183] The removable carrier that is in the order-receiving state is added to the removable carrier resource pool.
[0184] Further, the processor 1001 may call the order allocation program stored in the memory 1005, and further perform the following operations:
[0185] Sending a detection instruction to each movable carrier, so that each movable carrier collects and feeds back status information of sensors on each component after receiving the detection instruction;
[0186] Performing state prediction based on state information fed back by each movable carrier to obtain a prediction result;
[0187] When the prediction result is that the state is normal, it is determined that the overall state detection of the movable carrier has passed.
[0188] This embodiment adopts the above scheme, by adding a pending confirmation identifier generated based on the user equipment identifier to the selected movable carrier in the movable carrier resource pool, and allocating an order to the target movable carrier according to the received status change request of the target movable carrier and the pending confirmation identifier of each movable carrier in the movable carrier resource pool. The pending confirmation identifier of the target movable carrier can be used to distinguish whether to allocate an order, thereby avoiding conflicts between orders and status changes and preventing waste of user order resources.
[0189] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.
[0190] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0191] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present invention.
[0192] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. An order allocation method based on autonomous driving, It is characterized in that The order allocation method based on autonomous driving comprises the following steps: When receiving an order sent by a user device, extracting a user device identifier and a current location from the order; Selecting at least one to-be-selected removable carrier from a removable carrier resource pool according to the current position; Adding a to-be-confirmed identifier for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identifier is generated based on the user equipment identifier; An order is allocated to the target removable carrier based on a received status change request of the target removable carrier and the pending identification of each removable carrier in the removable carrier resource pool, wherein the status change request is a request sent when the target removable carrier goes offline, and the target removable carrier is determined by sorting results in ascending order of the number of first identifications of each pending identification, and the pending identification is traversed according to the sorting results to obtain the current identification, and is determined from the removable carrier resource pool according to the current identification.
2. The order allocation method based on autonomous driving according to claim 1, It is characterized in that The to-be-confirmed identifier is generated based on the user device identifier and the order receiving time; The step of allocating an order to the target removable carrier according to the received state change request of the target removable carrier and the to-be-confirmed identifiers of each removable carrier in the removable carrier resource pool comprises: Upon receiving a state change request of a target removable carrier, determining whether the target removable carrier has multiple to-be-confirmed identifiers; When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier; When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
3. The order allocation method based on autonomous driving according to claim 1, It is characterized in that The to-be-confirmed identifier is generated based on the user device identifier and the order receiving time; After the step of adding a pending confirmation mark to the selected movable carrier in the movable carrier resource pool, the order allocation method based on automatic driving further includes: When receiving the carrier allocation instruction, taking the removable carrier with the to-be-determined identifier in the removable carrier resource pool as the removable carrier to be allocated; Counting the number of first identifiers of each identifier to be determined; Sort the to-be-confirmed identifiers in ascending order of the number of first identifiers to obtain a sorting result; Traversing the to-be-determined identifiers according to the sorting result, and taking the traversed to-be-determined identifiers as the current identifiers; Searching for a pending removable carrier having the current identifier from the removable carrier resource pool; Obtain the number of second identifications of the identifications to be determined of each removable carrier to be determined; Taking the undetermined removable carrier with the least number of the second identifications as the target removable carrier; When there is only one identification to be confirmed on the target removable carrier, assigning the target removable carrier to the target user equipment corresponding to the identification to be confirmed on the target removable carrier, removing the target removable carrier from the removable carrier resource pool, and sending the order corresponding to the target user equipment to the target removable carrier; When there are multiple pending confirmation identifiers on the target removable carrier, search for the target user device identifier with the earliest order reception time among the pending confirmation identifiers on the target removable carrier, assign the target removable carrier to the target user device corresponding to the target user device identifier, remove the target removable carrier from the removable carrier resource pool, and send the order corresponding to the target user device to the target removable carrier.
4. The order allocation method based on autonomous driving according to claim 2 or 3, It is characterized in that Before the step of adding a pending confirmation mark for the selected movable carrier in the movable carrier resource pool, the order allocation method based on automatic driving further includes: Obtaining the user device identification and order receiving time; Formatting the user equipment identifier and order receiving time; The formatted user device identifier and order receiving time are combined to obtain the information to be allocated; The information to be allocated is saved in a preset storage area, and the storage address of the information to be allocated in the preset storage area is used as a to-be-confirmed identifier.
5. The order allocation method based on autonomous driving according to any one of claims 1 to 3, It is characterized in that The step of selecting at least one removable carrier to be selected from a removable carrier resource pool according to the current position includes: Determining the straight-line distance between each movable carrier in the movable carrier resource pool and the current position; The movable carrier whose straight-line distance is less than the preset distance threshold is used as the first movable carrier; Acquiring the remaining energy amount of each first movable carrier; searching, from the first movable carrier, a second movable carrier capable of completing the order according to the remaining energy amount; Acquiring road condition information from each second movable carrier to the current position; A to-be-selected movable carrier is selected from the second movable carrier according to the road condition information.
6. The order allocation method based on autonomous driving according to any one of claims 1 to 3, It is characterized in that Before the step of selecting at least one movable carrier to be selected from the movable carrier resource pool according to the current position, the order allocation method based on automatic driving further includes: Performing overall status detection on each movable carrier; Determine whether the movable carrier that has passed the vehicle status detection is in a state where it can receive orders; The removable carrier that is in the order-receiving state is added to the removable carrier resource pool.
7. The order allocation method based on autonomous driving according to claim 6, It is characterized in that The step of performing overall status detection on each movable carrier includes: Sending a detection instruction to each movable carrier, so that each movable carrier collects and feeds back status information of sensors on each component after receiving the detection instruction; Performing state prediction based on state information fed back by each movable carrier to obtain a prediction result; When the prediction result is that the state is normal, it is determined that the overall state detection of the movable carrier has passed.
8. An order distribution device based on automatic driving, It is characterized in that The order allocation device based on automatic driving comprises: A data extraction module, configured to extract a user device identifier and a current location from an order when receiving an order sent by a user device; A carrier selection module, configured to select at least one to-be-selected movable carrier from a movable carrier resource pool according to the current position; an identification adding module, configured to add a to-be-confirmed identification for the selected removable carrier in the removable carrier resource pool, wherein the to-be-confirmed identification is generated based on the user equipment identification; An order allocation module based on autonomous driving is used to allocate an order to a target movable carrier according to a received state change request of the target movable carrier and the pending identification of each movable carrier in the movable carrier resource pool, wherein the state change request is a request sent when the target movable carrier goes offline, and the target movable carrier is determined by sorting results in ascending order of the number of first identifications of each pending identification, and the pending identification is traversed according to the sorting results to obtain the current identification, and is determined from the movable carrier resource pool according to the current identification.
9. A server, It is characterized in that The server includes: a memory, a processor, and an order allocation program based on autonomous driving stored in the memory and executable on the processor, wherein the order allocation program based on autonomous driving is configured to implement the steps of the order allocation method based on autonomous driving as described in any one of claims 1 to 7.
10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores an order allocation program based on autonomous driving, and when the order allocation program based on autonomous driving is executed by a processor, the steps of the order allocation method based on autonomous driving are implemented as described in any one of claims 1 to 7.
