Disclosure of Invention
In view of the above-mentioned drawbacks or shortcomings in the prior art, it is desirable to provide a method, an apparatus, a device and a storage medium for sorting express mail, so as to solve the problem of resource waste caused by empty sorting grids due to distribution of one sorting grid in each sorting flow direction in the prior art.
In a first aspect, an embodiment of the present application provides a method for sorting a express mail, including:
Acquiring historical sorting data in a preset time period;
counting the quantity and frequency of pieces in each time granularity of the preset time period in each sorting flow direction in the historical sorting data;
Determining the bottom-of-pocket index of each sorting flow direction according to the quantity and the frequency of each sorting flow direction, and sorting the sorting flow directions according to the size of the bottom-of-pocket index;
And selecting a plurality of sorting flows of the number of the spam from the sorting from the minimum value of the spam index, and distributing the sorting flows to the same spam lattice mouth.
Further, the number of the underreceptacles is a maximum m value satisfying the following relation,
Wherein, F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction, a is the number of the grids of the sorting cabinet corresponding to the grid of the pocket bottom, C is the grid amplification factor of the sorting cabinet, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, b is the sorting efficiency of the sorting cabinet, and d is the sorting efficiency factor of the grid cabinet.
Further, the spam score is determined according to the following relationship:
Wherein, I i is the bottom of pocket index of the ith sorting flow direction, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, and F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction.
Further, the sorting objects in the pocket bottom grid mouth are subjected to secondary sorting, and the secondary sorting comprises:
Sequentially scanning to obtain sorting flows of the sorting objects, distributing secondary sorting grids to each sorting flow, emptying the sorting objects in the secondary sorting grids reaching the maximum loading capacity when any secondary sorting grid reaches the maximum loading capacity, and distributing the current sorting flows which are obtained by scanning and different from other sorting flows to the emptied secondary sorting grids.
Further, the secondary sorting includes:
Sequentially scanning to obtain sorting flows of the objects to be sorted, distributing secondary sorting grids to each sorting flow, emptying any secondary sorting grid when the N-th sorting flow obtained by current scanning is larger than the total secondary sorting grids of the sorting cabinet, and distributing the N-th sorting flow to the emptied secondary sorting grids.
In a second aspect, the present invention provides a express mail sorting apparatus, comprising:
An acquisition unit for acquiring history sorting data within a predetermined time period;
A statistics unit for counting the quantity and frequency of pieces in each time granularity of the predetermined time period for each sorting flow direction in the history sorting data;
the sorting flow direction sorting unit is used for determining the bottom-of-pocket index of each sorting flow direction according to the quantity and the frequency of each piece in each sorting flow direction and sorting the sorting flow directions according to the size of the bottom-of-pocket index;
and the distribution unit is used for selecting the sorting flow directions of the quantity of the spam from the sorting from the minimum value of the spam index and distributing the sorting flow directions to the same spam grid.
Further, the method further comprises the following steps:
a spam number calculation unit for determining a maximum m value satisfying the following relation as a spam number,
Wherein, F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction, a is the number of the grids of the sorting cabinet corresponding to the grid of the pocket bottom, C is the grid amplification factor of the sorting cabinet, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, b is the sorting efficiency of the sorting cabinet, and d is the sorting efficiency factor of the grid cabinet.
Further, the method further comprises the following steps:
a spam score calculation unit configured to determine the spam score according to the following relationship:
Wherein, I i is the bottom of pocket index of the ith sorting flow direction, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, and F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction.
Further, the method further comprises the following steps:
The secondary sorting unit is used for sequentially scanning and obtaining sorting flow directions of the sorting objects, distributing secondary sorting grids to each sorting flow direction, emptying the sorting objects in the secondary sorting grids reaching the maximum loading capacity when any secondary sorting grid reaches the maximum loading capacity, and distributing the current sorting flow directions which are different from other sorting flow directions and obtained by scanning to the emptied secondary sorting grids.
Further, the method further comprises the following steps:
The secondary sorting unit is used for sequentially scanning and obtaining sorting flow directions of objects to be sorted, each sorting flow direction is provided with a secondary sorting grid, when the N-th sorting flow direction obtained by current scanning is larger than the total number of the secondary sorting grids of the sorting cabinet, any secondary sorting grid is emptied, and the N-th sorting flow direction is distributed to the emptied secondary sorting grid.
In a third aspect, the present invention provides a computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the method described above when executing the computer program.
In a fourth aspect, the present invention provides a computer readable storage medium having stored thereon a computer program which when executed by a processor implements the method described above.
According to the scheme, the sorting flows are ordered according to the size of the pocket bottom index determined by the piece quantity and the frequency corresponding to each time granularity of each sorting flow, the sorting flows with the minimum value of the pocket bottom index are selected from the ordering and distributed to the same pocket bottom grid, namely, the sorting flows with small piece quantity and low frequency are unified to the same grid, the uncertain risk of the flows is concentrated, only grid is not required to be distributed for each flow, the resource utilization rate of sorting equipment is improved, and the demand of the equipment is further reduced.
Detailed Description
The application is described in further detail below with reference to the drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the application and are not limiting of the application. It should be noted that, for convenience of description, only the portions related to the application are shown in the drawings.
It should be noted that, without conflict, the embodiments of the present application and features of the embodiments may be combined with each other. The application will be described in detail below with reference to the drawings in connection with embodiments.
Referring to fig. 1, fig. 1 shows a flow chart of a method for sorting express items according to an embodiment of the application.
As shown in fig. 1, the method includes:
S1, acquiring historical sorting data in a preset time period;
the method for acquiring the historical sorting quantity in the preset time period in the embodiment of the application can be realized by directly acquiring from a transit field service center or through network transmission, or can be realized by other transit server transit data. The historical sorting data at least comprises sorted flow direction, sorting time and the like of the sorting objects
The predetermined period of time may be, but is not limited to, 30 days, 60 days, 90 days, etc.
S2, counting the quantity and frequency of pieces in each time granularity of the preset time period in each sorting flow direction in the historical sorting data;
After the historical sorting data is obtained, the sorting flows are counted to obtain several sorting flows in the historical sorting data, which are all sorting flows. Dividing the preset time period into a plurality of time periods, wherein each time period is a time granularity, counting the corresponding part quantity C and frequency F of each sorting flow direction in each time granularity,
For example, the predetermined time period is 30 days, the time granularity is 1 day, and when the sorting equipment sorts for 30 days, the total sorting flow directions in the 30 days are counted, and the number of sorting objects corresponding to each time granularity and the occurrence frequency in each sorting flow direction are counted.
The amount and frequency of time granularity pieces corresponding to each sorting flow direction are shown in the following table:
Quantity of parts |
T1 |
T2 |
... |
Tn |
Frequency of |
T1 |
T2 |
... |
Tn |
D1 |
C11 |
C12 |
... |
C1n |
D1 |
F11 |
F12 |
... |
F1n |
D2 |
C21 |
C22 |
... |
C2n |
D2 |
F21 |
F22 |
... |
F2n |
... |
... |
... |
... |
... |
... |
... |
... |
... |
... |
Dm |
Cm1 |
Cm2 |
... |
Cmn |
Dm |
Fm1 |
Fm2 |
... |
Fmn |
T j in the above table is the j-th time granularity, D i is the i-th sort flow direction, C ij is the j-th time granularity of the i-th sort flow direction, F ij is the frequency of the j-th time granularity of the i-th sort flow direction, i=1, 2, 3.
S3, determining the bottom-of-pocket index of each sorting flow direction according to the quantity and the frequency of each sorting flow direction, and sorting the sorting flow directions according to the size of the bottom-of-pocket index;
The bottom-of-pocket index is used for representing the uncertainty of the sorting objects in the preset time period, the larger the bottom-of-pocket index is, the smaller the uncertainty is, the larger the number of the sorting objects in the corresponding sorting flow direction is, the larger the uncertainty is, the smaller the bottom-of-pocket index is, the smaller the number of the sorting objects in the corresponding sorting flow direction is, the probability of the occurrence is small, namely the bottom-of-pocket index is positively related to the piece quantity and the frequency in the corresponding sorting flow direction, namely the larger the bottom-of-pocket index in the corresponding sorting flow direction is, and the larger the frequency is, the larger the bottom-of-pocket index in the corresponding sorting flow direction is. After determining the bottom-of-pocket index of each sorting flow direction, sorting the sorting flow directions according to the size of the bottom-of-pocket index, wherein the sorting manner can be in ascending order or in descending order.
As one implementation, the spam score may be determined according to the following relationship:
Wherein, I i is the bottom of pocket index of the ith sorting flow direction, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, and F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction.
S4, selecting a plurality of sorting flows of the number of the spam from the sorting from the minimum value of the spam index, and distributing the sorting flows to the same spam grid.
For example, there are 180 sorting flows, the 180 sorting flows are sorted in an ascending order of the bottom of the pocket index, if the number of the bottom of the pocket is 100, the first 100 sorting flows are selected as bottom of the pocket flow, and the bottom of the pocket flow is allocated to a bottom of the pocket, and the sorting object is, for example, an express delivery.
Of course, the 180 sorting flows may be sorted in descending order of the bottom index, and if the number of the bottom is 100, the last 100 sorting flows are selected as bottom flows, and the bottom flows are allocated to a bottom grid.
As one implementation, each of the other flows may be assigned a sort bin in addition to the other flows assigned to the same spam bin. Of course, other flows may also be sorted according to other predetermined sorting schemes according to predetermined sorting requirements.
According to the scheme, the sorting flows are ordered according to the size of the pocket bottom index determined by the piece quantity and the frequency corresponding to each time granularity of each sorting flow, the sorting flows with the minimum value of the pocket bottom index are selected from the ordering and distributed to the same pocket bottom grid, namely, the sorting flows with small piece quantity and low frequency are unified to the same grid, the uncertain risk of the flows is concentrated, only grid is not required to be distributed for each flow, the resource utilization rate of sorting equipment is improved, and the demand of the equipment is further reduced.
Further, the number of the stomachers is the maximum m value satisfying the following relation,
Wherein, F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction, a is the number of the grids of the sorting cabinet corresponding to the grid of the pocket bottom, C is the grid amplification factor (which can be set or regulated according to experience), C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, b is the sorting efficiency of the sorting cabinet, and d is the sorting efficiency factor (which can be set or regulated according to experience) of the grid cabinet. The sorting cabinet performs secondary sorting on the sorting objects of 100 sorting flows allocated to the pocket openings in the above embodiment, and generally, in order to save resources, the number of openings of the sorting cabinet is smaller than the number of sorting flows allocated to the pocket openings.
Further, the sorting objects in the pocket bottom grid mouth are subjected to secondary sorting, and the secondary sorting comprises:
Sequentially scanning to obtain sorting flows of the sorting objects, distributing a secondary sorting grid to each sorting flow, emptying the sorting objects in the secondary sorting grids reaching the maximum loading capacity when any secondary sorting grid reaches the maximum loading capacity, and distributing the current sorting flows different from other sorting flows obtained by scanning to the emptied secondary sorting grids.
For example, the sorting cabinet is provided with 30 secondary sorting grids, sorting objects in the pocket bottom grid are provided with 50 sorting flows, sorting flows of the sorting objects are obtained by scanning sorting correspondences in sequence, each sorting flow is obtained, one secondary sorting grid is allocated to the newly obtained sorting flow in the sorting cabinet, as sorting is carried out, if a certain secondary sorting grid reaches the maximum loading capacity, sorting objects in the secondary sorting grid reaching the maximum loading capacity are emptied, and the current sorting flow different from other sorting flows obtained by scanning in sequence is allocated to the emptied secondary sorting grid. I.e. which secondary sort bin is full, the sorting objects within that secondary sort bin are emptied and the sorting direction of that secondary sort bin is reconfigured. By adopting the scheme, the sorting capacity of the sorting cabinet can be maximized, and the sorting efficiency corresponding to sorting in the pocket bottom grid openings is improved.
Further, the sorting objects in the pocket bottom grid mouth are subjected to secondary sorting, and the secondary sorting comprises:
Sequentially scanning to obtain sorting flows of the objects to be sorted, distributing secondary sorting grids to each sorting flow, emptying any secondary sorting grid when the N-th sorting flow obtained by current scanning is larger than the total secondary sorting grids of the sorting cabinet, and distributing the N-th sorting flow to the emptied secondary sorting grids.
In actual secondary sorting, there is a case where the sorting cabinet has 30 secondary sorting pockets, the sorting objects in the pocket bottom pockets have 50 sorting flows, the sorting flows of the sorting objects are obtained by scanning the sorting correspondences in turn, each sorting flow is obtained by assigning a secondary sorting pocket to the newly obtained sorting flow in the sorting cabinet, as sorting proceeds, 30 secondary sorting pockets are not filled up when the 31 st sorting flow is obtained by scanning, and at this time, any secondary sorting pocket is emptied for sorting to proceed, and the 31 st sorting flow is assigned to the emptied secondary sorting pocket. If the 32 nd sorting flow direction is obtained by scanning along with sorting, any secondary sorting grid is emptied again, and the 32 nd sorting flow direction is distributed to the emptied secondary sorting grid. And if a new sorting flow direction is obtained through scanning, distributing the secondary sorting grids in the above mode. By adopting the scheme, the sorting capacity of the sorting cabinet can be maximized, the sorting efficiency corresponding to sorting in the pocket bottom grid openings is improved, and the sorting flexibility is improved.
It should be noted that although the operations of the method of the present invention are depicted in the drawings in a particular order, this does not require or imply that the operations must be performed in that particular order or that all of the illustrated operations be performed in order to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step to perform, and/or one step decomposed into multiple steps to perform.
Further, referring to fig. 2, fig. 2 shows a schematic diagram of a express sorting apparatus according to an embodiment of the present application. The device can be applied to sorting of express packages.
As shown in fig. 2, the device comprises an acquisition unit 1 for acquiring historical sorting data in a preset time period, a statistics unit 2 for counting the piece quantity and frequency of each sorting flow direction in each time granularity of the preset time period in the historical sorting data, a sorting flow direction sorting unit 3 for determining the spam index of each sorting flow direction according to the piece quantity and the frequency of each sorting flow direction and sorting the sorting flow directions according to the size of the spam index, and a distribution unit 4 for selecting the sorting flow directions of the spam number from the sorting according to the minimum value of the spam index and distributing the sorting flow directions to the same spam grid.
The device is used for implementing the method of the above embodiment, and the working principle and effect thereof are referred to the above method embodiment, and are not repeated here.
Further, as shown in FIG. 3, the system further comprises a spam quantity calculation unit 5 for determining a maximum m value satisfying the following relation as a spam quantity,
Wherein, F ij is the frequency corresponding to the jth time granularity of the ith sorting flow direction, a is the number of the grids of the sorting cabinet corresponding to the grid of the pocket bottom, C is the grid amplification factor of the sorting cabinet, C ij is the piece quantity corresponding to the jth time granularity of the ith sorting flow direction, b is the sorting efficiency of the sorting cabinet, and d is the sorting efficiency factor of the grid cabinet.
Further, as shown in fig. 4, the sorting system further comprises a secondary sorting unit 6, wherein the secondary sorting unit is used for sequentially scanning and obtaining sorting flow directions of the sorting objects, each sorting flow direction is distributed with a secondary sorting grid, when any secondary sorting grid reaches the maximum loading capacity, sorting objects in the secondary sorting grid reaching the maximum loading capacity are emptied, and the current sorting flow directions which are different from other sorting flow directions and obtained by scanning are distributed to the emptied secondary sorting grid.
Further, the secondary sorting unit 6 is further configured to sequentially scan to obtain sorting flows of the objects to be sorted, allocate a secondary sorting bin to each sorting flow, empty any secondary sorting bin when the nth sorting flow obtained by the current scanning is greater than the total number of secondary sorting bins of the sorting cabinet, and allocate the nth sorting flow to the empty secondary sorting bin.
Referring now to fig. 5, a schematic diagram of a computer system suitable for use in implementing a certain sort site 500 of an embodiment of the present application is shown.
As shown in fig. 5, the computer system 500 includes a Central Processing Unit (CPU) 501, which can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the system 500 are also stored. The CPU 501, ROM 502, and RAM 503 are connected to each other through a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
Connected to the I/O interface 505 are an input section 506 including a keyboard, a mouse, and the like, an output section 507 including a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, a speaker, and the like, a storage section 508 including a hard disk, and the like, and a communication section 509 including a network interface card such as a LAN card, a modem, and the like. The communication section 509 performs communication processing via a network such as the internet. The drive 510 is also connected to the I/O interface 505 as needed. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as needed so that a computer program read therefrom is mounted into the storage section 508 as needed.
In particular, according to embodiments of the present disclosure, the process described above with reference to fig. 1 may be implemented as a computer software program. For example, embodiments of the present disclosure include a method of sorting a good, including a computer program tangibly embodied on a machine-readable medium, the method of sorting including program code for performing the method of fig. 1. In such an embodiment, the computer program may be downloaded and installed from a network via the communication portion 509, and/or installed from the removable media 511.
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units or modules involved in the embodiments of the present application may be implemented in software or in hardware. The described units or modules may also be provided in a processor, which may be described as, for example, a processor comprising an acquisition unit, a statistics unit, a sort flow ordering unit. The names of these units or modules do not constitute a limitation on the unit or module itself in some cases, and the acquisition unit may also be described as "a unit for acquiring history sorting data within a predetermined time period", for example.
In another aspect, the present application further provides a computer readable storage medium, which may be a computer readable storage medium included in the foregoing apparatus in the foregoing embodiment, or may be a computer readable storage medium that exists separately and is not assembled into a device. The computer readable storage medium stores one or more programs for use by one or more processors in performing the method of the present application for express mail sorting.
The above description is only illustrative of the preferred embodiments of the present application and of the principles of the technology employed. It will be appreciated by persons skilled in the art that the scope of the application referred to in the present application is not limited to the specific combinations of the technical features described above, but also covers other technical features formed by any combination of the technical features described above or their equivalents without departing from the inventive concept described above. Such as the above-mentioned features and the technical features disclosed in the present application (but not limited to) having similar functions are replaced with each other.