Method, device and readable storage medium for flexible production line scheduling
By constructing a virtual factory environment and a sorting and routing model, the problem of balancing multiple objectives in flexible production line scheduling was solved, thereby improving production efficiency and scheduling flexibility.
Patent Information
- Application Number
- CN202610058508.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-15
- Publication Date
- 2026-06-09
AI Technical Summary
Existing flexible production line scheduling methods, based on heuristic rules and metaheuristic algorithms, cannot effectively balance multiple scheduling objectives, resulting in low production efficiency and difficulty in adapting to dynamic changes and real-time scheduling needs on the production site.
By constructing a virtual factory environment, using a target sequencing model to determine the production sequence, and combining a target routing model to allocate workstations for each process, multiple scheduling objectives can be coordinated and balanced at both the order level and the workstation level, thereby improving production efficiency.
By determining the production sequence and workstation allocation plan, the order delay rate and equipment idle rate are significantly reduced, and the scheduling flexibility and production efficiency of the flexible production line are improved.
Smart Images

Figure CN122175181A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent manufacturing technology, and in particular to a scheduling method, equipment and readable storage medium for flexible production lines. Background Technology
[0002] A flexible production line refers to a physical production system that can quickly adapt to various product processing or assembly tasks within a certain range. "Flexibility" is mainly reflected in equipment adaptability, process flexibility, and capacity adjustability, which greatly balances the efficiency and cost of producing various products.
[0003] In flexible production line scheduling scenarios, heuristic rules are a common method for solving the task allocation problem involving multiple processes and multiple devices. Heuristic rules are a class of decision criteria designed based on experience, intuition, or locally optimal strategies. During scheduling, feasible scheduling strategies are quickly obtained based on optimization objectives. An optimization objective might be to minimize the average process time; the corresponding rule for this objective is Shortest Processing Time (SPT).
[0004] However, scheduling strategies based on heuristic rules have poor accuracy, which seriously affects production efficiency. Summary of the Invention
[0005] This application provides a scheduling method, equipment, and readable storage medium for flexible production lines. By sorting orders to balance multiple objectives such as completion time and on-time rate, and by allocating workstations to each process to optimize workstation utilization and other objectives, it adapts to multiple objectives of optimization while improving production efficiency.
[0006] In a first aspect, embodiments of this application provide a scheduling method for flexible production lines, comprising: Construct a virtual factory environment for the target production line, wherein the virtual factory environment is used to indicate the real-time status of the target production line in multiple dimensions, and the target production line is a flexible production line; Based on the real-time status of each dimension in the first set, the production order of each product in the target order is determined. Each dimension in the first set belongs to the multiple dimensions. The production order is used to balance multiple scheduling objectives from the order level. Based on the real-time status of each dimension in the production sequence and the second set, workstations are assigned to each process of each product in the production sequence to obtain a workstation allocation scheme. The workstation allocation scheme is used to coordinate and balance multiple scheduling objectives at the workstation level. The multiple scheduling objectives correspond to different optimization directions of the flexible production line, and each dimension in the second set belongs to the multiple dimensions. The target production line is scheduled according to the production sequence and the workstation allocation scheme to complete the target order.
[0007] Secondly, embodiments of this application provide a scheduling device for flexible production lines, comprising: A construction module is used to construct a virtual factory environment for the target production line. The virtual factory environment is used to indicate the real-time status of the target production line in multiple dimensions. The target production line is a flexible production line. The sorting module is used to determine the production order of each product in the target order based on the real-time status of each dimension in the first set, wherein each dimension in the first set belongs to the multiple dimensions, and the production order is used to balance multiple scheduling objectives from the order level. The allocation module is used to allocate workstations to each process of each product in the production sequence according to the real-time status of each dimension in the production sequence and the second set, so as to obtain a workstation allocation scheme. The workstation allocation scheme is used to coordinate and balance multiple scheduling objectives at the workstation level. The multiple scheduling objectives correspond to different optimization directions of the flexible production line, and each dimension in the second set belongs to the multiple dimensions. The processing module is used to schedule the target production line according to the production sequence and the workstation allocation scheme to complete the target order.
[0008] Thirdly, embodiments of this application provide an electronic device, including: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it causes the electronic device to implement the method described in the first aspect or various possible implementations of the first aspect.
[0009] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer instructions, which, when executed by a processor, are used to implement the method described in the first aspect or various possible implementations of the first aspect.
[0010] Fifthly, embodiments of this application provide a computer program product comprising a computing program, wherein when the computer program is executed by a processor, it implements the method described in the first aspect or various possible implementations of the first aspect.
[0011] This application provides a scheduling method, device, and readable storage medium for flexible production lines. The electronic device constructs a virtual factory environment for the target production line, which indicates the real-time status of the target production line across multiple dimensions. The target production line is a flexible production line. The electronic device determines the production sequence of each product in the target order based on the real-time status of each dimension belonging to a first set of dimensions within the target production line. Then, based on the production sequence and the real-time status of each dimension belonging to a second set of dimensions within the target production line, it allocates workstations to each process of each product in the production sequence to obtain a workstation allocation scheme. Finally, the electronic device schedules the target production line according to the production sequence and the workstation allocation scheme to complete the target order. This scheme balances multiple scheduling objectives at the order level by determining the production sequence of each product in the target order. Subsequently, by allocating workstations to each process of each product in the production sequence, it collaboratively balances multiple scheduling objectives at the workstation level, adapting to multi-objective optimization while improving production efficiency. Attached Figure Description
[0012] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0013] Figure 1 This is a flowchart of a scheduling method for flexible production lines provided in an embodiment of this application; Figure 2A This is the process route diagram of blade A in the scheduling method for flexible production lines provided in this application embodiment; Figure 2B This is the process route diagram of blade B in the scheduling method for flexible production lines provided in this application embodiment; Figure 3 This is another flowchart of the scheduling method for flexible production lines provided in the embodiments of this application; Figure 4A yes Figure 3 A schematic diagram illustrating the training process of the target ranking model; Figure 4B yes Figure 3 A schematic diagram illustrating the training process of the target routing model; Figure 5 A schematic diagram of a scheduling device for flexible production lines provided in an embodiment of this application; Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0014] Flexible production lines, as an important component of modern manufacturing, are characterized by product diversification, small production batches, and frequent changeovers, placing higher demands on production scheduling and control. Traditional scheduling methods for flexible production lines mainly include heuristic rules and metaheuristic algorithms, which have achieved automated scheduling of the production process to a certain extent.
[0015] Heuristic rules quickly generate feasible scheduling strategies based on optimization objectives. For example, if the optimization objective is to minimize the average process time, the corresponding rule is SPT (Scheduled Process Time). However, scheduling strategies derived from heuristic rules have a single objective and may not be optimal, failing to autonomously optimize multiple objectives. For instance, they may only focus on the shortest processing time of tasks without considering equipment load conditions. Furthermore, SPT is a fixed rule and cannot autonomously adjust its weights according to dynamic changes in the production environment, such as equipment failures and order insertions.
[0016] Metaheuristic algorithms, including but not limited to genetic algorithms and simulated annealing, traverse the solution space through randomized search and iterative evolution to obtain the global optimum, thus avoiding getting trapped in local optima to some extent. However, real-time scheduling of flexible production lines faces dynamic disturbances such as order insertions, equipment failures, and material delays. Each disturbance requires re-executing the "exploration-development" iterative process and traversing the solution space, resulting in long computation times and making it difficult to meet the requirements of real-time scheduling.
[0017] Based on this, embodiments of this application provide a scheduling method, equipment, and readable storage medium for flexible production lines. A sorting model determines the production sequence of each product in a target order, thereby balancing multiple scheduling objectives at the order level. Subsequently, a routing model allocates workstations to each process of each product in the production sequence to collaboratively balance multiple scheduling objectives at the workstation level. This adapts to multi-objective optimization while simultaneously improving production efficiency.
[0018] The execution subject of this application embodiment is an electronic device, such as a server, desktop computer, or laptop, on which a simulation platform such as Salabim is loaded. Furthermore, a target sequencing model and a target routing model are deployed on the electronic device. After the electronic device constructs a virtual factory environment for the target production line using the simulation platform, the subsequent scheduling is divided into two stages: In the first stage, the electronic device uses the target sequencing model to determine the production sequence of each product in the target order; in the second stage, based on the production sequence output by the target sequencing model, the electronic device uses the target routing model to allocate workstations for each process of each product in the production sequence to obtain a workstation allocation scheme. Afterwards, the electronic device schedules the target production line according to the production sequence and workstation allocation scheme to complete the target order.
[0019] In this embodiment, the target production line is a flexible production line, including but not limited to flexible production lines for automotive parts, medical devices, home appliances, and flexible production lines for producing different types of blades. When the target production line is used to produce different types of blades, the target order includes at least two types of blades. For example, the target production line is used to produce onshore wind turbine blades and Shanghai wind turbine blades. As another example, the target production line is used to produce 1.5 MW blades, 2 MW blades, and 2.5 MW blades.
[0020] By adopting this approach, when the target production line is used to produce different types of blades, the production sequence and workstation allocation scheme are generated in stages, which significantly reduces the order delay rate and equipment idle rate, while improving the scheduling flexibility of the target production line.
[0021] Figure 1 This is a flowchart of a scheduling method for flexible production lines provided in an embodiment of this application. This embodiment applies to the aforementioned electronic equipment and includes: 101. Construct a virtual factory environment for the target production line, wherein the virtual factory environment is used to indicate the real-time status of the target production line in multiple dimensions, and the target production line is a flexible production line.
[0022] In this embodiment, the electronic device constructs a virtual factory environment for the target production line based on simulation platforms such as Salabim. Salabim is an object-oriented Python discrete event simulation framework designed specifically for simulating systems where the state changes only at discrete points in time. For example, the process of waiting → starting processing → processing completed, or the machine's idle → busy → fault → repair, all involve instantaneous state switching at a certain point in time, with the state remaining unchanged during the intermediate processing or repair process. Each process includes a type, processing time, and a set of optional machines. By inheriting the sim.Component class, the lifecycle of a process is defined by the function process(), the processing time of a process is simulated by the function hold(), and the scheduling decision of a process is waited for by the function passivate(). The lifecycle includes: process activation → processing completion → triggering the next process.
[0023] In this embodiment, each machine defines attributes through capabilities, uses status variables to record states such as idle, busy, and faulty, and uses a built-in monitor to collect utilization data in real time. In the global queue, a container object `sim.Queue` is used to manage pending processes and prioritize urgent orders; a container object `sim.Resource` is used to simulate a limited number of machine workstations; and the `request()` and `release()` methods control resource usage. When a workstation needs to be allocated to a process, the target routing model is activated. Based on the real-time status of the target production line across multiple dimensions, the target routing model selects and executes actions in the second action space, thereby outputting a workstation allocation scheme.
[0024] Taking the construction of a virtual factory environment for electronic devices based on Salabim as an example, process attributes and workstation attributes are predefined to provide a unified inference environment for the target ranking model and the target routing model. Process attributes include, but are not limited to, processing time and constraints. Workstation attributes include, but are not limited to, compatible processes and capacity limits.
[0025] Suppose the target order instructs the production of 2 blades A and 3 blades B, where blades A and B are different models. Blade A includes A1 and A2; blade B includes B1, B2, and B3. Sub-components of blade A include a1, a2, a3, share1, share2, and share3; sub-components of blade B include b1, b2, b3, share1, share2, and share3. That is, both blades A and B contain share1, share2, and share3. Blade A has 3 independent workstations [a_s1, a_s2, a_s3], with 2, 2, and 1 workstations of each type, used to produce sub-components [a1, a2, a3] respectively. Blade B has 3 independent workstations [b_s1, b_s2, b_s3], with 1, 2, and 1 workstation of each type, used to produce sub-components [b1, b2, b3] respectively. Blades A and B share 3 types of workstations [share_s1, share_s2, share_s3], with each type of workstation having a quantity of [1, 2, 1], and are used to produce sub-components [share1, share2, sahare3] respectively.
[0026] Figure 2A This is the process route diagram of blade A in the scheduling method for flexible production lines provided in this application embodiment. Figure 2B This is the process route diagram for blade B in the scheduling method for flexible production lines provided in this application embodiment. Please refer to... Figure 2ADuring the production of blade A, sub-components a1 and a2 are produced in parallel, followed by the sequential production of sub-components share1, a3, share2, and share3. Please refer to... Figure 2B During the production of blade B, sub-components b1 and b2 are produced in parallel, followed by the sequential production of sub-components share1, b3, share2, and share3.
[0027] Based on the above generation rules, the electronic device uses salabim to build a virtual factory environment with multiple different workstations. The main function of salabim is to simulate discrete probability events, such as simulating the interleaved production of blade A and blade B.
[0028] 102. Based on the real-time status of each dimension in the first set, determine the production order of each product in the target order. Each dimension in the first set belongs to the multiple dimensions. The production order is used to balance multiple scheduling targets from the order level.
[0029] In this embodiment of the application, the dimensions in the first set include the number of jobs in the system, the number of jobs in the queue, the global completion rate, the global actual delay rate, the number of products indicated by the target order, the available time of each workstation, the load of the workstation, and other dimensions used for sorting decisions.
[0030] The electronic device inputs the real-time status of each dimension in the first set and the target order into the target sorting model so that the target sorting model outputs the production order. For example, the target order is to produce 2 blades A and 3 blades B. The production order output by the target sorting model is: [A1, B1, B2, A2, B3].
[0031] 103. Based on the real-time status of each dimension in the production sequence and the second set, assign workstations to each process of each product in the production sequence to obtain a workstation allocation scheme. The workstation allocation scheme is used to coordinate and balance multiple scheduling objectives at the workstation level. The multiple scheduling objectives correspond to different optimization directions of the flexible production line, and each dimension in the second set belongs to the multiple dimensions.
[0032] In this embodiment of the application, the dimensions in the second set include the current process type, the processing time required for the current process, the arrival time and relaxation time of the next process, the real-time status of each workstation, and the process adapted to the workstation.
[0033] The electronic device inputs the production sequence output by the target sorting model and the real-time status of each dimension in the second set into the target routing model, so that the target routing model can allocate workstations for each process of each product in the production sequence to obtain a workstation allocation scheme.
[0034] Table 1 shows the workstations assigned to each process in A1, and Table 2 shows the workstations assigned to each process in B1.
[0035] Table 1 Table 2 As described above: the production sequence obtained in step 102 indicates which product in the target order should be produced first, balancing the utilization of independent and shared workstations and preventing a particular product model from occupying a bottleneck workstation for an extended period. For example, there is only one independent workstation b_s1, and the production of blade B is not centrally scheduled. The workstation allocation scheme obtained in step 103 determines which workstation each process will be performed at, enabling parallel processes to start synchronously and shared workstations to be used at different times, ensuring the shortest total completion time. The production sequence determines the workstation allocation scheme; for example, if A1 is produced first, a shared workstation will be allocated to A1 first. For each shared workstation, after the production of A1's sub-components is completed at that workstation, the shared workstation will then be allocated to B1 to produce B1's sub-components.
[0036] 104. Schedule the target production line according to the production sequence and the workstation allocation scheme to complete the target order.
[0037] After determining the production sequence and workstation allocation plan, in the actual production process, the electronic equipment produces the products in the target order in sequence according to the production sequence, and allocates workstations for each process of each product according to the workstation allocation plan, so as to complete the target order in an orderly and fast manner.
[0038] The scheduling method for flexible production lines provided in this application involves an electronic device constructing a virtual factory environment for the target production line. This virtual factory environment indicates the real-time status of the target production line across multiple dimensions, where the target production line is flexible. The electronic device determines the production sequence of each product in the target order based on the real-time status of each dimension belonging to a first set of dimensions within the target production line. Then, based on the production sequence and the real-time status of each dimension belonging to a second set of dimensions within the target production line, it allocates workstations to each process of each product in the production sequence to obtain a workstation allocation scheme. Finally, the electronic device schedules the target production line according to the production sequence and the workstation allocation scheme to complete the target order. This scheme balances multiple scheduling objectives at the order level by determining the production sequence of each product in the target order. Subsequently, by allocating workstations to each process of each product in the production sequence, it collaboratively balances multiple scheduling objectives at the workstation level, adapting to multi-objective optimization while improving production efficiency.
[0039] Figure 3This is another flowchart of a scheduling method for flexible production lines provided in this application. This embodiment includes: 301. Building a virtual environment for a sample production line based on salabim.
[0040] 302. Create workstations, processes, etc. in the sample virtual environment.
[0041] 303. The first stage is to train the target ranking model.
[0042] 304. The second stage trains the target routing model.
[0043] In this embodiment of the application, both the target ranking model and the target routing model are based on Deep Q-Network (DQN) models.
[0044] 305. The inference phase calls the target sorting model and the target routing model.
[0045] During the inference phase, the electronic device calls the target sequencing model to determine the production sequence and the target routing model to determine the workstation allocation scheme.
[0046] according to Figure 3 It is known that pre-trained target ranking and target routing models are deployed on the electronic equipment. During actual scheduling, the electronic equipment inputs the real-time status and target orders of each dimension from the first set into the target ranking model, causing the target ranking model to output a production order. Subsequently, the electronic equipment inputs the real-time status and production order of each dimension from the second set into the target routing model, causing the target routing model to output a workstation allocation scheme. The training processes of the target ranking and target routing models are described in detail below.
[0047] First, the training process of the target ranking model.
[0048] Optionally, during the training of the target ranking model, the electronic device constructs a virtual environment for the sample production line. This virtual environment indicates the real-time status of the sample production line across multiple dimensions, and the sample production line is a flexible production line. Then, for each sample order in the sample set, the electronic device inputs the sample order and the sample status of each dimension belonging to the first set from the multiple dimensions of the sample production line into the initial ranking model. The initial ranking model is then trained according to a first action space and a first multi-objective reward rule to obtain the target ranking model. The first action space contains multiple sample ranking strategies.
[0049] In this embodiment, the sample production line and the target production line can be identical flexible production lines or different flexible production lines. When the sample production line and the target production line are identical, both are built based on Salabim and use the same workstation definitions, constraints, etc. When the sample production line and the target production line are different, both are still built based on Salabim, but the virtual environment of the sample production line and the virtual factory environment of the target production line are different. In this way, the trained target ranking model and target routing model have generalization ability and can be used for flexible production lines of different products.
[0050] During the training of the target ranking model, electronic devices interact with the virtual sample environment in real time to obtain the sample status of each dimension belonging to the first set in multiple dimensions of the sample production line. For example, a sample order contains 6 products, which can be divided into 3 models.
[0051] Subsequently, the electronic equipment trains an initial ranking model based on the first action space and the first multi-objective reward rule to obtain the target ranking model. The first action space contains multiple sample ranking strategies. These strategies include, but are not limited to, SPT (Solution-Purpose Tracking), Work-In-Queue (WINQ), Machine Spare Rest (MS), and Critical Ratio (CR). Each of these strategies corresponds to a different optimization objective: SPT aims to minimize the average process time; WINQ aims to balance the waiting time of each process; MS aims to reduce equipment idle time and improve workstation utilization; and CR aims to reduce order delay risk and improve on-time delivery rate.
[0052] After the initial ranking model outputs the sample order each time, the electronic device determines the first reward value according to the first objective reward rule, and updates the network parameters of the initial ranking model according to the first reward value. Thus, through the closed loop of "state → action → reward", the parameters of the initial ranking model are continuously updated, and the above process is repeated until the first reward value converges.
[0053] This approach uses a closed-loop optimization training of the initial ranking model through "state → action → reward" to continuously converge the sample order output by the initial ranking model towards the multi-objective goal, thereby obtaining the target ranking model and achieving the goal of adapting to multi-objective optimization.
[0054] Optionally, in the above embodiments, during the process of training the initial ranking model according to the first action space and the first multi-objective reward rule to obtain the target ranking model, the electronic device uses the initial ranking model to select a sample ranking strategy from the first action space, so that the initial ranking model outputs a sample order according to the sample ranking strategy. Then, the electronic device inputs the sample order into the sample virtual environment to simulate production, and determines a first reward value based on the simulation results and the first multi-objective reward rule. Subsequently, it updates the parameters of the initial ranking model according to the first reward value until the first reward value converges to obtain the target ranking model. The first reward value is used to indicate the rationality of the sample order.
[0055] For example, after obtaining the sample sequence each time, the electronic device submits the sample sequence to the sample virtual environment to simulate production and obtain the simulated production results. The simulated production results may include: a total completion time of 16 hours, an average equipment utilization rate of 85%, and no order delays. Then, the electronic device determines a first reward value based on a first multi-objective reward rule and the simulated production results. For example, the shorter the total completion time, the higher the average equipment utilization rate, and the higher the on-time work ratio, the higher the first reward value.
[0056] After the electronic device determines the first reward value, it updates the parameters of the initial sorting model based on the first reward value, thus forming a closed loop of "state → action → reward". Based on this closed loop, the parameters of the initial sorting model are continuously updated until the first reward value converges, and the initial sorting model at the time of convergence of the first reward value is used as the target sorting model.
[0057] When electronic devices use the target ranking model for reasoning, they input the real-time status of each dimension in the first set and the target orders into the target ranking model so that the target ranking model can quickly output the optimal production order without needing to iterate again.
[0058] In this scheme, the electronic device simulates production by sequentially inputting samples into a virtual environment. Based on the results of the simulated production and the first multi-objective reward rule, it determines the first reward value, thereby improving the accuracy of the first reward value. Then, it uses the accurate first reward value to drive the iterative optimization of the initial sorting model, thereby improving the accuracy of the target sorting model.
[0059] In the process of training the target ranking model described above, the electronic device determines the first reward value based on the simulated production results and the first multi-objective reward rule. The first multi-objective reward rule is the key to multi-objective optimization. The construction of the first multi-objective reward rule will be explained in detail below.
[0060] Optionally, before training the initial ranking model based on the first action space and the first multi-objective reward rule to obtain the target ranking model, the electronic device also inputs the sample order output by the initial ranking model into the sample virtual environment for simulated production to obtain a first value, a second value, and a third value. The first value is negatively correlated with the total completion time of the sample order, the second value is positively correlated with the on-time rate of the sample order, and the third value is positively correlated with the workstation utilization rate of the sample order. Afterwards, the electronic device constructs the first multi-objective reward rule based on the first value, the second value, and the third value.
[0061] In this embodiment, a first multi-objective reward rule is used to guide the training of the target ranking model so that the production order output by the target ranking model can take into account multiple objectives. Multiple objectives, also known as multiple optimization objectives, include, but are not limited to, total completion time, workstation utilization rate, and order on-time rate. The first multi-objective reward rule balances multiple objectives at the order level, aiming to ensure that the target ranking model outputs a production order that balances global delivery efficiency and resource utilization.
[0062] In constructing the first multi-objective reward rule, for each sample order, the electronic device inputs the sample status of each dimension belonging to the first set from multiple dimensions of the sample order and sample production line into the initial sorting model to obtain the sample order. Then, the electronic device submits this sample order to a sample virtual environment to simulate production, thereby obtaining the first, second, and third values. For example, the simulated production results include total completion time, order on-time rate, and workstation utilization rate. The electronic device assigns weights to each optimization objective and performs a weighted sum of the first, second, and third values based on these weights to construct the first multi-objective reward rule. Optionally, the electronic device can adjust the weights of each optimization objective as needed.
[0063] This approach involves inputting samples sequentially into a virtual environment to simulate production and obtain first, second, and third values. Then, based on these first, second, and third values, a first multi-objective reward rule is constructed. This allows the production sequence output by the trained target ranking model to take into account multiple optimization objectives, thereby improving the accuracy of flexible production line scheduling.
[0064] Figure 4A yes Figure 3 A schematic diagram illustrating the training process of the target ranking model. Please refer to... Figure 4A The first action space contains multiple sample sorting strategies, such as SPT, WINQ, MS, and CR. The optimization objective of SPT is to minimize the average process time; the optimization objective of WINQ is to balance the waiting time of each process; the optimization objective of MS is to reduce equipment idle time and improve workstation utilization; and the optimization objective of CR is to reduce the risk of order delays and improve on-time delivery rate.
[0065] Please refer to Figure 4A The construction of the first multi-objective reward rule needs to consider total completed working hours, average equipment utilization rate, and on-time order ratio. The sample status of each dimension in the first set includes the number of jobs in the system, the number of jobs in the queue, the global completion rate, the available time of each machine, the statistical characteristics of the processing time of all remaining jobs, the statistical characteristics of the processing time of local queue jobs, and the statistical characteristics of the due date. Among these, the statistical characteristics of the processing time of all remaining jobs include the mean and standard deviation; the statistical characteristics of the processing time of local queue jobs include the sum, mean, and minimum; and the statistical characteristics of the due date include the mean, minimum, and delay rate. Electronic devices interact with the sample virtual environment to obtain the sample status of each dimension in the first set.
[0066] Secondly, the training process of the target routing model.
[0067] Optionally, during the training of the target routing model, for each sample order in the sample set, the electronic device inputs the sample order's sample order order and the sample status of each dimension belonging to the second set in multiple dimensions of the sample production line into the initial routing model. Then, the electronic device trains the initial routing model according to the second action space and the second multi-objective reward rule to obtain the target routing model. The second action space includes multiple workstation allocation methods.
[0068] In this embodiment, the electronic device interacts with the virtual sample environment in real time to obtain the sample status of each dimension belonging to the second set in multiple dimensions of the sample production line. For example, the real-time status of each workstation and the processing time required for the current product. Then, the electronic device selects a workstation allocation method from the second action space, and the initial routing model outputs and executes a sample allocation scheme based on the selected method. Each time the initial routing model outputs a sample allocation scheme, the electronic device determines a second reward value according to the second multi-objective reward rule and updates the network parameters of the initial routing model based on the second reward value. This process, through a closed loop of "status → action → reward," continuously updates the parameters of the initial routing model, repeating the above process until the second reward value converges.
[0069] This approach uses a closed-loop optimization training of the initial routing model through "state → action → reward" to continuously converge the sample allocation scheme output by the initial routing model to multiple objectives, thereby obtaining the target routing model and achieving the goal of adapting to multi-objective optimization.
[0070] During the training of the target routing model described above, the electronic device determines the second reward value according to the second multi-objective reward rule. The second multi-objective reward rule is crucial for multi-objective optimization. The construction of the second multi-objective reward rule will be explained in detail below.
[0071] Optionally, before training the initial routing model based on the second action space and the second multi-objective reward rule to obtain the target routing model, the electronic device also inputs the sample allocation scheme output by the initial routing model into the sample virtual environment to simulate production, thereby obtaining a fourth, fifth, and sixth value. The fourth value is positively correlated with the workstation utilization rate of the sample order, the fifth value is negatively correlated with the processing time of the sample order, and the sixth value is positively correlated with the on-time rate of the sample order. Afterwards, the electronic device constructs the second multi-objective reward rule based on the fourth, fifth, and sixth values.
[0072] In this embodiment, the second multi-objective reward rule guides the training of the target routing model, enabling the workstation allocation scheme output by the target routing model to consider multiple objectives. These multiple objectives, also known as multiple optimization goals, include, but are not limited to, total completion time, workstation utilization rate, and order on-time rate. The second multi-objective reward rule balances these multiple optimization goals at the micro-process-workstation level, aiming to ensure that the workstation allocation scheme output by the target routing model guarantees process execution efficiency while also considering total completion time and order on-time rate.
[0073] In constructing the second multi-objective reward rule, for each sample order, after the initial routing model outputs a sample allocation scheme each time, the electronic device submits this scheme to the sample virtual environment to simulate production, thereby obtaining the fourth, fifth, and sixth values. For example, the simulation results include the workstation utilization rate, processing time, and on-time rate of the sample order. The electronic device assigns weights to the workstation utilization rate, processing time, and on-time rate of the sample order, and then performs a weighted sum of the fourth, fifth, and sixth values based on these weights to construct the second multi-objective reward rule. Optionally, the electronic device can adjust the weights of each optimization objective as needed.
[0074] This approach involves inputting the sample allocation scheme into a virtual sample environment to simulate production and obtain the fourth, fifth, and sixth values. Then, based on the fourth, fifth, and sixth values, a second multi-objective reward rule is constructed, enabling the workstation allocation scheme output by the trained target routing model to take into account multiple optimization objectives and achieve the goal of improving the scheduling accuracy of flexible production lines.
[0075] Figure 4B yes Figure 3 A schematic diagram illustrating the training process of the target routing model. Please refer to... Figure 4BThe workstation allocation methods in the second action space include allocation to machine 1, machine 2, machine 3, and allocation methods combining probability output and machine masks. The construction of the second multi-objective reward rule needs to consider total completion time, average equipment utilization, and order on-time ratio. The sample states for each dimension in the second set include the current process type, the processing time required for the current process, the arrival time and relaxation time of the next process, and the status information of individual machines. The status information of an individual machine includes queue length and available time, and the current process type can be combined with available workstation masks. Electronic devices interact with the sample virtual environment to obtain the sample states for each dimension in the second set.
[0076] Optionally, in the above embodiments, during the process of constructing the virtual factory environment of the target production line by the electronic device, firstly, the electronic device obtains a list of elements of the target production line. The list of elements includes at least the type and number of workstations of the target production line and the processes adapted to the workstations. Then, the electronic device inputs the list of elements into a simulation platform to output a basic virtual factory model, and configures the basic virtual factory model according to the multiple dimensions to construct the virtual factory environment of the target production line.
[0077] For example, the electronic device acquires key information such as the type and number of workstations in the target production line, the process-workstation adaptation relationship, and the sequence of process dependencies to obtain a list of production elements. Then, using this list of production elements, the electronic device builds the basic framework of a virtual factory environment based on simulation platforms such as Salabim, resulting in a configurable virtual factory basic model. Next, the electronic device configures multiple dimensions of real-valued states for the virtual factory basic model to construct the virtual factory environment of the target production line. These multiple dimensions include the first and second dimensions mentioned above.
[0078] This approach, through a virtual factory environment built on simulation platforms such as Salabim, can accurately map the resources and constraints of the real target production line. It can digitally simulate the production process and provide real-time status feedback, offering a reliable simulation environment for determining the production sequence and workstation allocation scheme, thus achieving the goal of accurately scheduling flexible production lines.
[0079] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.
[0080] Figure 5 This is a schematic diagram of a scheduling device for a flexible production line provided in an embodiment of this application. The scheduling device 500 for a flexible production line includes: a construction module 51, a sorting module 52, an allocation module 53, and a processing module 54.
[0081] The construction module 51 is used to construct a virtual factory environment for the target production line. The virtual factory environment is used to indicate the real-time status of the target production line in multiple dimensions. The target production line is a flexible production line. The sorting module 52 is used to determine the production order of each product in the target order based on the real-time status of each dimension in the first set, wherein each dimension in the first set belongs to the multiple dimensions, and the production order is used to balance multiple scheduling targets from the order level. The allocation module 53 is used to allocate workstations to each process of each product in the production sequence according to the real-time status of each dimension in the production sequence and the second set, so as to obtain a workstation allocation scheme. The workstation allocation scheme is used to coordinate and balance multiple scheduling objectives at the workstation level. The multiple scheduling objectives correspond to different optimization directions of the flexible production line, and each dimension in the second set belongs to the multiple dimensions. The processing module 54 is used to schedule the target production line according to the production sequence and the workstation allocation scheme to complete the target order.
[0082] In one feasible implementation, the construction module 51 is further used to build a sample virtual environment for the sample production line. The sample virtual environment is used to indicate the real-time status of the sample production line in multiple dimensions. The sample production line is a flexible production line. The processing module 54 is further configured to, for each sample order in the sample set, input the sample status of the sample order and the sample production line in each dimension belonging to the first set into the initial sorting model; train the initial sorting model according to the first action space and the first multi-objective reward rule to obtain the target sorting model, wherein the first action space contains multiple sample sorting strategies; The sorting module 52 is used to input the real-time status of each dimension in the first set and the target order into the target sorting model so that the target sorting model outputs the production order.
[0083] In one feasible implementation, during the process of training the initial ranking model according to the first action space and the first multi-objective reward rule to obtain the target ranking model, the processing module 54 uses the initial ranking model to select a sample ranking strategy from the first action space, so that the initial ranking model outputs a sample order according to the sample ranking strategy; the sample order is input into the sample virtual environment to simulate production; a first reward value is determined according to the result of the simulated production and the first multi-objective reward rule, the first reward value is used to indicate the rationality of the sample order; the parameters of the initial ranking model are updated according to the first reward value until the first reward value converges to obtain the target ranking model.
[0084] In one feasible implementation, before training the initial sorting model according to the first action space and the first multi-objective reward rule to obtain the target sorting model, the processing module 54 is further configured to input the sample sequence output by the initial sorting model into the sample virtual environment for simulated production to obtain a first value, a second value, and a third value. The first value is negatively correlated with the total completion time of the sample order, the second value is positively correlated with the on-time rate of the sample order, and the third value is positively correlated with the workstation utilization rate of the sample order. The first multi-objective reward rule is constructed based on the first value, the second value, and the third value.
[0085] In one feasible implementation, the processing module 54 is further configured to, for each sample order in the sample set, input the sample order order and the sample status of each dimension belonging to the second set in the multiple dimensions of the sample production line into the initial routing model; train the initial routing model according to the second action space and the second multi-objective reward rule to obtain the target routing model, wherein the second action space includes multiple workstation allocation methods; The allocation module 53 is used to input the real-time status of each dimension in the second set and the production sequence into the target routing model, so that the target routing model outputs the workstation allocation scheme.
[0086] In one feasible implementation, before training the initial routing model according to the second action space and the second multi-objective reward rule to obtain the target routing model, the processing module 54 is further configured to input the sample allocation scheme output by the initial routing model into the sample virtual environment for simulated production to obtain a fourth value, a fifth value, and a sixth value. The fourth value is positively correlated with the workstation utilization rate of the sample order, the fifth value is negatively correlated with the processing time of the sample order, and the sixth value is positively correlated with the on-time rate of the sample order. The second multi-objective reward rule is constructed based on the fourth value, the fifth value, and the sixth value.
[0087] In one feasible implementation, the construction module 51 is used to obtain a list of elements of the target production line, the list of elements including at least the type and number of workstations of the target production line and the process adapted to the workstations; input the list of elements into a simulation platform to output a virtual factory basic model; configure the virtual factory basic model according to the multiple dimensions to construct a virtual factory environment for the target production line.
[0088] In one feasible implementation, the target production line is used to produce blades of different models, and the target order includes at least two models of blades.
[0089] The scheduling device for flexible production lines provided in this application embodiment can execute the actions of the electronic devices in the above embodiments. Its implementation principle and technical effect are similar, and will not be described again here.
[0090] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device 600 includes: Processor 61 and memory 62; The memory 62 stores computer instructions and test data; The processor 61 executes the computer instructions stored in the memory 62, causing the processor 61 to perform the scheduling method for flexible production lines as described above.
[0091] The specific implementation process of processor 61 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.
[0092] Optionally, the electronic device 600 also includes a communication component 63. The processor 61, memory 62, and communication component 63 can be connected via a bus 64.
[0093] This application also provides a computer-readable storage medium storing computer instructions, which, when executed by a processor, are used to implement the scheduling method for flexible production lines as described above.
[0094] This application also provides a computer program product, which includes a computer program that, when executed by a processor, implements the scheduling method for flexible production lines as described above.
[0095] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the application disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and embodiments are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.
[0096] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.
Claims
1. A scheduling method for flexible production lines, characterized in that, include: Construct a virtual factory environment for the target production line, wherein the virtual factory environment is used to indicate the real-time status of the target production line in multiple dimensions, and the target production line is a flexible production line; Based on the real-time status of each dimension in the first set, the production order of each product in the target order is determined. Each dimension in the first set belongs to the multiple dimensions. The production order is used to balance multiple scheduling objectives from the order level. Based on the real-time status of each dimension in the production sequence and the second set, workstations are assigned to each process of each product in the production sequence to obtain a workstation allocation scheme. The workstation allocation scheme is used to coordinate and balance multiple scheduling objectives at the workstation level. The multiple scheduling objectives correspond to different optimization directions of the flexible production line, and each dimension in the second set belongs to the multiple dimensions. The target production line is scheduled according to the production sequence and the workstation allocation scheme to complete the target order.
2. The method according to claim 1, characterized in that, Determining the production sequence of each product in the target order based on the real-time status of each dimension in the first set includes: A virtual environment for a sample production line is constructed. The virtual environment is used to indicate the real-time status of the sample production line in multiple dimensions. The sample production line is a flexible production line. For each sample order in the sample set, the sample status of each dimension belonging to the first set in the multiple dimensions of the sample production line is input into the initial sorting model; The initial ranking model is trained according to the first action space and the first multi-objective reward rule to obtain the target ranking model. The first action space contains multiple sample ranking strategies. The real-time status of each dimension in the first set and the target order are input into the target sorting model so that the target sorting model outputs the production order.
3. The method according to claim 2, characterized in that, The step of training the initial ranking model according to the first action space and the first multi-objective reward rule to obtain the target ranking model includes: The initial sorting model is used to select a sample sorting strategy from the first action space, so that the initial sorting model outputs the sample order according to the sample sorting strategy; The samples are sequentially input into the sample virtual environment to simulate production; A first reward value is determined based on the results of the simulated production and the first multi-objective reward rule. The first reward value is used to indicate the rationality of the sample order. The parameters of the initial ranking model are updated based on the first reward value until the first reward value converges to obtain the target ranking model.
4. The method according to claim 2, characterized in that, Before training the initial ranking model according to the first action space and the first multi-objective reward rule to obtain the target ranking model, the method further includes: The sample sequence output by the initial sorting model is input into the sample virtual environment to simulate production, so as to obtain a first value, a second value and a third value. The first value is negatively correlated with the total completion time of the sample order, the second value is positively correlated with the on-time rate of the sample order, and the third value is positively correlated with the workstation utilization rate of the sample order. The first multi-objective reward rule is constructed based on the first value, the second value, and the third value.
5. The method according to claim 2, characterized in that, The step of allocating workstations for each process of each product in the production sequence based on the real-time status of each dimension in the production sequence and the second set, to obtain a workstation allocation scheme, includes: For each sample order in the sample set, the sample order of the sample order and the sample status of each dimension of the sample production line belonging to the second set are input into the initial routing model. The initial routing model is trained according to the second action space and the second multi-objective reward rule to obtain the target routing model. The second action space includes multiple workstation allocation methods. The real-time status of each dimension in the second set and the production sequence are input into the target routing model so that the target routing model outputs the workstation allocation scheme.
6. The method according to claim 5, characterized in that, Before training the initial routing model according to the second action space and the second multi-objective reward rule to obtain the target routing model, the method further includes: The sample allocation scheme output by the initial routing model is input into the sample virtual environment to simulate production, so as to obtain the fourth, fifth and sixth values. The fourth value is positively correlated with the workstation utilization rate of the sample order, the fifth value is negatively correlated with the processing time of the sample order, and the sixth value is positively correlated with the on-time rate of the sample order. The second multi-objective reward rule is constructed based on the fourth value, the fifth value, and the sixth value.
7. The method according to any one of claims 1 to 6, characterized in that, The virtual factory environment for constructing the target production line includes: Obtain a list of elements for the target production line, the list of elements including at least the type and number of workstations in the target production line and the processes that are compatible with the workstations; Input the aforementioned list of elements into the simulation platform to output a basic model of the virtual factory; The virtual factory base model is configured according to the multiple dimensions to construct the virtual factory environment of the target production line.
8. The method according to any one of claims 1 to 6, characterized in that, The target production line is used to produce different types of blades, and the target order includes at least two types of blades.
9. An electronic device comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it causes the electronic device to implement the method as described in any one of claims 1 to 8.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1 to 8.