Production line personnel balancing method based on genetic algorithm, medium and terminal
By optimizing the personnel allocation of shipyard production lines using a genetic algorithm, the imbalance caused by different supply cycles of production lines within the shipyard was resolved, achieving balanced production and efficient execution of plans.
Patent Information
- Application Number
- CN202510951669.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-10
- Publication Date
- 2025-10-28
AI Technical Summary
In the phased construction of ships, the different supply cycles of different types of production lines in the shipyard lead to an imbalance in personnel allocation, which affects the balance of production and the achievement rate of plans.
A genetic algorithm-based approach is adopted to optimize personnel attendance by sorting out basic production line information, establishing an objective function, encoding adjustment values as chromosome genes, and performing genetic operations to achieve the global optimal solution.
Without affecting product delivery time, optimize production line layout to ensure a balanced number of workers per day, solve worker turnover issues, and improve production efficiency and plan achievement rate.
Smart Images

Figure CN120851473A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of production management, and in particular to a method, medium, and terminal for balancing production line personnel based on genetic algorithms. Background Technology
[0002] Lean manufacturing is now widely implemented in the shipbuilding industry, striving for segmented, rhythmic construction of ship sections and balanced output to achieve on-time delivery. During the planning process for segmented, rhythmic ship construction, multiple production lines for different types of products are formed based on group technology.
[0003] However, the shipyard has a complex section structure and a variety of production lines with different rhythms. Different types of production lines have different delivery cycles and different staffing levels. When multiple production lines are assigned to one workshop, the daily workload of the staff will inevitably fluctuate greatly, affecting the balance of production and the actual achievement rate of the plan. Summary of the Invention
[0004] In view of the shortcomings of the above-mentioned related technologies, the purpose of this invention is to provide a production line personnel balancing method, medium and terminal based on genetic algorithm to solve the problem of balancing personnel load in the workshop.
[0005] To achieve the above and other related objectives, this invention provides a production line personnel balancing method based on a genetic algorithm. The specific steps include: sorting out basic information related to the production line and the allowable adjustment range of the production line; establishing an objective function based on the sorting results; encoding the adjustment value of the production line as chromosome genes based on the allowable adjustment range of the production line; randomly initializing the population size; calculating the fitness of each individual and selecting superior genes; performing genetic operations on the selected individuals and selecting the optimal solution in the current population; repeating the first two steps until the maximum number of iterations, comparing the optimal solutions of each generation of the population, and selecting the globally optimal solution; applying the globally optimal solution to the actual production line layout in the workshop to obtain a balanced personnel attendance arrangement.
[0006] Optionally, sorting out basic information related to the production line includes sorting out the number of production lines and analyzing the supply relationship between each production line and its respective upstream and downstream processes.
[0007] Optionally, the objective function is expressed as: Where lt represents the total number of days required for the workshop to complete all production lines; t represents the first day of production line operation; i represents the production line; Pi represents the number of employees on production line i on a given day; Δi represents the number of days production line i is delayed in starting; t-Δi represents the date corresponding to production line i after shifting Δi days on day t; and μ represents the average number of employees on the production line workshop per day.
[0008] Optionally, the step of encoding the adjustment value of the production line into a chromosome gene is as follows: the chromosome contains the same number of loci as the production lines, each locus corresponds to an adjustment interval, each chromosome traverses all production lines, and randomly assigns an integer value within the allowed range to each locus.
[0009] Optionally, after the chromosomes are generated, each chromosome is tested to check whether it violates the constraints, and if so, it is discarded and regenerated.
[0010] Optionally, the step of calculating the fitness of each individual and selecting superior genes is as follows: using the objective function as the fitness function, calculating the fitness of each individual as the selection criterion, and using a roulette wheel strategy to select individuals.
[0011] Optionally, the genetic operations include crossover and mutation.
[0012] Optionally, the step of performing genetic operations on the selected individuals and selecting the optimal solution in the current population is as follows: by using an elite retention strategy, a small portion or a single individual with the highest fitness is directly retained to the next generation without performing genetic operations, and the remaining positions are filled by breeding other individuals in the current population.
[0013] A storage medium storing a computer program that, when executed by a processor, implements the production line personnel balancing method based on a genetic algorithm as described above.
[0014] A terminal includes a processor and a memory; the memory is used to store a computer program; the processor is connected to the memory and is used to execute the computer program stored in the memory, so that the terminal performs the production line personnel balancing method based on genetic algorithm as described above.
[0015] As described above, the production line personnel balancing method based on genetic algorithm of the present invention has the following beneficial effects: The method of the present invention optimizes the layout of the production line in the shipyard workshop without affecting the product delivery date, so that the number of workers on duty each day is as balanced as possible, solves the workshop shutdown caused by worker turnover problem, makes production more balanced, improves production efficiency, and significantly improves the plan achievement rate. Attached Figure Description
[0016] Figure 1 The diagram shows a flowchart of the production line personnel balancing method based on genetic algorithms in an embodiment of the present invention. Detailed Implementation
[0017] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention.
[0018] In the detailed description of embodiments of the present invention, for ease of explanation, the cross-sectional views illustrating the device structure may be partially enlarged and not to scale. Furthermore, the schematic diagrams are merely examples and should not limit the scope of protection of the present invention. In actual fabrication, the three-dimensional spatial dimensions of length, width, and depth should be included.
[0019] For ease of description, spatial relation terms such as “below,” “under,” “lower than,” “below,” “above,” and “upper” may be used herein to describe the relationship between one element or feature shown in the accompanying drawings and other elements or features. It will be understood that these spatial relation terms are intended to include directions other than those depicted in the drawings for the device in use or operation. Furthermore, when a layer is referred to as being “between” two layers, it can be the only layer between the two layers, or there may be one or more layers in between. The phrase “between” as used herein includes both endpoint values.
[0020] In the context of this application, the structure described above the first feature may include embodiments in which the first and second features are formed in direct contact, or embodiments in which additional features are formed between the first and second features, such that the first and second features may not be in direct contact.
[0021] It should be noted that the illustrations provided in this embodiment are only schematic representations of the basic concept of the present invention. Therefore, the illustrations only show the components related to the present invention and are not drawn according to the actual number, shape and size of the components in the actual implementation. In the actual implementation, the form, quantity and proportion of each component can be arbitrarily changed, and the layout of the components may also be more complex.
[0022] like Figure 1 As shown, this embodiment provides a production line personnel balancing method based on a genetic algorithm, the specific steps of which include:
[0023] Organize basic information related to the production line and the allowable adjustment range of the production line.
[0024] Specifically, the number of workers required for a production line, or workshop, varies depending on the product structure.
[0025] The basic information related to the production line includes the number of production lines and the number of personnel involved in each production line. In this embodiment, the total number of personnel involved in the production line and the number of workers scheduled for each day are considered to be known.
[0026] The allowable adjustment range of a production line is determined by the fact that the start-up time of each production line is affected by the preceding process and the completion time of each production line is affected by the following process. Therefore, by analyzing the supply relationship between each production line and its preceding and following processes, the production time range of each production line can be determined. The allowable adjustment range of a production line refers to the time range within which the production line can delay its start-up after the preceding process is completed. The allowable adjustment range is included in the production time range. For example, if the allowable adjustment range of a production line is [0, 5], it means that the production line can start up as early as after the preceding process is completed and start up as late as 5 days after the earliest start-up point.
[0027] Based on the analysis results, an objective function was established to address the relationship between production line adjustments and personnel balance.
[0028] Based on the relationship between production line adjustment and personnel balance, the objective function is expressed as: Where lt represents the total number of days required for the workshop to complete all production lines; t represents the first day of production line operation; i represents the production line; Pi represents the number of employees on production line i on a certain day, which is considered known, i.e., it was designed in the production line design; Δi represents the number of days production line i is delayed in starting; t-Δi represents the date corresponding to production line i after shifting Δi days on day t; μ represents the average number of employees on the production line workshop per day.
[0029] Based on the principle that production lines should not conflict with upstream and downstream processes, the production cycle of all production lines in the workshop is defined within a fixed range. The sum of the number of personnel on all production lines is a fixed value, so the average daily attendance μ is a constant that does not change due to adjustments in production lines.
[0030] Based on the allowable adjustment range of the production line, the adjustment value of the production line is encoded as a chromosome gene.
[0031] Specifically, each chromosome contains the same number of loci as the production lines in the workshop. Each locus corresponds to an adjustment interval. For each chromosome, all production lines are traversed, and an integer value within the allowed range is randomly assigned to each locus. After chromosomes are generated, each chromosome is checked to see if it violates the constraints. If the production line adjustment exceeds the allowed range, it is discarded and regenerated. The constructed chromosome is: Ch = {Δ1, Δ2, Δ3, Δ4...Δ...} iFor example, if there are three production lines in a workshop, and the allowable adjustment ranges for each production line are [0, 5], [0, 4], and [0, 8] respectively, then a certain chromosome can be represented as {2, 3, 7}, which means: the first production line is delayed by 2 days from its earliest start point, the second production line is delayed by 3 days from its earliest start point, and the third production line is delayed by 7 days from its earliest start point.
[0032] Randomly initialize the population size.
[0033] Calculate the fitness of each individual and select superior genes.
[0034] Specifically, the objective function in this embodiment is to find the minimum standard deviation in the population, which can be directly used as the fitness function. The fitness of each individual is calculated as the selection criterion, and a roulette wheel selection strategy is used to select individuals. The probability of an individual being selected is expressed as:
[0035] Where f represents fitness, a represents an individual, and m represents the number of chromosomes in the population. When the roulette wheel is spun, the pointer will randomly point to an area. Obviously, individuals with higher fitness scores have a greater probability of being selected.
[0036] For example, if a population has 3 chromosomes with corresponding fitness values of 1, 3, and 5, then the cumulative total fitness is expressed as: The probabilities of each individual being selected are as follows: Clearly, chromosome 3 has the highest probability of being selected.
[0037] Crossover and mutation operations are performed on the selected chromosomes.
[0038] In this context, crossover refers to the process by which each offspring is produced from both parents. The offspring inherits DNA from both parents, with the mating point randomly generated (any location on the chromosome). Through crossover, the offspring chromosomes acquire characteristics from both parents. The offspring may also mutate, resulting in DNA that originates neither from the father nor the mother, but rather from a random mutation at a specific location. This mutation may lead to a shift beyond the defined domain, requiring modification of the mutated chromosome to conform to the domain constraints. It is important to note that setting an appropriate mutation probability and performing mutations at random sites in the offspring's genes prevents premature convergence and getting trapped in local optima.
[0039] The elite retention strategy directly preserves a small subset or a single individual with the highest fitness to the next generation without performing genetic operations (crossover and mutation). The remaining positions are filled by breeding other individuals in the current population (including selection, crossover, and mutation). The first two steps are repeated until the maximum number of iterations is reached. At the maximum iteration count, the global optimum is determined through comparison.
[0040] The global optimal solution, which is the adjustment value for each production line, is converted into the actual start and finish points of the production line. This is used to schedule the production line plan in the workshop. The workshop arranges personnel according to this plan, which can make the daily attendance of personnel on the production line most balanced.
[0041] This embodiment also discloses a storage medium storing a computer program, which, when executed by a processor, implements the production line personnel balancing method based on a genetic algorithm as described above.
[0042] This embodiment also discloses a terminal, which includes a processor and a memory; the memory is used to store computer programs; the processor is connected to the memory and is used to execute the computer programs stored in the memory, so that the terminal executes the production line personnel balancing method based on genetic algorithms as described above.
[0043] The above embodiments are merely illustrative of the principles and effects of the present invention and are not intended to limit the invention. Any person skilled in the art can modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by those skilled in the art without departing from the spirit and technical concept disclosed in the present invention should still be covered by the claims of the present invention.
Claims
1. A production line personnel balancing method based on genetic algorithms, characterized in that, The specific steps include: Organize basic information related to the production line and the allowable adjustment range for the production line; Establish an objective function based on the analysis results; Based on the allowable adjustment range of the production line, the adjustment value of the production line is encoded as a chromosome gene; Randomly initialize the population size; Calculate the fitness of each individual and select superior genes; Perform genetic operations on the selected individuals and select the optimal solution in the current population; Repeat the first two steps until the maximum number of iterations is reached. Compare the optimal solutions of each generation of the population and select the global optimal solution. The global optimal solution is applied to the actual production line layout in the workshop to obtain a balanced personnel attendance arrangement.
2. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: Organizing basic information related to the production line includes identifying the number of production lines and the number of personnel involved in each production line.
3. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: The objective function is expressed as: Where lt represents the total number of days required for the workshop to complete all production lines; t represents the first day of production line operation; i represents the production line; Pi represents the number of employees on production line i on a given day; Δi represents the number of days production line i is delayed in starting; t-Δi represents the date corresponding to production line i after shifting Δi days on day t; and μ represents the average number of employees on the production line workshop per day.
4. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: The step of encoding the adjustment value of the production line into a chromosome gene is as follows: the chromosome contains the same number of loci as the production lines, each locus corresponds to an adjustment interval, each chromosome traverses all production lines, and randomly assigns an integer value within the allowed range to each locus.
5. The production line personnel balancing method based on genetic algorithm according to claim 4, characterized in that: After the chromosomes are generated, each chromosome is tested to check if it violates the constraints. If so, it is discarded and a new chromosome is generated.
6. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: The steps for calculating the fitness of each individual and selecting superior genes are as follows: using the objective function as the fitness function, calculating the fitness of each individual as the selection criterion, and using a roulette wheel strategy to select individuals.
7. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: The genetic operations include crossover and mutation.
8. The production line personnel balancing method based on genetic algorithm according to claim 1, characterized in that: The steps of performing genetic operations on the selected individuals and selecting the optimal solution in the current population are as follows: using an elite retention strategy, a small portion or a single individual with the highest fitness is directly retained to the next generation without performing genetic operations, and the remaining positions are filled by breeding other individuals in the current population.
9. A storage medium, characterized in that: The storage medium stores a computer program, which, when executed by a processor, implements the production line personnel balancing method based on genetic algorithms as described in any one of claims 1 to 8.
10. A terminal, characterized in that: The terminal includes a processor and a memory; the memory is used to store computer programs; the processor is connected to the memory and is used to execute the computer programs stored in the memory, so that the terminal executes the production line personnel balancing method based on genetic algorithms as described in any one of claims 1 to 8.