Computing task scheduling method and system applied to numerical control machining system
By obtaining the processing complexity and resource requirements characteristics of the task request set, calling the task priority evaluation model to generate a priority sequence, and dynamically adjusting the scheduling scheme is solved, and unreasonable task scheduling in traditional CNC machining systems is solved, and processing efficiency and resource utilization are improved.
Patent Information
- Application Number
- CN202510848157.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-24
- Publication Date
- 2025-07-22
- Estimated Expiration
- 2045-06-24
AI Technical Summary
The traditional CNC machining system calculation task scheduling method is difficult to fully consider the complexity, resource requirements and real-time constraints of the task, resulting in too long waiting time for the task and low resource utilization, which affects processing efficiency and quality.
By obtaining the task request set, extracting processing complexity characteristics and resource requirements characteristics, calling the task priority evaluation model to generate a priority sequence, and dynamic adjustment of the scheduling scheme is performed in combination with real-time feedback information to ensure the reasonable matching of tasks and resources and optimized configuration.
The processing efficiency and resource utilization of the CNC machining system are improved, ensuring that the system maintains an efficient and stable operating state under various changes.
Smart Images

Figure CN120355196A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of numerical control machining task scheduling. Specifically, it relates to a calculation task scheduling method and system applied to a numerical control machining system. Background Art
[0002] In a numerical control machining system, calculation task scheduling is a key link affecting machining efficiency and system performance. With the continuous development of numerical control machining technology, machining tasks are becoming increasingly complex and diverse, involving various machining process types, and different tasks have different requirements for real-time performance. Traditional calculation task scheduling methods for numerical control machining systems often rely on simple task priority rules or the first-come, first-served principle, and it is difficult to fully consider multiple factors such as task complexity, resource requirements, and real-time constraints. This leads to problems such as excessive task waiting time, low resource utilization rate, and inability to complete machining tasks on time during actual machining, seriously affecting the overall operating efficiency and machining quality of the numerical control machining system. Summary of the Invention
[0003] In view of the above-mentioned problems, in combination with the first aspect of the present invention, embodiments of the present invention provide a calculation task scheduling method applied to a numerical control machining system, and the method includes: Obtain a task request set of the numerical control machining system, where the task request set includes multiple calculation task units to be scheduled, and each calculation task unit to be scheduled is associated with machining process type information and a real-time constraint identifier; Perform task feature extraction processing on the task request set to obtain a processing complexity feature and a resource requirement feature of each calculation task unit to be scheduled, where the processing complexity feature reflects the scale of the calculation amount of the task unit, and the resource requirement feature reflects the adaptability requirement of the task unit for the type of calculation resources; Call a pre-constructed task priority evaluation model to perform joint priority evaluation processing on the processing complexity feature and the resource requirement feature, and generate a priority sequence including the priority ranking of task units; According to the priority sequence and the current available resource information of the numerical control machining system, perform dynamic matching processing of tasks and resources to generate an initial scheduling plan including the corresponding relationship between task units and calculation resources; Based on the task execution status information fed back in real time, perform adaptive adjustment processing on the initial scheduling plan to generate a final scheduling plan including the execution order of task units and resource allocation parameters.
[0004] In another aspect, an embodiment of the present invention further provides a computing task scheduling system applied to a numerical control processing system, including a processor and a machine-readable storage medium. The machine-readable storage medium is connected to the processor. The machine-readable storage medium is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the machine-readable storage medium to implement the above method.
[0005] Based on the above aspects, in the embodiment of the present invention, by obtaining a set of task requests including machining process type information and real-time constraint identifiers, and performing task feature extraction processing, the processing complexity features and resource requirement features of each computing task unit to be scheduled are comprehensively obtained. For calling the pre-constructed task priority evaluation model for joint priority evaluation processing to generate a priority sequence including the priority sorting of task units, fully considering the complexity and resource requirements of tasks, ensuring the rationality and efficiency of task scheduling. According to the priority sequence and the current available resource information of the numerical control processing system, perform dynamic matching processing of tasks and resources to generate an initial scheduling plan, realizing the optimal configuration of tasks and resources. Finally, based on the real-time feedback task execution status information, perform adaptive adjustment processing on the initial scheduling plan to generate a final scheduling plan, which can timely respond to various changes during the machining process, ensure that the numerical control processing system always maintains an efficient and stable operating state, and significantly improve the machining efficiency and resource utilization rate of the numerical control processing system. BRIEF DESCRIPTION OF THE DRAWINGS
[0006] Figure 1 is a schematic execution flow diagram of a computing task scheduling method applied to a numerical control processing system provided by an embodiment of the present invention.
[0007] Figure 2 is a schematic diagram of exemplary hardware and software components of a computing task scheduling system applied to a numerical control processing system provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0008] The present invention will be specifically described below with reference to the accompanying drawings of the specification. Figure 1 is a schematic flow diagram of a computing task scheduling method applied to a numerical control processing system provided by an embodiment of the present invention. The computing task scheduling method applied to the numerical control processing system will be introduced in detail below.
[0009] Step S110: Obtain a set of task requests of the numerical control processing system. The set of task requests includes a plurality of computing task units to be scheduled, and each computing task unit to be scheduled is associated with machining process type information and a real-time constraint identifier.
[0010] In the actual scenario of numerical control machining, the numerical control machining system will receive calculation task requests from different production links during operation. The requests of the calculation task requests originate from various machining requirements. For example, when manufacturing complex mechanical parts, calculation tasks such as the calculation of the surface flatness of the parts, the tool path planning, and the optimization of machining parameters are generated. The numerical control machining system collects and integrates these received task requests to form a task request set.
[0011] Each calculation task unit to be scheduled has corresponding machining process type information. The machining process types are rich and diverse, including but not limited to turning process, milling process, grinding process, boring process, etc. Different machining process types determine the nature and characteristics of the tasks. For example, the turning process is mainly used for machining rotary parts, and its related calculation tasks may involve the calculation of parameters such as rotational speed, feed rate, and cutting depth; while the milling process is often used for machining planes, steps, grooves, etc., and the corresponding calculation tasks may include the planning of tool paths and the calculation of cutting forces.
[0012] At the same time, each calculation task unit to be scheduled is also associated with a real-time constraint identifier. The real-time constraint identifier is used to distinguish the time sensitivity of the task, and the tasks can be divided into urgent tasks with high real-time requirements and non-urgent tasks with relatively low real-time requirements. For example, in an automated production line, if the result of a certain calculation task directly affects the start of the next machining process, then the real-time constraint identifier of this task indicates that it is an urgent task and needs to be processed as soon as possible; while for some calculation tasks used for production statistics and analysis, their real-time requirements are relatively low and can be processed at an appropriate time.
[0013] Step S120: Perform task feature extraction processing on the task request set to obtain the processing complexity feature and resource requirement feature of each calculation task unit to be scheduled. The processing complexity feature reflects the scale of the calculation amount of the task unit, and the resource requirement feature reflects the adaptability requirement of the task unit for the type of computing resources.
[0014] Step S121: Perform parsing processing on the machining process type information of each calculation task unit to be scheduled in the task request set, and extract the algorithm execution process information corresponding to the machining process type.
[0015] In order to extract the processing complexity feature and resource requirement feature of each calculation task unit to be scheduled, it is necessary to first deeply analyze the machining process type information. Taking the calculation task of the outer diameter size accuracy of parts under the turning process as an example, first, the process knowledge base corresponding to this machining process type needs to be obtained. The process knowledge base is a database that stores a large amount of information related to machining processes, and it contains the mapping relationship between different machining process types and algorithm execution processes.
[0016] Step S1211: Obtain the process knowledge base corresponding to the processing technology type information, where the process knowledge base stores the mapping relationship between different processing technology types and algorithm execution processes.
[0017] The construction of the process knowledge base is based on long-term processing experience and research results. In this process knowledge base, each processing technology type corresponds to a set of corresponding algorithm execution processes. For example, for the turning process, its algorithm execution process may include steps such as data input, tool selection, cutting parameter calculation, machining path planning, and result output. By querying the process knowledge base, algorithm execution process information related to a specific processing technology type can be found.
[0018] Step S1212: Query the process knowledge base according to the processing technology type information, and extract the algorithm execution process description document that matches the processing technology type.
[0019] After determining the processing technology type of the task unit to be scheduled for calculation, use this processing technology type information to query in the process knowledge base. The query process can be carried out by means of keyword matching, etc., to find the algorithm execution process description document that exactly matches the processing technology type. This algorithm execution process description document details the algorithm steps and operation processes required to complete this processing technology.
[0020] Step S1213: Perform semantic parsing processing on the algorithm execution process description document to identify the data input node, intermediate calculation node, and result output node in the process.
[0021] After obtaining the algorithm execution process description document, semantic parsing needs to be performed on it. The purpose of semantic parsing is to convert the text information in the document into recognizable node information. The data input node is the starting point of the algorithm execution process, which receives raw data from the outside. For example, in the task of calculating the outer diameter dimension accuracy of a part, the data input node may receive data such as the designed dimension of the part and the actual dimension collected by the measuring device. The intermediate calculation node is the core part of the algorithm execution, which performs various calculations and processes on the input data. For the task of calculating the outer diameter dimension accuracy of a part, the intermediate calculation node may perform operations such as dimension deviation calculation and error analysis. The result output node is the end point of the algorithm execution, which outputs the calculated result to the subsequent application link. In this task of calculating the outer diameter dimension accuracy of a part, the result output node may output information such as the dimension accuracy evaluation result of the part and the judgment of whether it meets the design requirements.
[0022] Step S1214: Extract the operation type identifier of each node and the data transfer path information between nodes, where the operation type identifier includes numerical calculation operation, geometric modeling operation, or path planning operation.
[0023] After identifying the data input node, the intermediate calculation node, and the result output node, it is necessary to further extract the operation type identifier of each node and the data transfer path information between the nodes. The operation type identifier is used to clarify the operation type performed by each node. For example, in the task of calculating the dimensional accuracy of the outer diameter of a part, the operation type identifier of the intermediate calculation node may be a numerical calculation operation because it mainly performs numerical calculations of dimensional deviations. The data transfer path information between the nodes describes the flow direction and method of data between each node. For example, data is transferred from the data input node to the intermediate calculation node, and after being calculated and processed, it is then transferred to the result output node.
[0024] Step S1215: Based on the operation type identifier of the node and the data transfer path information, construct the topological graph of the algorithm execution process of the to-be-scheduled calculation task unit.
[0025] According to the operation type identifier of the node and the data transfer path information between the nodes, the topological graph of the algorithm execution process of the to-be-scheduled calculation task unit can be constructed. The topological graph of the algorithm execution process is a graphical representation that shows the entire process of algorithm execution in the form of nodes and edges. In this topological graph of the algorithm execution process, the nodes represent each operation node, and the edges represent the data transfer paths. Through the topological graph of the algorithm execution process, the execution order of the algorithm and the flow direction of data can be intuitively understood.
[0026] Step S122: According to the number of operation nodes and the amount of data transferred between the nodes in the algorithm execution process information, calculate the computational scale parameter of the to-be-scheduled calculation task unit as the processing complexity feature.
[0027] Step S1221: Count the total number of operation nodes in the topological graph of the algorithm execution process, and the total number of operation nodes reflects the number of calculation steps of the task unit.
[0028] The total number of operation nodes is an important indicator to measure the number of calculation steps of the task unit. In the topological graph of the algorithm execution process, all data input nodes, intermediate calculation nodes, and result output nodes are counted. The more the total number of operation nodes, the more complex the calculation steps of the task unit and the greater the possible computational amount. For example, in a complex task of machining path planning for a part, the topological graph of the algorithm execution process may contain multiple intermediate calculation nodes, and each node represents a specific calculation step, such as tool attitude adjustment calculation, path optimization calculation, etc., and the total number of operation nodes will be relatively large.
[0029] Step S1222: Calculate the amount of data transferred between adjacent nodes in the topological graph of the algorithm execution process, and the amount of data transferred is determined by the product of the data dimension output by the previous node and the data dimension input by the subsequent node.
[0030] The amount of data transferred between adjacent nodes is an indicator to measure the scale of data flow between nodes. For each pair of adjacent nodes in the algorithm execution flow topology graph, calculate the product of the output data dimension of the previous node and the input data dimension of the subsequent node. The data dimension can be understood as the number of features of the data. For example, in a material stress analysis task, the previous node may output data in multiple dimensions such as the elastic modulus and Poisson's ratio of the material, and the subsequent node may need to input this data for stress calculation. By calculating the product of the output data dimension of the previous node and the input data dimension of the subsequent node, the amount of data transferred between these two adjacent nodes is obtained.
[0031] Step S1223: Perform a weighting process on the total number of operation nodes to obtain the weighted total number of operation nodes. The weight coefficient is determined by the operation type identifier corresponding to the node, and the weight coefficient of the numerical calculation operation node is greater than that of the geometric modeling operation node.
[0032] To more accurately reflect the computational complexity of the task unit, it is necessary to perform a weighting process on the total number of operation nodes. The weight coefficient is determined according to the operation type identifier corresponding to the node. Since numerical calculations usually involve a large number of mathematical operations and the computational complexity is relatively high, the weight coefficient of the numerical calculation operation node is greater than that of the geometric modeling operation node. For example, in a task that includes numerical calculation operations and geometric modeling operations, the weight coefficient of the numerical calculation operation node may be set to a relatively large value, while the weight coefficient of the geometric modeling operation node is set to a relatively small value. By multiplying the weight coefficient corresponding to the operation type identifier of each operation node by the total number of operation nodes, the weighted total number of operation nodes is obtained.
[0033] Step S1224: Perform an accumulation and summation process on the amount of data transferred to obtain the total data transfer amount parameter of the to-be-scheduled calculation task unit.
[0034] After calculating the amount of data transferred between each pair of adjacent nodes, perform an accumulation and summation process on the amount of data transferred between all adjacent nodes. The total data transfer amount parameter reflects the scale of data flow in the entire algorithm execution process. The larger the amount of data transferred, the more data is transferred between nodes, and more computing resources and time may be required to complete the data transfer and processing. For example, in a multi-step processing process simulation task, the amount of data transferred between each node is relatively large, and after accumulating and summing these amounts of data transferred, the obtained total data transfer amount parameter will also be relatively large.
[0035] Step S1225: Perform a linear combination process on the weighted total number of operation nodes and the total data transfer amount parameter to generate the computational scale parameter of the to-be-scheduled calculation task unit as the processing complexity feature.
[0036] Perform a linear combination process on the total number of weighted operation nodes and the total data transfer volume parameter. The result obtained is the computational scale parameter of the to-be-scheduled computational task unit, and this parameter serves as the processing complexity feature. The linear combination process can perform a weighted summation on the total number of weighted operation nodes and the total data transfer volume parameter through set coefficients. For example, set one coefficient for the total number of weighted operation nodes and another coefficient for the total data transfer volume parameter. Multiply them by the corresponding parameters respectively and then add them to obtain the computational scale parameter. This computational scale parameter comprehensively considers the number of computational steps and the data transfer scale of the task unit, and can more accurately reflect the processing complexity of the task unit.
[0037] Step S123: Classify the real-time constraint identifiers of each to-be-scheduled computational task unit in the task request set, and identify the resource type adaptation rules corresponding to the real-time constraint identifiers.
[0038] Real-time constraint identifiers can be divided into different categories, such as emergency real-time tasks, general real-time tasks, and non-real-time tasks, etc. Different categories of real-time constraint identifiers correspond to different resource type adaptation rules. For emergency real-time tasks, due to their high sensitivity to time, resources with fast computing speed and strong processing capabilities, such as dedicated computing chip resources, need to be preferentially allocated. General real-time tasks can allocate graphics processor resources or central processor resources according to specific situations. Non-real-time tasks can be processed when the system resources are idle, and the real-time requirements for resources are relatively low. By classifying the real-time constraint identifiers, the resource type adaptation rules applicable to each to-be-scheduled computational task unit can be clarified.
[0039] Step S124: Based on the resource type adaptation rules, extract the adaptation requirement parameters of the to-be-scheduled computational task unit for central processor resources, graphics processor resources, or dedicated computing chip resources as resource demand features.
[0040] After identifying the resource type adaptation rules corresponding to the real-time constraint identifiers, extract the adaptation requirement parameters of the to-be-scheduled computational task unit for central processor resources, graphics processor resources, or dedicated computing chip resources according to these rules. The adaptation requirement parameters include resource type adaptation identifiers and resource performance lower limit values. The resource type adaptation identifier clarifies the resource type suitable for the task unit. For example, for a task that requires a large amount of graphics processing, its resource type adaptation identifier may be graphics processor resources. The resource performance lower limit value stipulates the minimum requirement for the resource performance of the task unit. For example, for a task that requires fast computing, its lower limit value for the performance of central processor resources may require the processor to have a high main frequency and multi-core processing capabilities. These adaptation requirement parameters constitute the resource demand features of the to-be-scheduled computational task unit.
[0041] Step S125: Input the processing complexity feature and the resource requirement feature into the feature normalization module, and perform standardization processing on the feature parameters with different dimensions through the linear scaling method to obtain a target feature set with a unified numerical range.
[0042] The processing complexity feature and the resource requirement feature may have different dimensions and numerical ranges. For the convenience of subsequent processing and analysis, they need to be input into the feature normalization module for standardization processing. The linear scaling method is a commonly used standardization processing method, which maps the feature parameters to a unified numerical range, such as the interval [0, 1]. For each parameter in the processing complexity feature and the resource requirement feature, a linear transformation is performed according to its maximum and minimum values, so that the transformed parameter values are all within the interval [0, 1]. After the standardization processing, all the feature parameters in the obtained target feature set have a unified numerical range, which is convenient for subsequent model processing and analysis.
[0043] Step S130: Invoke the pre-constructed task priority evaluation model to perform joint priority evaluation processing on the processing complexity feature and the resource requirement feature, and generate a priority sequence including the priority ranking of task units.
[0044] Step S131: Input the processing complexity feature and the resource requirement feature into the feature input layer of the task priority evaluation model, and perform non-linear transformation processing on the features through a fully connected neural network to generate a fused feature vector.
[0045] The task priority evaluation model is a pre-trained artificial intelligence model, which consists of multiple modules and levels. The feature input layer is the first layer of the model, which receives the processing complexity feature and the resource requirement feature as inputs. The fully connected neural network is a commonly used neural network structure, which performs non-linear transformation processing on the input features. In the feature input layer, the processing complexity feature and the resource requirement feature are input into the fully connected neural network. The neurons in the network perform weighted summation on the input features and perform non-linear transformation through the activation function. The activation function can map the output value of the neuron to a set range, increasing the non-linear expression ability of the model. After the processing of the fully connected neural network, a fused feature vector is generated. The fused feature vector synthesizes the information of the processing complexity feature and the resource requirement feature.
[0046] Step S132: Through the time perception layer of the task priority evaluation model, perform context information extraction processing on the fused feature vector in the time dimension to generate a time series enhanced feature vector containing real-time constraint information.
[0047] Step S1321: Input the fused feature vector into the long short-term memory network module of the time perception layer, and perform selective memory and forgetting processing on the historical feature information through the memory gate, input gate, and output gate.
[0048] The time perception layer is an important part of the task priority evaluation model, which is used to extract the context information of the fused feature vector in the time dimension. The long short-term memory (LSTM) network module is the core component of the time perception layer, which can effectively handle the long-term dependencies in sequential data. After inputting the fused feature vector into the LSTM network module, the memory gate, input gate, and output gate in the module will perform selective memory and forgetting processing on the historical feature information. The memory gate controls whether the hidden state information of the previous moment is retained to the current moment, the input gate controls whether the current input feature information is added to the cell state of the current moment, and the output gate controls whether the cell state information of the current moment is output to the hidden state. Through the above method, the LSTM network module can selectively retain and forget historical feature information, so as to capture the context information of the fused feature vector in the time dimension.
[0049] Step S1322: Extract the hidden state vector output by the long short-term memory network module, and the hidden state vector contains the context information of the fused feature vector at historical time steps.
[0050] After the LSTM network module processes the fused feature vector, a hidden state vector can be output. The hidden state vector contains the context information of the fused feature vector at historical time steps, and the context information is a comprehensive representation of the fused feature vector in the time dimension. By extracting the hidden state vector, the change trend and dependency relationship of the fused feature vector in the time dimension can be obtained.
[0051] Step S1323: Obtain the time threshold parameter corresponding to the real-time constraint identifier of the to-be-scheduled computing task unit, and the time threshold parameter represents the maximum execution delay allowed for the task unit.
[0052] Each to-be-scheduled computing task unit's real-time constraint identifier corresponds to a time threshold parameter. The time threshold parameter represents the maximum execution delay allowed for the task unit. For example, for an urgent real-time task, its time threshold parameter may be set to a smaller value, meaning that the task needs to be completed within a shorter time; while for a non-real-time task, its time threshold parameter may be set to a larger value, allowing the task to be completed within a longer time. By obtaining the time threshold parameter corresponding to the real-time constraint identifier of the to-be-scheduled computing task unit, the time constraint information can be introduced into the priority evaluation process.
[0053] Step S1324: Concatenate the time threshold parameter and the hidden state vector to generate a joint feature vector containing time constraint information.
[0054] To incorporate time constraint information into the feature vector, the time threshold parameter and the hidden state vector are concatenated. Concatenation is the process of connecting two vectors in a set order to form a new vector. In this process, the time threshold parameter is added to the end of the hidden state vector to form a joint feature vector containing time constraint information. The joint feature vector combines the context information of the fusion feature vector in the time dimension and the time constraint information of the task unit, providing a more comprehensive feature representation for subsequent priority evaluation.
[0055] Step S1325: Normalize the joint feature vector to eliminate the dimensional difference between the time threshold parameter and the hidden state vector, and generate a time-series enhanced feature vector containing real-time constraint information.
[0056] The time threshold parameter and the hidden state vector may have different dimensions and numerical ranges. To eliminate this dimensional difference, the joint feature vector needs to be normalized. The normalization process can use a linear scaling method to map each parameter in the joint feature vector to a unified numerical range, such as the interval [0, 1]. After normalization, a time-series enhanced feature vector containing real-time constraint information is generated. The time-series enhanced feature vector not only retains the information of the fusion feature vector but also incorporates time constraint information and eliminates the dimensional difference, providing a more suitable feature input for subsequent priority evaluation.
[0057] Step S133: Use the attention mechanism module of the task priority evaluation model to respectively assign attention weights to the processing complexity feature and the resource requirement feature in the time-series enhanced feature vector, and the attention weights reflect the influence degree of the features on the priority evaluation.
[0058] The attention mechanism module is an important part of the task priority evaluation model, which is used to respectively assign attention weights to the processing complexity feature and the resource requirement feature in the time-series enhanced feature vector. The attention weights reflect the influence degree of each feature on the priority evaluation. In the attention mechanism module, the model automatically learns the importance of each feature based on the input time-series enhanced feature vector and assigns corresponding attention weights. For example, for a task with high computational resource requirements, the resource requirement feature may be assigned a higher attention weight; while for a task with high computational complexity, the processing complexity feature may be assigned a higher attention weight. By assigning attention weights, the importance of different features in the priority evaluation can be highlighted, improving the accuracy of the priority evaluation.
[0059] Step S134: Based on the attention weights, perform weighted aggregation processing on the time-series enhanced feature vector to generate a priority evaluation feature vector.
[0060] After assigning attention weights to the processing complexity feature and resource requirement feature in the time-series enhanced feature vector, it is necessary to perform weighted aggregation processing on the time-series enhanced feature vector. Weighted aggregation processing is to combine each feature in the time-series enhanced feature vector according to its corresponding attention weight. Specifically, for each feature element in the time-series enhanced feature vector, multiply it by the corresponding attention weight, and then combine these weighted feature elements in a set way.
[0061] Suppose the time-series enhanced feature vector can be represented as a vector containing multiple dimensions, and each dimension represents a specific feature, such as a certain sub-feature of the processing complexity feature or an aspect of the resource requirement feature. The attention weight is also a vector with the same dimension as the feature vector, and each element corresponds to the importance of the element in the same position in the time-series enhanced feature vector. When performing weighted aggregation, multiply the first element of the time-series enhanced feature vector by the first element of the attention weight, the second element by the second element of the attention weight, and so on.
[0062] After that, for these weighted elements, they can be combined by concatenation. Concatenation is to arrange these elements in a set order to form a new vector. This method avoids the problems that may be brought by directly adding features with different dimensions, because different features may represent different physical meanings and dimensions, and adding them may cause the result to lose its practical meaning. Through concatenation, the information of each feature is retained and weighted according to its importance.
[0063] After such weighted aggregation and concatenation processing, a priority evaluation feature vector is generated. This priority evaluation feature vector comprehensively considers the processing complexity feature, resource requirement feature, and time constraint information, and highlights the influence degree of each feature on priority evaluation through the attention mechanism, providing a more comprehensive and targeted feature representation for accurately evaluating the priority of task units in the subsequent process.
[0064] Step S135: Invoke the sorting output layer of the task priority evaluation model to calculate the sorting score of the priority evaluation feature vector, generate the priority score value of each task unit to be scheduled for calculation, and generate a priority sequence according to the magnitude relationship of the priority score values.
[0065] The sorting output layer is the last layer of the task priority evaluation model. Its main task is to process the priority evaluation feature vectors and calculate the priority score values for each computing task unit to be scheduled. In the sorting output layer, a pre-set scoring mechanism can be used. This scoring mechanism may be based on various factors, such as the comprehensive impact of each element in the feature vector on the priority.
[0066] For the priority evaluation feature vectors, the sorting output layer will input them into a specific computing process. This computing process may involve weighted summation of each element in the feature vector or other complex computing methods. For example, according to the importance of different features to the priority, an additional coefficient may be assigned to each element in the feature vector, and then these elements are multiplied by the corresponding coefficients and summed up.
[0067] After obtaining the priority score values for each computing task unit to be scheduled, the sorting can be performed according to the magnitude relationship of these score values. The score values are arranged from high to low. The task units with high score values are ranked in the front, and the task units with low score values are ranked in the back. In this way, a priority sequence containing the priority sorting of task units is generated. This priority sequence clearly shows the priority order of each computing task unit to be scheduled.
[0068] Step S140: According to the priority sequence and the current available resource information of the numerical control machining system, perform dynamic matching processing of tasks and resources to generate an initial scheduling plan including the correspondence between task units and computing resources.
[0069] Step S141: Analyze the priority sequence to determine the priority order of each computing task unit to be scheduled.
[0070] After obtaining the priority sequence, it is necessary to analyze it to determine the priority order of each computing task unit to be scheduled. The priority sequence is usually an ordered list, where each element represents a computing task unit to be scheduled and is arranged from high to low in terms of priority. By traversing this list, the priority order of each task unit can be determined in turn. For example, the task unit corresponding to the first element in the list is the task with the highest priority, and the task unit corresponding to the second element has the second highest priority, and so on. This clear priority order provides clear guidance for subsequent resource allocation, ensuring that high-priority tasks can be processed first.
[0071] Step S142: Obtain the current available resource information of the numerical control machining system. The current available resource information includes the remaining computing cores of the central processing unit, the remaining video memory capacity of the graphics processing unit, and the remaining processing bandwidth of the dedicated computing chip.
[0072] To match tasks with resources, it is necessary to obtain the current available resource information of the numerical control processing system. The resources of the numerical control processing system mainly include the central processing unit, the graphics processing unit, and the dedicated computing chip. For the central processing unit, the remaining number of computing cores is an important resource indicator. The number of computing cores determines the number of tasks that the central processing unit can process simultaneously and its processing capacity. For example, if the central processing unit has a total of multiple computing cores and some of the cores are already occupied by other tasks, then the remaining number of computing cores is the resource available for new task allocation.
[0073] The remaining video memory capacity of the graphics processing unit is also a key resource information. The video memory is used to store data during the graphics processing. For tasks that require a large amount of graphics calculations, such as 3D modeling, image rendering, etc., the size of the video memory capacity directly affects the execution efficiency of the tasks. If the video memory of the graphics processing unit has been partially occupied, then the remaining video memory capacity is the resource that can be allocated to new tasks.
[0074] The remaining processing bandwidth of the dedicated computing chip is equally important. The dedicated computing chip usually has specific computing capabilities, such as high-speed data processing, complex algorithm calculation, etc. The remaining processing bandwidth represents the computing capabilities that the dedicated computing chip can still provide. For some tasks with extremely high requirements for computing speed, the remaining processing bandwidth of the dedicated computing chip is an important factor in determining whether the task can be allocated.
[0075] Step S143: Match computing resources for each computing task unit to be scheduled in turn according to the priority order. The matching rules include: preferentially allocate dedicated computing chip resources to high-priority task units, allocate graphics processing unit resources as the second best, and finally allocate central processing unit resources.
[0076] After determining the priority order of each computing task unit to be scheduled and the current available resource information of the numerical control processing system, start to match computing resources for each task unit in turn according to the priority order. The matching rules follow the set priority strategy. First, preferentially allocate dedicated computing chip resources to high-priority task units. The dedicated computing chip usually has the characteristics of high performance and high speed and can quickly process complex computing tasks. For high-priority tasks, using the dedicated computing chip can ensure that the tasks can be completed in the shortest time and meet their real-time requirements.
[0077] If the dedicated computing chip resources are insufficient or not suitable for the task unit, then the second-best choice is to allocate graphics processing unit resources. The graphics processing unit has advantages in processing graphics and parallel computing. For some tasks involving graphics processing and large-scale data parallel computing, the graphics processing unit can provide better processing performance.
[0078] Finally, if the resources of the dedicated computing chip and the graphics processing unit cannot meet the requirements of the task unit, or all the resources have been occupied, then the resources of the central processing unit will be considered for allocation. The central processing unit is a general computing resource. Although its computing power may be relatively weak compared to the dedicated computing chip and the graphics processing unit, it can still undertake some relatively simple computing tasks in the case of limited resources.
[0079] Step S144: During the matching process, check the adaptability between the resource requirement characteristics of the to-be-scheduled computing task unit and the candidate computing resources. If the candidate computing resources meet the adaptability requirements of the resource requirement characteristics, the resource allocation is completed.
[0080] During the process of matching computing resources for each to-be-scheduled computing task unit, it is necessary to check the adaptability between the resource requirement characteristics of the task unit and the candidate computing resources. The resource requirement characteristics include information such as the adaptability requirements of the task unit for the type of computing resources and the lower limit value of the resource performance. The candidate computing resources are the resources that may be allocated to the task unit selected according to the matching rules, such as dedicated computing chips, graphics processing units, or central processing units.
[0081] Specifically, first extract the adaptability requirement parameters in the resource requirement characteristics of the to-be-scheduled computing task unit, including the resource type adaptability identifier and the lower limit value of the resource performance. The resource type adaptability identifier clarifies the type of resources suitable for the task unit. For example, for a task that requires a large amount of graphics processing, its resource type adaptability identifier may be the graphics processing unit resource. The lower limit value of the resource performance stipulates the minimum requirements of the task unit for the resource performance, such as the minimum main frequency of the central processing unit and the minimum video memory capacity of the graphics processing unit.
[0082] Then obtain the resource type identifier and the current value of the resource performance of the candidate computing resources. The resource type identifier corresponds to the central processing unit, the graphics processing unit, or the dedicated computing chip, and the current value of the resource performance is the performance index currently possessed by the resource, such as the current available number of computing cores of the central processing unit and the current remaining video memory capacity of the graphics processing unit.
[0083] Judge whether the resource type identifier of the candidate computing resources is consistent with the resource type adaptability identifier of the resource requirement characteristics. If they are not consistent, it means that the candidate computing resources are not suitable for the task unit, and other candidate resources need to be reselected. If they are consistent, further judge whether the current value of the resource performance of the candidate computing resources is greater than or equal to the lower limit value of the resource performance of the resource requirement characteristics. If both are satisfied, that is, the type of the candidate computing resources is appropriate and the performance meets the requirements, it is determined that the candidate computing resources meet the adaptability requirements of the resource requirement characteristics, and the candidate computing resources are allocated to the to-be-scheduled computing task unit.
[0084] Step S1441: Extract the adaptability requirement parameters in the resource requirement characteristics of the to-be-scheduled computing task unit, where the adaptability requirement parameters include a resource type adaptation identifier and a resource performance lower limit value.
[0085] The resource requirement characteristics of the to-be-scheduled computing task unit contain the specific requirements of the task for computing resources. The adaptability requirement parameters are a key part of the resource requirement characteristics and consist of a resource type adaptation identifier and a resource performance lower limit value. The resource type adaptation identifier is determined according to the nature and characteristics of the task, which clarifies the resource type suitable for the task. For example, for a task mainly performing numerical calculations, the resource type adaptation identifier may be a central processing unit resource; while for a task involving a large amount of image rendering, the resource type adaptation identifier may be a graphics processing unit resource.
[0086] The resource performance lower limit value is the minimum requirement of the task for resource performance. Different tasks have different requirements for resource performance. For a task that requires fast calculations, it may require the central processing unit to have a high main frequency and multi-core processing capabilities, then the resource performance lower limit value will specify the minimum main frequency and the number of cores of the central processing unit. For a task that needs to process a large amount of graphic data, the resource performance lower limit value may specify the minimum video memory capacity and bandwidth of the graphics processing unit. By extracting these adaptability requirement parameters, the specific requirements of the task unit for computing resources can be accurately understood.
[0087] Step S1442: Obtain the resource type identifier and the current resource performance value of the candidate computing resources, where the resource type identifier corresponds to a central processing unit, a graphics processing unit, or a dedicated computing chip.
[0088] When performing resource matching, relevant information of the candidate computing resources needs to be obtained. The candidate computing resources are the resources that may be allocated to the task unit according to the matching rules. The resource type identifier is used to clarify the type of the candidate computing resources, which corresponds to a central processing unit, a graphics processing unit, or a dedicated computing chip. Through the resource type identifier, it can be quickly determined whether the candidate computing resource meets the resource type adaptation requirements of the task unit.
[0089] The current resource performance value is the performance index currently possessed by the candidate computing resources. For the central processing unit, the current resource performance value may include the remaining number of computing cores, the current main frequency, etc.; for the graphics processing unit, the current resource performance value may include the remaining video memory capacity, video memory bandwidth, etc.; for the dedicated computing chip, the current resource performance value may include the remaining processing bandwidth, computing speed, etc. Obtaining these current resource performance values can accurately understand the actual available performance of the candidate computing resources for comparison with the resource performance lower limit value of the task unit.
[0090] Step S1443: Determine whether the resource type identifier of the candidate computing resource is consistent with the resource type adaptation identifier of the resource requirement characteristics.
[0091] This is the first step of resource adaptability check. Compare the resource type identifier of the candidate computing resource with the resource type adaptation identifier in the resource requirement characteristics of the computing task unit to be scheduled. If the two are consistent, it means that the candidate computing resource meets the requirements of the task unit in terms of type and may be allocated to the task unit; if they are inconsistent, it means that the candidate computing resource is not suitable for the task unit and other candidate resources need to be reselected. For example, if the resource type adaptation identifier of the task unit is a graphics processor resource, while the resource type identifier of the candidate computing resource is a central processing unit resource, then the candidate computing resource does not meet the requirements and other suitable resources need to be continued to be searched.
[0092] Step S1444: If they are consistent, further determine whether the current value of the resource performance of the candidate computing resource is greater than or equal to the lower limit value of the resource performance of the resource requirement characteristics.
[0093] When the resource type identifier of the candidate computing resource is consistent with the resource type adaptation identifier of the resource requirement characteristics, it is also necessary to further check whether the resource performance meets the requirements. Compare the current value of the resource performance of the candidate computing resource with the lower limit value of the resource performance of the task unit. If the current value of the resource performance of the candidate computing resource is greater than or equal to the lower limit value of the resource performance, it means that the candidate computing resource can meet the minimum requirements of the task unit in terms of performance; if it is less than the lower limit value of the resource performance, it means that although the candidate computing resource is suitable in type, its performance is insufficient and it cannot be allocated to the task unit, and other resources also need to be reselected. For example, if the lower limit value requirement for the video memory capacity of the graphics processor by the task unit is a certain value, and the current remaining video memory capacity of the candidate graphics processor is less than this lower limit value, then the candidate graphics processor cannot be allocated to the task unit.
[0094] Step S1445: If both are satisfied, determine that the candidate computing resource meets the adaptability requirements of the resource requirement characteristics, allocate the candidate computing resource to the computing task unit to be scheduled, and update the current available resource information of the numerical control machining system.
[0095] When the resource type identifier of the candidate computing resource is consistent with the resource type adaptation identifier of the resource requirement characteristics, and the current value of the resource performance of the candidate computing resource is greater than or equal to the lower limit value of the resource performance of the resource requirement characteristics, it is determined that the candidate computing resource meets the adaptability requirements of the resource requirement characteristics. At this time, allocate the candidate computing resource to the computing task unit to be scheduled.
[0096] Meanwhile, it is necessary to update the information on the currently available resources of the numerical control processing system. Since the resources have been allocated to the task units, the corresponding resource quantities will decrease. For example, if a computing core of a central processing unit is allocated to a certain task unit, the remaining number of computing cores of the central processing unit needs to be reduced accordingly; if a part of the video memory of a graphics processing unit is allocated to a task unit, the remaining video memory capacity of the graphics processing unit also needs to be updated. By updating the currently available resource information in a timely manner, it can be ensured that the subsequent resource matching process is based on the accurate resource status.
[0097] Step S145: Record the allocated resource types and resource occupancies of each computing task unit to be scheduled, and generate an initial scheduling plan containing the correspondence between task units and computing resources.
[0098] After the resource allocation for each computing task unit to be scheduled is completed, it is necessary to record the allocated resource types and resource occupancies of each task unit. The allocated resource type clarifies whether the task unit is allocated central processing unit resources, graphics processing unit resources, or dedicated computing chip resources; the resource occupancy records the specific quantity of the resource occupied by the task unit, such as the number of computing cores of the central processing unit occupied, the video memory capacity of the graphics processing unit occupied, etc.
[0099] Organize and summarize the recorded information to form an initial scheduling plan containing the correspondence between task units and computing resources. This initial scheduling plan shows the correspondence between each computing task unit to be scheduled and the allocated computing resources, providing clear guidance for subsequent task execution. For example, the initial scheduling plan may indicate that a certain task unit is allocated several computing cores of the central processing unit and a certain video memory capacity of the graphics processing unit, as well as the allocation situations of other task units and computing resources.
[0100] Step S150: Based on the task execution status information fed back in real time, perform an adaptive adjustment process on the initial scheduling plan to generate a final scheduling plan containing the task unit execution order and resource allocation parameters.
[0101] Step S151: Obtain the real-time execution status information of the task units that have been started and executed in the initial scheduling plan, and the real-time execution status information includes the actual execution progress and resource occupancy of the task units.
[0102] After the initial scheduling plan starts to be executed, it is necessary to obtain the real-time execution status information of the task units that have been started and executed. The real-time execution status information is important data reflecting the current execution situation of the task units. The actual execution progress represents the proportion of the workload completed by the task unit at the current moment to the total workload. For example, for a task of optimizing part processing parameters, the actual execution progress may represent the proportion of the parameter calculation steps completed to the total calculation steps.
[0103] The resource occupancy is the amount of computing resources actually occupied by a task unit during its execution. Such as the number of CPU computing cores actually occupied by a task unit during its execution, the video memory capacity of a graphics processing unit, etc. By obtaining this real-time execution status information, the actual execution situation of the task unit can be accurately understood.
[0104] Step S152: Calculate the deviation value between the actual execution progress and the planned execution progress of the task unit, where the planned execution progress is determined by the execution order and time arrangement of the initial scheduling plan.
[0105] The planned execution progress is determined according to the execution order and time arrangement of the initial scheduling plan. In the initial scheduling plan, a predicted execution time and progress arrangement are usually set for each task unit. For example, for a task consisting of multiple steps, the initial scheduling plan may stipulate that a certain proportion of steps should be completed at a certain time point.
[0106] Compare the actual execution progress of the task unit with the planned execution progress, and calculate the deviation value between them. The deviation value can be obtained by subtracting the planned execution progress from the actual execution progress. If the deviation value is positive, it means that the actual execution progress of the task unit is faster than the planned execution progress; if the deviation value is negative, it means that the actual execution progress of the task unit is slower than the planned execution progress. This deviation value can reflect whether the execution of the task unit meets the expectations.
[0107] Step S153: Calculate the deviation value between the actual resource occupancy and the planned resource occupancy of the task unit, where the planned resource occupancy is determined by the resource allocation parameters of the initial scheduling plan.
[0108] The planned resource occupancy is determined according to the resource allocation parameters of the initial scheduling plan. In the initial scheduling plan, a set amount of computing resources is allocated to each task unit, such as the number of CPU computing cores, the video memory capacity of a graphics processing unit, etc., and these allocated resource amounts are the planned resource occupancy.
[0109] Compare the actual resource occupancy of the task unit with the planned resource occupancy, and calculate the deviation value between them. The deviation value can be obtained by subtracting the planned resource occupancy from the actual resource occupancy. If the deviation value is positive, it means that the actual resource amount occupied by the task unit exceeds the planned resource occupancy; if the deviation value is negative, it means that the actual resource amount occupied by the task unit is less than the planned resource occupancy. This deviation value can reflect whether the task unit meets the expectations in terms of resource usage.
[0110] Step S154: Evaluate the execution effect of the initial scheduling plan according to the progress deviation value and the resource occupancy deviation value. If the progress deviation value or the resource occupancy deviation value exceeds the corresponding preset threshold, trigger the adjustment mechanism.
[0111] To evaluate the execution effect of the initial scheduling plan, it is necessary to comprehensively consider the progress deviation value and the resource occupancy deviation value. The preset threshold is a criterion set in advance to judge whether the execution effect of the scheduling plan is good. The progress deviation threshold represents the maximum allowable progress deviation, and the resource occupancy deviation threshold represents the maximum allowable resource occupancy deviation.
[0112] Compare the progress deviation value and the resource occupancy deviation value with the corresponding preset thresholds respectively. First, perform an absolute value calculation on the progress deviation value to obtain the absolute progress deviation; perform an absolute value calculation on the resource occupancy deviation value to obtain the absolute resource occupancy deviation. This is because the deviation value may be positive or negative, and we are concerned about the magnitude of the deviation, so we take the absolute value.
[0113] Judge whether the absolute progress deviation is greater than the progress deviation threshold, or whether the absolute resource occupancy deviation is greater than the resource occupancy deviation threshold. If either condition is met, it means that the execution effect of the initial scheduling plan does not meet the requirements, and there may be problems such as too slow task execution progress or unreasonable resource usage. At this time, trigger the adjustment mechanism; if neither condition is met, it means that both the execution progress of the task unit and the resource usage situation are within the acceptable range, and retain the initial scheduling plan as the final scheduling plan.
[0114] For example, Step S1541: Perform an absolute value calculation on the progress deviation value to obtain the absolute progress deviation.
[0115] After obtaining the progress deviation value, since the deviation value may be positive or negative, and when evaluating the execution effect of the initial scheduling plan, we are concerned about the magnitude of the deviation rather than the direction of the deviation, so it is necessary to perform an absolute value calculation on the progress deviation value. The absolute value calculation can be simply understood as follows: if the progress deviation value is positive, the value remains unchanged; if the progress deviation value is negative, it is changed to the corresponding positive number. Through the above processing, the absolute progress deviation obtained can accurately reflect the deviation degree between the actual execution progress and the planned execution progress of the task unit.
[0116] For example, for a certain task unit of the scheduling calculation to be performed, its progress deviation value may be due to some unexpected situations encountered during the actual execution process, such as data acquisition delay or some minor failures during the calculation process, resulting in the execution progress being slower than the planned progress, and the progress deviation value is negative; it may also be that the actual execution efficiency of the task unit is higher than expected, and the progress deviation value is positive. In either case, taking the absolute value can intuitively reflect the deviation amplitude of the progress.
[0117] Step S1542: Perform an absolute value calculation process on the resource occupancy deviation value to obtain the absolute value of the resource occupancy deviation.
[0118] Similar to the schedule deviation value, the resource occupancy deviation value can also be positive or negative. A positive resource occupancy deviation value indicates that the actual amount of resources occupied by the task unit exceeds the planned resource occupancy. This may mean that the resource requirements during the task execution exceed expectations, perhaps the task complexity is higher than expected, or the resource allocation is not reasonable enough; a negative resource occupancy deviation value indicates that the actual amount of resources occupied by the task unit is less than the planned resource occupancy, which may be that the task execution is smoother than expected, or the resource allocation is excessive.
[0119] To evaluate the deviation degree of resource usage, it is necessary to perform an absolute value calculation process on the resource occupancy deviation value. Similarly, if the resource occupancy deviation value is positive, its absolute value is the value itself; if it is negative, it is changed to the corresponding positive number. The obtained absolute value of the resource occupancy deviation can clearly show the gap between the actual resource occupancy of the task unit and the planned resource occupancy.
[0120] Step S1543: Obtain a preset schedule deviation threshold and a resource occupancy deviation threshold. The schedule deviation threshold represents the maximum allowable schedule deviation, and the resource occupancy deviation threshold represents the maximum allowable resource occupancy deviation.
[0121] The preset schedule deviation threshold and resource occupancy deviation threshold are pre-set measurement criteria for judging whether the execution effect of the initial scheduling scheme is within an acceptable range. The schedule deviation threshold is determined based on factors such as the nature and importance of the task and the time arrangement of the entire production process. For some tasks with very strict time requirements, the schedule deviation threshold may be set smaller because even a small schedule deviation may affect subsequent production links; while for some tasks with relatively loose time requirements, the schedule deviation threshold can be set appropriately larger.
[0122] The resource occupancy deviation threshold is set based on factors such as the availability, cost of resources, and the dependence of the task on resources. If a certain resource is scarce or has a high cost, then the resource occupancy deviation threshold may be set smaller to ensure the reasonable use of resources; on the contrary, if the resources are relatively abundant, the resource occupancy deviation threshold can be appropriately relaxed.
[0123] The process of obtaining these preset thresholds can be to read from a pre-stored configuration file or to query from a database. These thresholds are important bases for subsequent judgment on whether to trigger the adjustment mechanism.
[0124] Step S1544: Determine whether the absolute value of the progress deviation is greater than the progress deviation threshold, or whether the absolute value of the resource occupancy deviation is greater than the resource occupancy deviation threshold.
[0125] After obtaining the absolute value of the progress deviation, the absolute value of the resource occupancy deviation, and the corresponding preset thresholds, a judgment operation needs to be performed. This judgment process is a key step in evaluating the execution effect of the initial scheduling plan. The absolute value of the progress deviation is compared with the progress deviation threshold respectively, and the absolute value of the resource occupancy deviation is compared with the resource occupancy deviation threshold.
[0126] As long as either of the two conditions that the absolute value of the progress deviation is greater than the progress deviation threshold or the absolute value of the resource occupancy deviation is greater than the resource occupancy deviation threshold holds, it indicates that there are major problems in the execution of the initial scheduling plan. It may be that the task execution progress lags seriously, affecting the time arrangement of the entire production process; or it may be that the use of resources exceeds the reasonable range, resulting in waste of resources or shortage of resources for other tasks.
[0127] Step S1545: If either condition holds, determine that the execution effect of the initial scheduling plan does not meet the requirements, and trigger the adjustment mechanism; if neither holds, retain the initial scheduling plan as the final scheduling plan.
[0128] If in the judgment of step S1544, the absolute value of the progress deviation is greater than the progress deviation threshold or the absolute value of the resource occupancy deviation is greater than the resource occupancy deviation threshold, then it is determined that the execution effect of the initial scheduling plan does not meet the requirements. At this time, it is necessary to trigger the adjustment mechanism to optimize the scheduling plan. The adjustment mechanism can include operations such as re-evaluating the priorities of task units and reallocating resources to ensure that tasks can be executed according to the expected progress and resources can be reasonably utilized.
[0129] On the contrary, if the absolute value of the progress deviation is less than or equal to the progress deviation threshold, and the absolute value of the resource occupancy deviation is less than or equal to the resource occupancy deviation threshold, it indicates that the execution effect of the initial scheduling plan is good, and the execution progress of the task and the resource usage situation are within the acceptable range. In this case, retain the initial scheduling plan as the final scheduling plan, and the task can continue to be executed according to this plan.
[0130] Step S155: For the task units that trigger the adjustment mechanism, re-evaluate their processing complexity characteristics and resource requirement characteristics, call the task priority evaluation model to regenerate the priority sequence, and based on the updated current available resource information, re-perform the dynamic matching process of tasks and resources to generate the adjusted scheduling plan as the final scheduling plan.
[0131] After the adjustment mechanism is triggered, it is first necessary to re-evaluate the processing complexity characteristics and resource requirement characteristics of the task units involved. Since some changes may occur during the execution of the task, for example, the originally expected amount of computation may change due to data changes or algorithm optimizations, which will lead to changes in the processing complexity characteristics; at the same time, the resource usage situation may also be different from the initial estimate, and the resource requirement characteristics need to be re-determined.
[0132] When re-evaluating the processing complexity characteristics, again follow the previous method to parse the processing technology type information of the task unit, extract the algorithm execution process information, count the total number of operation nodes, calculate the data transfer volume between adjacent nodes, perform weighted processing and linear combination to obtain the new processing complexity characteristics. For the resource requirement characteristics, re-classify the real-time constraint identifiers, identify the resource type adaptation rules, and extract the new adaptability requirement parameters.
[0133] Input the re-evaluated processing complexity characteristics and resource requirement characteristics into the task priority evaluation model. The task priority evaluation model will process these characteristics again. Through the fully connected neural network in the feature input layer, it performs non-linear transformation to generate a fused feature vector. The time perception layer extracts the context information in the time dimension to generate a time series enhanced feature vector. The attention mechanism module assigns attention weights, performs weighted aggregation processing to generate a priority evaluation feature vector, and finally the sorting output layer calculates the priority score value and generates a new priority sequence.
[0134] Based on the updated current available resource information, that is, the resource information that has changed during resource allocation and task execution, re-perform the dynamic matching process of tasks and resources. According to the new priority sequence, match computing resources for each task unit in turn, check the adaptability of the resource requirement characteristics and the candidate computing resources, complete resource allocation, and record the allocated resource type and resource occupancy of each task unit. The finally generated adjusted scheduling plan is the final scheduling plan that meets the current task execution requirements.
[0135] The construction and training process of the task priority evaluation model is introduced as follows.
[0136] The task priority evaluation model mainly consists of a feature input layer, a time perception layer, an attention mechanism module, and a sorting output layer.
[0137] The feature input layer is the entrance of the model, which receives and processes the complexity features and resource requirement features as inputs. It adopts a fully connected neural network structure, where each neuron in the fully connected neural network is connected to all neurons in the previous layer. Its role is to perform a non-linear transformation on the input features, fuse different types of features, and generate a fused feature vector. When constructing the feature input layer, the number of neurons needs to be determined, which can be decided according to the dimension of the input features and the complexity of the model. Generally speaking, the more neurons, the stronger the expressive ability of the model, but it will also increase the computational amount and training time.
[0138] The time perception layer contains a long short-term memory network (LSTM) module, which is used to extract the context information of the fused feature vector in the time dimension. The LSTM module performs selective memory and forgetting processing on the historical feature information through memory gates, input gates, and output gates. The memory gate controls whether the hidden state information of the previous moment is passed to the current moment, the input gate determines whether the current input feature information is added to the cell state of the current moment, and the output gate controls whether the cell state information of the current moment is output to the hidden state. Through the above mechanism, the LSTM module can capture the long-term dependence relationship of the feature vector in the time dimension. When constructing the time perception layer, the number of LSTM units needs to be determined, which will affect the model's processing ability for time series information.
[0139] The role of the attention mechanism module is to respectively assign attention weights to the complexity features and resource requirement features in the time-series enhanced feature vector. The attention weights reflect the influence degree of each feature on the priority evaluation. When constructing the attention mechanism module, a suitable attention calculation method needs to be designed. For example, the time-series enhanced feature vector can be mapped to a low-dimensional space through a fully connected layer, then the attention scores are calculated, and the scores are converted into weights through the softmax function.
[0140] The sorting output layer is used to calculate the sorting scores for the priority evaluation feature vector, generate the priority score value for each task unit to be scheduled for calculation, and generate a priority sequence according to the size relationship of the score values. The sorting output layer can adopt a simple fully connected layer to map the priority evaluation feature vector to a one-dimensional space to obtain the priority score value.
[0141] During the model training process, a large amount of historical task data needs to be collected, including the processing complexity features, resource requirement features, real-time constraint identifiers, and the final priority sorting results of each task unit. These data are divided into a training set, a validation set, and a test set. The training set is used for the parameter learning of the model, the validation set is used to adjust the hyperparameters of the model during the training process, and the test set is used to evaluate the final performance of the model.
[0142] Moreover, it is necessary to determine the parameters required for training, such as the learning rate, batch size, number of training epochs, etc. The learning rate controls the step size of model parameter updates. An overly large learning rate may cause the model to fail to converge, while an overly small learning rate will slow down the training speed. The batch size refers to the number of data samples used in each training. A larger batch size can improve the stability of training but increases the memory requirement. The number of training epochs indicates the number of times the model trains on the entire training set. Too many training epochs may lead to overfitting of the model, while too few training epochs may cause the model to fail to fully learn the features of the data.
[0143] Thus, the data in the training set can be input into the task priority evaluation model and processed sequentially according to the structure of the task priority evaluation model. In each training epoch, calculate the loss between the output result of the model and the true priority ranking result. The loss function can use cross-entropy loss or other loss functions suitable for ranking tasks. Through the backpropagation algorithm, update the model parameters according to the gradient of the loss function, so that the output result of the model gradually approaches the true result.
[0144] During the training process, regularly evaluate the model using the validation set and adjust the hyperparameters of the model, such as the learning rate, according to the performance of the validation set. Stop training when the number of training epochs reaches the preset value or the performance of the validation set no longer improves.
[0145] Finally, evaluate the trained task priority evaluation model using the test set, and calculate the evaluation metrics of the task priority evaluation model on the test set, such as ranking accuracy, average ranking error, etc. The evaluation metrics can reflect the performance of the task priority evaluation model on unknown data. If the evaluation metrics meet the expected requirements, it is considered that the task priority evaluation model is successfully trained and can be used for actual task priority evaluation.
[0146] During the data collection process, some privacy-sensitive data may be involved, such as the key parameters of some production processes associated with task units. To protect this privacy-sensitive data, encrypt the privacy-sensitive data during the data collection phase. A symmetric encryption algorithm, such as the AES algorithm, can be used to generate an encryption key, and perform an encryption operation on the privacy-sensitive data and the encryption key to obtain the encrypted data. Use the encrypted data during both data storage and transmission. Only when these data need to be used, use the corresponding decryption key for decryption. Moreover, establish a strict access control mechanism to restrict access to privacy-sensitive data. Only authorized personnel or system components can access these data. Access control can be achieved through user authentication, role-based permission management, etc. For example, assign different roles to different users, and each role has different access permissions. Only the roles with the corresponding permissions can access privacy-sensitive data.
[0147] Figure 2 FIG. shows a schematic diagram of exemplary hardware and software components of a computing task scheduling system 100 applicable to a numerical control machining system that can implement the idea of the present application. For example, the processor 120 can be used on the computing task scheduling system 100 applicable to the numerical control machining system and is used to execute the functions in the present application.
[0148] The computing task scheduling system 100 applicable to the numerical control machining system can be a general-purpose server or a special-purpose server, both of which can be used to implement the computing task scheduling method applicable to the numerical control machining system of the present application. Although only one server is shown in the present application, for convenience, the functions described in the present application can be implemented in a distributed manner on multiple similar platforms to balance the processing load.
[0149] For example, the computing task scheduling system 100 applicable to the numerical control machining system can include a network port 110 connected to the network, one or more processors 120 for executing program instructions, a communication bus 130, and different forms of storage media 140, such as disks, ROM, or RAM, or any combination thereof. Exemplarily, the computing task scheduling system 100 applicable to the numerical control machining system can also include program instructions stored in ROM, RAM, or other types of non-transitory storage media, or any combination thereof. The method of the present application can be implemented according to these program instructions. The computing task scheduling system 100 applicable to the numerical control machining system also includes an I / O interface 150 between the computer and other input / output devices.
[0150] For ease of explanation, only one processor is described in the computing task scheduling system 100 applicable to the numerical control machining system. However, it should be noted that the computing task scheduling system 100 applicable to the numerical control machining system in the present application can also include multiple processors. Therefore, the steps performed by one processor described in the present application can also be jointly executed or separately executed by multiple processors. For example, if the processor of the computing task scheduling system 100 applicable to the numerical control machining system executes steps A and B, it should be understood that steps A and B can also be jointly executed by two different processors or separately executed in one processor. For example, the first processor executes step A, the second processor executes step B, or the first processor and the second processor jointly execute steps A and B.
[0151] In addition, an embodiment of the present invention also provides a readable storage medium, in which computer-executable instructions are preset. When the processor executes the computer-executable instructions, the above-mentioned computing task scheduling method applicable to the numerical control machining system is implemented.
[0152] It should be noted that, in order to simplify the description of the present invention disclosed and thus help the understanding of one or more embodiments of the invention, in the foregoing description of the embodiments of the present invention, sometimes multiple features are merged into one embodiment, drawing or description thereof.
Claims
1. A calculation task scheduling method applied to a numerical control processing system, characterized in that, The method includes: Obtaining a task request set of a numerical control processing system, where the task request set contains multiple to-be-scheduled calculation task units, and each to-be-scheduled calculation task unit is associated with processing technology type information and a real-time constraint identifier; Performing task feature extraction processing on the task request set to obtain a processing complexity feature and a resource requirement feature of each to-be-scheduled calculation task unit, where the processing complexity feature reflects the computational scale of the task unit, and the resource requirement feature reflects the adaptability requirement of the task unit for the type of computing resources; Invoking a pre-constructed task priority evaluation model to perform joint priority evaluation processing on the processing complexity feature and the resource requirement feature, and generating a priority sequence including the priority ranking of task units; According to the priority sequence and the current available resource information of the numerical control processing system, performing dynamic matching processing of tasks and resources to generate an initial scheduling plan including the corresponding relationship between task units and computing resources; Based on the task execution status information fed back in real time, performing adaptive adjustment processing on the initial scheduling plan to generate a final scheduling plan including the execution order of task units and resource allocation parameters; The performing task feature extraction processing on the task request set to obtain a processing complexity feature and a resource requirement feature of each to-be-scheduled calculation task unit includes: Performing parsing processing on the processing technology type information of each to-be-scheduled calculation task unit in the task request set, and extracting the algorithm execution process information corresponding to the processing technology type; According to the number of operation nodes and the amount of data transfer between nodes in the algorithm execution process information, calculating the computational scale parameter of the to-be-scheduled calculation task unit as the processing complexity feature; Performing classification processing on the real-time constraint identifier of each to-be-scheduled calculation task unit in the task request set, and identifying the resource type adaptation rule corresponding to the real-time constraint identifier; Based on the resource type adaptation rule, extracting the adaptability requirement parameter of the to-be-scheduled calculation task unit for central processing unit resources, graphics processing unit resources or dedicated computing chip resources as the resource requirement feature; Inputting the processing complexity feature and the resource requirement feature into a feature normalization module, and performing standardization processing on the feature parameters with different dimensions through a linear scaling method to obtain a target feature set with a unified numerical range.
2. The calculation task scheduling method applied to a numerical control machining system according to claim 1, characterized in that, The performing parsing processing on the processing technology type information of each to-be-scheduled calculation task unit in the task request set, and extracting the algorithm execution process information corresponding to the processing technology type includes: Obtaining a process knowledge base corresponding to the processing technology type information, where the process knowledge base stores the mapping relationship between different processing technology types and algorithm execution processes; Querying the process knowledge base according to the processing technology type information, and extracting the algorithm execution process description document matching the processing technology type; Performing semantic parsing processing on the algorithm execution process description document to identify the data input node, intermediate calculation node and result output node in the process; Extract the operation type identifier of each node and the data transfer path information between nodes. The operation type identifier includes numerical calculation operation, geometric modeling operation, or path planning operation; Based on the operation type identifier and data transfer path information of the nodes, construct the topological graph of the algorithm execution process of the to-be-scheduled calculation task unit.
3. The calculation task scheduling method applied to a numerical control machining system according to claim 2, wherein, The calculation of the computational scale parameter of the to-be-scheduled calculation task unit as the processing complexity feature according to the number of operation nodes and the data transfer volume between nodes in the algorithm execution process information includes: Count the total number of operation nodes in the topological graph of the algorithm execution process. The total number of operation nodes reflects the number of calculation steps of the task unit; Calculate the data transfer volume between adjacent nodes in the topological graph of the algorithm execution process. The data transfer volume is determined by the product of the output data dimension of the previous node and the input data dimension of the subsequent node; Perform weighted processing on the total number of operation nodes to obtain the weighted total number of operation nodes. The weight coefficient is determined by the operation type identifier corresponding to the node. The weight coefficient of the numerical calculation operation node is greater than that of the geometric modeling operation node; Perform cumulative summation processing on the data transfer volume to obtain the total data transfer volume parameter of the to-be-scheduled calculation task unit; Perform linear combination processing on the weighted total number of operation nodes and the total data transfer volume parameter to generate the computational scale parameter of the to-be-scheduled calculation task unit as the processing complexity feature.
4. The computational task scheduling method applied to a numerical control machining system according to claim 1, wherein, The invocation of the pre-constructed task priority evaluation model to perform joint priority evaluation processing on the processing complexity feature and the resource requirement feature, and generate a priority sequence including the priority ranking of task units, includes: Input the processing complexity feature and the resource requirement feature into the feature input layer of the task priority evaluation model, and perform non-linear transformation processing on the features through a fully connected neural network to generate a fused feature vector; Through the time perception layer of the task priority evaluation model, perform context information extraction processing on the fused feature vector in the time dimension to generate a time-series enhanced feature vector containing real-time constraint information; Use the attention mechanism module of the task priority evaluation model to assign attention weights to the processing complexity feature and the resource requirement feature in the time-series enhanced feature vector respectively. The attention weight reflects the influence degree of the feature on the priority evaluation; Perform weighted aggregation processing on the time-series enhanced feature vector based on the attention weight to generate a priority evaluation feature vector; Invoke the sorting output layer of the task priority evaluation model to perform sorting score calculation processing on the priority evaluation feature vector, generate the priority score value of each to-be-scheduled calculation task unit, and generate a priority sequence according to the magnitude relationship of the priority score values.
5. The calculation task scheduling method applied to a numerical control processing system according to claim 4, characterized in that The process of performing context information extraction processing on the fused feature vector in the time dimension through the time perception layer of the task priority evaluation model to generate a time-series enhanced feature vector containing real-time constraint information includes: Input the fused feature vector into the long short-term memory network module of the time perception layer, and perform selective memory and forgetting processing on the historical feature information through the memory gate, input gate, and output gate; Extract the hidden state vector output by the long short-term memory network module, and the hidden state vector contains the context information of the fused feature vector at historical time steps; Obtain the time threshold parameter corresponding to the real-time constraint identifier of the to-be-scheduled computing task unit, and the time threshold parameter represents the maximum execution delay allowed for the task unit; Concatenate the time threshold parameter and the hidden state vector to generate a joint feature vector containing time constraint information; Perform normalization processing on the joint feature vector to eliminate the dimensional difference between the time threshold parameter and the hidden state vector, and generate a time-series enhanced feature vector containing real-time constraint information.
6. The calculation task scheduling method applied to a numerical control machining system according to claim 1, wherein, The dynamic matching process of tasks and resources according to the priority sequence and the current available resource information of the numerical control machining system to generate an initial scheduling plan including the correspondence between task units and computing resources includes: Parse the priority sequence to determine the priority order of each to-be-scheduled computing task unit; Obtain the current available resource information of the numerical control machining system, and the current available resource information includes the remaining computing cores of the central processing unit, the remaining video memory capacity of the graphics processing unit, and the remaining processing bandwidth of the dedicated computing chip; Match computing resources for each to-be-scheduled computing task unit in sequence according to the priority order, and the matching rules include: giving priority to allocating dedicated computing chip resources to high-priority task units, secondarily allocating graphics processing unit resources, and finally allocating central processing unit resources; During the matching process, check the adaptability between the resource requirement characteristics of the to-be-scheduled computing task unit and the candidate computing resources. If the candidate computing resources meet the adaptability requirements of the resource requirement characteristics, the resource allocation is completed; Record the allocated resource type and resource occupancy of each to-be-scheduled computing task unit to generate an initial scheduling plan including the correspondence between task units and computing resources.
7. The computational task scheduling method applied to a numerical control machining system according to claim 6, characterized in that, The step of checking the adaptability between the resource requirement characteristics of the to-be-scheduled computing task unit and the candidate computing resources during the matching process. If the candidate computing resources meet the adaptability requirements of the resource requirement characteristics, the resource allocation is completed includes: Extract the adaptability requirement parameters in the resource requirement characteristics of the to-be-scheduled computing task unit, and the adaptability requirement parameters include the resource type adaptability identifier and the resource performance lower limit value; Obtain the resource type identifier and the current resource performance value of the candidate computing resources, and the resource type identifier corresponds to the central processing unit, the graphics processing unit, or the dedicated computing chip; Judge whether the resource type identifier of the candidate computing resources is consistent with the resource type adaptability identifier of the resource requirement characteristics; If they are consistent, further judge whether the current resource performance value of the candidate computing resources is greater than or equal to the resource performance lower limit value of the resource requirement characteristics; If all are satisfied, it is determined that the candidate computing resource meets the adaptability requirements of the resource demand characteristics, the candidate computing resource is allocated to the to-be-scheduled computing task unit, and the current available resource information of the numerical control machining system is updated.
8. The calculation task scheduling method applied to the numerical control processing system according to claim 1, wherein, Performing an adaptive adjustment process on the initial scheduling plan based on the real-time feedback task execution status information to generate a final scheduling plan including the task unit execution order and resource allocation parameters, including: Obtaining the real-time execution status information of the task units that have been started and executed in the initial scheduling plan, where the real-time execution status information includes the actual execution progress and resource occupancy of the task units; Calculating the progress deviation value between the actual execution progress and the planned execution progress of the task unit, where the planned execution progress is determined by the execution order and time arrangement of the initial scheduling plan; Calculating the resource occupancy deviation value between the actual resource occupancy and the planned resource occupancy of the task unit, where the planned resource occupancy is determined by the resource allocation parameters of the initial scheduling plan; Evaluating the execution effect of the initial scheduling plan according to the progress deviation value and the resource occupancy deviation value. If the progress deviation value or the resource occupancy deviation value exceeds the corresponding preset threshold, a adjustment mechanism is triggered; For the task units for which the adjustment mechanism is triggered, re-evaluate their processing complexity characteristics and resource demand characteristics, call the task priority evaluation model to regenerate the priority sequence, and re-perform the dynamic matching process of tasks and resources based on the updated current available resource information, and generate an adjusted scheduling plan as the final scheduling plan.
9. A computing task scheduling system applied to a numerical control processing system, characterized in that, Including a processor and a memory, the memory is connected to the processor, the memory is used to store programs, instructions or codes, and the processor is used to execute the programs, instructions or codes in the memory to implement the computing task scheduling method applied to the numerical control machining system according to any one of claims 1-8 above.
Citation Information
Patent Citations
Optimized scheduling method and system for hardware mold production process
CN119272932A
Intelligent manufacturing-oriented digital workshop production process management platform
CN119849878A
Self-adaptive task scheduling system and method
CN120144257A
Multi-line cooperative scheduling method and device based on artificial intelligence
CN120179366A
Cited By
Large model reasoning optimization method and system for operation and maintenance technology service
CN120729803A
Large-scale model inference optimization method and system for operation and maintenance technical services
CN120729803B
Intelligent scheduling system and method for multi-station numerical control machining equipment
CN120941074A
Parallel processing scheduling method and system of multi-station laser cutting machine and medium
CN121165671A
Running analysis method and system for CAD (Computer Aided Design) path-finding algorithm connection program
CN121257049A