A method and apparatus for discharging, electronic device and storage medium
By optimizing the layout of front and back plates and ordinary plates in the engraving machine using heuristic algorithms and neighborhood operators, the low efficiency of existing nesting methods on the engraving machine is solved, and efficient nesting result generation is achieved.
Patent Information
- Application Number
- CN202211132961.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-16
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2042-09-16
AI Technical Summary
Existing nesting methods cannot meet the specific needs of engraving machines. The Deepnest nesting optimization method suffers from premature convergence and low utilization. Furthermore, the Huawei and Wang Shi nesting methods are slow to solve large-scale problems, which affects factory efficiency.
A heuristic algorithm is used to arrange the front and back plates and ordinary plates of the engraving machine respectively. The arrangement is optimized by using intra-class recombination and inter-class insertion neighborhood operators. Combined with the fitness function and the two-dimensional arrangement heuristic algorithm, the plate utilization rate is optimized and the optimal arrangement result is generated.
It improves the efficiency and speed of material layout for engraving machines, reduces processing time, and generates optimized material layout results suitable for engraving machines.
Smart Images

Figure CN115742611B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of material arrangement, in particular to a material arrangement method and device, electronic equipment and storage medium. BACKGROUND
[0002] At present, there are two material arrangement methods. The first one is Deepnest material arrangement optimization method. Deepnest material arrangement optimization method uses genetic method as the core method and is suitable for large-scale material arrangement. The biggest disadvantage is the premature problem of genetic method, so the utilization rate is very low. In actual use, the gap between the final solution and the initial solution is very small. The second one is Huawei material arrangement optimization method and Wangshi material arrangement optimization method. This method uses integer programming as the core method and models and solves the two-dimensional material arrangement problem in the form of integer programming. Although the modeling method of integer programming can obtain a relatively good solution, the solving speed of integer programming is very slow for large-scale problems, which affects the work efficiency of the factory in actual problems.
[0003] The prior art solutions cannot meet the specific needs of engraving machine material arrangement. Deepnest and other material arrangement methods are inclined to academic problems, and the problems are the simplest type. Huawei material arrangement and Wangshi material arrangement are inclined to the electronic saw material arrangement branch of factory production, and are not suitable for engraving machine material arrangement. SUMMARY
[0004] The purpose of the embodiments of the present application is to provide a material arrangement method, device, electronic equipment and storage medium, which can be suitable for the material arrangement of engraving machines.
[0005] In a first aspect, the embodiments of the present application provide a material arrangement method, comprising:
[0006] obtaining a plate piece;
[0007] The plate piece includes a positive and negative plate piece and a general plate piece;
[0008] arranging the positive and negative plate piece on the plate material to obtain a material arrangement result;
[0009] arranging the general plate piece based on the material arrangement result to obtain an optimized material arrangement result.
[0010] In the above implementation process, the properties of the plate pieces to be processed are considered, the positive and negative plate pieces and the general plate pieces are arranged on the plate material respectively, the processing time is reduced, the processing efficiency is improved, and the material arrangement on the engraving machine is suitable.
[0011] Further, the step of arranging the positive and negative plate piece on the plate material to obtain a material arrangement result comprises:
[0012] Step one: arranging the positive and negative plate pieces on a first plate material by using a heuristic algorithm to obtain a positive and negative initial set;
[0013] Step two: destroying the positive and negative initial set by using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator according to a preset probability to obtain a first positive and negative update set;
[0014] Step three: obtaining the fitness of the positive and negative initial set and the fitness of the first positive and negative update set according to a fitness function;
[0015] Step four: judging whether the fitness of the first positive and negative update set is greater than the fitness of the positive and negative initial set; if yes, taking the first positive and negative update set as the positive and negative initial set; if no, executing step two;
[0016] Step five: obtaining a first calculation time;
[0017] Step six: judging whether the first calculation time exceeds a first preset calculation time; if no, executing step two; if yes, taking the positive and negative initial set as the material arrangement result.
[0018] Further, the step of arranging the ordinary plate pieces based on the material arrangement result to obtain an optimized material arrangement result comprises:
[0019] Step one: arranging the ordinary plate pieces on a second plate material by using a heuristic algorithm to obtain an ordinary initial set;
[0020] Step two: destroying the ordinary initial set by using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator according to a preset probability to obtain a first ordinary update set;
[0021] Step three: judging whether the fitness of the first ordinary update set is greater than the fitness of the ordinary initial set;
[0022] Step four: if yes, taking the first ordinary update set as the ordinary initial set;
[0023] Step five: destroying the positive and negative initial set by using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator according to a preset probability to obtain a second positive and negative update set;
[0024] Step six: judging whether the fitness of the second positive and negative update set is greater than the fitness of the positive and negative initial set;
[0025] Step seven: if yes, taking the second positive and negative update set as the positive and negative initial set;
[0026] Step eight: according to a predetermined probability, using the inter-class insertion neighborhood operator to take out the ordinary plate to be processed from the ordinary initial set and insert it into the positive-negative initial set; obtain a second ordinary update set and a third updated positive-negative set;
[0027] Step nine: according to the fitness function, judge whether the sum of the fitness of the second ordinary update set and the third updated positive-negative set is greater than the sum of the fitness of the ordinary initial set and the positive-negative initial set; if yes, take the second ordinary update set as the ordinary initial set; take the third updated positive-negative set as the positive-negative initial set;
[0028] Step ten: obtain a second calculation time, judge whether the second calculation time exceeds a second preset value, if yes, execute step two, if not, take the ordinary initial set and the positive-negative initial set as the optimized layout result.
[0029] Further, after the step of obtaining the optimized layout result, further comprising:
[0030] Traverse the plate material of the optimized layout result; determine the vertical direction of the cutting direction of the first plate material or the second plate material currently traversed;
[0031] Increase the side length of the currently traversed plate material in the vertical direction until all plate pieces can be placed in the currently traversed plate material;
[0032] Traverse the plate piece in the currently traversed plate material;
[0033] Move the currently traversed plate piece along the vertical direction until the currently traversed plate piece abuts against other plate pieces on the currently traversed plate material;
[0034] Judge whether the currently traversed plate material is the plate material with the lowest utilization rate in the ordinary initial set;
[0035] If yes, cut the currently traversed plate material in the vertical direction;
[0036] After traversing the optimized layout result, obtain an optimal layout result;
[0037] Generate a tool path according to the optimal layout result.
[0038] Further, the fitness function is:
[0039]
[0040] u i The layout s of the i-th plate material in the set to be calculated iutilization rate; l is a layout corresponding to a plate pair with the minimum average area of plates in the set to be calculated; |S| is the number of layouts in the set to be calculated; F(s) is the fitness of the set to be calculated;
[0041] The set to be calculated includes one of a positive-negative initial set, a first positive-negative update set, a first normal update set, a second normal update set, and a third update positive-negative set.
[0042] Further, the method for using the intra-class recombination neighborhood operator includes the following steps.
[0043] Randomly obtaining one plate to be recombined in the intra-class neighborhood from a set to be recombined in the intra-class neighborhood;
[0044] Taking out all plates in the plate to be recombined in the intra-class neighborhood to form a first plate set;
[0045] Generating a maximum number of plates to be used, and determining whether all plates in the first plate set can be cut by the maximum number of plates to be used by using a two-dimensional layout heuristic algorithm;
[0046] If not, the set to be recombined in the intra-class neighborhood is taken as a set to be recombined in the intra-class neighborhood after processing,
[0047] If yes, a first reconstructed plate is obtained, and the plate to be recombined in the intra-class neighborhood and the second plate to be recombined in the intra-class neighborhood are replaced by the first reconstructed plate in the set to be destroyed to obtain a set to be recombined in the intra-class neighborhood after processing;
[0048] The set to be recombined in the intra-class neighborhood includes one of a positive-negative initial set, a normal initial set, a first positive-negative update set, and a first normal update layout set.
[0049] Further, the method for using the intra-class insertion neighborhood operator includes the following steps.
[0050] Randomly obtaining a first plate to be inserted in the intra-class and a second plate to be inserted in the intra-class from a set to be inserted in the intra-class;
[0051] Randomly obtaining one plate from the first plate to be inserted in the intra-class as an insertion plate, and obtaining a third plate to be inserted in the intra-class;
[0052] Taking the insertion plate and all plates in the second plate to be inserted in the intra-class as a second plate set;
[0053] Determining whether all plates in the second plate set can be cut by one plate by using a two-dimensional layout heuristic algorithm;
[0054] If yes, obtaining a fourth type of interposed plate material, replacing the first type of interposed plate material and the second type of interposed plate material in the first positive and negative update set with the third type of interposed plate material and the fourth type of interposed plate material to obtain a processed to-be-class-interposed set;
[0055] If no, taking the to-be-class-interposed set as a processed to-be-class-interposed set;
[0056] The to-be-class-interposed set comprises one of a positive and negative initial set, a common initial set, a first positive and negative update set, and a first updated common layout set.
[0057] Further, the action process of the inter-class interposition neighborhood operator comprises:
[0058] Step one: randomly obtaining an updated common processing plate material in the first common update set;
[0059] Step two: traversing a plate piece in the updated common processing plate material as an interposed plate piece;
[0060] Step three: traversing all positive and negative updated common processing plate materials in the second positive and negative update set;
[0061] Step four: comprising all plate pieces of a positive and negative surface layout sub-set and the interposed plate piece as a third plate piece set;
[0062] Step five: determining whether all plate pieces in the third plate piece set can be cut by one cutting plate material by using a two-dimensional layout heuristic algorithm, if no, executing step three, and if yes, obtaining a new plate material and executing step six;
[0063] Step six: replacing the positive and negative updated common processing plate material with a cutting plate material cutting all plate pieces in the third plate piece set, and removing the interposed plate piece of the updated common processing plate material to obtain a processed first updated common layout sub-set; and executing step two;
[0064] Step seven: returning the processed first common update set and the processed second positive and negative update set.
[0065] The action process of the inter-class interposition neighborhood operator comprises:
[0066] Step one: randomly obtaining an updated common processing plate material in the first common update set;
[0067] Step two: traversing a plate piece in the updated common processing plate material as an interposed plate piece;
[0068] Step three: traversing all positive and negative updated common processing plate materials in the second positive and negative update set;
[0069] Step four: including all the plate parts of the front and back layout sub-set and the insert plate part as a third plate part set;
[0070] Step five: using a two-dimensional layout heuristic algorithm to determine whether all the plate parts in the third plate part set can be cut by a cutting plate, if not, executing step three, if yes, obtaining a new plate, and executing step six;
[0071] Step six: replacing the front and back updated normal machining plate with the cutting plate cutting all the plate parts in the third plate part set, and removing the insert plate part of the updated normal machining plate to obtain a processed first updated normal layout sub-set; executing step two;
[0072] Step seven: returning the processed first normal updated set and the processed second front and back updated set.
[0073] In a second aspect, an embodiment of the present application provides a layout device, comprising:
[0074] In a third aspect, an embodiment of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, and the processor executes the computer program to implement the steps of the method according to any one of the first aspect.
[0075] Other features and advantages of the present application will be illustrated in the following description, or can be known or determined without doubt from the description, or can be known by implementing the above-mentioned technology of the present application.
[0076] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the following preferred embodiments are specifically described, and the accompanying drawings are described in detail as follows. BRIEF DESCRIPTION OF DRAWINGS
[0077] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments of the present application. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation on the scope, and for those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.
[0078] Figure 1 The flowchart of the layout method provided by the embodiments of the present application;
[0079] Figure 2 The structural diagram of the layout device provided by the embodiments of the present application;
[0080] Figure 3 The structural diagram of the electronic device provided by the embodiments of the present application. Detailed Implementation
[0081] The technical solutions in the embodiments of this application will now be described with reference to the accompanying drawings.
[0082] It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. Furthermore, in the description of this application, terms such as "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0083] Example 1
[0084] See Figure 1 This application provides a material discharge method, including:
[0085] S1: Obtain the sprue; sprues include: front and back sprues and regular sprues;
[0086] In the above embodiments, front and back panels refer to panels that can be arranged on the front and back sides of a board; ordinary panels are panels that can only be arranged on one side of a board.
[0087] S2: Arrange the front and back panels on the board to obtain the layout result;
[0088] S3: Based on the layout results, the ordinary sheet metal is laid out to obtain optimized layout results.
[0089] In the above embodiments, both the layout result and the optimized layout result refer to the arrangement of the panels on the board.
[0090] In the above implementation process, considering that in the field of engraving machines, there are front and back panels and ordinary panels, the existing material layout methods generate layout results slowly when applied to the material layout field of engraving machines. Therefore, this application proposes to first arrange the front and back panels on the board to obtain the layout result; based on the layout result, the ordinary panels are then arranged to obtain an optimized layout result. Based on the above implementation method, the layout result can be generated quickly.
[0091] S2 includes:
[0092] S21: Use a heuristic algorithm to arrange the front and back plates on the first plate to obtain the initial set of front and back plates;
[0093] S22: According to the preset probability, the positive and negative initial sets are destroyed by using the intra-class reorganization neighborhood operator or the intra-class insertion neighborhood operator to obtain the first positive and negative updated sets;
[0094] S23: Obtain the fitness of the initial positive and negative sets and the fitness of the first updated positive and negative sets according to the fitness function;
[0095] S24: judging whether the fitness of the first positive-negative update set is greater than the fitness of the positive-negative initial set; if yes, taking the first positive-negative update set as the positive-negative initial set; if no, executing step S22;
[0096] S26: obtaining the first calculation time;
[0097] In the above embodiment, the first calculation time is the calculated time of S2 as a whole.
[0098] S37: judging whether the first calculation time exceeds the first preset calculation time; if no, executing step S22; if yes, taking the positive-negative initial set as the layout result.
[0099] In the above implementation process, the positive-negative initial set is destructed and recombined according to the preset probability, the intra-class recombination neighborhood operator and the intra-class insertion neighborhood operator, and the calculation time is iterated until it is lower than the preset calculation time, so that the layout result can be continuously optimized.
[0100] S3 comprises:
[0101] S31: arranging the ordinary plate pieces on the second plate material by using a heuristic algorithm to obtain an ordinary initial set;
[0102] S32: destructing the ordinary initial set by using the intra-class recombination neighborhood operator or the intra-class insertion neighborhood operator according to a preset probability to obtain a first ordinary update set;
[0103] S33: judging whether the fitness of the first ordinary update set is greater than the fitness of the ordinary initial set;
[0104] S34: if yes, taking the first ordinary update set as the ordinary initial set;
[0105] S35: destructing the positive-negative initial set by using the intra-class recombination neighborhood operator or the intra-class insertion neighborhood operator according to a preset probability to obtain a second positive-negative update set;
[0106] S36: judging whether the fitness of the second positive-negative update set is greater than the fitness of the positive-negative initial set;
[0107] S37: if yes, taking the second positive-negative update set as the positive-negative initial set;
[0108] S38: taking out the ordinary plate pieces to be processed from the ordinary initial set and inserting them into the positive-negative initial set by using the inter-class insertion neighborhood operator according to a preset probability to obtain a second ordinary update set and a third positive-negative update set;
[0109] S39: judging whether the sum of the fitness of the second common update set and the third update positive-negative set is greater than the sum of the fitness of the common initial set and the positive-negative initial set according to the fitness function; if yes, taking the second common update set as the common initial set; and taking the third update positive-negative set as the positive-negative initial set;
[0110] S310: acquiring a second calculation time, judging whether the second calculation time exceeds a second preset value, if yes, executing step S21, and if no, taking the common initial set and the positive-negative initial set as the optimized layout result.
[0111] In the implementation process, the positive-negative initial set is destructed and recombined according to the preset probability, the intra-class recombination domain operator and the intra-class insertion domain operator, and the layout result is continuously optimized through multiple iterations until the calculation time meets the preset calculation time.
[0112] In a possible implementation, after S4, the method further includes:
[0113] S41: traversing the board in the optimized layout result; determining a vertical direction of a cutting direction of a first board or a second board currently traversed;
[0114] S42: increasing the edge length of the board currently traversed in the vertical direction until all the board pieces can be placed in the board currently traversed;
[0115] S43: traversing the board pieces in the board currently traversed;
[0116] S44: moving the board piece currently traversed in the vertical direction until the board piece currently traversed abuts against other board pieces on the board currently traversed;
[0117] S45: judging whether the board currently traversed is the board with the lowest utilization rate in the common initial set, if yes, executing S46;
[0118] S46: cutting the board currently traversed at the vertical direction;
[0119] S47: obtaining the optimal layout result after traversing the optimized layout result;
[0120] S48: generating a tool path according to the optimal layout result.
[0121] In the implementation process, after the step of obtaining the optimized layout result, the position and distance of the board pieces on the board are further optimized to obtain the optimal layout result, and the tool path is generated according to the optimal layout result, so that the engraving machine can better cut the board.
[0122] Further, the embodiment of the application provides a fitness function, which is:
[0123]
[0124] u i a layout s of an i-th plate in a set to be calculated i a utilization rate of the set to be calculated; l is a layout corresponding to a plate pair with the minimum average area in the set to be calculated; |s| is a number of layouts in the set to be calculated; and F(s) is a fitness of the set to be calculated;
[0125] In the above embodiment, the layout is an arrangement of the plate pieces on the plate.
[0126] The set to be calculated includes one of a positive-negative initial set, a first positive-negative update set, a first normal update set, a second normal update set, and a third update positive-negative set.
[0127] The fitness function takes into account the utilization rate of the plate pieces, and based on the fitness function, the utilization area of the arranged plate is most reasonable.
[0128] Further, the method of action of the intra-class recombination neighborhood operator includes:
[0129] randomly obtaining a plate to be intra-class recombination neighborhood recombined from a set to be intra-class neighborhood recombined;
[0130] taking out all plate pieces of the plate to be intra-class neighborhood recombined to form a first plate piece set;
[0131] generating a maximum number of plates to be used, and using a two-dimensional layout heuristic algorithm to determine whether the maximum number of plates to be used can cut all plate pieces in the first plate piece set;
[0132] if not, the set to be intra-class neighborhood recombined is taken as a processed set to be intra-class neighborhood recombined,
[0133] if yes, a first recombined plate is obtained, and the plate to be intra-class neighborhood recombined and the first recombined plate are replaced in the set to be destroyed to obtain a processed intra-class neighborhood recombined set;
[0134] The intra-class neighborhood recombination set includes one of the positive-negative initial set, the normal initial set, the first positive-negative update set, and the first normal update layout set.
[0135] Further, the action process of the intra-class insertion neighborhood operator is as follows:
[0136] randomly obtaining a first intra-class insertion plate and a second intra-class insertion plate from a set to be intra-class inserted;
[0137] randomly obtaining a plate piece from the first intra-class insertion plate as an insertion plate piece, and obtaining a third intra-class insertion plate;
[0138] The inserted plate member and all plate members inserted into the second type of plate material are taken as a second plate member set;
[0139] Whether all plate members in the second plate member set can be cut by one plate material is determined by using a two-dimensional nesting heuristic algorithm;
[0140] If yes, a fourth type of inserted plate material is obtained, the first type of inserted plate material and the second type of inserted plate material in the first positive-negative update set are replaced by the third type of inserted plate material and the fourth type of inserted plate material, and a processed to-be-class-inserted set is obtained;
[0141] If no, the to-be-class-inserted set is taken as a processed to-be-class-inserted set;
[0142] The to-be-class-inserted set comprises one of the positive-negative initial set, the common initial set, the first positive-negative update set and the first updated common layout set.
[0143] Further, the action process of the inter-class insertion neighborhood operator comprises:
[0144] Step one: a updated common processing plate material in the first common update set is randomly obtained;
[0145] Step two: plate members in the updated common processing plate material are traversed as inserted plate members;
[0146] Step three: all positive-negative updated common processing plate materials in the second positive-negative update set are traversed;
[0147] Step four: all plate members in the positive-negative layout sub-set and the inserted plate members are taken as a third plate member set;
[0148] Step five: whether all plate members in the third plate member set can be cut by one cutting plate material is determined by using a two-dimensional nesting heuristic algorithm, if no, step three is executed, and if yes, a new plate material is obtained, and step six is executed;
[0149] Step six: the updated common processing plate material is replaced by the cutting plate material cutting all plate members in the third plate member set, and the inserted plate member of the updated common processing plate material is removed, a processed first updated common layout sub-set is obtained, and step two is executed;
[0150] Step seven: the processed first common update set and the processed second positive-negative update set are returned.
[0151] The application also provides a two-dimensional nesting method, comprising:
[0152] Step 1: a set P composed of a plurality of plate members and a maximum plate material usage number n are obtained;
[0153] Step 2: a plate material layout set S is set to contain only one empty plate material S={s l};
[0154] Step 3: When the set of boards to be laid out, P, is not empty, set the optimal profit, bestScore, best part number, bestPart, best board number, bestBin, and bestBin to 0; otherwise, exit and return to S.
[0155] Step 4: Traverse the set of plates to be laid out P, including the plates P. i ;
[0156] Step 5: Traverse the set of board layouts S to find the board S. j Recording board P i The best score for the maximum return based on the MaxRectsBSSF (Max Rectangle Heuristic) strategy i =-int, and the corresponding board serial number bestBin i =0;
[0157] Step 6: If bestScore i If the score is greater than bestScore, then update the optimal profit and board material number, and bestScore = bestScore. i bestBin=bestBin i ;
[0158] Step 7: If bestScore i If ≠-int, then the board part P bestPart Insert into board S bestBin Delete P from P bestPart Proceed to step 3;
[0159] Step 8: If bestScore i If S = -int and |S| < n, then add an empty board to S, and S = S + {s} |S| +l}, jump to step 3;
[0160] Step 9: Return to discharge failure.
[0161] Example 2
[0162] See Figure 2 This application provides a discharge device, including:
[0163] Module 1 is used to acquire the board material;
[0164] Sheet materials include: front and back panels and ordinary panels;
[0165] The material arrangement module 2 is used to arrange the front and back panels to obtain the arrangement result; based on the arrangement result, the ordinary panels are arranged to obtain the optimized arrangement result.
[0166] The application also provides an electronic device, please refer to Figure 3 , Figure 3 The application provides a structural block diagram of an electronic device. The electronic device can include a processor 31, a communication interface 32, a memory 33, and at least one communication bus 34. The communication bus 34 is used to realize direct connection communication between the components. The communication interface 32 of the electronic device in the application is used for signaling or data communication with other node devices. The processor 31 can be an integrated circuit chip with signal processing capability.
[0167] The processor 31 described above can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a ready-to-use programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component. The disclosed methods, steps and logic block diagrams in the application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor 31 can be any conventional processor.
[0168] The memory 33 can be, but is not limited to, a random access memory (RAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM) and the like. The memory 33 stores computer readable instructions, which are executed by the processor 31, so that the electronic device can perform the steps of the above Figures 1 to 2 The method embodiments involve various steps.
[0169] Optionally, the electronic device can also include a storage controller, an input / output unit.
[0170] The memory 33, the storage controller, the processor 31, the peripheral interface, and the input / output unit are electrically connected to each other directly or indirectly to realize data transmission or interaction. For example, these boards can be electrically connected to each other through one or more communication buses 34. The processor 31 is configured to execute executable modules stored in the memory 33, for example, software function modules or computer programs included in the electronic device.
[0171] The input / output unit is configured to provide a user with a creation task and create an optional period or a preset execution time for starting the task to realize interaction between the user and the server. The input / output unit can be, but is not limited to, a mouse, a keyboard, and the like.
[0172] It can be understood that, Figure 3 The structure shown is only schematic, and the electronic device can further include more or fewer components than those shown in the figures, or have a different configuration from those shown in the figures. Figure 3 The components shown in the figures can be implemented in hardware, software, or a combination thereof. Figure 3 Figure 3 The embodiments of the present application further provide a computer readable storage medium, and the computer readable storage medium stores instructions. When the instructions are run on a computer, the computer program is executed by a processor to implement the method of the method embodiments. To avoid repetition, details are not described here.
[0173] In several embodiments provided in the present application, it should be understood that the disclosed apparatus and method can also be implemented in other ways. The apparatus embodiments described above are only schematic. For example, the flowcharts and block diagrams in the drawings show the possible implementation architectures, functions and operations of the apparatus, method and computer program product according to the embodiments of the present application. In this regard, each block in the flowcharts or block diagrams can represent a module, a program segment or a part of code, which contains one or more executable instructions for implementing the specified logical functions. It should also be noted that in some alternative implementations, the functions noted in the blocks can occur in different orders from those shown in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, and sometimes they can be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and the combination of blocks in the block diagrams and / or flowcharts, can be implemented by a dedicated hardware-based system for executing the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
[0174] In several embodiments provided in the present application, it should be understood that the disclosed apparatus and method can also be implemented in other ways. The apparatus embodiments described above are only schematic. For example, the flowcharts and block diagrams in the drawings show the possible implementation architectures, functions and operations of the apparatus, method and computer program product according to the embodiments of the present application. In this regard, each block in the flowcharts or block diagrams can represent a module, a program segment or a part of code, which contains one or more executable instructions for implementing the specified logical functions. It should also be noted that in some alternative implementations, the functions noted in the blocks can occur in different orders from those shown in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, and sometimes they can be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and the combination of blocks in the block diagrams and / or flowcharts, can be implemented by a dedicated hardware-based system for executing the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
[0175] In addition, each functional module in each embodiment of the present application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0176] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer readable storage medium. Based on this understanding, the technical solutions of the present application essentially or the parts that make contributions to the prior art or parts of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods in the various embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various other media that can store program codes.
[0177] The above is only an embodiment of the present application and does not limit the protection scope of the present application. For those skilled in the art, the present application can have various modifications and changes. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application. It should be noted that similar reference numbers and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings.
[0178] The above is only a specific embodiment of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical scope disclosed by the present application, which shall be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
[0179] It is to be noted that, as used in this specification and the appended claims, the singular forms "a," "an," and "the" include plural referents unless the context clearly dictates otherwise. Thus, for example, reference to "a component" can include a combination of two or more components. Additionally, the terms "comprise," "comprises," and "comprising," or any variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements is not necessarily limited to those elements, but can include other elements not expressly listed or inherent to such process, method, article, or apparatus.
Claims
1. A method of discharging material, characterized by, The method comprises the following steps: acquiring plate pieces; the plate pieces comprise positive and negative plate pieces and common plate pieces; arranging the positive and negative plate pieces on a plate material to obtain a layout result; based on the layout result, the common plate pieces are arranged to obtain an optimized layout result; the step of arranging the positive and negative plate pieces on the plate material to obtain the layout result comprises: step one: using a heuristic algorithm to arrange the positive and negative plate pieces on a first plate material to obtain a positive and negative initial set; step two: according to a preset probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the positive and negative initial set to obtain a first positive and negative update set; step three: obtaining the fitness of the positive and negative initial set and the fitness of the first positive and negative update set according to a fitness function; step four: determining whether the fitness of the first positive and negative update set is greater than the fitness of the positive and negative initial set; if yes, taking the first positive and negative update set as the positive and negative initial set; if no, executing step two; step five: obtaining a first calculation time; step six: determining whether the first calculation time exceeds a first preset calculation time; if no, executing step two; if yes, taking the positive and negative initial set as the layout result; the step of arranging the common plate pieces based on the layout result to obtain the optimized layout result comprises: step one: using a heuristic algorithm to arrange the common plate pieces on a second plate material to obtain a common initial set; step two: according to a preset probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the common initial set to obtain a first common update set; step three: determining whether the fitness of the first common update set is greater than the fitness of the common initial set; step four: if yes, taking the first common update set as the common initial set; step five: according to a predetermined probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the positive and negative initial set to obtain a second positive and negative update set; step six: determining whether the fitness of the second positive and negative update set is greater than the fitness of the positive and negative initial set; step seven: if yes, taking the second positive and negative update set as the positive and negative initial set; step eight: according to a predetermined probability, using an inter-class insertion neighborhood operator to take out the common plate pieces to be processed from the common initial set and insert them into the positive and negative initial set to obtain a second common update set and a third update positive and negative set; step nine: according to a fitness function, determining whether the sum of the fitness of the second common update set and the third update positive and negative set is greater than the sum of the fitness of the common initial set and the positive and negative initial set; if yes, taking the second common update set as the common initial set and taking the third update positive and negative set as the positive and negative initial set; step ten: obtaining a second calculation time, determining whether the second calculation time exceeds a second preset value; if yes, executing step two; if no, taking the common initial set and the positive and negative initial set as the optimized layout result.
2. The method of claim 1, wherein, after the step of obtaining the optimized layout result, the method further comprises the following steps: traversing the plate material of the optimized layout result; determining the vertical direction of the cutting direction of the first plate material or the second plate material being currently traversed; increasing the side length of the current traversed panel in the vertical direction until all the panel pieces can be placed in the current traversed panel; traversing the panel pieces in the current traversed panel; moving the current traversed panel piece in the vertical direction until the current traversed panel piece abuts other panel pieces on the current traversed panel; determining whether the current traversed panel is the panel with the lowest utilization in the normal initial set; if yes, cutting the current traversed panel at the vertical direction; after traversing the optimized layout result, obtaining an optimal layout result; generating a tool path according to the optimal layout result.
3. The method of claim 2, wherein, The fitness function is: ; the layout of the i-th plate in the set to be calculated utilization of the layout of the i-th plate in the set to be calculated; the layout of the plate with the minimum average area in the set to be calculated; |S| is the number of layouts in the set to be calculated; the fitness of the set to be calculated; The set to be calculated includes one of the positive and negative initial set, the first positive and negative update set, the first normal update set, the second normal update set, and the third update positive and negative set.
4. The method of claim 3, wherein, The method for applying the intra-class recombination neighborhood operator includes: randomly obtaining a to-be-intra-class neighborhood recombination panel from a to-be-intra-class neighborhood recombination set; taking out all the panel pieces of the to-be-intra-class neighborhood recombination panel to form a first panel piece set; generating a maximum number of plates, and determining whether all the panel pieces in the first panel piece set can be cut by the maximum number of plates by using a two-dimensional layout heuristic algorithm; if no, taking the to-be-intra-class neighborhood recombination set as a processed to-be-intra-class neighborhood recombination set, if yes, obtaining a first reconstructed panel, replacing the to-be-intra-class neighborhood recombination panel and the replacement in the to-be-destroyed sub-set with the first reconstructed panel to obtain a processed intra-class neighborhood recombination set; The intra-class neighborhood recombination set includes one of the positive and negative initial set, the normal initial set, the first positive and negative update set, and the first normal update layout set.
5. The method of claim 4, wherein, The intra-class insertion neighborhood operator includes: randomly obtaining a first intra-class insertion panel and a second intra-class insertion panel from a to-be-intra-class insertion set; randomly obtaining a panel piece from the first intra-class insertion panel as an insertion panel piece, and obtaining a third intra-class insertion panel; taking the insertion panel piece and all the panel pieces in the second intra-class insertion panel as a second panel piece set; determining whether all the panel pieces in the second panel piece set can be cut by a panel by using a two-dimensional layout heuristic algorithm; if yes, obtaining a fourth intra-class insertion panel, replacing the first intra-class insertion panel and the second intra-class insertion panel in the first positive and negative update set with the third intra-class insertion panel and the fourth intra-class insertion panel to obtain a processed to-be-intra-class insertion set; if no, taking the to-be-intra-class insertion set as a processed to-be-intra-class insertion set; The to-be-intra-class insertion set includes one of the positive and negative initial set, the normal initial set, the first positive and negative update set, and the first normal update layout set.
6. The method of claim 5, wherein, The inter-class insertion neighborhood operator includes: Step one: randomly obtaining an update normal processing panel from the first normal update set; Step two: traversing the panel pieces in the update normal processing panel as insertion panel pieces; Step three: traversing all the positive and negative update normal processing panels in the second positive and negative update set; Step four: including taking all the panel pieces of the positive and negative layout sub-set and the insertion panel pieces as a third panel piece set; Step five: using a two-dimensional material arrangement heuristic algorithm to determine whether all the third set of plates can be cut by a cutting plate, if not, step three is executed, if yes, a new plate is obtained, and step six is executed; Step six: replacing the positive and negative update normal processing plate with the cutting plate that cuts all the third set of plates, and removing the inserted plate of the update normal processing plate to obtain the processed first update normal layout sub-set; step two is executed; Step seven: obtaining a third calculation time; if the third calculation time exceeds a third preset time, returning the processed first normal update set and the processed second positive and negative update set.
7. A material arrangement device, characterized in that, The acquisition module is configured to acquire the plate; The plate includes positive and negative plates and normal plates; The material arrangement module is configured to arrange the positive and negative plates to obtain an arrangement result; Based on the arrangement result, the normal plates are arranged to obtain an optimized arrangement result; The step of arranging the positive and negative plates on the plate to obtain the arrangement result comprises: Step one: using a heuristic algorithm to arrange the positive and negative plates on a first plate to obtain a positive and negative initial set; Step two: according to a preset probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the positive and negative initial set to obtain a first positive and negative update set; Step three: obtaining the fitness of the positive and negative initial set and the fitness of the first positive and negative update set according to a fitness function; Step four: determining whether the fitness of the first positive and negative update set is greater than the fitness of the positive and negative initial set; if yes, the first positive and negative update set is used as the positive and negative initial set; if no, step two is executed; Step five: obtaining a first calculation time; Step six: determining whether the first calculation time exceeds a first preset calculation time; if no, step two is executed; if yes, the positive and negative initial set is used as the arrangement result; The step of arranging the normal plates based on the arrangement result to obtain the optimized arrangement result comprises: Step one: using a heuristic algorithm to arrange the normal plates on a second plate to obtain a normal initial set; Step two: according to a preset probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the normal initial set to obtain a first normal update set; Step three: determining whether the fitness of the first normal update set is greater than the fitness of the normal initial set; Step four: if yes, the first normal update set is used as the normal initial set; Step five: according to a predetermined probability, using an intra-class recombination neighborhood operator or an intra-class insertion neighborhood operator to destroy the positive and negative initial set to obtain a second positive and negative update set; Step six: determining whether the fitness of the second positive and negative update set is greater than the fitness of the positive and negative initial set; Step seven: if yes, the second positive and negative update set is used as the positive and negative initial set; Step eight: according to a predetermined probability, using an inter-class insertion neighborhood operator to insert the normal plate to be processed from the normal initial set into the positive and negative initial set to obtain a second normal update set and a third update positive and negative set; Step nine: judging whether the sum of the fitness of the second normal update set and the third update positive-negative set is greater than the sum of the fitness of the normal initial set and the positive-negative initial set according to the fitness function; if yes, taking the second normal update set as the normal initial set and taking the third update positive-negative set as the positive-negative initial set; Step ten: obtaining a second calculation time, judging whether the second calculation time exceeds a second preset value, if yes, executing step two, if no, taking the normal initial set and the positive-negative initial set as the optimized material distribution result.
8. An electronic device, comprising: Comprise: a memory, a processor and a computer program stored in the memory and capable of running on the processor, the processor executing the computer program to implement the steps of the material distribution method according to any one of claims 1-6.
Citation Information
Patent Citations
Web service crowdsourcing test task allocation method based on a heuristic algorithm
CN109948940A
Material automatic rising dust cover is arranged to conveyer belt
CN208716460U