Packing scheme search method, device, electronic device and storage medium
By simultaneously optimizing the packing rate and balance in the packing problem, using technical means such as tree search algorithm and block selection function, the problem that the packing solution in the existing technology cannot meet the business requirements is solved, and efficient multi-objective optimization and the provision of Pareto solutions are achieved.
Patent Information
- Application Number
- CN202410422622.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-09
- Publication Date
- 2025-02-28
- Estimated Expiration
- 2044-04-09
AI Technical Summary
The prior art often sacrifices balance indicators when optimizing the packing rate, resulting in the packing solution being unable to meet business requirements. The multi-objective optimization method takes a long time to deal with large-scale problems, making it difficult to improve search efficiency.
A search method for packing scheme is proposed. By simultaneously optimizing the two goals of packing rate and balance, it realizes multi-objective optimization of packing scheme search, and uses technical means such as tree search algorithm and block selection function to improve search efficiency and provide Pareto solution.
It achieves the simultaneous optimization of packing rate and balance, improves the search efficiency of multi-objective packing solutions, can effectively provide Pareto solutions, and provides decision makers with diverse and rich packing reference solutions.
Smart Images

Figure 00000000_0000_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of logistics, and in particular to a method, device, electronic device and storage medium for searching for a packing solution. Background Art
[0002] The packing problem is an important issue in the field of logistics management. It requires determining the number of containers and the location and placement of the goods in them. Most optimization targets are based on container utilization. The classic packing model does not consider many real-world constraints, such as load balance. However, most algorithms and technologies sacrifice balance indicators when optimizing utilization indicators, and the final solution cannot meet business requirements.
[0003] Currently, the packing problem is modeled as a single-objective optimization problem and solved using a single-objective optimization method. The limitations of the single-objective optimization method are: (1) the hard constraint modeling method cannot provide a satisfactory solution; (2) the soft constraint method is difficult to determine the appropriate weight coefficient; (3) it cannot provide a Pareto set for decision makers to use. In addition, the population-based multi-objective optimization paradigm takes a long time to deal with large-scale problems. Based on this, how to improve the search efficiency of multi-objective packing solutions has become an urgent problem to be solved. Summary of the invention
[0004] The present application aims to solve at least one of the technical problems existing in the prior art. To this end, the present application proposes a packing solution search method, which realizes multi-objective optimization of packing solution search by optimizing both packing rate and balance at the same time, improves the search efficiency of multi-objective packing solutions, and can effectively provide Pareto solutions, thereby providing decision makers with diverse and rich packing reference solutions.
[0005] The present application also proposes a search device, an electronic device and a storage medium for a packaging solution.
[0006] A method for searching a packing solution according to an embodiment of the first aspect of the present application includes:
[0007] Determining free space for cargo to be loaded; the free space represents space in the container not occupied by cargo;
[0008] Determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space;
[0009] Determine multiple complete solutions of packing scheme based on the free space and the multiple cargo blocks to be loaded;
[0010] Based on the maximum loading rate and the minimum balance deviation rate of the packing solution, each of the complete solutions is evaluated, and the packing solution is searched based on the evaluation results of the complete solutions.
[0011] According to one embodiment of the present application, the maximum loading rate is determined based on the following method:
[0012] Determining the maximum loading rate based on the packing information of the goods to be loaded, the length, width and height of the goods to be loaded, and the length, width and height of the container;
[0013] The minimized balance deviation rate is determined based on the following method:
[0014] Determining the front-to-back relative offset of the cargo to be loaded based on the total weight and the front-to-back offset weight of the cargo to be loaded;
[0015] Determining the left-right relative offset of the cargo to be loaded based on the total weight and the left-right offset weight of the cargo to be loaded;
[0016] The minimized balance offset rate is determined based on the front-rear relative offset and the left-right relative offset.
[0017] According to an embodiment of the present application, the step of evaluating each complete solution based on the maximum loading rate and the minimum balance deviation rate of the packing solution includes:
[0018] Based on the minimized balance offset rate, obtaining the front-to-rear relative offset and the left-to-right relative offset;
[0019] Determining a weighted objective function of the complete solution based on the maximized loading rate and its first weight coefficient, the front-to-back relative offset and its second weight coefficient, and the left-to-right relative offset and its third weight coefficient;
[0020] Each of the complete solutions is evaluated based on the weighted objective function.
[0021] According to an embodiment of the present application, the step of evaluating each complete solution based on the maximum loading rate and the minimum balance deviation rate of the packing solution includes:
[0022] Based on the maximized loading rate and the minimized equilibrium deviation rate, the complete solutions are non-dominated sorted to obtain a non-dominated solution set;
[0023] Determine the crowding distance between every two non-dominated solutions in the non-dominated solution set;
[0024] Based on the crowding distance, the non-dominated solutions are screened to complete the evaluation of each of the complete solutions.
[0025] According to one embodiment of the present application, determining the free space for cargo to be loaded includes:
[0026] Determine the Manhattan distance between each vertex of each free space in the free space list and the vertex corresponding to the container;
[0027] The free space corresponding to the minimum Manhattan distance is used as the free space for the goods to be loaded.
[0028] According to one embodiment of the present application, the determining a plurality of cargo blocks to be loaded based on the cargo blocks to be loaded and the free space includes:
[0029] Determining a plurality of objective functions based on the attribute values corresponding to the combination of the cargo block and the free space;
[0030] Determining a block selection function based on the objective function and its weight;
[0031] Based on the block selection function, a plurality of cargo blocks to be loaded are selected from a block list.
[0032] According to one embodiment of the present application, the block list is updated in the following manner:
[0033] Retain the cargo blocks corresponding to the unloaded cargo in the block list; and
[0034] Delete the cargo blocks in the block list whose cargo quantity is greater than the set unloaded quantity.
[0035] A device for searching a packing solution according to an embodiment of the second aspect of the present application includes:
[0036] A free space determination module, used to determine the free space for cargo to be loaded; the free space represents the space in the container that is not occupied by cargo;
[0037] A cargo block determination module to be loaded, configured to determine a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space;
[0038] A complete solution determination module, used to determine multiple complete solutions of the packing scheme based on the free space and the multiple cargo blocks to be loaded;
[0039] A search module is used to evaluate each of the complete solutions based on the maximum loading rate and the minimum balance deviation rate of the packing solution, and search for the packing solution based on the evaluation results of the complete solution.
[0040] According to an electronic device of an embodiment of the third aspect of the present application, the electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, a method for searching for a packing solution as described above is implemented.
[0041] According to the non-transitory computer-readable storage medium of the fourth aspect embodiment of the present application, a computer program is stored thereon, and when the computer program is executed by a processor, a method for searching for a packing scheme as described in any one of the above is implemented.
[0042] The above one or more technical solutions in the embodiments of the present application have at least one of the following technical effects:
[0043] It can optimize both packing rate and balance at the same time, realize multi-objective optimization of packing scheme search, improve the search efficiency of multi-objective packing scheme, and effectively provide Pareto solution, thus providing decision makers with diverse and rich packing reference schemes.
[0044] Additional aspects and advantages of the present application will be given in part in the description below, and in part will become apparent from the description below, or will be learned through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0046] Figure 1 It is a flowchart of a method for searching a packing solution provided in an embodiment of the present application;
[0047] Figure 2 is a schematic diagram of the correspondence between the free space and the container vertices provided in the embodiment of the present application;
[0048] Figure 3 This is a schematic diagram of free space generation after a cargo block b provided in an embodiment of the present application is placed in a free space r;
[0049] Figure 4 It is a schematic diagram of space update after the cargo block b and the free space r overlap, provided by an embodiment of the present application;
[0050] Figure 5 It is a structural schematic diagram of a search device for a packing solution provided in an embodiment of the present application;
[0051] Figure 6 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0052] The following is a further detailed description of the implementation of the present application in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present application but cannot be used to limit the scope of the present application.
[0053] In the description of the embodiments of the present application, it should be noted that the terms "first", "second" and "third" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance.
[0054] In the embodiments of the present application, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0055] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the embodiments of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0056] The packing algorithm that considers the center of gravity balance can provide a safe and compliant packing solution, reduce losses caused by fines and safety accidents, avoid the secondary loading and excessive stay of goods at the destination port, and thus reduce international logistics costs. In the air transportation scenario, the position of the center of gravity has an impact on flight safety and efficiency. Even a small deviation from the ideal center of mass can lead to a significant increase in fuel consumption. Therefore, the packing algorithm that considers the center of gravity balance is extremely important both from a safety and economic perspective.
[0057] Currently, load balancing problems are modeled using a multi-objective form, aiming to minimize both the number of containers used and the load imbalance of the containers, for example, using a meta-heuristic algorithm for solving them. However, there are not many multi-objective solutions to the 3D-CLP (3D Container Loading Problem). Tree search algorithms are one of the most effective methods for solving single-box loading, but due to the limitations of the search mechanism, most tree search algorithms have a single goal of optimizing the loading rate, which cannot effectively provide a Pareto solution, and thus cannot provide decision makers with a variety of rich reference solutions.
[0058] Based on the above-mentioned problems, an embodiment of the present application proposes a method for searching for packing solutions to implement tree search for multi-target packing scenarios.
[0059] Figure 1 is a flow chart of a method for searching a packing solution provided in an embodiment of the present application. Figure 1 , the present application embodiment provides a method for searching a packing solution, including:
[0060] Step 100, determining the free space for cargo to be loaded.
[0061] This application uses a tree search algorithm to search for packing solutions, which is used to find a path to solve the problem in the search space, and to find a path from a certain initial state to a certain terminal state by exploring the search space. In the packing problem, the search space can be modeled as a tree, where each node represents a state or partial solution, and each edge represents a transition from one state to another. The intermediate state (or partial solution) corresponds to a partial loading solution, which consists of three components:
[0062] a. Free space list R: This list describes the available space in a container (such as a container). It can be a two-dimensional or three-dimensional representation to represent the available space inside the container. Among them, free space represents the space in the container that is not occupied by goods.
[0063] b. Remaining goods list C: This list contains all the goods that have not yet been loaded into the container.
[0064] c. Block list B: This list contains cargo blocks, where cargo blocks are generated by cargo to be loaded.
[0065] In the process of searching for a packing solution, it is necessary to continuously select free spaces for the goods to be loaded. Specifically, the Manhattan distance between each vertex of each free space in the free space list and the vertex corresponding to the container is determined, and then the free space corresponding to the smallest Manhattan distance is used as the free space for the goods to be loaded.
[0066] For example, Figure 2 As shown, each of the eight vertices of the free space corresponds to the eight corners of the container, and the corresponding relationships are (A1, B1), (A2, B2), (A3, B3), (A4, B4), (A5, B5), (A6, B6), (A7, B7) and (A8, B8). Assume that the coordinates of any vertex in the free space are (x1, y1, z1), and the coordinates of the container vertex corresponding to the vertex are (x2, y2, z2), then the Manhattan distance between the above two points is:
[0067] |x1-y1|+|y1-y2|+|z1-z2|;
[0068] When a free space needs to be selected to fill in the cargo, the Manhattan distance between each vertex of each free space and the vertex corresponding to the container is calculated, and the angle of the free space corresponding to the minimum Manhattan distance is found as the anchor angle. This means selecting an angle of the free space so that the Manhattan distance between the angle and a corner in the container is the minimum. Once the anchor angle is determined, the free space corresponding to the minimum Manhattan distance can be used as the free space for the cargo to be loaded, that is, the cargo to be loaded can be filled into the free space.
[0069] Assume that there are two free spaces in the free space list, namely free space 1 and free space 2. First, calculate the Manhattan distance between each vertex of free space 1 and each vertex of the container, and find that the minimum Manhattan distance is 1. Then, calculate the Manhattan distance between each vertex of free space 2 and each vertex of the container, and find that the minimum Manhattan distance is 3. Since the minimum Manhattan distance of free space 1 is smaller than the minimum Manhattan distance of free space 2, free space 1 is selected as the free space that matches the container most closely, that is, the free space to be loaded with goods.
[0070] By selecting the free space corresponding to the smallest Manhattan distance, it can be ensured that the goods are placed closest to other goods or the edge of the container, thereby maximizing the use of space, reducing space waste, and making packaging more compact and efficient.
[0071] Step 200: determining a plurality of cargo blocks to be loaded based on the cargo blocks to be loaded and the free space.
[0072] After selecting the free space, it is also necessary to select appropriate cargo blocks to fill the free space. Based on the cargo blocks of the cargo to be loaded and the free space, multiple cargo blocks to be loaded are determined. Specifically, based on the attribute values corresponding to the combination of cargo blocks and free space, multiple objective functions are determined; based on the objective functions and their weights, a block selection function is determined; based on the block selection function, multiple cargo blocks to be loaded are selected from the block list. Among them, the block selection function is:
[0073]
[0074] Where b is the cargo block, r is the free space, and ρ is the weight of the objective function. is the objective function, that is, the attribute value corresponding to the combination of cargo block b and free space r, i1 is the number of objective functions, i1 = 0, 1, 2, ..., n.
[0075] Attribute values refer to the numerical values or attributes that describe the characteristics of cargo blocks and free space, including the size, weight, shape, value and other characteristics of cargo blocks, as well as the remaining capacity, location, availability and other information of free space. Optionally, attribute values can be some numerical data, such as the length, width, height and weight of cargo blocks; or they can be discrete values that describe the characteristics of cargo, such as the type and shape of cargo. For free space, attribute values can be information describing the size, location, and constraints of space. In the block selection function, different attribute values reflect the degree of match or correlation between cargo blocks and free space. By considering these attribute values, the block selection function can evaluate the degree of fit between cargo blocks and free space, thereby helping the system to intelligently select the best packing solution.
[0076] Through the block selection function F(b, r, ρ), the top N cargo blocks to be loaded, namely candidate blocks, can be screened out.
[0077] F(b,r,ρ) is a universal block selection function. After concretizing F(b,r,ρ), it can be expressed as:
[0078]
[0079] Where b is the cargo block, θ is the coefficient vector, V(b) is the volume of the cargo block, P(b) is the mass of the cargo block, D(b) is the density of the cargo block, L(b) is the space loss rate of the free space after the cargo block is placed, and N(b) is the number of cargo in the cargo block. It can be understood that f i (b,r) is equivalent to V(b), P(b), D(b), L(b) and N(b), that is, the attribute values.
[0080] By defining a universal block selection function F(b,r,ρ), it can be applied to different types of cargo blocks and free spaces, realizing a universal cargo block selection method. This universality makes the algorithm more flexible and applicable, and can meet the needs of various packing problems. On the other hand, the block selection function F(b,r,ρ) considers the attribute values corresponding to different features separately, and combines them by multiplication, so that the influence of each attribute value can be accumulated and superimposed independently, thereby better reflecting the multi-faceted matching between cargo blocks and free spaces. By separating different attribute values, the selection of cargo blocks can be evaluated more accurately. In addition, the weight ρ in the block selection function F(b,r,ρ) can be used to adjust the importance of different attribute values. By adjusting the weight, the influence of each attribute value in the cargo block selection process can be flexibly controlled. Based on this, users can optimize the block selection function according to specific circumstances and needs to make it more in line with the requirements of actual problems.
[0081] The advantages of using the F(b,r,ρ) function for cargo block screening are its versatility, separation of attribute value effects, and flexibility in adjusting the importance of attribute values. These advantages make the cargo block selection process more intelligent, flexible, and effective, thereby improving the search efficiency and accuracy of the packing solution.
[0082] In one embodiment, in order to improve the search efficiency and the accuracy of the search space, the block list needs to be updated. The block list is updated in the following manner: retaining the cargo blocks corresponding to the unloaded cargo in the block list; and deleting the cargo blocks in the block list whose cargo quantity is greater than the set unloaded quantity.
[0083] For example, during the search process, only the cargo blocks corresponding to the cargo that needs to be loaded are retained according to the current situation of the cargo that has been loaded and not loaded. This ensures that the cargo blocks corresponding to the cargo that has been loaded or no longer needs to be loaded will not be considered during the search process, thereby reducing the search space and improving the search efficiency. In addition, if the number of cargoes corresponding to a cargo block exceeds the upper limit of the number of cargoes that have not been loaded, the cargo block will be deleted. This is to avoid considering cargo blocks that cannot be completely packed, thereby maintaining the rationality and accuracy of the search process.
[0084] By updating the block list, unnecessary search space can be reduced, focusing only on cargo blocks that may be loaded in the current state, so that the search algorithm can find suitable cargo blocks to fill the container more quickly, thereby improving search efficiency. In addition, deleting cargo blocks that do not meet the conditions can reduce the complexity of the search space, making the algorithm easier to handle and optimize, which helps to reduce the time complexity and space complexity of the search. At the same time, updating the block list can also ensure that only cargo blocks that match the current state are considered during the search process, avoiding the consideration of inapplicable cargo blocks, thereby improving the accuracy of the search and the quality of the results.
[0085] Step 300: determining a plurality of complete solutions of a packing scheme based on the free space and the plurality of cargo blocks to be loaded.
[0086] After selecting the free space and the cargo blocks to be loaded, the cargo blocks to be loaded are filled into the free space to generate multiple complete solutions of the packing scheme. For example, the greedy method of generating complete solutions is adopted. The basic idea is to select the free space with the smallest Manhattan distance each time, and load the cargo block ranked first into it according to the block selection function. Then repeat this process until no more cargo blocks can be filled or all cargo blocks are loaded, and record the position and arrangement structure of the filled cargo blocks to obtain a complete solution.
[0087] The greedy method for generating a complete solution can include the following steps:
[0088] 1) Select free space: Select a space with the smallest Manhattan distance in the remaining free space.
[0089] 2) Select the best cargo block: In the selected free space, the matching score of each cargo block is calculated according to the block selection function, and the cargo block ranked first is selected for loading.
[0090] 3) Repeat loading: Repeat the above steps until no more cargo blocks can be loaded or all cargo blocks are loaded. By greedily selecting the best combination of cargo blocks and space, the space is gradually filled to achieve a better packing effect.
[0091] The embodiment of the present application uses a greedy method to generate a complete solution by selecting the free space with the smallest Manhattan distance and selecting the best cargo block to fill the space according to the block selection function, thereby quickly solving the complete solution.
[0092] Step 400 , based on the maximum loading rate and the minimum balance deviation rate of the packing solution, each of the complete solutions is evaluated, and the packing solution is searched based on the evaluation results of the complete solutions.
[0093] Maximizing the loading rate means that in the packing problem, the utilization rate of each container should be maximized as much as possible. In other words, in the packing process, the space of each container should be fully utilized to reduce the number of containers required and reduce costs. The balance deviation rate refers to the balance problem caused by the uneven distribution of the load of the container during the loading process. Minimizing the balance deviation rate means that the items in the container are distributed as evenly as possible to avoid the situation where some containers are overloaded and some containers are underloaded, so as to ensure the stability and safety of loading.
[0094] Based on the maximum loading rate and the minimum balance deviation rate of the packing scheme, each complete solution is evaluated, and the packing scheme is searched based on the evaluation results of the complete solution. For example, after determining the maximum loading rate and the minimum balance deviation rate, each complete solution is evaluated by an evaluation function, wherein the evaluation method adopted by the evaluation function may include a weighted method and a Pareto method. Further, based on the evaluation results of the complete solution, the intermediate node can be back-pushed to screen the complete solution with a high score, and then the tree search is continued starting from the excellent complete solution after the last screening.
[0095] The search method for packing schemes provided in the embodiments of the present application is by determining the free space of the goods to be loaded; the free space represents the space in the container that is not occupied by the goods; based on the cargo blocks and free space of the goods to be loaded, multiple cargo blocks to be loaded are determined; based on the free space and multiple cargo blocks to be loaded, multiple complete solutions of the packing scheme are determined; based on the maximization of the loading rate and the minimization of the balance deviation rate of the packing scheme, each complete solution is evaluated, and the packing scheme is searched based on the evaluation results of the complete solutions. The present application can optimize the two goals of packing rate and balance at the same time, realize multi-objective optimization of packing scheme search, improve the search efficiency of multi-objective packing schemes, and can effectively provide Pareto solutions, thereby providing decision makers with diverse and rich packing reference schemes.
[0096] Based on the above embodiment, the maximum loading rate is determined based on the following method:
[0097] Step 411: determine the maximum loading rate based on the packing information of the goods to be loaded, the length, width and height of the goods to be loaded, and the length, width and height of the container.
[0098] The calculation formula for maximizing the loading rate is:
[0099]
[0100] Among them, s i is the packing information of the cargo i to be loaded, that is, whether the cargo to be loaded is loaded into the box. If s i The value is 1, which means it is packed into the box. i A value of 0 means it is not loaded into the box; i , w i and h i are the length, width and height of the cargo i to be loaded; L, W and H are the length, width and height of the container respectively, and N is the total number of cargoes to be loaded.
[0101] The minimized balance deviation rate is determined based on the following method:
[0102] Step 421, determining the front-to-back relative offset of the cargo to be loaded based on the total weight and the front-to-back offset weight of the cargo to be loaded;
[0103] Step 422, determining the left-right relative offset of the cargo to be loaded based on the total weight and the left-right offset weight of the cargo to be loaded;
[0104] Step 423: Determine the minimized balance offset rate based on the front-rear relative offset and the left-right relative offset.
[0105] The calculation formula for minimizing the balance deviation rate is:
[0106] minr2+r3;
[0107]
[0108]
[0109]
[0110]
[0111]
[0112] Where r2 is the relative front-to-back offset of the cargo to be loaded, r3 is the relative left-to-right offset of the cargo to be loaded; a is the front-to-back offset weight of the cargo to be loaded, b is the left-to-right offset weight of the cargo to be loaded, and W is the total weight of the cargo to be loaded; x i is the horizontal coordinate of the center of gravity of the i-th cargo to be loaded, y i is the vertical coordinate of the center of gravity of the i-th cargo to be loaded, m i is the weight of the i-th cargo to be loaded.
[0113] After determining the maximum loading rate and the minimum balance deviation rate, the complete solution can be evaluated by a weighted method. Specifically, based on the minimum balance deviation rate, the front-to-back relative offset and the left-to-right relative offset are obtained; based on the maximum loading rate and its first weight coefficient, the front-to-back relative offset and its second weight coefficient, and the left-to-right relative offset and its third weight coefficient, the weighted objective function of the complete solution is determined; based on the weighted objective function, each complete solution is evaluated.
[0114] In the weighted method, each objective is assigned a weight coefficient, and then the values of different objectives are multiplied by the corresponding weight coefficients, and finally they are combined into a single comprehensive indicator. In the multi-objective bin packing problem, the multiple objective problems can be transformed into a single objective problem and solved using a single objective optimization algorithm. By adjusting the weight coefficients of different objectives, a series of different solutions can be obtained, from which the solution that best meets the requirements can be selected.
[0115] Among them, the weighted objective function is:
[0116] maxw1r1-w2r2-w3r3;
[0117] Among them, r1 is the maximum loading rate, r2 is the front-to-back relative offset of the cargo to be loaded, r3 is the left-to-right relative offset of the cargo to be loaded, and w1, w2 and w3 are weight coefficients.
[0118] The weight coefficient is determined by the expert scoring method. Once the weight coefficient is determined, the quality of the solution can be judged and can be used to evaluate the complete solution during the tree search process.
[0119] In order to obtain the Pareto solution, it is necessary to generate multiple weight combinations according to different expert combinations, and execute a tree search algorithm for each weight combination. Finally, all leaf nodes are merged and non-dominated sorting is performed to obtain the optimal Pareto front solution. For example, in multi-objective packing optimization, due to the existence of multiple conflicting objective functions, it is necessary to find the optimal solution by weighing the importance of these objective functions. Therefore, for each possible weight combination, a tree search algorithm needs to be executed to determine the optimal solution under the weight combination. By executing the tree search algorithm, the optimal solution for each weight combination can be obtained, so that the optimal solution under different weights can be fully considered, providing more options for subsequent decision-making. After obtaining the optimal solution for each weight combination, all these optimal solutions are merged together and non-dominated sorting is performed. Among them, non-dominated sorting is a method for evaluating solutions in multi-objective optimization. By comparing the dominance relationship between each solution, the optimal solution that does not dominate each other is found, that is, the Pareto front solution, where the Pareto front is a solution set consisting of all Pareto optimal solutions. By executing the tree search algorithm and merging the optimal solutions and performing non-dominated sorting, the Pareto frontier solution in the multi-objective optimization problem can be obtained, providing decision makers with a comprehensive selection of optimal solutions. This method can fully consider the trade-offs between multiple objectives and help find solutions that better meet actual needs.
[0120] After determining the maximum loading rate and the minimum equilibrium deviation rate, the Pareto method can be used to evaluate the complete solution. Specifically, based on the maximum loading rate and the minimum equilibrium deviation rate, the complete solution is non-dominated sorted to obtain a non-dominated solution set; the crowding distance between every two non-dominated solutions in the non-dominated solution set is determined; based on the crowding distance, the non-dominated solutions are screened to complete the evaluation of each complete solution.
[0121] In the multi-objective bin packing problem, if there is a solution that is better than another solution under a certain objective function but not worse than another solution, this solution is called the Pareto optimal solution. Through the Pareto method, we can get the optimal solution under multiple different trade-offs without simplifying multiple objective functions into a single objective function. The Pareto method is suitable for situations where there are contradictions between multiple objectives or they cannot be comprehensively considered through weighted summation.
[0122] In the tree search process, the non-dominated sorting + crowding distance method is used to sort and screen the complete solutions. Finally, the leaf nodes are non-dominated sorted to select the solution corresponding to the Pareto frontier.
[0123] In the multi-objective packing problem of the embodiment of the present application, two objectives are included, the first objective O1 is to maximize the loading rate, and the second objective O2 is to minimize the equilibrium deviation rate. By performing non-dominated sorting on the complete solution, the advantages and disadvantages of the solutions can be distinguished by taking into account O1 and O2, and at least one non-dominated solution set can be obtained. For the solutions in the same non-dominated solution set, the advantages and disadvantages of the decomposition need to be further distinguished by the crowding distance, where the larger the crowding distance, the more advantageous it is. It can be understood that in a multi-objective optimization problem, if there are multiple solutions on the Pareto front, there may be advantages and disadvantages between these solutions. In order to better select the final optimal solution, these solutions need to be further evaluated and distinguished. The crowding distance is an indicator for evaluating the position of the solution in the Pareto front. It can help distinguish the density of the decomposition, so as to find a more advantageous solution.
[0124] Among them, the specific steps of crowding distance calculation are:
[0125] Step 1: Initialization, set the crowding distance i of each point d is 0. Among them, each point can be understood as each solution in the non-dominated solution set.
[0126] Step 2: Sort the solutions in the current non-dominated solution set from small to large according to the first goal O1. After the sorting is completed, the crowding distance of the two points at the two ends (i.e., the boundary) of the sorting result is set to infinity, i.e. In this way, it can be ensured that solutions on the boundary can be effectively distinguished.
[0127] Step 3: Calculate the crowding distance for other points. The calculation formula of the crowding distance is:
[0128]
[0129] Among them, i d is the crowding distance of i2 points; is the jth target value of point i2+1, is the j-th target value of point i2-1.
[0130] In the multi-objective packing problem, after determining the crowding distance, filtering the solutions in the non-dominated solution set based on the crowding distance can help find a better packing solution. For example, sort the crowding distances from large to small, and select the first N solutions as the final non-dominated solution set. Alternatively, the crowding distance and the number of times each solution is dominated can be combined into a comprehensive evaluation index, and the solutions in the non-dominated solution set are sorted according to the comprehensive evaluation index. According to the sorted results, the first few solutions are selected as the final non-dominated solution set.
[0131] The embodiments of the present application may adopt a weighted method or a Pareto method to achieve effective optimization of different objectives, wherein the weighted method can simplify a multi-objective problem into a single-objective problem, and different solutions can be obtained by adjusting the weights. The Pareto method can obtain a variety of optimal solutions, because it does not require simplifying multiple objective functions into a single objective function, but retains the diversity between the various objective functions, so that a set of optimal solutions under different trade-offs can be obtained, helping decision makers to better understand various possible solutions. Through the above two optimization methods, multi-objective optimization of packing scheme search can be achieved, and the search efficiency of multi-objective packing schemes can be improved.
[0132] In order to further analyze and explain the search method for the packing solution proposed in this application, refer to the following examples.
[0133] The present application embodiment specifically proposes a tree search method for a multi-target box packing scenario, which mainly includes the following aspects:
[0134] First, the tree search framework.
[0135] The tree search algorithm searches for a path from some initial state to some final state by exploring the search space. The intermediate states (or partial solutions) correspond to partial loading solutions and consist of three components: a list R representing the free space in the container, a list C of the remaining cargo, and a list B of the blocks.
[0136] Among them, the pseudo code involved in the tree search algorithm is shown in Table 1:
[0137] Table 1
[0138]
[0139]
[0140] The pseudo code of the search process involved in the tree search algorithm is shown in Table 2:
[0141] Table 2
[0142]
[0143] In Table 2, the detailed analysis of each line of pseudo code is as follows:
[0144] Line 1: Initialize free space. In the packing problem, the free space inside the container needs to be initialized in the initial case so that the subsequent search process can be based on the free space.
[0145] Line 2: Initialize the search state with the triple (free space, remaining unloaded goods, block list) and get a current solution. That is, determine the current search environment, and then get a current solution based on the current state, that is, an initial packing solution.
[0146] Line 3: Initialize the current solution set to store the solutions generated in subsequent searches.
[0147] Lines 4 to 12: The main structure of the tree search. Among them, lines 5 to 8: branch each current solution, each solution is associated with at most ω successor solutions, and the successor solution set S' is obtained. Line 9 mainly uses a greedy method to give the complete solution corresponding to the successor solution, and then evaluates the quality of the successor solution (such as line 10). In line 11, different screening rules are used to screen out high-quality intermediate solutions for the next branch. Line 12 is the update of the branch coefficient.
[0148] Line 7: Free space selection and cargo block selection. Each of the eight vertices of the free space corresponds to the eight corners of the container, such as Figure 2 The corresponding relationships are shown as follows: (A1, B1), (A2, B2), (A3, B3), (A4, B4), (A5, B5), (A6, B6), (A7, B7) and (A8, B8). Assume that the coordinates of any vertex in the free space are (x1, y1, z1) and the coordinates of the container vertex corresponding to the vertex are (x2, y2, z2). The Manhattan distance between the two points is:
[0149] |x1-y1|+|y1-y2|+|z1-z2|;
[0150] The angle of the free space corresponding to the minimum Manhattan distance is called the anchor angle, and the minimum Manhattan distance is called the anchor distance. After the minimum anchor distance free space is selected, it is necessary to select appropriate blocks to fill the free space.
[0151] Without loss of generality, define the block selection function:
[0152]
[0153] Where b is the cargo block, r is the free space, and ρ is the weight of the objective function. is the objective function, i.e., the attribute value corresponding to the combination of cargo block b and free space r, i1 is the number of objective functions, i1 = 0, 1, 2, ..., n. The top N candidate blocks can be screened out through the block selection function F(b, r, ρ).
[0154] Line 9: Greedy method to generate complete solutions. Each time, select the free space with the smallest Manhattan distance and put the top-ranked cargo block into it according to the block selection function. Repeat the above steps until no cargo blocks can be filled or all cargo blocks are filled.
[0155] Line 10: Complete solution evaluation method. Without loss of generality, the evaluation function of the complete solution is defined as Eval(s c )=(f1,f2,...,f n ). For the single-objective packing problem, the quality of the solutions can be directly compared by comparing the function values; for the multi-objective packing problem, the quality of the solutions can be compared by non-dominated sorting, and the solutions in the non-dominated solution set can be compared by crowding distance.
[0156] Second, pre-generated blocks and block list maintenance.
[0157] The cargo blocks involved in the tree search framework are pre-generated. A cargo block refers to a set of cargoes. According to the sameness of the cargoes and the consistency of their placement, cargo blocks can be divided into simple blocks and complex blocks. A simple block means that all cargoes are the same and are placed in the same way; any cargo block with different cargoes or placements is called a complex block.
[0158] Pre-generated block technology can help improve the retrieval efficiency of the search process. By pre-generating a block list, a corresponding exclusive block list can be generated for each intermediate solution, and the branch of each node depends on the block list. When updating the block list, the following methods can be adopted:
[0159] For the pre-generated block list, only the cargo blocks corresponding to the unloaded cargo are retained: that is, only the cargo blocks containing the unloaded cargo are retained to ensure that the cargo in the block list matches the unloaded cargo of the current node.
[0160] Delete cargo blocks whose cargo quantity exceeds the unloaded cargo limit: When the cargo quantity in a cargo block exceeds the unloaded cargo limit of the current node, such cargo block needs to be deleted from the block list because it cannot be a candidate block for a complete loading plan.
[0161] Among them, the simple block generation method is shown in Table 3.
[0162] Table 3
[0163]
[0164] In Table 3, the analysis of each row operation in the simple block generation method is as follows:
[0165] The first line initializes the block list.
[0166] Lines 2 to 9 are the block list generation process:
[0167] 1) Traverse all types of goods: By looping through all types of goods, consider each type of goods as the basic unit of the block.
[0168] 2) Traverse all length, width and height combinations: For each type of cargo, traverse the possible length, width and height combinations to determine the specific shape and size of each cargo block.
[0169] 3) If the number of cargo blocks meets the requirements and can be placed in the container, add the cargo block to the block list: For each cargo block generated by the length, width and height combination, check whether the number of cargo meets the requirements and determine whether the cargo block can be placed inside the container (without exceeding the capacity limit of the container). If a cargo block meets the above conditions, that is, the number of cargo meets the requirements and can be placed in the container, then add the cargo block to the block list for subsequent search and loading plan generation.
[0170] Among them, the complex block generation method is shown in Table 4.
[0171] Table 4
[0172]
[0173] In Table 4, the analysis of each row operation in the complex block generation method is as follows:
[0174] Line 1 combines the simple chunk lists of all cargo chunks into one large list collection.
[0175] In the second row, to ensure the feasibility of generating complex blocks, only the 50% blocks with the smallest volume in B are retained.
[0176] Lines 4 to 12 are the main components for generating complex blocks. They are mainly generated through lists PG and B. g The combination of inner blocks in different directions generates complex blocks. If b is feasible and does not overlap with B g If the blocks in are repeated, then NG←NG∪b.
[0177] Line 13 is used to control the scale of complex blocks. For example, by setting parameters or conditions, the scale of complex blocks generated can be controlled to avoid generating too many or too large complex blocks, so as to improve the efficiency and feasibility of the loading plan.
[0178] Third, free space representation and its updating method.
[0179] The detailed analysis of the free space involved in the tree search framework is as follows:
[0180] The concept of maximum space is used to represent the free space in a container. When a single cargo block is placed in a corner of a container, the remaining free space can be represented by three overlapping cuboids, each of which is the largest rectangular box that does not intersect the interior of the cargo block. Such a cuboid is called free space. Figure 3 The free space obtained after placing a cargo block is shown, and since the three cuboids overlap, they are illustrated in three separate diagrams for clarity of presentation.
[0181] exist Figure 3 In the figure, after the cargo block b is placed in the free space r, free spaces associated with the three faces of b are generated:
[0182] (1) Sub-image (b) corresponds to the free space on the front side: first, a cross section perpendicular to the bottom surface is generated based on the front side surface, and then it is extended to the outside of the free space cube to finally generate a spatial body.
[0183] (2) Sub-figure (c) corresponds to the free space on the top surface: first, a cross section parallel to the bottom surface is generated based on the top surface, and then it is extended upward to finally generate a spatial body.
[0184] (3) Sub-figure (d) corresponds to the free space on the side surface: first, a cross section perpendicular to the bottom surface is generated based on the side surface, and then it is extended to the free space r where no goods are placed, and finally a spatial body is generated.
[0185] Since the maximum space representation method has the overlapping nature, that is, when a block is placed at the corner of a free space, it may overlap with other free spaces. After placing the block, these overlapping free spaces need to be updated. Figure 4 We show the general case where a placed block b overlaps with a residual space r, in which case the remaining free space in r can be represented using the maximum space concept, and the resulting free space can be computed. For any free space that overlaps with a placed block b, its remaining free space can be represented by at most six free spaces corresponding to the six faces of b. As in Figure 4 In the example, the plane corresponding to the right side of b generates residual space r'. Based on this, the free space in the container can be effectively managed and updated, ensuring that the remaining available space can be accurately calculated when placing blocks, providing accurate information for subsequent block selection and packing solutions.
[0186] Fourth, multi-objective optimization method.
[0187] Based on the tree search framework, two optimization paradigms for the multi-objective bin packing problem are proposed, namely the weighted method and the Pareto method.
[0188] (1) The block selection function F(b, r, ρ) can be expressed as follows after being concretized:
[0189]
[0190] Where b is the cargo block, θ is the coefficient vector, V(b) is the volume of the cargo block, P(b) is the mass of the cargo block, D(b) is the density of the cargo block, L(b) is the space loss rate of the free space after the cargo block is placed, and N(b) is the number of cargo in the cargo block. It can be understood that f i (b,r) is equivalent to V(b), P(b), D(b), L(b) and N(b), that is, the attribute values.
[0191] (2) Greedy method to generate complete solution.
[0192] The method of generating a complete solution is involved in line 9 of the tree search algorithm. After selecting the minimum anchor distance free space, the optimal block is selected according to the block selection function, and the above steps are repeated until no blocks can be installed or all blocks are installed. Through the above method, a greedy complete solution generation method suitable for multi-objective optimization scenarios can be obtained.
[0193] (3)Goal description.
[0194] 3.1) The first objective O1: The calculation formula for maximizing the loading rate is:
[0195]
[0196] Among them, s i is the packing information of the cargo i to be loaded, that is, whether the cargo to be loaded is loaded into the box. If s i The value is 1, which means it is packed into the box. i A value of 0 means it is not loaded into the box; i , w i and h i are the length, width and height of the cargo i to be loaded; L, W and H are the length, width and height of the container respectively, and N is the total number of cargoes to be loaded.
[0197] 3.2) The second objective O2: Minimizing the balance deviation rate is calculated as:
[0198] min r2+r3;
[0199]
[0200]
[0201]
[0202]
[0203]
[0204] Where r2 is the relative front-to-back offset of the cargo to be loaded, r3 is the relative left-to-right offset of the cargo to be loaded; a is the front-to-back offset weight of the cargo to be loaded, b is the left-to-right offset weight of the cargo to be loaded, and W is the total weight of the cargo to be loaded; x i is the horizontal coordinate of the center of gravity of the i-th cargo to be loaded, y i is the vertical coordinate of the center of gravity of the i-th cargo to be loaded, m i is the weight of the i-th cargo to be loaded.
[0205] 3.3) Weighted method.
[0206] The weighted objective function is:
[0207] max w1r1-w2r2-w3r3;
[0208] Among them, r1 is the maximum loading rate, r2 is the front-to-back relative offset of the cargo to be loaded, r3 is the left-to-right relative offset of the cargo to be loaded, and w1, w2 and w3 are weight coefficients.
[0209] The weight coefficient is determined by the expert scoring method. Once the weight coefficient is determined, the quality of the solution can be judged and can be used to evaluate the complete solution during the tree search process.
[0210] In order to obtain the Pareto solution, it is necessary to generate multiple weight combinations based on different expert combinations, and execute a tree search algorithm for each weight combination. Finally, all leaf nodes are merged and non-dominated sorting is performed to obtain the optimal Pareto front solution.
[0211] 3.4) Pareto method.
[0212] In the tree search process, the non-dominated sorting + crowding distance method is used to sort and screen the complete solutions. Finally, the leaf nodes are non-dominated sorted to select the solution corresponding to the Pareto frontier.
[0213] By performing non-dominated sorting on the complete solutions, we can distinguish the pros and cons of the solutions from O1 and O2 and obtain at least one non-dominated solution set. For the solutions in the same non-dominated solution set, we need to further distinguish the pros and cons of the solutions by using the crowding distance. The larger the crowding distance, the more advantageous it is. The specific steps for calculating the crowding distance are:
[0214] Step 1: Initialization, set the crowding distance i of each point d is 0. Among them, each point can be understood as each solution in the non-dominated solution set.
[0215] Step 2: Sort the solutions in the current non-dominated solution set from small to large according to the first goal O1. After the sorting is completed, the crowding distance of the two points at the two ends (i.e., the boundary) of the sorting result is set to infinity, i.e. In this way, it can be ensured that solutions on the boundary can be effectively distinguished.
[0216] Step 3: Calculate the crowding distance for other points. The calculation formula of the crowding distance is:
[0217]
[0218] Among them, i d is the crowding distance of i2 points; is the jth target value of point i2+1, is the j-th target value of point i2-1.
[0219] The tree search method for multi-objective packing scenarios provided in the embodiments of the present application can simultaneously optimize the two objectives of packing rate and balance, realize multi-objective optimization of packing solution search, improve the search efficiency of multi-objective packing solutions, and effectively provide Pareto solutions, thereby providing decision makers with diverse and rich packing reference solutions.
[0220] Based on the above embodiments, the embodiments of the present application propose a device for searching for a packing solution, including a free space determination module 501 , a to-be-loaded cargo block determination module 502 , a complete solution determination module 503 and a search module 504 .
[0221] A free space determination module 501 is used to determine the free space for cargo to be loaded; the free space represents the space in the container that is not occupied by cargo;
[0222] A cargo block determination module 502 for determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space;
[0223] A complete solution determination module 503 is used to determine multiple complete solutions of the packing scheme based on the free space and the multiple cargo blocks to be loaded;
[0224] The search module 504 is used to evaluate each of the complete solutions based on the maximum loading rate and the minimum balance deviation rate of the packing solution, and search for the packing solution based on the evaluation results of the complete solution.
[0225] The search device for packing schemes provided in the embodiment of the present application determines the free space of the goods to be loaded; the free space represents the space in the container that is not occupied by the goods; based on the cargo blocks and free space of the goods to be loaded, multiple cargo blocks to be loaded are determined; based on the free space and multiple cargo blocks to be loaded, multiple complete solutions of the packing scheme are determined; based on the maximum loading rate and the minimum balance deviation rate of the packing scheme, each complete solution is evaluated, and the packing scheme is searched based on the evaluation results of the complete solutions. The present application can optimize the two goals of packing rate and balance at the same time, realize multi-objective optimization of packing scheme search, improve the search efficiency of multi-objective packing schemes, and can effectively provide Pareto solutions, thereby providing decision makers with diverse and rich packing reference schemes.
[0226] In one embodiment, the search module 504 is further configured to:
[0227] Determining the maximum loading rate based on the packing information of the goods to be loaded, the length, width and height of the goods to be loaded, and the length, width and height of the container;
[0228] The minimized balance deviation rate is determined based on the following method:
[0229] Determining the front-to-back relative offset of the cargo to be loaded based on the total weight and the front-to-back offset weight of the cargo to be loaded;
[0230] Determining the left-right relative offset of the cargo to be loaded based on the total weight and the left-right offset weight of the cargo to be loaded;
[0231] The minimized balance offset rate is determined based on the front-rear relative offset and the left-right relative offset.
[0232] In one embodiment, the search module 504 is further configured to:
[0233] Based on the minimized balance offset rate, obtaining the front-to-rear relative offset and the left-to-right relative offset;
[0234] Determining a weighted objective function of the complete solution based on the maximized loading rate and its first weight coefficient, the front-to-back relative offset and its second weight coefficient, and the left-to-right relative offset and its third weight coefficient;
[0235] Each of the complete solutions is evaluated based on the weighted objective function.
[0236] In one embodiment, the search module 504 is further configured to:
[0237] Based on the maximized loading rate and the minimized equilibrium deviation rate, the complete solutions are non-dominated sorted to obtain a non-dominated solution set;
[0238] Determine the crowding distance between every two non-dominated solutions in the non-dominated solution set;
[0239] Based on the crowding distance, the non-dominated solutions are screened to complete the evaluation of each of the complete solutions.
[0240] In one embodiment, the free space determination module 501 is further configured to:
[0241] Determine the Manhattan distance between each vertex of each free space in the free space list and the vertex corresponding to the container;
[0242] The free space corresponding to the minimum Manhattan distance is used as the free space for the goods to be loaded.
[0243] In one embodiment, the module 502 for determining the cargo block to be loaded is further used to:
[0244] Determining a plurality of objective functions based on the attribute values corresponding to the combination of the cargo block and the free space;
[0245] Determining a block selection function based on the objective function and its weight;
[0246] Based on the block selection function, a plurality of cargo blocks to be loaded are selected from a block list.
[0247] In one embodiment, the module 502 for determining the cargo block to be loaded is further used to:
[0248] Retain the cargo blocks corresponding to the unloaded cargo in the block list; and
[0249] Delete the cargo blocks in the block list whose cargo quantity is greater than the set unloaded quantity.
[0250] Figure 6 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 6 As shown, the electronic device may include: a processor 610, a communication interface 620, a memory 630 and a communication bus 640, wherein the processor 610, the communication interface 620 and the memory 630 communicate with each other through the communication bus 640. The processor 610 may call the logic instructions in the memory 630 to execute the following method:
[0251] Determining free space for cargo to be loaded; the free space represents space in the container not occupied by cargo;
[0252] Determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space;
[0253] Determine multiple complete solutions of packing scheme based on the free space and the multiple cargo blocks to be loaded;
[0254] Based on the maximum loading rate and the minimum balance deviation rate of the packing solution, each of the complete solutions is evaluated, and the packing solution is searched based on the evaluation results of the complete solutions.
[0255] In addition, the logic instructions in the above-mentioned memory 630 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art, and the computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk.
[0256] On the other hand, an embodiment of the present application further provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for searching for the packing solutions provided in the above embodiments is implemented, for example, including:
[0257] Determining free space for cargo to be loaded; the free space represents space in the container not occupied by cargo;
[0258] Determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space;
[0259] Determine multiple complete solutions of packing scheme based on the free space and the multiple cargo blocks to be loaded;
[0260] Based on the maximum loading rate and the minimum balance deviation rate of the packing solution, each of the complete solutions is evaluated, and the packing solution is searched based on the evaluation results of the complete solutions.
[0261] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative effort.
[0262] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0263] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
[0264] The above implementation modes are only used to illustrate the present application, but not to limit the present application. Although the present application is described in detail with reference to the embodiments, a person skilled in the art should understand that various combinations, modifications or equivalent substitutions of the technical solutions of the present application do not depart from the spirit and scope of the technical solutions of the present application, and should be included in the scope of the claims of the present application.
Claims
1. A method for searching a packing solution, characterized in that: include: Determining free space for cargo to be loaded; the free space represents space in the container not occupied by cargo; Determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space; Determine multiple complete solutions of packing scheme based on the free space and the multiple cargo blocks to be loaded; Based on the maximum loading rate and the minimum balance deviation rate of the packing solution, each of the complete solutions is evaluated, and the packing solution is searched based on the evaluation results of the complete solution; wherein the packing solution is searched using a tree search algorithm; The maximum loading rate is determined based on the following method: based on the packing information of the goods to be loaded, the length, width and height of the goods to be loaded, and the length, width and height of the container, the maximum loading rate is determined; The minimized balance deviation rate is determined based on the following methods: determining the front-to-back relative deviation of the cargo to be loaded based on the total weight and the front-to-back deviation of the cargo to be loaded; determining the left-to-right relative deviation of the cargo to be loaded based on the total weight and the left-to-right deviation of the cargo to be loaded; determining the minimized balance deviation rate based on the front-to-back relative deviation and the left-to-right relative deviation; The step of evaluating each complete solution based on the maximum loading rate and the minimum balance deviation rate of the packing solution includes: Based on the maximized loading rate and the minimized equilibrium deviation rate, the complete solutions are non-dominated sorted to obtain a non-dominated solution set; Determine the crowding distance between every two non-dominated solutions in the non-dominated solution set; Based on the crowding distance, the non-dominated solutions are screened to complete the evaluation of each of the complete solutions; Among them, a variety of weight combinations are generated according to different expert combinations, and for each weight combination, a tree search algorithm is executed to determine the optimal solution under each weight combination; all optimal solutions are merged together and non-dominated sorting is performed to obtain the Pareto front solution.
2. The method for searching for a packing solution according to claim 1, characterized in that: Determining the free space for cargo to be loaded includes: Determine the Manhattan distance between each vertex of each free space in the free space list and the vertex corresponding to the container; The free space corresponding to the minimum Manhattan distance is used as the free space for the goods to be loaded.
3. The method for searching for a packing solution according to claim 1, characterized in that: The step of determining a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space comprises: Determining a plurality of objective functions based on the attribute values corresponding to the combination of the cargo block and the free space; Determining a block selection function based on the objective function and its weight; Based on the block selection function, a plurality of cargo blocks to be loaded are selected from a block list.
4. The method for searching for a packing solution according to claim 3, characterized in that: The block list is updated as follows: Retain the cargo blocks corresponding to the unloaded cargo in the block list; and Delete the cargo blocks in the block list whose cargo quantity is greater than the set unloaded quantity.
5. A device for searching for a packing solution, characterized in that: include: A free space determination module, used to determine the free space for cargo to be loaded; the free space represents the space in the container that is not occupied by cargo; A cargo block determination module to be loaded, configured to determine a plurality of cargo blocks to be loaded based on the cargo block to be loaded and the free space; A complete solution determination module, used to determine multiple complete solutions of the packing scheme based on the free space and the multiple cargo blocks to be loaded; A search module is used to evaluate each of the complete solutions based on the maximum loading rate and the minimum balance deviation rate of the packing solution, and search for the packing solution based on the evaluation results of the complete solution; wherein the packing solution is searched using a tree search algorithm; The search module is further used to determine the maximum loading rate based on the packing information of the goods to be loaded, the length, width and height of the goods to be loaded, and the length, width and height of the container; determine the front-to-back relative offset of the goods to be loaded based on the total weight and the front-to-back offset of the goods to be loaded; determine the left-to-right relative offset of the goods to be loaded based on the total weight and the left-to-right offset of the goods to be loaded; determine the minimum balance offset rate based on the front-to-back relative offset and the left-to-right relative offset; The search module is also used to perform non-dominated sorting on the complete solutions based on the maximized loading rate and the minimized equilibrium offset rate to obtain a non-dominated solution set; determine the crowding distance between every two non-dominated solutions in the non-dominated solution set; screen the non-dominated solutions based on the crowding distance to complete the evaluation of each complete solution; wherein a plurality of weight combinations are generated according to different expert combinations, and a tree search algorithm is executed for each weight combination to determine the optimal solution under each weight combination; all optimal solutions are merged together and non-dominated sorted to obtain a Pareto front solution.
6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method for searching a packing solution according to any one of claims 1 to 4 is implemented.
7. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for searching for a packing solution according to any one of claims 1 to 4 is implemented.