CN117519030B - Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning - Google Patents

Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning Download PDF

Info

Publication number
CN117519030B
CN117519030B CN202311565429.0A CN202311565429A CN117519030B CN 117519030 B CN117519030 B CN 117519030B CN 202311565429 A CN202311565429 A CN 202311565429A CN 117519030 B CN117519030 B CN 117519030B
Authority
CN
China
Prior art keywords
product
workpiece
factory
workpieces
key
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311565429.0A
Other languages
Chinese (zh)
Other versions
CN117519030A (en
Inventor
张梓琪
李瑛�
钱斌
胡蓉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Kunming University of Science and Technology
Original Assignee
Kunming University of Science and Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Kunming University of Science and Technology filed Critical Kunming University of Science and Technology
Priority to CN202311565429.0A priority Critical patent/CN117519030B/en
Publication of CN117519030A publication Critical patent/CN117519030A/en
Application granted granted Critical
Publication of CN117519030B publication Critical patent/CN117519030B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/418Total factory control, i.e. centrally controlling a plurality of machines, e.g. direct or distributed numerical control [DNC], flexible manufacturing systems [FMS], integrated manufacturing systems [IMS] or computer integrated manufacturing [CIM]
    • G05B19/41885Total factory control, i.e. centrally controlling a plurality of machines, e.g. direct or distributed numerical control [DNC], flexible manufacturing systems [FMS], integrated manufacturing systems [IMS] or computer integrated manufacturing [CIM] characterised by modeling, simulation of the manufacturing system
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B2219/00Program-control systems
    • G05B2219/30Nc systems
    • G05B2219/32Operator till task planning
    • G05B2219/32339Object oriented modeling, design, analysis, implementation, simulation language

Landscapes

  • Engineering & Computer Science (AREA)
  • Manufacturing & Machinery (AREA)
  • General Engineering & Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning, which is characterized in that a mathematical model considering machine blocking DABFSP is established and a scheduling optimization algorithm is designed on the basis of the scheduling problem of the distributed assembly flow shop; applying QLHHEA based on Q learning to solve the mathematical model of DABFSP; the low-level heuristic LLH is defined as a state, transition between states is defined as an action, a high-level strategy based on Q learning is adopted in global exploration, a proper action is automatically selected under a specific state, a searching direction is effectively driven, and LLHs based on problem characteristics is adopted in local development, so that searching behaviors are effectively enriched. The use of the acceleration strategy based on insertion effectively saves the calculation cost and improves the searching efficiency; the quality of the initial solution is improved and the present invention aims to determine DABFSP the product distribution, the work order of the work pieces and the assembly order of the products in each factory, so as to minimize the maximum finishing time of all factories.

Description

Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning
Technical Field
The invention discloses a distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning, and belongs to the technical field of production scheduling.
Background
Scheduling aims at reasonably allocating available resources among activities, balancing multiple conflict goals, and meeting the requirements of different decision makers within a specific time frame, which is an important component of modern supply chains and manufacturing systems. In recent years, with the rapid development of intelligent manufacturing and industry 4.0, together with the globalization trend, enterprises are faced with serious and complex problems such as dynamic demands, economic benefits and production modes, and manufacturing enterprises change manufacturing modes and purchase and manage multi-area manufacturing centers or factories to provide flexibility and adaptability to face vigorous competition. Thus, the traditional centralized single-factory production model has turned to an emerging distributed assembly production model, inevitably requiring three important issues to be addressed: how to distribute the work pieces to the factory, how to arrange the processing of the work pieces at the factory, and how to adjust the assembly of the product. Therefore, developing effective and efficient algorithms and emerging technologies to solve the distributed shop scheduling problem (Distributed shop scheduling problems, DSSPs) is of significant interest.
In previous DSSPs studies, distributed assembly replacement flow shop problems (Distributed assembly permutation FSP, DAPFSP) have become a hotspot study problem; however, many existing DAPFSP studies assume that the buffer capacity between successive processing machines in a flow shop is infinite, meaning that workpieces can be temporarily stored in an intermediate buffer. However, in practice, due to process characteristics or specifications, no buffers are allowed or are not available between adjacent machines, meaning that the work piece processed on a certain machine must remain on the current processing machine and cannot be immediately released to the next machine, a condition known as a jam. This is often the case in actual production due to buffer capacity or storage device limitations. Clogging increases the processing time of the workpiece, and therefore it is important to reduce the clogging time reasonably to increase the machine productivity. The distributed assembly choked flow shop scheduling problem is an important class of discrete optimization problems that is more realistic. Therefore, the research on the distributed assembly blocking flow shop scheduling problem (DABFSP) considering blocking constraint has practical significance and potential application prospect.
DABFSP can be decomposed into two strongly coupled sub-problems, a workpiece processing sub-problem and a product assembling sub-problem, and four closely coupled sub-decisions are derived: the work pieces are distributed to factories, the processing sequence of the work pieces in each factory is adjusted, products on the assembly machine are arranged, and meanwhile, the blocking time between machines is reduced. Generally, for large-scale DABFSP problems, it is difficult to solve by accurate mathematical methods, such as branch-and-bound methods and column generation methods, due to their computational complexity; a constructive heuristic algorithm can generally construct a viable solution based on problem-based rules and constraints and quickly provide an appropriate scheduling plan, but it is difficult to guarantee the superiority of the solution.
In the scheduling field, hybrid intelligent optimization algorithms (Hybrid intelligent optimization algorithms, HIOAs) have become the dominant approach to solving such problems. HIOAs typically use efficient evolutionary mechanisms, specific search strategies, and efficient neighborhood operators to produce some satisfactory scheduling schemes within a limited time. HIOAs has a significant effect in solving the complex scheduling problem of strong coupling. Hyper-heuristic algorithms (Hyper-heuristic algorithms, HHAs) are a class of HIOAs of great interest. HHA is typically composed of a high-level policy and a set of low-level heuristics, which instead of searching directly within the solution space of the problem, mainly applies a high-level policy (HLS) to manage or manipulate a series of pre-designed low-level heuristics (LLHs), determines the best order of LLHs in the policy space or heuristic search space, and then executes the selected LLHs to search the solution space for more superior solutions. HHAs have wide application in combinatorial optimization problems because of their ability to automatically select, integrate and develop simple and efficient heuristic algorithms. The search behavior of HHA can be generally divided into two categories, namely, heuristic generation and heuristic selection. The former employs appropriate high-level policies to construct heuristics, and the latter employs appropriate selection policies to extract LLH and evaluate its effectiveness. According to literature studies, most studies generally utilize evolutionary algorithm-based methods or artificial intelligence-based methods as advanced selection strategies. Reinforcement learning (Reinforcement learning, RL) integrates perception, adaptive learning and autonomous decision making through an object-oriented learning mechanism, and has stronger learning capability. The RL aims to gain experience and perform optimal search behavior through dynamic interactions between agents and the environment. In general, RL has two key features: trial-and-error searching and delayed rewarding policies. In the RL framework, an agent can perceive the likely state of the environment based on one or more objectives with a well-defined goal (i.e., maximizing the jackpot), and then take action to change it. Q learning is a relatively successful learning strategy that allows an agent to determine the best search behavior by learning to obtain a function of action values that expresses the expected utility of applying appropriate actions in certain specific states. Thus, Q learning based hyper-heuristics can provide appropriate strategies to select appropriate search behavior and guide search trends toward promising areas; these advantages inspire the design of the Q-learning based hyper-heuristic evolutionary algorithm (QLHHEA) and use it to solve DABFSP.
Disclosure of Invention
The invention aims to provide a distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning, which is used for determining DABFSP the product distribution, the processing sequence of workpieces and the assembly sequence of products of each factory, so that the maximum working time of all factories is minimized; 12 valid low-level heuristics are designed and all defined as states, transitions between states are defined as actions, and an evolution framework based on Q-learning is used as HLS regulation LLHs to search a solution space; two acceleration strategies based on insertion are formulated, so that the time complexity of an evaluation solution is reduced, the calculation cost is saved, and the search efficiency is accelerated; second, a construction heuristic based on the problem characteristics was developed to produce a high quality initial solution.
In order to achieve the above purpose, the technical scheme provided by the invention is as follows:
A distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning specifically comprises the following steps:
step 1: initializing a population and a Q table, wherein individuals in a low-level population are generated by adopting a construction heuristic method, individuals in a high-level population are randomly generated, and the scales of the two populations are the same (the size is popsize); setting related parameters; the q value (q-value) of the state action pair is set to zero.
Step 2: each individual acquired global optimal solution pi best is decoded by adopting a forward or backward calculation method, and two acceleration strategies based on insertion are executed when the solution is evaluated so as to save the calculation cost of the evaluation solution.
Step 3: sequentially executing LLHs (i.e., states, where the conversion of one LLH to another LLH is defined) in higher-level individuals (consisting of 12 high-efficiency heuristics) on feasible scheduling solutions in lower-level individuals, and if the new solution adaptation value is better, replacing the old solution with the new solution and updating the globally optimal solution; calculating the Contribution Rate (CR) of each higher-layer individual, thereby selectingThe Q table is updated by adopting an updating mechanism for each high-level individual with high contribution rate; while setting count=0.
Step 4: the updated Q-table is sampled to generate new higher-level individuals, i.e., lower-level heuristics are operated to search the solution space using a higher-level strategy based on Q-learning.
Step 4.1: the action selection policy is utilized to select state s t, obtain action a t and next state s t+1.
Step 4.2: applying state s t+1 to pi best to yield pi' best; the adaptation values for pi best (C (pi best))、C(π′best), IR, get bonus function r (s t,at), update Q value (Q t+1(st,at)), probabilities ε t, and pi best are calculated.
Step 4.3: if C (pi 'best)<C(πbest), updating the global optimal solution pi best to pi' best, otherwise jumping to step 4.1.
Step 4.4: if count= popsize, then go to step 3, otherwise go to step 4.
Step 5: checking whether the stopping condition is met, if not, jumping to the step 4, otherwise outputting pi best.
Preferably, the individuals in the lower population in the step (1) of the present invention are generated by adopting a construction heuristic method, which specifically comprises the following steps:
Step 1.1: for product P h (h=1, 2,.,. S.) the processing time I (h, I) for each workpiece on all machines was calculated by the following formula:
Where i is the work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; h is the product index, h=1, 2,..s; m is the number of machines in the production stage; i (h, I) is the processing time of each workpiece on all machines; p h,i,j is the processing time of the ith workpiece belonging to product P h on machine M j.
The I (h, I) is arranged in an ascending order to obtain an initial workpiece sequence lambda h formed by omega h workpieces of the product P h, and if the I (h, I) of the two workpieces are the same, P h,i,1 is selected to be smaller; the quality of the work order is improved by utilizing NEH heuristic algorithm, and the earliest completion time e h of the product P h is further determined.
Step 1.2: the product sequence lambda is obtained by arranging the earliest finishing time e h in ascending order.
Step 1.3: extracting the first s products from the product sequence lambda and distributing them to plants, at least one for each plant; the part of the product sequence assigned to the plant f' is denoted asS is assigned to the variable k, i.e. k=s.
Step 1.4: if there are still products to be dispensed in the product sequence λ and k < S, assuming δ f′ products have been dispensed to the factory f', then the first product P h, S < h+.s, where h is the product index, h=1, 2,..s, performs the following steps:
step 1.4.1: for F' =1, 2, F, insert lambda h as a block To ensure that all workpieces of the same product are not separated; the cost function σ (h, l ', f') of the non-dispensed product P h inserted into the void l 'is calculated by the following formula, l' =1, 2.
Where i is the work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; n is the number of work pieces; f is the number of factories; m is the number of machines in the production stage; s is the number of products; h is the product index; l is the index of the product in factory f, l=1, 2,..delta fh is the work order of product P l in factory f, Is a product in a factory f The departure time of the workpiece V l,i on the machine M j in the factory f; /(I)For the processing time of the workpiece V l,i on the machine M j in the factory f.
Selecting the product with the smallest sigma (h, l ', f'); if σ (h, l ', f') is the same, the earliest finishing time is selectedThe shortest product; let/>Is the corresponding vacancy.
Step 1.4.2: finding the plant f * with the shortest finishing time, i.eProduct P h was dispensed to the factory and lambda h was inserted into/>Vacancies/>
Step 1.5: let k=k+1, repeat step 1.4 until all products have been traversed.
Preferably, the invention decodes each individual to obtain the global optimal solution pi best by adopting a forward or backward calculation method, and comprises the following specific steps:
When decoding the higher-layer individuals, sequentially executing LLH contained in each higher-layer individual, and searching a better solution in a solution space by using the LLH; if the obtained candidate solution has better adaptability than the original solution, replacing with a new solution, and executing the rest LLHs, otherwise, executing the next LLH until all LLHs in the higher-level individual are executed; during which the effectiveness of each higher-level individual is assessed by the contribution rate.
When decoding a lower-layer individual, two forward or backward calculation methods are adopted, and two acceleration strategies based on insertion are executed before calculation, specifically: and inserting each product into all possible positions to evaluate all solutions, selecting an optimal solution, inserting workpieces belonging to the same product in the solution into all positions of the product to evaluate all solutions, and finally selecting the optimal solution to execute a forward or backward decoding calculation method.
Preferably, the two acceleration strategies based on the insertion of the present invention specifically include the following steps:
Step 2.1: acceleration strategy based on product insertion: inserting each product into all possible locations to evaluate all solutions; assuming that δ f′ products are distributed to f' plants, product P l′ has δ f′ +1 pluggable positions in total; the acceleration strategy for evaluating all insertion solutions based on product insertion is as follows:
Step 2.1.1: in the factory f' as a product The time and product of the ith workpiece leaving the machine M j The times of departure from the assembly machine M A are/>, respectivelyAnd/>
Step 2.1.2: on the basis of step 2.1.1, the processing time and the product of the ith workpiece on machine M j The assembly time on the assembly machine M A is/>, respectivelyAnd,/>
Step 2.1.3: assume thatProduct/>Inserted, the following formula holds:
Step 2.1.4: maximum finishing time of factory f' after product P l′ is inserted Calculated as follows:
Step 2.1.5: steps 2.1.3 and 2.1.4 are repeated until all insertion positions have been tried.
Step 2.2: acceleration strategy based on workpiece insertion: inserting workpieces belonging to the same product into the product; assume thatIn item 1/>If the first n [l′] -1 workpieces have completed scheduling, then the i' th workpiece may have n [l′] insert positions; the acceleration strategy for evaluating all insertion solutions based on workpiece insertion is as follows:
Step 2.2.1: calculation of
Step 2.2.2: suppose that workpiece V [l′],i′ is inserted into a productThe time for workpiece V [l′],i′ to leave machine M j is calculated as follows:
step 2.2.3: if the workpiece V [l′],i′ is inserted into Then product/>Completion time/>It must be calculated as follows:
step 2.2.4: finishing time of factory f' after workpiece insertion The calculation is as follows:
in the above formula, i is a work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; delta f is the number of products in the plant f, F factory index, f=1, 2,; m is the machine set, m= { M 1,M2,...,Mm }; /(I)For the product in factory f,/> The departure time of product P l on machine M j in factory f; /(I)The departure time of the workpiece V l,i on the machine M j in the factory f; /(I)Assembly time on machine M A in factory f for product P l; /(I)Processing time on machine M j in factory f for workpiece V l,i; /(I)The duration on machine M j in factory f for workpiece V l,i; /(I)The duration on machine M j in factory f for product P l; l is the product index in factory f, l=1, 2.
Step 2.2.5: steps 2.2.2 to 2.2.4 are repeated until the possible insertion positions are taken into account.
Preferably, the higher-level individuals in the step 3 of the present invention are constructed by 12 heuristic LLHs, and the heuristic LLHs can be divided into two categories, wherein one category is based on critical paths, and the other category is based on non-critical paths; the factories through which the critical path passes are named critical factories, and the products and workpieces allocated to the critical factories are named critical products and critical workpieces; the heuristic designed is as follows:
LLH 1: randomly selecting a key product from a key factory, and randomly selecting a key workpiece from a workpiece set of the product; this workpiece is inserted until all of the workpieces of the product have been selected before the other workpieces are inserted into position.
LLH 2: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; after inserting this work piece into the position of each of the other work pieces, until all work pieces of the key product are selected.
LLH 3: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; the position of the workpiece is swapped with all other workpieces until all workpieces of the key product are selected.
LLH 4: randomly selecting a key product from a key factory, and randomly selecting two different key workpieces from a workpiece set of the product; the subsequence between the two selected key workpieces is inverted.
LLH 5: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; this workpiece is inserted until all workpieces that are not critical products are selected before the other workpieces are placed.
LLH 6: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; after inserting this work piece into the position of each other work piece, until all work pieces of the non-critical product are selected.
LLH 7: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; the position of the selected workpiece is swapped with all other workpieces until all workpieces of non-critical products are selected.
LLH 8: one product is randomly selected from a non-critical factory, two different workpieces are randomly selected from a set of workpieces for the non-critical product, and then the subsequence between the selected two non-critical workpieces is inverted.
LLH 9: randomly selecting a key product from a key factory; each product is inserted before or after its location in the critical factory until all critical products are selected and all insert-based operations are performed.
LLH 10: one key product is randomly selected from the key factories, and the location of the product is exchanged with other products until all key products are selected and all exchange-based operations are performed.
LLH 11: one product is randomly selected from a non-critical factory and the selected product is inserted before or after the location of all other products.
LLH 12: one product is randomly selected from the non-critical factories, and the location of the selected product is exchanged with the locations of all other products.
Preferably, in the step (3) of the present invention, the Q-value of Q (S t,at) reflects the priority preference of the agent to execute action a t e a in state S t e S, because the Q table records the knowledge learned by the agent from the environment; for each state-action pair (s t,at),Q(st,at) updated by weighting the instant prize r (s t,at) and the discounted q-value, it can be calculated by the following formula:
In the above formula, s is a state, a is an action, and r (s, a) is an instant prize for executing the action a in the state s; s is a state space, s= { s|s 1,s2,...,sT},t=1,...,T,st represents a selectable state; a is an action set, a= { a|a 1,a2,...,aT},t=1,...,T,at representing a selectable action; (s t,at) is a selectable state-action pair; the Q (s t,at) table performs the priority preference of state-action pairs (s t,at); lambda is a coefficient.
Preferably, the action selection policy in step 4.1 of the present invention is specifically as follows:
For a particular state s t for a particular time step t, a modified ε greedy strategy is used to select either a random action with probability ε t or an action yielding the maximum reward with probability 1- ε t; the action selection policy is used to determine the appropriate actions for the initial state s 0 and all subsequent states; at initial iteration, setting q-value of all state-action pairs to 0, thereby randomly selecting initial state and action; while lower epsilon t values facilitate depth-first searches around potential regions; thus, an epsilon adaptive adjustment method is provided for the T cur event, noted as The formula is as follows:
Where ε 0 is an initial value (i.e., ε 0=0.15),εf is a final value (i.e., ε f=0.01);Ttotal is the total number of time steps, T cur is the current number of time steps, according to the description above, the action selection policy first sets state s t+1 to 0, if a random number of 1 is generated, s t+1 will be selected by the ε greedy policy with a probability of The resulting random action a t determines that, otherwise, state s t+1 is to be randomly generated.
Preferably, the reward function of step 4.2 of the present invention is designed as follows:
In the above formula, r (s, a) is the immediate reward for executing action a in state s, and is determined by the quality IR of the improved solution pi, IR can be calculated by [ C max(π)-Cmax(π′)]/Cmax (pi), C max (pi) is the maximum completion time of the scheduling solution pi, and pi' is the new candidate solution obtained after executing action.
The invention establishes DABFSP scheduling model based on the scheduling problem with blocking constraint; some of its properties are deduced from the characteristics of DABFSP; two acceleration strategies based on DABFSP properties have been proposed to reduce the time complexity of evaluating solutions.
The heuristic method for constructing the initial population based on the problem characteristics ensures the quality and diversity of the initial population.
According to the neighborhood structure of the specific problem, twelve low-level heuristics are designed to construct the LLH pool; the switching between LLHs is defined as the available action.
The invention embeds the Q-learning algorithm into QLHHEA as HLS, thereby controlling LLHs selection for selecting an appropriate search strategy in the solution space of the problem.
The beneficial effects of the invention are as follows:
Compared with other high-level strategies, the HLS based on the Q learning, which is applied by the method, allows proper actions to be automatically selected in a specific state, so that the searching behavior is effectively enriched; QLHHEA, which is a learning paradigm driven by knowledge, makes decisions in the strategy space through trial and error feedback, guides the search to promising solution space areas, which is advantageous over most hybrid intelligent optimization algorithms based on random search solution spaces. The new definition of states and actions provides insight into the connection relationships of LLHs, focusing on mining patterns and key features that are hidden in the future in higher-level individuals.
Drawings
FIG. 1 is a general flow chart of the present invention;
FIG. 2 is an exemplary diagram of forward and backward calculation methods; wherein a is a forward calculation method schematic diagram, and b is a backward calculation method schematic diagram;
FIG. 3 is an exemplary diagram of an acceleration strategy based on product insertion;
FIG. 4 is an exemplary graph of an acceleration strategy based on workpiece insertion; wherein a is a schematic drawing of the workpiece 14 inserted into the first position of the product P3, b is a schematic drawing of the workpiece 14 inserted into the second position of the product P3, c is a schematic drawing of the workpiece 14 inserted into the third position of the product P3;
FIG. 5 is a directional fully connected network of selectable states and available actions; wherein a is a state selection directional full-connection network, b is an action selection directional full-connection network;
FIG. 6 is a schematic diagram of the present invention QLHHEA.
Detailed Description
The invention of the present disclosure is further described below with reference to the drawings and examples, but the scope of the invention is not limited to the description.
DABFSP, which is a two-stage scheduling problem, is divided into processing and assembly stages; there are F identical plants, each plant having a flow shop for processing workpieces and an assembly machine for product assembly; the method comprises the following steps that n workpieces and S products exist, each product consists of different workpieces, and each workpiece only belongs to one product; in the processing stage, distributing all workpieces to a factory according to a proper distribution rule; each workpiece is processed on M machines in the same route (M 1,M2,...,Mm); no buffer area exists between any two machines, and the workpiece just processed cannot immediately leave the current machine due to the lack of the buffer area, and the next machine is required to be free and available; all the workpieces belonging to the same product must be processed together, and workpieces of different products are not allowed to be cross-processed; that is, workpieces belonging to the same product in pi f cannot be mixed with workpieces belonging to other products, which means that the products are in sequenceImplicit in the work order pi f of factory f; once all the pieces of product P h are completed in the processing phase and the assembly machine is idle, they can be immediately delivered to the assembly machine; in the assembly phase, all the work pieces processed by each factory are gathered and assembled into S final products on an assembly machine.
The distributed assembly replacement flow shop problem (DABFSP) described in this embodiment satisfies the following assumptions:
(1) The processing time of the workpiece and the assembly time of the product are predetermined positive integers; the processing time comprises setting time and transportation time; irrespective of the release time of the workpiece.
(2) Each workpiece can only be processed on one machine at most, and each machine cannot process a plurality of workpieces at a time; the workpiece and machine are available from time zero.
(3) Preemption is not allowed; once the work-piece machining process and the product assembly operation are started, they must be performed without interruption, without allowing the work to be interrupted.
(4) Each workpiece can be distributed to any one factory, and all operations of each workpiece must be completed in the same factory; the work pieces that have been assigned to the factories cannot be transferred to other factories any more.
DABFSP on the premise of meeting the above assumption, the constructed model is as follows:
the start time of each workpiece and product in each factory is determined by formulas (1) - (3).
The departure time of the first workpiece from machines M 1 to M m-1 for the first product in each plant is calculated by equation (4).
The start time of each workpiece of each product in the factory on the first machine is calculated by equation (5).
Calculation by equation (6) ensures that the departure time of each workpiece must be greater than its completion time and the completion time of its previous workpiece.
The workpiece departure time on the last machine of each factory is calculated by equation (7).
The assembly completion time of the product on the assembly machine is determined by equation (8).
In the recursive formulae of formulae (10) - (19), for each plant, the last product is first processedAnd to the process for preparing the sameWork pieces and then processing a second product/>And so on until the first product/>Thus, C max (pi) can be calculated from equation (19), with a temporal complexity of/>
The goal of DABFSP with minimized maximum completion time is to find the optimal schedule pi * among all possible schedule sets pi, equation (20).
In the above formula: n is the number of work pieces; m is the number of machines in the production stage; f is the number of factories; s is the number of products; f factory index, f=1, 2,; l is the index of products in factory f, l=1, 2,..delta ff is the number of products in factory f,I is the work index, i=1, 2,., n l; j is the index of the machine and, j=1, 2, m; h is the product index, h=1, 2,..s; j is the workpart set, j= { J 1,J2,...,Jn }; m is the machine set, m= { M 1,M2,...,Mm }; p is the product set, P= { P 1,P2,...,PS};Vl is the work set belonging to product P l,/>N f is the number of tools in the plant f,Omega h is the number of work pieces belonging to product P h,/>N l is the set of workpieces belonging to product P l in factory f,Lambda is the total product order, lambda= [ lambda 12,...,λs];λh is the work order of product P l in factory f,Pi f is the work order in factory f, pi f=[πf(1),πf(2),...,πf(nf) ]; /(I)For product in plant f/>P l,i,j is the processing time of the workpiece V l,i on machine M j; o l,i,j is the operation of the workpiece V l,i on machine M j; /(I)Processing time on machine M j in factory f for workpiece V l,i; /(I)Assembly time on machine M A in factory f for product P l; /(I)The departure time of the workpiece V l,i on the machine M j in the factory f; /(I)The duration on machine M j in factory f for workpiece V l,i; /(I)The departure time of product P l on machine M j in factory f; /(I)The duration on machine M j in factory f for product P l; pi is DABFSP, pi= [ pi 12,...,πF ]; pi is a feasible solution set; /(I)Is the completion time of plant f; c max (pi) is the total finishing time for the complete solution pi.
Example 1
A distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning comprises the following specific steps:
step 1: initializing a population and a Q table, wherein individuals in a low-level population are generated by adopting a construction heuristic method, individuals in a high-level population are randomly generated, and the scales of the two populations are the same (the size is popsize); setting related parameters; the q value (q-value) of the state action pair is set to zero.
Step 2: each individual acquisition global optimal solution pi best is decoded by adopting a forward or backward calculation method, and two acceleration strategies based on insertion are executed before calculation so as to save the calculation cost of the evaluation solution.
Step 3: sequentially executing LLHs (i.e., states, where the conversion of one LLH to another LLH is defined) in higher-level individuals (consisting of 12 high-efficiency heuristics) on feasible scheduling solutions in lower-level individuals, and if the new solution adaptation value is better, replacing the old solution with the new solution and updating the globally optimal solution; calculating the Contribution Rate (CR) of each higher-layer individual, thereby selectingThe Q table is updated by adopting an updating mechanism for each high-level individual with high contribution rate; while setting count=0.
Step 4: sampling the updated Q table generates a new higher-level individual.
Step 4.1: state s t is selected, action a t and next state s t+1 are obtained.
Step 4.2: applying state s t+1 to pi best to yield pi' best; the adaptation values for pi best (C (pi best))、C(π′best), IR, get prize r (s t,at), update Q value (Q t+1(st,at)), probabilities ε t, and pi best are calculated.
Step 4.3: if C (pi 'best)<C(πbest), updating the global optimal solution pi best to pi' best, otherwise jumping to step 4.1.
Step 4.4: if count= popsize, then go to step 3, otherwise go to step 4.
Step 5: checking whether the stopping condition is met, if not, jumping to the step 4, otherwise outputting pi best.
Further, the coding method of solutions (individuals) in the upper and lower layer populations is as follows:
QLHHEA is a two-level framework that involves the high-level individuals consisting of LLHs and the possible scheduling schemes in the problem solution space (low-level individuals); all higher individuals were sequences of LLH random composition, the length depending on the number of LLHs designed, where the same LLHs was allowed to occur; a viable scheduling scheme for the problem is the total work-piece procedure pi, which consists of F subsequences, i.e., pi= [ pi 12,...,πf,...,πF ], f=1, 2. Each sub-sequence pi f=[πf(1),πf(2),...,πf(nf) ] represents the processing order of n f workpieces assigned to factory f; the makespan value and C max (pi) are used as fitness to evaluate each feasible solution pi.
Further, the individuals in the lower-layer population in the step 1 are generated by adopting a construction heuristic method, and specifically include the following steps:
Step 1.1: for product P h (h=1, 2,., S), the initial work sequence λ h of ω h pieces of belonging P h is obtained by calculating the processing time I (h, I) of each piece on all machines from formula (21) and then arranging in ascending order; if I (h, I) of the two workpieces are the same, p h,i,1 is selected to be smaller; improving the work order quality by NEH heuristic (conventional method), and further determining the earliest completion time e h of the product P h:
/>
step 1.2: the product sequence lambda is obtained by arranging the earliest finishing time e h in ascending order.
Step 1.3: extracting the first s products from λ and distributing them to plants, at least one for each plant; the part of the product sequence assigned to the plant f' is denoted asSetting k=s.
Step 1.4: if there are still products to be dispensed in λ and k < S, assuming that δ f′ products have been dispensed to the plant f', the first product P h is selected (S < h.ltoreq.S) to perform the following steps:
Step 1.4.1: for F' =1, 2, F, insert lambda h as a block as much as possible To ensure that all workpieces of the same product are not separated; calculating a cost function σ (h, l ', f') of the undispensed product P h inserted into the slot l '(l' =1, 2,., δ f′) by formula (22), selecting the product with the smallest σ (h, l ', f'); if σ (h, l ', f') is the same then the earliest finishing time/>, is selectedThe shortest product; let/>Is the corresponding vacancy.
Step 1.4.2: finding the plant f * with the shortest finishing time, i.eProduct P h was dispensed to the factory and lambda h was inserted into/>Vacancies/>
Step 1.5: let k=k+1, repeat step 1.4 until all products have been traversed.
Further, in step 2, a forward or backward calculation method is adopted to decode each individual to obtain a global optimal solution pi best, which specifically comprises the following steps:
When decoding the higher-layer individuals, sequentially executing LLH contained in each higher-layer individual, and searching for a better solution in a solution space; if the obtained candidate solution has better adaptability than the original solution, replacing with a new solution, and executing the rest LLHs, otherwise, executing the next LLH until all LLHs in the higher-level individual are executed; during which the effectiveness of each higher-level individual is assessed by Contribution Rate (CR).
When decoding the low-layer individual, adopting a forward calculation method or a backward calculation method; however, whether forward calculation or backward calculation is used, each product needs to be inserted into all possible positions to evaluate all solutions (i.e. based on the acceleration strategy of product insertion) before calculation, a better solution is selected, then workpieces belonging to the same product in the solution are inserted into all positions of the product (i.e. based on the acceleration strategy of workpiece insertion) to evaluate all solutions, and finally the better solution is selected to execute a forward or backward decoding calculation method; for a clearer description, examples of two calculation methods are given in fig. 2 ((a) forward calculation and (b) backward calculation), where n=16, m=3, f=2, s=5; table 1 provides the processing times for the jobs and products; as in fig. 2, products P 1、P3 and P 5 are assigned to plant 1, product P 2 and to plant 2; the processing sequences of the workpieces in the two factories are pi 1 = [1,6,2,3,8,5,14,4] and pi 2 = [9,11,10,7,13,15,12,16] respectively; the times for products P 3 and P 4 to leave the processing machine are respectivelyAnd/>Thus, the maximum finishing time is
TABLE 1 processing time and assembly time for workpieces and products
Further, two acceleration strategies based on the insertion are as follows:
Step 2.1: acceleration strategy based on product insertion: inserting each product into all possible locations to evaluate all solutions; assuming that δ f′ products are distributed to f' plants, product P l′ has δ f′ +1 pluggable positions in total; the acceleration strategy for evaluating all insertion solutions based on product insertion is as follows:
Step 2.1.1: in the factory f' as a product The time and product of the ith workpiece leaving the machine M j The times of departure from the assembly machine M A are/>, respectivelyAnd/>Calculated as formulas (1) - (8).
Step 2.1.2: on the basis of step 2.1.1, the processing time and the product of the first workpiece on the machine M j The assembly time on the assembly machine M A is/>, respectivelyAnd,/>Calculated as formulas (10) - (18).
Step 2.1.3: assume thatProduct/>Inserted, the following formula holds:
Step 2.1.4: maximum finishing time of factory f' after product P l′ is inserted Calculated as follows:
Step 2.1.5: steps 2.1.3 and 2.1.4 are repeated until all insertion positions have been tried.
It is evident that the time complexity of both step 2.2.1 and step 2.2.2 isSince steps 2.2.3 and 2.2.4 are repeated to check all positions, the time complexity is O (δ f′mnl′); to sum up, the total time complexity/>, of δ f′ +1 solutions was evaluatedMuch lower than the time complexity without using an insertion-based acceleration strategyReferring to FIG. 2, products P 1、P3 and P 5 are present in plant 1, product P 2、P4 is present in plant 2, and product P 5 is extracted from plant 1 and inserted between product P 2 and product P 4 in plant 2; a schematic of the acceleration strategy based on product insertion is shown in fig. 3.
Step 2.2: acceleration strategy based on workpiece insertion: inserting workpieces belonging to the same product into the product; assume thatIn item 1/>If the first n [l′] -1 workpieces have completed scheduling, then the i' th workpiece may have n [l′] insert positions; the acceleration strategy for evaluating all insertion solutions based on workpiece insertion is as follows:
Step 2.2.1: calculation of
Step 2.2.2: suppose that workpiece V [l′],i′ is inserted into a productThe time for workpiece V [l′],i′ to leave machine M j is calculated as follows:
step 2.2.3: if the workpiece V [l′],i′ is inserted into Then product/>Completion time/>It must be calculated as follows:
step 2.2.4: finishing time of factory f' after workpiece insertion The calculation is as follows:
Step 2.2.5: steps 2.2.2 to 2.2.4 are repeated until the possible insertion positions are taken into account.
Obviously, the complexity of step 1 isSince steps 2 and 4 require n [l′] iterations to evaluate all post-insertion solutions, the time complexity is O (mn l′); total time complexity/>Much less than the temporal complexity/>, without employing a workpiece insertion-based acceleration strategyReferring to fig. 2, product P 3 in factory 1 contains 3 pieces (piece 5, piece 14, and piece 4), assuming that one piece is extracted from product P 3 (assuming that piece 14 is extracted), and then reinserted until all insertion positions in factory 1 are traversed, factory 2 is unchanged. Acceleration strategy based on workpiece insertion as shown in fig. 4 ((a) inserting workpiece 14 into a first position of product P 3, (b) inserting workpiece 14 into a second position of product P 3, (c) inserting workpiece 14 into a third position of product P 3).
Further, 12 high-efficiency heuristics are designed to build high-level individuals; based on three easy-to-implement operations (i.e., insert, swap, and reverse), 12 simple and efficient heuristic (LLH) were designed, which can be divided into two categories, one based on critical paths and the other based on non-critical paths; the factories through which the critical path passes are named critical factories, and the products and workpieces allocated to the critical factories are named critical products and critical workpieces; the details of the design LLHs are as follows:
LLH 1: randomly selecting a key product from a key factory, and randomly selecting a key workpiece from a workpiece set of the product; this workpiece is inserted until all of the workpieces of the product have been selected before the other workpieces are inserted into position.
LLH 2: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; after inserting this work piece into the position of each of the other work pieces, until all work pieces of the key product are selected.
LLH 3: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; the position of the workpiece is swapped with all other workpieces until all workpieces of the key product are selected.
LLH 4: randomly selecting a key product from a key factory, and randomly selecting two different key workpieces from a workpiece set of the product; the subsequence between the two selected key workpieces is inverted.
LLH 5: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; this workpiece is inserted until all workpieces that are not critical products are selected before the other workpieces are placed.
LLH 6: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; after inserting this work piece into the position of each other work piece, until all work pieces of the non-critical product are selected.
LLH 7: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; the position of the selected workpiece is swapped with all other workpieces until all workpieces of non-critical products are selected.
LLH 8: one product is randomly selected from a non-critical factory, two different workpieces are randomly selected from a set of workpieces for the non-critical product, and then the subsequence between the selected two non-critical workpieces is inverted.
LLH 9: randomly selecting a key product from a key factory; each product is inserted before or after its location in the critical factory until all critical products are selected and all insert-based operations are performed.
LLH 10: one key product is randomly selected from the key factories, and the location of the product is exchanged with other products until all key products are selected and all exchange-based operations are performed.
LLH 11: one product is randomly selected from a non-critical factory and the selected product is inserted before or after the location of all other products.
LLH 12: one product is randomly selected from the non-critical factories, and the location of the selected product is exchanged with the locations of all other products.
Further, the proposed QLHHEA contains five key components of state, action selection policy, rewards function and update mechanism, designed and described as follows:
(1) Definition of the states: the state tends to reflect key features of the external environment; where state refers to LLH, a state space (also called state set S) is divided into two subsets of 12 LLHs, namely 8 workpiece-based LLHs (S job) and 4 product-based LLHs (S product), as described below:
Sproduct={CPI,CPS,NPI,NPS}
Fig. 5 (transferto represents a transition between two states, (a) is a S job fully connected network, (b) is a S product fully connected network) shows two directed, fully connected networks of the 12 LLHs mentioned above, visualizing the relationship between selectable states and available actions.
(2) Definition of actions: the action refers to the action of state transition in S, namely, the action of transition from one state to another state; thus, the action set a consisting of available actions can be represented by a directed connection network g= { V, E }, where V is a set of V nodes and E is a set of E directed edges connecting these nodes; node V i′ e V represents a particular state; each edge E i′j′ E represents a preferential dependency between the two states s i′ and s j′ (i.e., LLH j′ can be performed after LLH i′ is completed); the weight of each edge represents the transition probability from LLH i′ to LLH j′.
(3) Action selection strategy: the choice of general action will affect the current reward, as well as the subsequent status and rewards; to rationally adjust the relationship between development and exploration, for a particular state s t for a particular time step t, a epsilon greedy strategy (epsilon t -greedy) is used to select either a random action with probability epsilon t or an action that produces the largest reward (i.e., the largest q-value) with probability 1-epsilon t (see algorithm 1); the pseudo code of action selection policy SelectionAnAction (s tt, type) is shown in algorithm 2 for determining the appropriate actions for the initial state s 0 and all subsequent states; at initial iteration, setting q-value of all state-action pairs to 0, thereby randomly selecting initial state and action; it is desirable to find regions that contain some good solutions, while lower epsilon t values facilitate depth-first searches around potential regions; thus, an epsilon adaptive adjustment method (denoted T cur event) As formula (29):
In equation (29), ε 0 is an initial value (i.e., ε 0=0.15),εf is a final value (i.e., ε f=0.01);Ttotal is the total number of time steps, T cur is the current number of time steps; according to the description above, the action selection policy first sets state s t+1 to 0, and if a random number of 1 is generated, s t+1 will be selected by the ε greedy policy with probability of being The resulting random action a t determines that, otherwise, state s t+1 is to be randomly generated. /(I)
(4) Bonus function: the reward function is a key component of developing a high-level strategy based on Q learning; the design of the reward function directly influences the ability of the agent to acquire required skills, and also has important influence on the convergence speed and the final performance of QLHHEA; since DABFSP is a single objective minimization problem, an appropriate action requires a reduction in the fitness of the feasible solution; the immediate prize of performing action a in state s is denoted r (s, a), determined by the quality IR of the improvement solution pi; IR may be calculated by [ C max(π)-Cmax(π′)]/Cmax (pi), where pi' is the new candidate solution obtained after performing the action; the bonus function r (s, a) is designed as shown in equation (30):
(5) Update mechanism: since the Q table records the knowledge that the agent learns from the environment, the Q-value of Q (S t,at) reflects the preferential preference of the agent to perform action a t e A in state S t e S; the q-value for each state-action pair (s t,at),Q(st,at) updated by weighting the instant prize r (s t,at) and the discount can be calculated by equation (33).
Further, a high-level strategy based on Q learning manipulates a low-level heuristic to search the solution space, as follows:
RL aims to get better behavior through dynamic interactions between agents and the environment; in general, RL has two key features: trial-and-error searching and delayed rewarding policies; in the RL framework, one or more objects with well-defined goals (i.e., maximizing jackpots) can perceive all aspects of the environment and then take action to change it; q learning is a sequential decision strategy based on Markov Decisions (MDP), which is one of the most successful strategies in reinforcement learning; MDP is used to search for policies in certain specific scenarios, aimed at simulating random policies and rewards through interactions between dynamic environment and agent agents whose system states satisfy Markov properties; MDP may be defined and described as a quadruple (S, A, P, R); s is a state space, a is a set of actions, where s= { s|s 1,s2,...,sT } represents a set of selectable states; a= { a|a 1,a2,...,aT } represents a set of available operations; s x A x S → R is the state transition probability, which refers to the potential possibility that the agent transitions to another state after taking action in the current state; s x A → R is a reward function, indicating that an enhanced reaction or reward is obtained immediately after appropriate action is taken; thus, the goal of the agent is to find the optimal strategy ω by trial and error, maximizing the desire for the discount rewards, as in equation (31).
In equation (31), V *(s) is a function of the action value under the optimal strategy ω; r (s t,at) represents the real-time rewards obtained by agent taking action a t in state s t in time step t; gamma e 0,1 represents the discount factor for the current and future rewards of the balance state-action pair (s t,at); in Q learning, the agent perceives a specific signal of state s t and makes a correct decision from action set A through epsilon-greedy; after one action a t is performed, state s t may be changed to another state s t+1 and rewards r t are returned by a well-designed rewards function; thus, a state-action trajectory (s 0,a0,s1,a1,) can be obtained at each time step; state action value Q ω(st,at) is defined in equation (32).
By solving the recursive Bellman optimality equation for the state-action pair (s t,at), the best Q ω(st,at can be found; i.e. by selecting the available action with the largest q value each time, determining the optimal strategy ω; the Q values of all state-action pairs are stored in a Q table and updated using equation (33).
In formula (31), Q ω(st,at) represents a Q value at which an action is taken in state s t; Maximum Q for all actions at state s t+1; lambda epsilon 0,1 is the learning rate for equilibrium exploration and development.
Further, in the following experiments, the effect of the proposed Q-learning based hyper-heuristic evolutionary algorithm solution DABFSP was tested; carrying out comparison on QLHHEA and iterative greedy algorithm IG, carrying out backtracking search on the super heuristic BS-HH based on a biological geography effective hybrid optimization algorithm HBBO, carrying out iterative local search ILS based on matrix cube distribution estimation algorithm MCEDA; all algorithms were re-implemented with Pascal and compiled by Embarcadero Rad Studio (XE 8); each algorithm runs independently on a PC with an Inter (R) Core (TM) i7-8700M@3.2GHz processor and 32GB RAM under the Windows 7 operating system.
The experimental dataset uses a reference dataset provided by Hatami et al (available at http:// soa. Iti. Es/S), i.e., n= {8, 12, 16, 20, 24}, m= {2,3,4}, f= {2,3,4}, s= {2,3,4}. The processing time of the work piece in the processing stage is uniformly distributed in [1, 99], and the assembly time of each product P l in the assembly stage is in the interval [ n l,99nl ]; the termination condition for all algorithms is a maximum CPU run time of 30nm milliseconds.
The invention uses four controllable parameters: population size popsize, high-quality high-rise individual proportionLearning rate λ and discounted silver γ; the horizontal values of the parameters are set as follows: popsize E {10,30,60,90},/>Lambda epsilon {0.1,0.3,0.5,0.7}, and gamma epsilon {0.3,0.5,0.7,0.9}; depending on the number and level of the parameters, there are a total of 4×4×4=256 groups; the sensitivity of the parameters is analyzed by adopting a full factor experimental design method, and each parameter group is independently and repeatedly operated for 10 times, so that the best parameter combination is determined as follows: ps=30,/>λ=0.5,γ=0.7。
To evaluate the performance of each algorithm, the experimental results were measured in percent form of relative deviation (ARPD):
Where R is the total number of runs, C i is the maximum time to finish obtained for a particular algorithm in the ith run, and C best is the optimal time to finish value for all algorithms.
The test results are shown in table 2,
Table 2 QLHHEA results of comparison with 4 advanced algorithms
n×m×F×S IG3 HBBO BS-HH MCEDA QLHHEA
8×2×2×2 0.068 0.045 0.032 0.013 0.000
12×2×2×2 0.096 0.063 0.048 0.023 0.002
16×2×2×2 0.125 0.091 0.066 0.031 0.004
20×2×2×2 0.157 0.114 0.084 0.047 0.009
24×2×2×2 0.133 0.090 0.065 0.033 0.006
8×3×3×3 0.094 0.055 0.034 0.014 0.000
12×3×3×3 0.132 0.083 0.061 0.032 0.003
16×3×3×3 0.151 0.101 0.056 0.041 0.005
20×3×3×3 0.174 0.124 0.075 0.054 0.008
24×3×3×3 0.186 0.143 0.093 0.063 0.013
8×4×4×4 0.147 0.096 0.067 0.037 0.005
12×4×4×4 0.183 0.125 0.085 0.056 0.012
16×4×4×4 0.165 0.118 0.074 0.048 0.008
20×4×4×4 0.172 0.142 0.093 0.085 0.016
24×4×4×4 0.246 0.184 0.128 0.112 0.025
Average 0.149 0.105 0.071 0.046 0.008
As seen in the table, the ensemble average ARPD (0.008) of QLHHEA over all example sizes is smaller than the average ARPD (0.149, 0.105, 0.071, 0.046) obtained by other algorithms; the results of BS-HH and MCEDA are also competitive in most arrays, but both are still inferior to QLHHEA; the main reason for this may be that BS-HH only uses retrospective search like differential evolution as HLS to operate a series of LLHs, and does not use some efficient advanced strategies, failing to reasonably record promising patterns in advanced individuals and thus failing to obtain better results; although MCEDA can learn the structural features or patterns in the high-quality solution, it still lacks a target-oriented search strategy to drive the search direction, and the accuracy of the probability model directly affects its performance; in addition, the results of IG 3 remain inferior to population-based HIOA, i.e., BS-HH and MCEDA, indicating that the population-based search method has significant advantages over the single-point search method; the results in Table 2 demonstrate the superiority of QLHHEA.
Aiming at the problem of distributed assembly blocking flow shop scheduling commonly existing in the actual production process, the invention provides a Q learning-based hyper-heuristic evolutionary algorithm; this is the application of the first study QLHHEA in solving DABFSP, which mainly contributes as follows: (1) A forward and backward calculation method based on the problem characteristics is provided; (2) Two acceleration strategies based on problem properties are provided, so that the calculation cost is reduced, and the search efficiency is improved; (3) A structured heuristic is proposed for specific problems to produce a high quality initial population; (4) There are 12 simple and efficient low-level heuristics that are defined as selectable states, and transitions between them are defined as available actions; (5) A high-level strategy based on Q learning is designed to guide searching behavior to obtain a better scheduling scheme; (6) Finally, experimental comparisons confirm the design advantages of the proposed evolutionary framework and key components, indicating that QLHHEA is an efficient algorithm for solving DABFSP.

Claims (8)

1. A distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning is characterized by comprising the following steps:
Step 1: initializing a population and a Q table, wherein individuals in a low-level population are generated by adopting a construction heuristic method, individuals in a high-level population are randomly generated, and the scales of the two populations are the same; setting related parameters; setting the q value of the state action pair to be zero;
Step 2: decoding each individual to obtain a global optimal solution pi best by adopting a forward or backward calculation method, and simultaneously executing two acceleration strategies based on insertion before calculation to save the calculation cost of an evaluation solution;
step 3: sequentially executing LLH in a higher-level individual on feasible scheduling solutions in a lower-level individual, wherein LLH is defined as a lower-level heuristic, and if a new solution adaptation value is better, replacing an old solution with the new solution and updating a global optimal solution; calculating the contribution rate of each higher-layer individual, and selecting according to the contribution rate The Q table is updated by adopting an updating mechanism for each high-level individual with high contribution rate; simultaneously setting count=0;
step 4: sampling the updated Q table to generate a new high-level individual, namely, operating a low-level heuristic by using a high-level strategy based on Q learning to search a solution space;
Step 4.1: selecting state s t using an action selection policy, obtaining action a t and next state s t+1;
Step 4.2: applying state s t+1 to pi best to yield pi' best; calculating the adaptation value of pi best (C (pi best))、C(π′best), IR, get bonus function r (s t,at), update Q value (Q t+1(st,at)), probability epsilon t and pi best;
Step 4.3: if C (pi 'best)<C(πbest), updating the global optimal solution pi best to pi' best, otherwise, skipping to the step 4.1;
Step 4.4: if count= popsize, jumping to step 3, otherwise jumping to step 4;
step 5: checking whether the stopping condition is met, if not, jumping to the step 4, otherwise outputting pi best.
2. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: the individuals in the low-level population in the step (1) are generated by adopting a construction heuristic method, and the method specifically comprises the following steps:
Step 1.1: for product P h (h=1, 2,.,. S.) the processing time I (h, I) for each workpiece on all machines was calculated by the following formula:
Where i is the work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; h is the product index, h=1, 2,..s; m is the number of machines in the production stage; i (h, I) is the processing time of each workpiece on all machines; p h,i,j is the processing time of the ith workpiece belonging to product P h on machine M j;
The I (h, I) is arranged in an ascending order to obtain an initial workpiece sequence lambda h formed by omega h workpieces of the product P h, and if the I (h, I) of the two workpieces are the same, P h,i,1 is selected to be smaller; improving the quality of the workpiece sequence by utilizing NEH heuristic algorithm, and further determining the earliest completion time e h of the product P h;
step 1.2: the product sequence lambda is obtained by arranging the earliest finishing time e h in ascending order;
Step 1.3: extracting the first s products from the product sequence lambda and distributing them to plants, at least one for each plant; the part of the product sequence assigned to the plant f' is denoted as Assigning s to the variable k, i.e. k=s;
Step 1.4: if there are still products to be dispensed in the product sequence λ and k < S, assuming δ f′ products have been dispensed to the factory f', then the first product P h, S < h+.s, where h is the product index, h=1, 2,..s, performs the following steps:
step 1.4.1: for F' =1, 2, F, insert lambda h as a block To ensure that all workpieces of the same product are not separated; the cost function σ (h, l ', f') of the undispensed product P h inserted into the slot l 'is calculated by the following formula, l' =1, 2,..delta f′;
Where i is the work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; n is the number of work pieces; f is the number of factories; m is the number of machines in the production stage; s is the number of products; h is the product index; l is the index of the product in factory f, l=1, 2,..delta fh is the work order of product P l in factory f, Is a product in a factory f The departure time of the workpiece V l,i on the machine M j in the factory f; /(I)Processing time on machine M j in factory f for workpiece V l,i;
selecting the product with the smallest sigma (h, l ', f'); if σ (h, l ', f') is the same, the earliest finishing time is selected The shortest product; let/>Is a corresponding vacancy;
Step 1.4.2: finding the plant f * with the shortest finishing time, i.e Product P h was dispensed to the factory and lambda h was inserted into/>Vacancies/>
Step 1.5: let k=k+1, repeat step 1.4 until all products have been traversed.
3. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: decoding each individual by adopting a forward or backward calculation method to obtain a global optimal solution pi best, wherein the method comprises the following specific steps of:
when decoding the higher-layer individuals, sequentially executing LLH contained in each higher-layer individual, and searching for a better solution in a solution space; if the obtained candidate solution has better adaptability than the original solution, replacing with a new solution, and executing the rest LLHs, otherwise, executing the next LLH until all LLHs in the higher-level individual are executed; during which the effectiveness of each higher-level individual is assessed by contribution rate;
When decoding a lower-layer individual, two forward or backward calculation methods are adopted, and two acceleration strategies based on insertion are executed before calculation, specifically: and inserting each product into all possible positions to evaluate all solutions, selecting an optimal solution, inserting workpieces belonging to the same product in the solution into all positions of the product to evaluate all solutions, and finally selecting the optimal solution to execute a forward or backward decoding calculation method.
4. A distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 3, wherein: the two acceleration strategies based on the insertion specifically comprise the following steps:
Step 2.1: acceleration strategy based on product insertion: inserting each product into all possible locations to evaluate all solutions; assuming that δ f′ products are distributed to f' plants, product P l′ has δ f′ +1 pluggable positions in total; the acceleration strategy for evaluating all insertion solutions based on product insertion is as follows:
Step 2.1.1: in the factory f' as a product The time and product/>, of the ith workpiece leaving machine M j The times of departure from the assembly machine M A are/>, respectivelyAnd/>
Step 2.1.2: on the basis of step 2.1.1, the processing time and the product of the ith workpiece on machine M j The assembly time on the assembly machine M A is/>, respectivelyAnd,/>
Step 2.1.3: assume thatProduct/>Inserted, the following formula holds:
Step 2.1.4: maximum finishing time of factory f' after product P l′ is inserted Calculated as follows:
Step 2.1.5: repeating steps 2.1.3 and 2.1.4 until all insertion positions are tried;
step 2.2: acceleration strategy based on workpiece insertion: inserting workpieces belonging to the same product into the product; assume that In item 1/>If the first n [l′] -1 workpieces have completed scheduling, then the i' th workpiece may have n [l′] insert positions; the acceleration strategy for evaluating all insertion solutions based on workpiece insertion is as follows:
Step 2.2.1: calculation of
Step 2.2.2: suppose that workpiece V [l′],i′ is inserted into a productThe time for workpiece V [l′],i′ to leave machine M j is calculated as follows:
step 2.2.3: if the workpiece V [l′],i′ is inserted into Then product/>Completion time/>It must be calculated as follows:
step 2.2.4: finishing time of factory f' after workpiece insertion The calculation is as follows:
in the above formula, i is a work index, i=1, 2,..n l; j is the index of the machine and, j=1, 2, m; delta f is the number of products in the plant f, F factory index, f=1, 2,; m is the machine set, m= { M 1,M2,...,Mm }; /(I)For the product in factory f,/> The departure time of product P l on machine M j in factory f; The departure time of the workpiece V l,i on the machine M j in the factory f; /(I) Assembly time on machine M A in factory f for product P l; /(I)Processing time on machine M j in factory f for workpiece V l,i; /(I)The duration on machine M j in factory f for workpiece V l,i; /(I)The duration on machine M j in factory f for product P l; l is the product index in factory f, l=1, 2,..delta f;
Step 2.2.5: steps 2.2.2 to 2.2.4 are repeated until the possible insertion positions are taken into account.
5. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: the higher-level individuals in the step 3 are constructed by 12 heuristic LLHs, and the heuristic LLHs can be divided into two categories, wherein one category is based on a critical path, and the other category is based on a non-critical path; the factories through which the critical path passes are named critical factories, and the products and workpieces allocated to the critical factories are named critical products and critical workpieces; the heuristic designed is as follows:
LLH 1: randomly selecting a key product from a key factory, and randomly selecting a key workpiece from a workpiece set of the product; inserting the workpiece into the position of other workpieces until all workpieces of the product have been selected;
LLH 2: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; inserting the workpiece into the position of each other workpiece until all the workpieces of the key product are selected;
LLH 3: randomly selecting a key product from a key factory and randomly selecting a key workpiece from a workpiece set of the product; exchanging the position of the workpiece with all other workpieces until all workpieces of the key product are selected;
LLH 4: randomly selecting a key product from a key factory, and randomly selecting two different key workpieces from a workpiece set of the product; performing inverse operation on the subsequences between the two selected key workpieces;
LLH 5: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; inserting the workpiece into the position of other workpieces until all workpieces of non-critical products are selected;
LLH 6: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; inserting the workpiece into the position of each other workpiece until all workpieces of the non-critical product are selected;
LLH 7: randomly selecting a product from a non-critical factory and randomly selecting a workpiece from a set of workpieces for the product; exchanging the position of the selected workpiece with all other workpieces until all workpieces of non-critical products are selected;
LLH 8: randomly selecting a product from a non-critical factory, randomly selecting two different workpieces from a workpiece set of the non-critical product, and then inverting a subsequence between the selected two non-critical workpieces;
LLH 9: randomly selecting a key product from a key factory; inserting each product before or after its location in the key factory until all key products are selected and all insert-based operations are performed;
LLH 10: randomly selecting a key product from the key factories, exchanging the position of the product with other products until all key products are selected and all exchange-based operations are performed;
LLH 11: randomly selecting one product from a non-critical factory, and inserting the selected product before or after the position of all other products;
LLH 12: one product is randomly selected from the non-critical factories, and the location of the selected product is exchanged with the locations of all other products.
6. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: in the step (3), the update mechanism records the knowledge learned by the agent from the environment, so the Q-value of Q (S t,at) reflects the preferential preference of the agent to execute the action a t epsilon A under the state S t epsilon S; for each state-action pair (s t,at),Q(st,at) updated by weighting the instant prize r (s t,at) and the discounted q-value, it can be calculated by the following formula:
In the above formula, s is a state, a is an action, and r (s, a) is an instant prize for executing the action a in the state s; s is a state space, s= { s|s 1,s2,...,sT},t=1,...,T,st represents a selectable state; a is an action set, a= { a|a 1,a2,...,aT},t=1,...,T,at representing a selectable action; (s t,at) is a selectable state-action pair; the Q (s t,at) table performs the priority preference of state-action pairs (s t,at); lambda is a coefficient.
7. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: the action selection strategy in step 4.1 is specifically as follows:
For a particular state s t for a particular time step t, a modified ε greedy strategy is used to select either a random action with probability ε t or an action yielding the maximum reward with probability 1- ε t; the action selection policy is used to determine the appropriate actions for the initial state s 0 and all subsequent states; at initial iteration, setting q-value of all state-action pairs to 0, thereby randomly selecting initial state and action; while lower epsilon t values facilitate depth-first searches around potential regions; thus, an epsilon adaptive adjustment method is provided for the T cur event, denoted epsilon Tcur, of the formula:
Where ε 0 is an initial value (i.e., ε 0=0.15),εf is a final value (i.e., ε f=0.01);Ttotal is the total number of time steps, T cur is the current number of time steps, according to the description above, the action selection policy first sets state s t+1 to 0, if a random number of 1 is generated, then s t+1 will be determined by random action a t generated by εgreedy policy selection probability ε Tcur, otherwise state s t+1 will be randomly generated.
8. The distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning according to claim 1, wherein: the bonus function of step 4.2 is designed as follows:
In the above formula, r (s, a) is the immediate reward for executing action a in state s, and is determined by the quality IR of the improved solution pi, IR can be calculated by [ C max(π)-Cmax(π′)]/Cmax (pi), C max (pi) is the maximum completion time of the scheduling solution pi, and pi' is the new candidate solution obtained after executing action.
CN202311565429.0A 2023-11-22 2023-11-22 Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning Active CN117519030B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311565429.0A CN117519030B (en) 2023-11-22 2023-11-22 Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311565429.0A CN117519030B (en) 2023-11-22 2023-11-22 Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning

Publications (2)

Publication Number Publication Date
CN117519030A CN117519030A (en) 2024-02-06
CN117519030B true CN117519030B (en) 2024-04-26

Family

ID=89764162

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311565429.0A Active CN117519030B (en) 2023-11-22 2023-11-22 Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning

Country Status (1)

Country Link
CN (1) CN117519030B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115344011A (en) * 2022-03-17 2022-11-15 兰州理工大学 Energy-saving distributed two-stage assembly zero-waiting flow shop scheduling problem optimization system
CN116300738A (en) * 2023-03-12 2023-06-23 兰州理工大学 Complex workshop scheduling optimizer based on improved meta heuristic algorithm
CN116466659A (en) * 2023-03-21 2023-07-21 昆明理工大学 Distributed assembly flow shop scheduling method based on deep reinforcement learning
CN116700176A (en) * 2023-06-19 2023-09-05 兰州理工大学 Distributed blocking flow shop scheduling optimization system based on reinforcement learning

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115344011A (en) * 2022-03-17 2022-11-15 兰州理工大学 Energy-saving distributed two-stage assembly zero-waiting flow shop scheduling problem optimization system
CN116300738A (en) * 2023-03-12 2023-06-23 兰州理工大学 Complex workshop scheduling optimizer based on improved meta heuristic algorithm
CN116466659A (en) * 2023-03-21 2023-07-21 昆明理工大学 Distributed assembly flow shop scheduling method based on deep reinforcement learning
CN116700176A (en) * 2023-06-19 2023-09-05 兰州理工大学 Distributed blocking flow shop scheduling optimization system based on reinforcement learning

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Fang-Chun Wu,Bin Qian.《A Q-Learning-Based Hyper-Heuristic Evolutionary Algorithm for the Distributed Flexible Job-Shop Scheduling Problem》.Lecture Notes in Computer Science,2023,全文. *
Jin-Han Zhu,Rong Hu.《Hyper-heuristic Q-Learning Algorithm for Flow-Shop Scheduling Problem with Fuzzy Processing Times》.Lecture Notes in Computer Science,2023,全文. *

Also Published As

Publication number Publication date
CN117519030A (en) 2024-02-06

Similar Documents

Publication Publication Date Title
Chamnanlor et al. Embedding ant system in genetic algorithm for re-entrant hybrid flow shop scheduling problems with time window constraints
Wang et al. Application of reinforcement learning for agent-based production scheduling
CN113792924A (en) Single-piece job shop scheduling method based on Deep reinforcement learning of Deep Q-network
CN111985672B (en) Single-piece job shop scheduling method for multi-Agent deep reinforcement learning
CN101901425A (en) Flexible job shop scheduling method based on multi-species coevolution
CN112561225B (en) Flexible job shop scheduling method based on marker post co-evolution algorithm
Vidal et al. Machine scheduling in custom furniture industry through neuro-evolutionary hybridization
CN116690589B (en) Robot U-shaped dismantling line dynamic balance method based on deep reinforcement learning
CN107831740A (en) A kind of Optimization Scheduling during the distributed manufacturing applied to notebook part
CN115130789A (en) Distributed manufacturing intelligent scheduling method based on improved wolf optimization algorithm
CN111144710A (en) Construction and dynamic scheduling method of sustainable hybrid flow shop
Wei et al. A multi-objective migrating birds optimization algorithm based on game theory for dynamic flexible job shop scheduling problem
CN114926033A (en) Flexible job shop dynamic event scheduling method based on improved NSGAII
CN115933568A (en) Multi-target distributed hybrid flow shop scheduling method
CN116027753A (en) Multi-target mixed flow shop scheduling method and system
CN115983423A (en) Feeding and discharging scene scheduling optimization method considering double resource constraints
Cao et al. An adaptive multi-strategy artificial bee colony algorithm for integrated process planning and scheduling
CN117519030B (en) Distributed assembly blocking flow shop scheduling method based on hyper-heuristic reinforcement learning
CN117369378A (en) Mixed flow manufacturing shop scheduling method and system based on Monte Carlo tree search algorithm
CN116774657A (en) Dynamic scheduling method for remanufacturing workshop based on robust optimization
CN116822217A (en) Man-machine double-resource constraint multi-target production scheduling method considering man-hour uncertainty
CN115730799A (en) Method, system and equipment for scheduling production tasks of flexible assembly job workshop
Yan et al. A job shop scheduling approach based on simulation optimization
CN113505910B (en) Mixed workshop production scheduling method containing multi-path limited continuous output inventory
CN110689216A (en) Robot assembly unit JIT energy-saving production optimization method based on mixed fruit fly algorithm

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant