Intelligent production scheduling method and system for spinning workshop based on deep reinforcement learning

By constructing a heterogeneous order machine graph and a Critic network with a multi-head decoupled structure, the problems of state perception and multi-objective optimization in the production scheduling method of the spinning workshop were solved, thereby improving the operational efficiency of the workshop.

CN123180650APending Publication Date: 2026-11-27HENAN DAYANG YARN CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611568878.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-12
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing production scheduling methods in spinning workshops are unable to effectively perceive the heterogeneous state of the workshops, decouple and coordinate the optimization of multiple scheduling objectives, resulting in delayed response, low scheduling efficiency and insufficient resource utilization.

Method used

A heterogeneous graph of order machines is constructed, features are extracted using graph neural networks, and an adjustment tensor is generated by combining dynamic weight coefficients and a broadcast mechanism. Sub-value components are output in parallel through a Critic network with a multi-head decoupled structure, and a production scheduling scheme is generated by combining an Actor network.

Benefits of technology

It improved the stability and efficiency of production scheduling in the spinning workshop, increased equipment utilization, reduced process changeover costs, and generated a more reasonable production scheduling plan.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123180650A_ABST
    Figure CN123180650A_ABST
Patent Text Reader

Abstract

The application provides a kind of spinning workshop intelligent production scheduling method and system based on deep reinforcement learning, including collecting spinning workshop real-time order, machine data to build order-machine heterogeneous graph, input graph neural network;According to the calculation of dynamic weight coefficient of node characteristics, generate dimension-adapted adjustment tensor through broadcast mechanism, modulate message aggregation to obtain node embedding;Embedding is sent into multi-head decoupling Critic network, and three types of sub-values of parallel output completion time, equipment utilization, process switching cost are fused into state evaluation value based on dynamic weight coefficient;The subsequent state is deduced and evaluated by the candidate action of Actor network;Combine the value expectation of subsequent state and immediate reward to construct time difference target, update Critic with difference error;Based on the strategy gradient of time difference error or advantage function to update Actor, the gradient step is positively adjusted according to the cosine similarity of sub-value gradient, and is inversely adjusted according to the non-dimensional variance of subsequent state evaluation value;Output spinning production scheduling scheme.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of intelligent scheduling, and in particular relates to an intelligent scheduling method and system for spinning workshops based on deep reinforcement learning. Background Technology

[0002] In the daily production process of a spinning workshop, production scheduling needs to rationally allocate production resources based on continuously changing real-time orders and machine operating status. Because spinning production combines discrete scheduling with continuous processing characteristics, order types are diverse, delivery deadlines vary significantly, and machine types, processing capacities, and real-time operating statuses are also complex, forming a typical heterogeneous relationship between orders and machines. Traditional workshop scheduling methods typically rely on manual experience or static rule-based heuristic algorithms, making it difficult to fully exploit the heterogeneous data characteristics between orders, equipment, and processes within the workshop. When faced with dynamic disturbances such as urgent order insertions or equipment failures, problems such as delayed response, low scheduling efficiency, and insufficient resource utilization easily arise.

[0003] Production scheduling in spinning workshops is not a single-objective optimization process, but rather requires simultaneously considering multiple interdependent production objectives, such as shortening overall completion time, improving equipment utilization, and reducing process changeover costs caused by frequent changes in product types. While intelligent scheduling methods based on deep reinforcement learning possess autonomous learning and dynamic decision-making capabilities, conventional network models often lack adaptive adjustment mechanisms oriented towards state characteristics when dealing with the heterogeneous relationship between orders and machines. This makes it difficult to identify key influencing factors under different production states, resulting in inaccurate state representations. Furthermore, when faced with conflicting optimization objectives such as completion time, equipment utilization, and process changeover costs, value evaluation networks often employ a single-dimensional comprehensive evaluation, failing to decouple and measure various production indicators. This can easily obscure the impact of different scheduling actions on specific objectives and lead to gradient conflicts and training oscillations during strategy optimization. In addition, the lack of an effective adjustment mechanism in the strategy update process can also lead to model convergence difficulties or getting trapped in local optima, making it difficult to consistently output high-quality scheduling solutions. Therefore, how to construct a stable scheduling method that can both perceive the heterogeneous state of the workshop and decouple and collaboratively optimize multiple scheduling objectives has become a pressing technical problem to be solved in the field of intelligent manufacturing in spinning. Summary of the Invention

[0004] This invention proposes an intelligent scheduling method for spinning workshops based on deep reinforcement learning, addressing the problem that existing technologies cannot construct a stable scheduling method that can both perceive the heterogeneous state of the workshop and decouple and collaboratively optimize multiple scheduling objectives. The method includes: Real-time order and machine status data of the spinning workshop are obtained, an order and machine heterogeneity graph is constructed, the order and machine heterogeneity graph is input into a graph neural network, dynamic weight coefficients are calculated through initial node features, the weight coefficients are expanded into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and the message aggregation process of the graph neural network is modulated using the adjustment tensor to generate a node state embedding vector. The node state is embedded into a vector input to a Critic network with a multi-head decoupling structure. Multiple sub-value components corresponding to completion time, equipment utilization, and process switching cost are output in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Multiple subsequent states are inferred based on multiple candidate actions output by the Actor network, and the evaluation value of each subsequent state is calculated. The expected value of each subsequent state's evaluation value is combined with the immediate reward to construct a temporal difference objective. The Critic network with a multi-head decoupled structure is updated by calculating the temporal difference error. Based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent states, the policy gradient is calculated and the Actor network is updated. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation value of each subsequent state. Using the updated Actor network, a spinning production scheduling scheme is generated based on the current state.

[0005] Furthermore, this invention also relates to an intelligent scheduling system for spinning workshops based on deep reinforcement learning, comprising the following modules: The modulation module is used to acquire real-time order and machine status data in the spinning workshop, construct an order and machine heterogeneity graph, input the order and machine heterogeneity graph into a graph neural network, calculate dynamic weight coefficients through initial node features, expand the weight coefficients into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and use the adjustment tensor to modulate the message aggregation process of the graph neural network to generate a node state embedding vector. The calculation module is used to embed the node state into the vector input of the Critic network with a multi-head decoupling structure, and output multiple sub-value components corresponding to completion time, equipment utilization rate and process switching cost in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Based on the multiple candidate actions output by the Actor network, multiple subsequent states are deduced, and the evaluation value of each subsequent state is calculated. The production scheduling module is used to construct a temporal difference objective by combining the expected evaluation values ​​of each subsequent state with the immediate reward. It updates the Critic network with a multi-head decoupled structure by calculating the temporal difference error. Based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent state, it calculates the policy gradient and updates the Actor network. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation values ​​of each subsequent state. Using the updated Actor network, a spinning production scheduling scheme is generated based on the current state.

[0006] This invention constructs a heterogeneous graph of order machines and uses a graph neural network to extract features from orders, machines, and their process constraints. It then combines dynamic weight coefficients and a broadcast mechanism-generated adjustment tensor to adaptively modulate the message aggregation process. By setting up a multi-head decoupled Critic network, it can output and evaluate multiple sub-value components in parallel, such as completion time, equipment utilization, and process changeover cost. It also combines the positive and negative attributes of each indicator with a signed linear combination to generate a comprehensive evaluation value for the current state. During network training, the policy gradient update step size is positively adjusted based on the cosine similarity between the gradients of each sub-value component, and negatively adjusted based on the dimensionless variance of subsequent state evaluation values. This improves the stability and convergence efficiency of the reinforcement learning model parameter updates, enabling the system to generate more reasonable production scheduling schemes for the spinning workshop and improve the overall operational efficiency of the workshop. Attached Figure Description

[0007] Figure 1 This is a flowchart of an intelligent scheduling method for spinning workshops based on deep reinforcement learning. Figure 2 This is a schematic diagram of the connection weight decay curve; Figure 3 This is a schematic diagram illustrating the dynamic weighting coefficient changes. Detailed Implementation

[0008] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0009] In this application, a method for intelligent scheduling in a spinning workshop based on deep reinforcement learning is described, such as... Figure 1 As shown, the method includes: S1. Obtain real-time order and machine status data from the spinning workshop, construct an order and machine heterogeneous graph, input the order and machine heterogeneous graph into a graph neural network, calculate dynamic weight coefficients through initial node features, expand the weight coefficients into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and use the adjustment tensor to modulate the message aggregation process of the graph neural network to generate a node state embedding vector.

[0010] Read real-time data from the Manufacturing Execution System (MES), including order delivery dates, yarn counts, required quantities, and machine status, processing type, and remaining available time. Create a heterogeneous graph, defining two types of nodes: order nodes and machine nodes. The initial feature vector of an order node is concatenated with delivery date, required quantity, and yarn count data; the initial feature vector of a machine node is concatenated with remaining available time and current processing type status identifier data. The current processing type status identifier data uses one-hot encoding or learnable embedding encoding before concatenating with other numerical features. Since the original feature dimensions of order nodes and machine nodes are different, a linear projection layer for order nodes and a linear projection layer for machine nodes are set before inputting into the graph neural network. This maps the original feature vectors of both order nodes and machine nodes to the same preset hidden dimension d, resulting in a unified node feature matrix with consistent dimensions.

[0011] Based on the process parameters required by the order and the processing capacity of the machine, a processing feasibility edge is established between the order node and the machine node. The corresponding process yarn clearing time, batch change preparation time or historical average preparation time is obtained, and this time is uniformly converted into edge connection strength as the edge weight. This avoids directly using the time consumption as the connection strength input. The constructed heterogeneous graph is then input into the graph attention network GAT.

[0012] For each node, unified node features are input into a dual-branch perceptron network to generate dynamic weight coefficients. The dual-branch perceptron network includes a shared fully connected hidden layer, a first output branch, and a second output branch. The first output branch outputs a first intermediate value, and the second output branch outputs a second intermediate value. A first weight coefficient corresponding to the completion time and a second weight coefficient corresponding to the equipment utilization rate are obtained through joint normalization constraints. A third weight coefficient corresponding to the process changeover cost is then obtained by subtracting the first and second weight coefficients from 1. This generates a three-dimensional dynamic weight coefficient vector. The dynamic weight coefficients originate from this weight generation network, not from the Critic network.

[0013] After each node generates its own node-level dynamic weight coefficients, the node-level dynamic weight coefficients of all order nodes and machine nodes are averaged or attention-pooled to obtain state-level dynamic weight coefficients representing the current overall workshop state preference. The node-level dynamic weight coefficients are used for feature modulation during the graph neural network message aggregation process, while the state-level dynamic weight coefficients are used for combining multiple sub-value components in the Critic network. In one specific implementation, the first and second output branches output unconstrained intermediate quantities u1 and u2, respectively. u1, u2, and the fixed reference quantity 0 are then input into the Softmax function to obtain three non-negative normalized weights that sum to 1. The first two terms serve as the first and second weight coefficients, respectively, and the third term serves as the third weight coefficient. This avoids the one-dimensional Softmax output always being 1 and ensures that the third weight coefficient is non-negative.

[0014] To align the dynamic weight coefficients with the hidden layer node feature channels, a learnable mapping matrix from the target semantics to the channel dimension is pre-defined. This maps the node-level 3D dynamic weight coefficients to a channel adjustment vector with the same number of node feature channels, and expands it into an adjustment tensor with the same shape as the node feature matrix through a broadcast mechanism. In each message passing iteration of the graph attention network, when calculating the attention coefficients between adjacent nodes, the adjustment tensor is used to perform a Hadamard product with the feature matrices of neighboring nodes, modulating the features of the neighboring nodes. The modulated neighbor features are then multiplied by the corresponding attention coefficients and summed to output the updated node state embedding vector.

[0015] In some implementations, obtaining real-time order and machine status data in the spinning workshop includes: Connect to the production scheduling system and read the queue of orders to be scheduled. Extract the target yarn count and the remaining time until delivery time for each order as the initial numerical features of the order node. The sensors connected to each machine station collect and calculate the average operating speed and number of downtimes of each machine station within a predetermined time window as the initial numerical characteristics of the machine station nodes. The initial numerical features of the order node and the machine node are normalized using a standardization algorithm. The calculation formula is the difference between the original numerical feature value and the mean, divided by the standard deviation. The normalized features are used as the initial node features.

[0016] The system uses an API interface to call the scheduling module of the Enterprise Resource Planning (ERP) system at a set frequency, such as every five minutes, to read the queue of orders awaiting production in real time. For each order in the queue, its target yarn count (e.g., 30 or 40 count, ranging from 10 to 120 count) and the remaining time until delivery (in hours, e.g., 72 hours) are extracted to form the initial numerical feature vector for the order node. Simultaneously, communication with the programmable logic controllers (PLCs) and sensors of each machine in the workshop is established via industrial Ethernet to continuously collect data, with a predetermined time window set to the past 24 hours. Within this time window, the average spindle speed of each machine (e.g., 15,000 to 25,000 revolutions per minute) and the number of downtimes due to yarn breakage or mechanical failure (e.g., 3 times) are calculated to form the initial numerical feature vector for the machine node.

[0017] The numerical features of order nodes and machine nodes are normalized, and the mean and standard deviation of the current batch samples are calculated for each feature attribute. For example, for the target yarn count, if the mean of the current batch of orders is 45 and the standard deviation is 12, and a certain order has a yarn count of 40, then its normalized feature value is the original value minus 45 and then divided by 12, which is approximately -0.417. After the same processing logic, all the original features of order nodes and machine nodes are uniformly transformed to a standardized numerical scale with a mean of approximately 0 and a standard deviation of approximately 1, and then mapped to the same hidden dimension through the corresponding linear projection layer of the node type to obtain the initial node feature matrix of the input graph neural network.

[0018] In some implementations, constructing the heterogeneous graph of order machines and inputting the heterogeneous graph of order machines into a graph neural network includes: Orders are classified as the first type of nodes to form an order node set, and machines are classified as the second type of nodes to form a machine node set. Given the process constraints when an order is assigned to a specific machine, obtain the corresponding process yarn clearing and batch change preparation time. The preparation time is converted into edge connection weights, and an adjacency matrix representing process constraints is constructed. The preparation time is substituted into an exponential decay function to calculate the edge connection weights. The connection weights are powers of the natural constant and are determined exponentially based on the preparation time and a preset penalty coefficient. The adjacency matrix is ​​used as the topology input of the graph neural network.

[0019] The N orders awaiting production are defined as the first type of nodes in the heterogeneous graph, forming an order node set. The M available machines in the workshop are defined as the second type of nodes, forming a machine node set. When simulating the assignment of orders to specific machines, the sum of the yarn clearing time and batch change preparation time required for matching the two is retrieved from the local process knowledge base. For example, if the machine is currently processing 40-count pure cotton yarn, and the new order requires the production of 60-count blended yarn, the required preparation time, for example, is 4.5 hours due to raw material changes and draft ratio adjustments. If the two processes are similar, the preparation time is, for example, 0.5 hours. If the machine does not have the physical conditions to produce the order, a processing feasibility edge is not established between the order node and the machine node, or the weight of the corresponding edge is set to 0 and masked in the adjacency matrix.

[0020] The preparation time is converted into edge connection weights in the heterogeneous graph, representing the strength of connectivity between nodes under process constraints and switching costs. The weight calculation formula is set to have the natural constant e as the base and the exponent being the negative of the product of a preset penalty coefficient and the preparation time. The penalty coefficient controls the sensitivity of time to the weights, and its unit matches the preparation time unit, making the product of the penalty coefficient and preparation time dimensionless; when the preparation time is in hours, the penalty coefficient is in hours. -1 The preset range is set to, for example, 0.1 to 1.0. For instance, with a penalty coefficient of 0.5, if the preparation time is 0.5 hours, the connectivity weight is approximately 0.7788, indicating high reachability. If the preparation time is 4.5 hours, the connectivity weight drops to 0.1054, indicating higher process changeover resistance. (Connectivity weight decay curve) Figure 2 As shown.

[0021] By traversing all order and machine node pairs and performing this operation, an N×M bipartite relation matrix is ​​constructed to establish the topological association structure between heterogeneous nodes. When inputting into the graph neural network, this N×M bipartite relation matrix is ​​equivalently converted into a set of edge indices and edge weights containing order nodes and machine nodes, or expanded into a (N+M)×(N+M) block adjacency matrix to ensure that the graph topology data and the unified node feature matrix correspond consistently in the dimension of the number of nodes. The graph neural network structure sequentially includes a graph structure input layer that receives graph connectivity relations and node feature matrices, a graph attention hidden layer that performs aggregation operations on the edge connection strength and attention coefficients of adjacent node information, and a feature embedding output layer that outputs a high-dimensional state representation.

[0022] The input to the graph neural network consists of a unified node feature matrix, normalized and aligned by linear projection in the preceding steps, and a set of edge indices and edge weights formed by converting connection weights from the process changeover preparation time, or a block adjacency matrix corresponding to the number of nodes in the unified node feature matrix. After the node features, edge connection weights, and attention coefficients are aggregated and calculated along the topology graph within the graph attention hidden layer, the output of the graph neural network is a high-dimensional graph embedding feature representation corresponding to each order and machine node, simultaneously fusing process constraint connectivity topology information and the original node physical attributes.

[0023] The feature aggregation and update process in the graph attention hidden layer includes: for the i-th node, first determine the set of its neighboring nodes; then calculate the attention coefficient based on the node feature relationship between the i-th node and each neighboring node, and use the edge connection strength obtained by the process preparation time decay function as the adjustment factor for the corresponding edge; subsequently, use the attention coefficient and the edge connection strength to jointly adjust the amount of information transmitted by the neighboring nodes, perform weighted aggregation on the adjusted neighboring node features, and after trainable linear transformation and nonlinear activation processing, obtain the node feature representation of the i-th node in the next layer. Thus, in the message aggregation process, the graph neural network retains the adaptive allocation capability of the graph attention network for the importance of different neighboring nodes, and also introduces the constraint of process preparation time on the connectivity strength between the order node and the machine node, ensuring that the graph neural network model is consistent with the implementation logic of the graph attention network GAT.

[0024] In some implementations, the calculation of dynamic weight coefficients based on initial node features includes: The initial node features are input into a dual-branch perceptron network; The first and second branch networks output non-negative values ​​whose sum is no greater than 1, which are used as the first weighting coefficient for the corresponding completion time and the second weighting coefficient for the corresponding equipment utilization rate, respectively. Based on the constraint that the sum of the weights is 1, the value obtained by subtracting the first weight coefficient and the second weight coefficient from 1 is used as the third weight coefficient of the corresponding process switching cost. The first, second, and third weight coefficients are used as dynamic weight coefficients. After being expanded into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, the message aggregation process of the graph neural network is modulated.

[0025] A multilayer perceptron network with a dual-branch structure is constructed. The dual-branch perceptron network includes a feature input layer, a shared fully connected hidden layer, and a first nonlinear output branch and a second nonlinear output branch that are set independently and in parallel. The feature input layer is used to receive and map input features, the shared fully connected hidden layer is used to perform multilayer linear transformation, and the first nonlinear output branch and the second nonlinear output branch are used to extract the first weight coefficient and the second weight coefficient, respectively.

[0026] The input to this two-branch perceptron network is an initial node feature vector. After the node features are passed and processed through multiple layers in the feedforward neural network structure within the model, the two-branch perceptron network includes a first nonlinear output branch and a second nonlinear output branch arranged in parallel, which are used to output a first weight coefficient corresponding to the maximum completion time and a second weight coefficient corresponding to the equipment utilization rate, respectively. The node feature transfer and feature dimensionality reduction process between the hidden layers includes: sending the input node vector output from the previous network layer into the current fully connected layer, performing a linear transformation through the weight coefficient matrix and bias parameter vector, and generating the output representation vector of the current network layer after nonlinear activation processing. The output representation vector continues to be passed to subsequent network layers.

[0027] Instead of directly outputting dynamic weights using one-dimensional Softmax at the network's end, the first and second output branches output a first intermediate value and a second intermediate value, respectively. These first and second intermediate values, along with a fixed reference value, are then input into the Softmax function for joint normalization, resulting in three non-negative target weights that sum to 1. The first two target weights serve as the first and second weight coefficients, respectively, while the third target weight serves as the process switching cost weight, equal to 1 minus the first and second weight coefficients. This ensures that the sum of the first and second weight coefficients is not greater than 1 during both the training and inference phases, and guarantees that the process switching cost weight is non-negative.

[0028] For example, when the input features indicate a large number of urgent delivery orders in the near future, the network will output a higher first weight coefficient, such as 0.60, and a second weight coefficient, such as 0.25. The dynamic weight coefficient changes are illustrated below. Figure 3 As shown. Based on the logical constraint that the sum of the overall multi-objective preference weights is 1, the third weight coefficient of the corresponding process switching cost is calculated using a constant deduction operation, resulting in a third weight coefficient of 0.15. This constitutes a dynamic weight coefficient vector representing the current system production status and order urgency characteristics.

[0029] Before employing the tensor broadcasting mechanism, the aforementioned node-level three-dimensional dynamic weight coefficient vector is first input into a linear mapping layer from the target semantics to the channel dimension, resulting in a channel adjustment vector with a length consistent with the number of feature channels of the hidden layer nodes in the graph neural network. This channel adjustment vector is then copied and expanded along the node count dimension to form an adjustment tensor with the same shape as the feature matrix of the hidden layer nodes in the graph neural network. During the node neighbor message passing and aggregation phase of the graph neural network, element-wise Hadamard product modulation is performed between the aggregated features and this adjustment tensor, allowing the tendency information of different production goals to be incorporated into the node's state embedding representation.

[0030] S2, the node state is embedded into the vector input of the Critic network with a multi-head decoupling structure, and multiple sub-value components corresponding to completion time, equipment utilization rate and process switching cost are output in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Based on the multiple candidate actions output by the Actor network, multiple subsequent states are deduced, and the evaluation value of each subsequent state is calculated.

[0031] A multi-head Critic network model with a shared underlying layer and three independent output branches is constructed. The previously obtained node state embedding vectors are first input into a shared multilayer perceptron consisting of fully connected layers and ReLU activation functions for feature extraction. The extracted hidden layer features are then input in parallel into three independent network branches with linearly transformed output layers. The outputs represent the first sub-value component (predicted completion time), the second sub-value component (predicted equipment utilization), and the third sub-value component (predicted process switching cost), respectively. The state-level dynamic weight coefficients, obtained by generating the weights from the network output and performing average pooling or attention pooling, are used as the three weight parameters; these dynamic weight coefficients are not extracted from the Critic network.

[0032] Following the logic that equipment utilization rate is a positive indicator, and completion time and process switching cost are negative indicators, the three sub-value components are normalized in dimension and then subjected to a signed linear combination to obtain a scalar global evaluation value for the current state. This signed linear combination is a type of linear combination, and its sign is determined by the positive and negative attributes of different evaluation indicators. The constructed Actor network generates multiple candidate action sequences representing order allocation to machines through its output layer sampling. Based on the state transition probability matrix of the spinning workshop, an environment deduction operation is performed on each candidate action to update the remaining order quantity and machine state parameters, resulting in multiple heterogeneous graph structures corresponding to different subsequent states. Each heterogeneous graph corresponding to a subsequent state is sequentially input into the same graph neural network and a Critic network with a multi-head decoupling structure. The aforementioned node feature extraction, branch forward propagation, and signed linear combination operation combining positive and negative indicator characteristics are reused to calculate the global evaluation value corresponding to each subsequent state.

[0033] In some implementations, the step of linearly combining the multiple sub-value components using the dynamic weight coefficients to obtain the evaluation value of the current state includes: The three sub-value components of the parallel output of the Critic network with a multi-head decoupling structure are obtained, namely the predicted value of the corresponding completion time, the predicted value of the corresponding equipment utilization rate, and the predicted value of the corresponding process switching cost. After normalizing the dimensions of each predicted value, it is combined with the corresponding positive and negative index characteristics and the corresponding dynamic weight coefficient. The calculation formula for the evaluation value of the current state is: the normalized value of the predicted value of the corresponding equipment utilization rate multiplied by the second weight coefficient of the corresponding equipment utilization rate, minus the normalized value of the predicted value of the corresponding completion time multiplied by the first weight coefficient of the corresponding completion time, and then minus the normalized value of the predicted value of the corresponding process switching cost multiplied by the third weight coefficient of the corresponding process switching cost. The evaluation value is used as the overall environmental evaluation of the current state of the system.

[0034] The multi-head decoupled Critic network under the reinforcement learning framework undertakes the task of state value assessment, used to estimate the comprehensive value of the current workshop state. The structure of this Critic network with multi-head decoupling mainly consists of a state observation input layer that extracts state information jointly constructed by different devices and orders, a multi-level nonlinear hidden processing layer that mines the implicit scheduling influence laws within the network state, and a cascaded combination of multiple decoupled state value output heads that execute parallel distribution strategies and reduce index coupling interference.

[0035] The input to the Critic network with a multi-head decoupled structure is a graph feature state representation vector, extracted from forward information, representing the current state of the system and including the states of various machines. No additional scheduling action matrix from the Actor network is input. Candidate actions output by the Actor network are transformed into subsequent states through an environment simulator, and then the same Critic network evaluates the state value of these subsequent states. This maintains the consistency of the Critic network's functional positioning as a V-network. The output of the Critic network with a multi-head decoupled structure consists of three independent sub-value scalar values ​​used to calculate the overall evaluation value: a predicted value for completion time, a predicted value for overall workshop equipment utilization, and a predicted value for the comprehensive process changeover cost caused by frequent process changes.

[0036] The forward numerical prediction calculation formulas corresponding to each decoupled task flow branch within the multi-level nonlinear hidden processing layer are defined as follows: , where the formula terms The scalar represents the specific evaluation and prediction result returned by a single output head when the above model performs multi-task forward inference. F represents the high-level abstract representation vector obtained by the model after multi-level nonlinear hidden layer information extraction, dimensionality reduction and fusion calculation operations, and provided to the value output head network for logical calculation. and The proprietary training connection weight coefficient matrix and the corrected bias vector parameters represent the current branch output head, which exists independently and has no physical gradient correlation with other branches, thereby reducing the cross-interference phenomenon of back-update.

[0037] The three independent fully connected layer output heads of the multi-head decoupled Critic network receive the current state embedding vector from the graph neural network output in parallel, and perform forward inference respectively, outputting three sub-value components with corresponding practical significance. Assuming the current state, the network predicts a maximum completion time of 120.5 hours, an average equipment utilization rate of 85.3%, and a total process changeover cost of 1500 yuan. The predicted values ​​are then normalized. Assuming the recorded extreme ranges for completion time (50-200 hours), equipment utilization rate (0.6-1.0), and changeover cost (500-3000 yuan), the normalized values ​​for these three indicators are 0.470, 0.6325, and 0.400, respectively.

[0038] When constructing the overall evaluation value for the current state, the gain logic of different evaluation objectives is combined: equipment utilization rate is a positive indicator, meaning the higher the value, the better; while completion time and process changeover cost are negative indicators, meaning the lower the value, the better. The first weighting coefficient of 0.60, the second weighting coefficient of 0.25, and the third weighting coefficient of 0.15 generated in the previous steps are substituted into the calculation, and the combination logic is set to the weighted sum of positive indicators minus the weighted sum of negative indicators. By substituting the normalized values ​​and performing the calculation, the evaluation value for this state is obtained as -0.183875. This continuous scalar result encompasses the multi-objective comprehensive evaluation of delivery efficiency and cost in the spinning workshop, and serves as the basis for the subsequent construction of time-series difference error and dominance function, which is then passed to subsequent stages.

[0039] S3. Combine the expected values ​​of the evaluation values ​​of each subsequent state with the immediate reward to construct a temporal difference objective. Update the Critic network with a multi-head decoupled structure by calculating the temporal difference error. Calculate the policy gradient and update the Actor network based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent states. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation values ​​of each subsequent state. Use the updated Actor network to generate a spinning production scheduling scheme based on the current state.

[0040] After performing environmental simulations for each candidate action, the immediate reward value corresponding to each candidate action is obtained. This immediate reward value is the difference in the total system utility before and after the action execution. Based on the probability of each candidate action output by the Actor network, the immediate reward value corresponding to each candidate action and the global evaluation values ​​of multiple subsequent states are weighted and summed to obtain the expected immediate reward and the expected evaluation value. The expected immediate reward is then multiplied by the reinforcement learning discount factor and the expected evaluation value to construct the temporal difference target value. The temporal difference error between the temporal difference target value and the current state global evaluation value is calculated. The gradient is calculated by backpropagation of this temporal difference error, and the network parameters of the shared layer and each branch in the Critic network with a multi-head decoupled structure are updated based on the gradient.

[0041] Based on the probability of the Actor network's output action, the probability of the old policy, and the advantage function obtained from the temporal difference error, the policy gradient of the Actor network is calculated. For the three independent branches of the Critic network, the gradient vector of each sub-value component with respect to the network's shared layer parameters is calculated. The cosine similarity between each pair of these three gradient vectors is calculated, and the average of all cosine similarities is taken to obtain the comprehensive similarity. The initial learning rate of the policy gradient is multiplied by the natural exponential function value of this comprehensive similarity to achieve positive adjustment.

[0042] The variance of the global evaluation value for each subsequent state is calculated. This variance is then divided by the square of the sum of the absolute value of the mean of the global evaluation value for each subsequent state and a preset stability constant to obtain the dimensionless variance. The learning rate after forward adjustment is divided by the sum of this dimensionless variance and the numerical stability smoothing constant to achieve reverse adjustment, resulting in the policy gradient update step size. To prevent the adjustment ratio from amplifying abnormally when the dimensionless variance is too small, preset upper and lower cutoff values ​​are set for the adjustment ratio. Finally, the actual update step size of the Actor network is calculated using the truncated adjustment ratio. Using the adjusted step size, the parameters of the Actor network are updated in conjunction with the Adam optimizer. The current spinning workshop orders and machine states are input into the updated and converged Actor network, and the forward propagation outputs deterministic optimal action instructions. These action instructions are then sent to the manufacturing execution system via an application programming interface (API), transforming them into a specific production scheduling scheme for allocating a batch of orders to designated spinning machines at a specific time, and driving workshop production execution.

[0043] In some implementations, updating the Critic network with a multi-head decoupling structure by calculating the temporal difference error includes: The expected value of the evaluation value of each subsequent state is obtained. The expected value of the evaluation value of each subsequent state is multiplied by a discount factor and then added to the immediate reward obtained from the production environment after the system executes the current action to obtain the time-series difference target value. The time-series difference error is calculated by subtracting the current state's evaluation value from the time-series difference target value. The loss function is constructed using the temporal difference error, and the gradient is calculated and the parameters of the Critic network with a multi-head decoupled structure are updated using the backpropagation algorithm.

[0044] When the production scheduling system, in its current state, outputs a probability distribution from the Actor network and samples a specific scheduling action, the production environment evolves, generating a series of multiple subsequent state branches. The current Critic network evaluates these subsequent states and calculates their expected evaluation value, assuming this expected evaluation result is -0.150. A discount factor parameter, representing the importance of long-term value, is used, with a configuration range of, for example, 0.90 to 0.99, and a value of 0.95. Simultaneously, the scheduling simulator provides an immediate environmental reward based on the process smoothness or constraint violations caused by the action. Assuming no batch changedown downtime occurs and delivery constraints are met, the immediate reward is 0.05.

[0045] The temporal difference target value is constructed using the aforementioned variables and used for subsequent network parameter updates. The temporal difference target value is calculated as the product of the immediate reward of 0.05, the discount factor of 0.95, and the expected evaluation value of -0.150, yielding a target value of -0.0925. After obtaining the target value calculated from the actual evolution, it is compared with the current state evaluation value predicted by the Critic network, which is -0.183875. By subtracting the predicted value of -0.183875 from the target value of -0.0925, the temporal difference error is calculated to be approximately 0.091375. This difference measures the discrepancy between the model's predicted value and the value obtained from the actual state transition. A mean squared error loss function is constructed based on the square of this error, and the gradient of the loss function with respect to the weight matrices and bias parameters in the multi-head Critic network is calculated. An adaptive moment estimation optimizer is used to update the Critic network parameters at a set small learning rate, continuously reducing the prediction bias in subsequent evaluations.

[0046] In some implementations, the update step size of the policy gradient is positively adjusted based on the cosine similarity of the gradients of the plurality of sub-value components, and negatively adjusted based on the dimensionless variance of the evaluation values ​​of each subsequent state, including: Calculate the mean cosine similarity between each pair of gradients corresponding to each sub-value component; Calculate the dimensionless variance of the evaluation values ​​of each subsequent state derived from each candidate action; The adjustment ratio is determined based on the mean cosine similarity and the dimensionless variance, and the adjusted update step size is obtained by multiplying the initial update step size by the adjustment ratio. The adjustment ratio is a value obtained by dividing the natural constant by the power of the mean cosine similarity, which is the power of the natural constant, by the sum of the dimensionless variance and the preset positive stability constant. The adjustment ratio is restricted between a preset upper limit and a preset lower limit to obtain a truncated adjustment ratio, and the adjusted update step size is determined based on the truncated adjustment ratio. Update the parameters of the Actor network using the adjusted update step size.

[0047] The Actor network consists of a state input layer that performs the task of collecting the front-end graph node encoding matrix, an action distribution mapping layer that converts high-dimensional input information into specific task decision features, and a nonlinear probabilistic activation output layer that quantifies the intensity of the probability distribution of specific scheduling operations. During task-driven processing, the Actor network uses a state vector as input, which is composed of global workshop operating parameters, equipment operation monitoring parameters, and graph embedding feature representations of each node. These graph embedding feature representations are generated based on the urgency and constraints of different order types. After deep feature propagation, numerical transformation, and bias adjustment, the Actor network outputs an action selection probability distribution from its terminal module. This action selection probability distribution represents the selection probability of each feasible combination of scheduling operations within a preset discrete scheduling action space.

[0048] The output of the Actor network maps the state embedding representation vector to the unnormalized score of each candidate scheduling operation combination, and generates an action selection probability distribution through Softmax normalization. Each component in the action selection probability distribution represents the selection probability of the corresponding feasible scheduling operation combination within a preset discrete scheduling action space, and the sum of all probability components is 1. Before updating the parameters of the Actor network that generates scheduling actions, the parameter gradients obtained by backpropagating the three sub-values ​​of completion time, equipment utilization, and process changeover cost from the shared hidden layer of the multi-head Critic network are extracted. The cosine similarity of these three gradient directions in the vector space is calculated by dividing each pair of inner products by the product of their respective moduli, and the average of these three similarity values ​​is taken to obtain the mean similarity. If the mean is positive, such as 0.6, it indicates that there is no significant divergence in the optimization direction of reducing completion time and reducing changeover cost, and the multiple objectives are in a cooperative state.

[0049] In addition, all subsequent state evaluation values ​​generated from the simulation of each candidate scheduling action are collected, and the normalized volatility of the subsequent state evaluation values ​​is calculated according to the aforementioned dimensionless variance formula, assuming a calculated value of 0.04. This dimensionless variance index represents the magnitude of uncertainty in future states and scheduling volatility risk caused by the current action. An adjustment mechanism is initiated based on an initial update step size, for example, 0.05%. The adjustment ratio is defined as an adaptive nonlinear fraction, where the numerator uses an exponential function to map the mean of the cosine similarity to positively encourage the direction of collaborative optimization (i.e., the larger the mean, the higher the ratio), and the denominator is the dimensionless variance plus a positive constant to prevent the denominator from being zero, for example... The sum of these factors helps to suppress excessive exploration under uncertain conditions.

[0050] After calculating the base adjustment ratio, the base adjustment ratio is limited between a preset lower limit and a preset upper limit to obtain the actual adjustment ratio. Specifically, when the base adjustment ratio is lower than the preset lower limit, the preset lower limit is used; when the base adjustment ratio is higher than the preset upper limit, the preset upper limit is used; otherwise, the base adjustment ratio remains unchanged. The preset lower limit is used to prevent training stagnation due to excessively small update steps, and the preset upper limit is used to prevent policy oscillations due to excessively large update steps.

[0051] Substituting the above values ​​into the calculation, the numerator is the natural constant e raised to the power of 0.6, approximately 1.822, and the denominator is 0.04001, resulting in a quotient of approximately 45.54. An upper limit cutoff value is set for the adjustment ratio, for example, 5.0. After the cutoff, the adjusted actual update step size is the initial update step size multiplied by 5.0, resulting in 0.0025. Using this calculated update step size, the parameters of the Actor network are updated according to the parameter update direction determined by the policy gradient.

[0052] In this application, a deep reinforcement learning-based intelligent scheduling system for a spinning workshop is disclosed, the system comprising: The modulation module is used to acquire real-time order and machine status data in the spinning workshop, construct an order and machine heterogeneity graph, input the order and machine heterogeneity graph into a graph neural network, calculate dynamic weight coefficients through initial node features, expand the weight coefficients into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and use the adjustment tensor to modulate the message aggregation process of the graph neural network to generate a node state embedding vector. The calculation module is used to embed the node state into the vector input of the Critic network with a multi-head decoupling structure, and output multiple sub-value components corresponding to completion time, equipment utilization rate and process switching cost in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Based on the multiple candidate actions output by the Actor network, multiple subsequent states are deduced, and the evaluation value of each subsequent state is calculated. The production scheduling module is used to construct a temporal difference objective by combining the expected evaluation values ​​of each subsequent state with the immediate reward. It updates the Critic network with a multi-head decoupled structure by calculating the temporal difference error. Based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent state, it calculates the policy gradient and updates the Actor network. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation values ​​of each subsequent state. Using the updated Actor network, a spinning production scheduling scheme is generated based on the current state.

[0053] In some implementations, obtaining real-time order and machine status data in the spinning workshop includes: Connect to the production scheduling system and read the queue of orders to be scheduled. Extract the target yarn count and the remaining time until delivery time for each order as the initial numerical features of the order node. The sensors connected to each machine station collect and calculate the average operating speed and number of downtimes of each machine station within a predetermined time window as the initial numerical characteristics of the machine station nodes. The initial numerical features of the order node and the machine node are normalized using a standardization algorithm. The calculation formula is the difference between the original numerical feature value and the mean, divided by the standard deviation. The normalized features are used as the initial node features.

[0054] In some implementations, constructing the heterogeneous graph of order machines and inputting the heterogeneous graph of order machines into a graph neural network includes: Orders are classified as the first type of nodes to form an order node set, and machines are classified as the second type of nodes to form a machine node set. Given the process constraints when an order is assigned to a specific machine, obtain the corresponding process yarn clearing and batch change preparation time. The preparation time is converted into edge connection weights, and an adjacency matrix representing process constraints is constructed. The preparation time is substituted into an exponential decay function to calculate the edge connection weights. The connection weights are powers of the natural constant and are determined exponentially based on the preparation time and a preset penalty coefficient. The adjacency matrix is ​​used as the topology input of the graph neural network.

[0055] In some implementations, the calculation of dynamic weight coefficients based on initial node features includes: The initial node features are input into a dual-branch perceptron network; The first and second branch networks output non-negative values ​​whose sum is no greater than 1, which are used as the first weighting coefficient for the corresponding completion time and the second weighting coefficient for the corresponding equipment utilization rate, respectively. Based on the constraint that the sum of the weights is 1, the value obtained by subtracting the first weight coefficient and the second weight coefficient from 1 is used as the third weight coefficient of the corresponding process switching cost. The first, second, and third weight coefficients are used as dynamic weight coefficients. After being expanded into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, the message aggregation process of the graph neural network is modulated.

[0056] In some implementations, the step of linearly combining the multiple sub-value components using the dynamic weight coefficients to obtain the evaluation value of the current state includes: The three sub-value components of the parallel output of the Critic network with a multi-head decoupling structure are obtained, namely the predicted value of the corresponding completion time, the predicted value of the corresponding equipment utilization rate, and the predicted value of the corresponding process switching cost. After normalizing the dimensions of each predicted value, it is combined with the corresponding positive and negative index characteristics and the corresponding dynamic weight coefficient. The calculation formula for the evaluation value of the current state is: the normalized value of the predicted value of the corresponding equipment utilization rate multiplied by the second weight coefficient of the corresponding equipment utilization rate, minus the normalized value of the predicted value of the corresponding completion time multiplied by the first weight coefficient of the corresponding completion time, and then minus the normalized value of the predicted value of the corresponding process switching cost multiplied by the third weight coefficient of the corresponding process switching cost. The evaluation value is used as the overall environmental evaluation of the current state of the system.

[0057] In some implementations, updating the Critic network with a multi-head decoupling structure by calculating the temporal difference error includes: The expected value of the evaluation value of each subsequent state is obtained. The expected value of the evaluation value of each subsequent state is multiplied by a discount factor and then added to the immediate reward obtained from the production environment after the system executes the current action to obtain the time-series difference target value. The time-series difference error is calculated by subtracting the current state's evaluation value from the time-series difference target value. The loss function is constructed using the temporal difference error, and the gradient is calculated and the parameters of the Critic network with a multi-head decoupled structure are updated using the backpropagation algorithm.

[0058] In some implementations, the update step size of the policy gradient is positively adjusted based on the cosine similarity of the gradients of the plurality of sub-value components, and negatively adjusted based on the dimensionless variance of the evaluation values ​​of each subsequent state, including: Calculate the mean cosine similarity between each pair of gradients corresponding to each sub-value component; Calculate the dimensionless variance of the evaluation values ​​of each subsequent state derived from each candidate action; The adjustment ratio is determined based on the mean cosine similarity and the dimensionless variance, and the adjusted update step size is obtained by multiplying the initial update step size by the adjustment ratio. The adjustment ratio is a value obtained by dividing the natural constant by the power of the mean cosine similarity, which is the power of the natural constant, by the sum of the dimensionless variance and the preset positive stability constant. The adjustment ratio is restricted between a preset upper limit and a preset lower limit to obtain a truncated adjustment ratio, and the adjusted update step size is determined based on the truncated adjustment ratio. Update the parameters of the Actor network using the adjusted update step size.

[0059] The above are merely preferred embodiments of the present invention and are not intended to limit the present invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments that can be applied to other fields. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.

Claims

1. A method for intelligent scheduling in a spinning workshop based on deep reinforcement learning, characterized in that, Includes the following steps: Real-time order and machine status data of the spinning workshop are obtained, an order and machine heterogeneity graph is constructed, the order and machine heterogeneity graph is input into a graph neural network, dynamic weight coefficients are calculated through initial node features, the weight coefficients are expanded into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and the message aggregation process of the graph neural network is modulated using the adjustment tensor to generate a node state embedding vector. The node state is embedded into a vector input to a Critic network with a multi-head decoupling structure. Multiple sub-value components corresponding to completion time, equipment utilization, and process switching cost are output in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Multiple subsequent states are inferred based on multiple candidate actions output by the Actor network, and the evaluation value of each subsequent state is calculated. The expected value of each subsequent state's evaluation value is combined with the immediate reward to construct a temporal difference objective. The Critic network with a multi-head decoupled structure is updated by calculating the temporal difference error. Based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent states, the policy gradient is calculated and the Actor network is updated. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation value of each subsequent state. Using the updated Actor network, a spinning production scheduling scheme is generated based on the current state.

2. The method according to claim 1, characterized in that, The acquisition of real-time order and machine status data in the spinning workshop includes: Connect to the production scheduling system and read the queue of orders to be scheduled. Extract the target yarn count and the remaining time until delivery time for each order as the initial numerical features of the order node. The sensors connected to each machine station collect and calculate the average operating speed and number of downtimes of each machine station within a predetermined time window as the initial numerical characteristics of the machine station nodes. The initial numerical features of the order node and the machine node are normalized using a standardization algorithm. The calculation formula is the difference between the original numerical feature value and the mean, divided by the standard deviation. The normalized features are used as the initial node features.

3. The method according to claim 2, characterized in that, The construction of the order machine heterogeneity graph, and inputting the order machine heterogeneity graph into a graph neural network, includes: Orders are classified as the first type of nodes to form an order node set, and machines are classified as the second type of nodes to form a machine node set. Given the process constraints when an order is assigned to a specific machine, obtain the corresponding process yarn clearing and batch change preparation time. The preparation time is converted into edge connection weights, and an adjacency matrix representing process constraints is constructed. The preparation time is substituted into an exponential decay function to calculate the edge connection weights. The connection weights are powers of the natural constant and are determined exponentially based on the preparation time and a preset penalty coefficient. The adjacency matrix is ​​used as the topology input of the graph neural network.

4. The method according to claim 1, characterized in that, The calculation of dynamic weight coefficients based on initial node features includes: The initial node features are input into a dual-branch perceptron network; The first and second branch networks output non-negative values ​​whose sum is no greater than 1, which are used as the first weighting coefficient for the corresponding completion time and the second weighting coefficient for the corresponding equipment utilization rate, respectively. Based on the constraint that the sum of the weights is 1, the value obtained by subtracting the first weight coefficient and the second weight coefficient from 1 is used as the third weight coefficient of the corresponding process switching cost. The first, second, and third weight coefficients are used as dynamic weight coefficients. After being expanded into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, the message aggregation process of the graph neural network is modulated.

5. The method according to claim 1, characterized in that, The step of linearly combining the multiple sub-value components using the dynamic weight coefficients to obtain the evaluation value of the current state includes: The three sub-value components of the parallel output of the Critic network with a multi-head decoupling structure are obtained, namely the predicted value of the corresponding completion time, the predicted value of the corresponding equipment utilization rate, and the predicted value of the corresponding process changeover cost. After normalizing the dimensions of each predicted value, it is combined with the corresponding positive and negative index characteristics and the corresponding dynamic weight coefficient. The calculation formula for the evaluation value of the current state is: the normalized value of the predicted value of the corresponding equipment utilization rate multiplied by the second weight coefficient of the corresponding equipment utilization rate, minus the normalized value of the predicted value of the corresponding completion time multiplied by the first weight coefficient of the corresponding completion time, and then minus the normalized value of the predicted value of the corresponding process switching cost multiplied by the third weight coefficient of the corresponding process switching cost. The evaluation value is used as the overall environmental evaluation of the current state of the system.

6. The method according to claim 1 or 5, characterized in that, The method of updating the Critic network with a multi-head decoupling structure by calculating the temporal difference error includes: The expected value of the evaluation value of each subsequent state is obtained. The expected value of the evaluation value of each subsequent state is multiplied by a discount factor and then added to the immediate reward obtained from the production environment after the system executes the current action to obtain the time-series difference target value. The time-series difference error is calculated by subtracting the current state's evaluation value from the time-series difference target value. The loss function is constructed using the temporal difference error, and the gradient is calculated and the parameters of the Critic network with a multi-head decoupled structure are updated using the backpropagation algorithm.

7. The method according to claim 1, characterized in that, The update step size of the policy gradient is positively adjusted based on the cosine similarity of the gradients of the multiple sub-value components, and negatively adjusted based on the dimensionless variance of the evaluation values ​​of each subsequent state, including: Calculate the mean cosine similarity between each pair of gradients corresponding to each sub-value component; Calculate the dimensionless variance of the evaluation values ​​of each subsequent state derived from each candidate action; The adjustment ratio is determined based on the mean cosine similarity and the dimensionless variance, and the adjusted update step size is obtained by multiplying the initial update step size by the adjustment ratio. The adjustment ratio is a value obtained by dividing the power of the natural constant with the mean cosine similarity as the exponent by the sum of the dimensionless variance and the preset positive stability constant. The adjustment ratio is restricted between a preset upper limit and a preset lower limit to obtain a truncated adjustment ratio, and the adjusted update step size is determined based on the truncated adjustment ratio. Update the parameters of the Actor network using the adjusted update step size.

8. A smart production scheduling system for a spinning workshop based on deep reinforcement learning, characterized in that, Includes the following modules: The modulation module is used to acquire real-time order and machine status data in the spinning workshop, construct an order and machine heterogeneity graph, input the order and machine heterogeneity graph into a graph neural network, calculate dynamic weight coefficients through initial node features, expand the weight coefficients into an adjustment tensor that matches the node feature dimension through a broadcast mechanism, and use the adjustment tensor to modulate the message aggregation process of the graph neural network to generate a node state embedding vector. The calculation module is used to embed the node state into the vector input of the Critic network with a multi-head decoupling structure, and output multiple sub-value components corresponding to completion time, equipment utilization rate and process switching cost in parallel. The multiple sub-value components are linearly combined using the dynamic weight coefficients to obtain the evaluation value of the current state. Based on the multiple candidate actions output by the Actor network, multiple subsequent states are deduced, and the evaluation value of each subsequent state is calculated. The production scheduling module is used to construct a temporal difference objective by combining the expected evaluation values ​​of each subsequent state with the immediate reward. It updates the Critic network with a multi-head decoupled structure by calculating the temporal difference error. Based on the temporal difference error or the advantage function determined by the evaluation value of the current state and the evaluation value of the subsequent state, it calculates the policy gradient and updates the Actor network. The update step size of the policy gradient is positively adjusted according to the cosine similarity of the gradients of the multiple sub-value components and negatively adjusted according to the dimensionless variance of the evaluation values ​​of each subsequent state. Using the updated Actor network, a spinning production scheduling scheme is generated based on the current state.

9. The system according to claim 8, characterized in that, The acquisition of real-time order and machine status data in the spinning workshop includes: Connect to the production scheduling system and read the queue of orders to be scheduled. Extract the target yarn count and the remaining time until delivery time for each order as the initial numerical features of the order node. The sensors connected to each machine station collect and calculate the average operating speed and number of downtimes of each machine station within a predetermined time window as the initial numerical characteristics of the machine station nodes. The initial numerical features of the order node and the machine node are normalized using a standardization algorithm. The calculation formula is the difference between the original numerical feature value and the mean, divided by the standard deviation. The normalized features are used as the initial node features.

10. The system according to claim 8, characterized in that, The construction of the order machine heterogeneity graph, and inputting the order machine heterogeneity graph into a graph neural network, includes: Orders are classified as the first type of nodes to form an order node set, and machines are classified as the second type of nodes to form a machine node set. Given the process constraints when an order is assigned to a specific machine, obtain the corresponding process yarn clearing and batch change preparation time. The preparation time is converted into edge connection weights, and an adjacency matrix representing process constraints is constructed. The preparation time is substituted into an exponential decay function to calculate the edge connection weights. The connection weights are powers of the natural constant and are determined exponentially based on the preparation time and a preset penalty coefficient. The adjacency matrix is ​​used as the topology input of the graph neural network.