Emerging Workflow Classification Methods Based on Composite Embedded Graph Transformers
By combining the embedding graph Transformer method, the features of task nodes and dependency edges are learned, which solves the problem that task priorities and dependencies are not captured in emerging application workflows, and achieves higher-precision workflow classification, which is suitable for resource allocation and task scheduling in cloud computing environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-07
- Publication Date
- 2026-04-07
AI Technical Summary
Existing technologies have failed to effectively capture the priorities and dependencies between tasks in emerging application workflow classification, resulting in poor classification performance, especially in graph structures where the correlation between nodes and the feature information of edges are not fully utilized.
We employ a combined embedding graph Transformer-based approach, which learns the features of task nodes and dependency edges through Graph Transformer layers and feedforward neural networks. By combining multi-head self-attention mechanism and Laplacian matrix encoding, we enhance the model's ability to model workflow structure and task dependencies.
It improves the classification accuracy of emerging application workflows, accurately classifies different task storage and computing types, enhances the model's learning ability, and is suitable for complex resource allocation and task scheduling in cloud computing environments.
Smart Images

Figure CN117171411B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of cloud computing technology, and in particular to an emerging application workflow classification method based on a combined embedded graph Transformer. Background Technology
[0002] Emerging applications have highly dynamic workflow resource requirements, complex in-memory computing resource topologies, and dynamic and diverse in-memory computing requirements, which brings new challenges to the resource allocation and task scheduling optimization of cloud computing systems.
[0003] Emerging application workflows consist of numerous tasks, including data and control dependencies, and can be represented by a Directed Acyclic Graph (DAG). Emerging application workflows are commonly used for modeling scientific computing applications such as facial recognition workflows, healthcare application workflows, web search workflows, DNA sequence analysis workflows, and service delivery workflows. However, these different types of emerging application workflows have their own characteristics in terms of structure, number of tasks, communication, and computational requirements. To meet users' Quality of Service (QoS) requirements, such as total execution time (makespan) and cost, different workflows need to be classified. Many machine learning-based algorithms have been proposed to achieve high-performance workflow classification, including Naive Bayes, K-Means, and Support Vector Machines. Zhang et al. designed a Bayesian classifier that matches tasks with the most suitable virtual machines based on historical scheduling data to save task execution costs, improve virtual machine utilization, and reduce task scheduling failure rates. Marahatta et al. proposed a dynamic task scheduling scheme for providing resources in virtualized cloud data centers to maximize resource utilization and minimize energy consumption. This algorithm designs a task classification method based on the matching characteristics of tasks and virtual machines, matching tasks with the most suitable virtual machines. Ullah and Youn et al. studied the efficient allocation of tasks on nodes in edge computing and developed a task classification and scheduling scheme based on K-means clustering to classify tasks based on their requirements for different types of resources (e.g., CPU, I / O, or COMM) and assign tasks to the best-matching nodes. Zuo et al. studied an interleaved peak scheduling method based on task classification to improve load balancing and resource utilization in cloud computing. This method first divides tasks into three categories: CPU-intensive, I / O-intensive, and memory-intensive, based on the proportion of CPU, I / O, and memory requirements of each task. Then, it allocates tasks according to the task type and the resource configuration of the VMs.
[0004] Machine learning-based algorithms have certain advantages in achieving high-performance workflow classification, but they require manual selection of feature values, and the classification effect of machine learning algorithms deteriorates as the amount and depth of data increase.
[0005] Existing workflow classification methods are designed for independent tasks, neglecting the priority and dependencies between tasks. However, in workflows, the execution order of tasks and their dependencies are crucial factors. Furthermore, among graph neural network-based workflow classification algorithms, graph convolutional neural networks are effective for modeling undirected, unidirectional graphs or networks. However, this method has a limitation: it fails to capture the correlations between nodes in the graph structure well. Additionally, most graph convolutional neural networks do not consider edge features, which can be significant in node classification within a workflow. Summary of the Invention
[0006] The technical problem to be solved by the present invention is to address the shortcomings of the prior art by providing an emerging application workflow classification method based on composite embedded graph Transformer, which achieves better classification performance by improving the ability to model workflow structure and task dependency edges.
[0007] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows:
[0008] An emerging application workflow classification method based on composite embedding graph Transformer includes the following steps:
[0009] Step 1: Set up workflow-related information, including the overall structure of the workflow, task node characteristics, dependency relationships between task nodes, and obtain workflow data;
[0010] Step 2: Feed the workflow data into the model for learning;
[0011] The model consists of multiple identical layers stacked together, each layer comprising two sub-layers: a Graph Transformer layer with directed edge features and a feedforward neural network; the input task nodes and edge embeddings are passed to the Graph Transformer layer to compute position encoding and center encoding;
[0012] Step 3: Learn node features and update the nodes;
[0013] Step 4: Combine node features with dependency edge features;
[0014] At the end of the model, task node embedding and dependency edge embedding are combined, and the information of the two is treated as a whole. The type of a node is determined by the combined operation of task node embedding and dependency edge embedding.
[0015] Step 5: Classify task nodes based on node characteristics.
[0016] Furthermore, the specific method of step 1 is as follows:
[0017] Step 1.1: Define the overall structure of the workflow;
[0018] Let G = {g s |s=1,2,...} represents a set of workflows with various node types, where g s = {T, E} represents a workflow, where T = {t i |i=1,2,...,n} is the workflow g s The task, n is the number of nodes, e ij Represents task t i and t j Dependency edges between them, E = {e ij} is a set of dependency edges, where task t i and t j It represents the relationship between a parent task and a child task, task t. i Depends on task t j In other words, a child task can only be executed after the parent task has been completed; a task without a parent task is the initial task, denoted as t. entry A task without subtasks is the end task, denoted as t. exit ;
[0019] Step 1.2: Define the task node feature vector α i ;
[0020] Workflow task node t i eigenvector α i This includes workflow task execution metrics, specifically: task runtime data size, input and output data size, memory used, CPU utilization, task node type, parent node of the task node, total bytes read, total bytes written, and runtime.
[0021] Step 1.3: Define the feature vector β of the dependency edges between task nodes. ij ;
[0022] For task t i and t j Task t i Depends on task t j , t i and t j The dependency edge between them is defined as e ij ∈E; Task t i After the machine executes the task, it will transmit the generated data to the next task node t.j , where t i The amount of data generated is defined as d i,j ; Feature vector β of the dependency edges between task nodes ij This includes the direction of the edges between task nodes and the amount of data d. i,j ;
[0023] The model considers the direction of edges as a type of dependency edge feature, increasing the number of directed edge channels p to two, encoded as: [e ijp e jip ], representing forward and reverse directions respectively, aggregating node information from these two different types of neighborhoods, including directional information; task node t i To task node t j The directed edge channel is encoded as [1 0], and the task node t j To task node t i The directed edge channel is encoded as [0 1];
[0024] Step 1.4: Obtain workflow data;
[0025] Using Pegasus, a distributed platform based on a workflow management system, we obtain the actual execution logs of scientific workflows to construct workflow instances; using the WfCommons tool, we parse the open-access production workflow instances according to the definitions in steps 1.2 and 1.3 to obtain workflow data represented in JSON format.
[0026] Furthermore, in step 2, the Graph Transformer layer with directed edge features is defined as follows:
[0027] First, the task nodes in the input workflow are processed through three linear mappings and then combined with pre-calculated task node position codes to obtain the representations of queries, keys, and values, respectively. For each query, the similarity between it and all keys in the graph is calculated using a dot product operation, i.e., the query is multiplied by all keys, and then normalized to obtain attention weights. The values are then weighted and summed using these attention weights to obtain the feature representation of each task node; the larger the weight, the greater the influence of the task node on other nodes. The multi-head self-attention mechanism introduces multiple independent attention calculations, each using different queries, keys, and values. Finally, the results of each attention calculation are concatenated and then linearly transformed to obtain the final multi-head attention representation.
[0028] The feedforward neural network includes two layers of linear transformation and an activation function ReLU; the feedforward neural network maps the representation of each position to a higher-dimensional space and then maps it back to the original dimension.
[0029] The features of dependency edges are also incorporated into the learning of node features in the model, and an edge weight matrix W is added when calculating attention. E When a task node t i After multiplication and scaling of the query and key feature projections, an attention score w is obtained. ij Consider it as the attention weight for the edge <i,j>, and the edge feature e. ij Perform a dot product with 0.
[0030] Furthermore, the specific method for passing the input task node and edge embedding to the Graph Transformer layer in step 2 is as follows:
[0031] For each task node t i Having node characteristics For task node t i and task node t j Each edge e between ij With edge features The workflow g will input task node features α i Sum of edge features β ij The data are passed to the d-dimensional hidden features via linear mapping. and In the following two equations:
[0032]
[0033]
[0034] Where, d n d represents the number of node features. e Let A be the number of edge features. 0 B 0 a0 and b0 are the parameters of the linear mapping layer. The linear mapping is achieved by learning trainable parameters, which maps the dimensions of the input task nodes and edges to a low-dimensional representation space for subsequent attention calculation.
[0035] The method for calculating the position code is as follows:
[0036] The eigenvectors obtained by eigenvalue decomposition of the graph's Laplacian matrix are used as positional codes, as shown in the following equation:
[0037] Δ=1-D -1 / 2 AD -1 / 2 =U T ΛU
[0038] Where A is an n×n adjacency matrix, D is the degree matrix, Λ and U correspond to eigenvalues and eigenvectors respectively, and Δ represents the Laplacian matrix; the k smallest nontrivial eigenvectors of the task node are used as the position encoding of the task node, denoted by λ. i This is represented by a linear mapping; then, a pre-computed task node position code of dimension k is embedded and added to the task node hidden features. In the following formula:
[0039] λ i 0 =C 0 λ i +c 0
[0040]
[0041] in, C 0 c 0 These are the parameters of the linear mapping layer; These are the task node features and the position encoding at layer 0, respectively.
[0042] The center code uses the degree of a node as a measure of its importance. The method for calculating the center code is as follows:
[0043] Construct a batch of vectors related to node degrees. Each degree has a vector representation, independent of which specific node it belongs to. Nodes with the same degree have the same center code. This center code is then directly added to the node features as input, as shown in the following formula:
[0044]
[0045] Among them, z - , They are respectively determined by in-degree deg - (v i ) and out-degree deg + (v i The learnable embedding vector specified by ).
[0046] Furthermore, in step 3, the nodes are updated, and the layer update equation for the l-th layer is defined as follows:
[0047]
[0048]
[0049]
[0050]
[0051] Among them, Q k,l K k,l V k,l , These are the weight parameters; k = 1 to H represents the number of attention points; || represents a connection; the output... and Then it is passed to the feedforward neural network, where residual connections and normalization occur beforehand. and The summation is followed by normalization; after passing through the feedforward neural network, there are still residual connections and normalization layers, i.e. and After addition and normalization using Normal, the edge characteristics are the same as described above, as follows:
[0052]
[0053]
[0054]
[0055]
[0056]
[0057]
[0058] in, For weight parameters, This represents a hidden feature.
[0059] Furthermore, in step 4, the combination function for combining task node embedding and dependency edge embedding is as follows:
[0060] h last =φ(t) last ,e last )
[0061] Among them, t last e last These represent task node embedding and dependency edge embedding, respectively. It is a combination of task node embedding and dependency edge embedding; h last This represents the final combined embedding vector;
[0062] The model is embedded using one of the following three combinations:
[0063] Add:φ(t last ,e last )=t last +e last ;
[0064] Multiplication: φ(t) last ,e last )=t last *e last ;
[0065] Concatenation:φ(t last ,e last )=[t last ;e last This combination method is the form of concatenating two vectors.
[0066] Furthermore, in step 5, the node representations obtained in the last layer of the network model are passed to a fully connected neural network to calculate the task classification-related output Z, as shown in the following equation:
[0067] Z = softmax(W) T h last +b)
[0068] Among them, W T b are the parameters of the linear mapping layer.
[0069] The beneficial effects of adopting the above technical solution are as follows: The emerging application workflow classification method based on combined embedding graph Transformer provided by this invention aims to solve the workflow classification problem in cloud computing environments. The classification accuracy for different task computing types is significantly improved. Compared with traditional and existing algorithms, the method proposed in this invention uses a combined embedding approach of task node features and relationship features. The model learns about task nodes and the relationships between them, enhancing the model's learning ability. This allows for the classification of unknown workflow nodes and accurately classifies different task computing types. Attached Figure Description
[0070] Figure 1 This is an example diagram of a workflow containing six tasks provided in an embodiment of the present invention;
[0071] Figure 2 A schematic diagram of workflow data details provided in an embodiment of the present invention;
[0072] Figure 3 This is a schematic diagram of the overall structure of the network model provided in an embodiment of the present invention;
[0073] Figure 4 This is a schematic diagram of a Graph Transformer layer structure with directed edge features provided in an embodiment of the present invention. Detailed Implementation
[0074] The specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and examples. The following examples are for illustrative purposes only and are not intended to limit the scope of the invention.
[0075] To fully consider the priorities and dependencies between tasks, this embodiment designs a workflow classification algorithm suitable for cloud environments, based on the idea of a combined embedding graph Transformer. First, the overall structure of the workflow, the characteristics of task nodes, and the edge features of dependencies between task nodes are clearly defined. Next, a model is constructed that can fuse and learn node features and dependency edge features. By employing different combined embedding methods, task node features and relationship features are combined. After network learning, rich information about workflow task node features and inter-task dependencies is obtained. Finally, this learned information is applied to downstream classification tasks, thus accurately classifying different task types.
[0076] The emerging application workflow classification method based on composite embedded graph Transformer in this embodiment is described in detail below.
[0077] Step 1: Set up workflow-related information.
[0078] Step 1.1: Define the overall structure of the workflow.
[0079] Let G = {g s |s=1,2,...} represents a set of workflows with various node types, where g s = {T, E} represents a workflow, where T = {t i |i=1,2,...,n} is the workflow g s The task, n is the number of nodes, e ij Represents task t i and t j Dependency edges between them, E = {e ij} is a set of dependency edges, where task t i and t j It represents the relationship between a parent task and a child task, task t. i Depends on task t j In other words, a child task can only be executed after the parent task has been completed; a task without a parent task is the initial task, denoted as t. entry A task without subtasks is the end task, denoted as t. exit A simple workflow implementation is as follows: Figure 1 As shown, it consists of six tasks, where t1 is the initial task and t6 is the final task.
[0080] Step 1.2: Define the task node feature vector α i .
[0081] Workflow task node t i eigenvector α i It includes workflow task execution metrics, which include: task runtime data size, input and output data size, memory used, CPU utilization, task node type, parent node of the task node, total read bytes, total write bytes, and runtime.
[0082] Step 1.3: Define the feature vector β of the dependency edges between task nodes. ij .
[0083] For task t i and t j Task t i Depends on task t j , t i and t j The dependency edge between them is defined as e ij ∈E; Task t i After the machine executes the task, it will transmit the generated data to the next task node t. j , where t i The amount of data generated is defined as d i,j The feature vector β of the dependency edges between task nodes. ij This includes the direction of the edges between task nodes and the amount of data d. i,j .
[0084] In this embodiment, the model considers the direction of the edge as one of the features of the dependency edge, increasing the directed edge channel p to two channels, encoded as: [e ijp e jip The symbols ] represent forward and reverse directions, respectively, aggregating node information from these two different types of neighborhoods, including directional information. Task node t i To task node t j The directed edge channel is encoded as [1 0], and the task node t j To task node t i The directed edge channel is encoded as [0 1].
[0085] Step 1.4: Obtain workflow data.
[0086] Using Pegasus, a distributed platform based on a workflow management system, actual execution logs of scientific workflows are obtained to construct workflow instances; these workflows come from representative applications across different scientific fields. The open-access production workflow instances are parsed using the WfCommons tool, following the definitions in steps 1.2 and 1.3, to obtain workflow data in JSON format. A workflow data example is... Figure 2 As shown.
[0087] Step 2: Feed the workflow data into the model for learning. The model consists of multiple identical stacked layers, each layer including two sub-layers: a Graph Transformer layer with directed edge features and a feedforward neural network; the input task nodes and edge embeddings are passed to the Graph Transformer layer to compute position encoding and center encoding.
[0088] Step 2.1: Define the model.
[0089] Step 2.1.1: Define the overall structure of the model. The overall structure of the model is as follows: Figure 3 As shown, it consists of multiple identical layers stacked together, each layer comprising two sub-layers: a Graph Transformer layer with directed edge features and a feedforward neural network.
[0090] Step 2.1.2: Define a Graph Transformer layer with directed edge features, as shown in the following structure. Figure 4 As shown.
[0091] First, the task nodes in the input workflow are processed through three linear mappings and then combined with pre-calculated task node position codes to obtain representations of queries, keys, and values, respectively. Next, for each query, its similarity to all keys in the graph is calculated. A dot product operation is used to calculate the similarity, i.e., the query is multiplied by all keys, and then normalized to obtain attention weights. The values are then weighted and summed using these attention weights to obtain the feature representation of each task node. The larger the weight, the greater the influence of that task node on other nodes. To increase the model's expressiveness and diversity, a multi-head self-attention mechanism introduces multiple independent attention calculations. Each attention calculation is independent, using different queries, keys, and values. Finally, the results of each attention calculation are concatenated and then linearly transformed to obtain the final multi-head attention representation.
[0092] Step 2.1.3: Following the multi-head self-attention mechanism, each layer also includes a feedforward neural network. The feedforward neural network consists of two linear transformation layers and an activation function ReLU. The feedforward neural network maps the representation at each location to a higher-dimensional space and then back to the original dimension. This mapping process helps to perform non-linear transformations and combinations of features in the input sequence, thereby improving the model's representational power.
[0093] Considering the structure and characteristics of the workflow, this embodiment incorporates the features of dependency edges into the learning of node features (which is also part of the Graph Transformer layer; that is, feeding node and edge features into the model is the process of feature learning). Specifically, an edge weight matrix W is added when calculating attention. E When a task node t i After multiplication and scaling of the query and key feature projections, an attention score w is obtained. ij Consider it as the attention weight for the edge <i,j>, and related to the edge features. Perform the dot product.
[0094] Step 2.2: Define the input.
[0095] Step 2.2.1: Pass the input task nodes and edge embeddings to the Graph Transformer layer.
[0096] For each task node t i Having node characteristics For task node t i and task node t j Each edge e between ij With edge features The workflow g will input task node features α i Sum of edge features β ij The data are passed to the d-dimensional hidden features via linear mapping. and In the following two equations:
[0097]
[0098]
[0099] Where, d n d represents the number of node features. e Let A be the number of edge features. 0 B 0 a0 and b0 are the parameters of the linear mapping layer. This linear mapping is achieved by learning trainable parameters that map the dimensions of the input task nodes and edges to a lower-dimensional representation space for subsequent attention computation.
[0100] Step 2.2.2: Calculate the location code.
[0101] Position encoding is performed using the eigenvectors obtained from the eigenvalue decomposition of the graph's Laplacian matrix, as shown in the following equation:
[0102] Δ=1-D -1 / 2AD -1 / 2 =U T ΛU
[0103] Where A is an n×n adjacency matrix, D is the degree matrix, Λ and U correspond to eigenvalues and eigenvectors respectively, and Δ represents the Laplacian matrix; the k smallest nontrivial eigenvectors of the task node are used as the position encoding of the task node, denoted by λ. i This is represented by a linear mapping; then, a pre-computed task node position code of dimension k is embedded and added to the task node hidden features. In the following formula:
[0104] λ i 0 =C 0 λ i +c 0
[0105]
[0106] in, C 0 c 0 These are the parameters of the linear mapping layer; These are the task node features and the position encoding of layer 0, respectively.
[0107] Note that Laplacian positional encoding is only added to the node features of the input layer, not to the intermediate GraphTransformer layers.
[0108] Step 2.2.3: Calculate the center code.
[0109] The center encoding uses the degree of a node as a measure of its importance. A set of vectors related to node degree is constructed, with each degree having its own vector representation, independent of the specific node. Nodes with the same degree have the same center encoding. This center encoding is then directly added to the node's features as input, as shown in the following formula:
[0110]
[0111] Among them, z - , They are respectively determined by in-degree deg - (v i ) and out-degree deg + (v i The learnable embedding vector specified by ).
[0112] Step 3: Learn node features.
[0113] To update the nodes, the layer update equation for layer l is defined as follows:
[0114]
[0115]
[0116]
[0117]
[0118] Among them, Q k,l K k,l V k,l , These are the weight parameters; k = 1 to H represents the number of attention points; || represents a connection; the output... and Then it is passed to the feedforward neural network, where residual connections and normalization occur beforehand. and The summation is followed by normalization; after passing through the feedforward neural network, there are still residual connections and normalization layers, i.e. and After addition and normalization using Normal, the edge characteristics are the same as described above, as follows:
[0119]
[0120]
[0121]
[0122]
[0123]
[0124]
[0125] in, For weight parameters, This represents a hidden feature.
[0126] Step 4: Combine node features with dependency edge features.
[0127] At the end of the model, task node embeddings and dependency edge embeddings are combined, and the information from both is treated as a whole. The combination function is as follows:
[0128] h last =φ(t) last ,e last )
[0129] Among them, t last e lastThese represent task node embedding and dependency edge embedding, respectively. It is a combination of task node embedding and dependency edge embedding; h last This represents the final combined embedding vector. The choice of combination method is a crucial factor determining the quality of embedding learning. The model uses one of the following three combination methods for embedding:
[0130] Add:φ(t last ,e last )=t last +e last ;
[0131] Multiplication: φ(t) last ,e last )=t last *e last ;
[0132] Concatenation:φ(t last ,e last )=[t last ;e last This combination method is the form of concatenating two vectors.
[0133] The type of a node is determined by a combination of task node embedding and dependency edge embedding.
[0134] Step 5: Classify task nodes based on node characteristics.
[0135] After learning the features of the nodes using the model in this embodiment, the node features are obtained. Then, classification is performed based on these features. The node representations obtained in the last layer of the network model are passed to a fully connected neural network to calculate the task classification-related output, as shown in the following equation:
[0136] Z = softmax(W) T h last +b)
[0137] Among them, W T b are the parameters of the linear mapping layer.
[0138] This embodiment proposes an emerging application workflow classification method based on a combined embedding graph Transformer, aiming to solve the workflow classification problem in cloud computing environments. Traditional classification algorithms typically only consider independent tasks, ignoring the priority and dependencies between tasks. The emerging application workflow classification method in the cloud environment described in this embodiment significantly improves the classification accuracy for different task types. Compared with traditional and existing algorithms, the method proposed in this embodiment employs a combined embedding approach of task node features and relationship features. The model learns about task nodes and the relationships between them, enhancing its learning ability and enabling the classification of unknown workflow nodes.
[0139] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope defined by the claims of the present invention.
Claims
1. An emerging application workflow classification method based on composite embedding graph Transformer, characterized in that: Includes the following steps: Step 1: Set up workflow-related information, including the overall workflow structure, task node characteristics, dependency edge characteristics between task nodes, and obtain workflow data; the specific method is as follows: Step 1.1: Define the overall structure of the workflow; set up This represents a collection of workflows with various node types, where Represents a workflow. Workflow The task is denoted by n, where n is the number of nodes. Indicates task and Dependency edges between them It is a set of dependency edges, where tasks and It refers to the relationship between a parent task and a child task. Task-dependent This means that a child task can only be executed after the parent task has been completed; a task without a parent task is an initial task, represented as... A task without subtasks is considered an end task, represented as... ; Step 1.2: Define the feature vector of the task node ; Workflow task nodes eigenvectors This includes workflow task execution metrics, specifically: task runtime data size, input and output data size, memory used, CPU utilization, task node type, parent node of the task node, total bytes read, total bytes written, and runtime. Step 1.3: Define the feature vectors of the dependency edges between task nodes. ; For the task and ,Task Task-dependent , and The dependency edges between them are defined as follows: ;Task After the machine executes the task, it transmits the generated data to the next task node. ,in The amount of data generated is defined as Feature vectors of dependency edges between task nodes This includes the direction of the edges between task nodes and the amount of data. ; The model considers the direction of edges as a type of dependency edge feature, thus defining directed edge channels. Increased to two, coded as follows: These represent forward and reverse directions, respectively. Information from these two different types of neighborhood nodes is aggregated, including directional information; task nodes. To the task node The directed edge channel encoding is Task Node To the task node The directed edge channel encoding is ; Step 1.4: Obtain workflow data; Pegasus, a distributed platform based on a workflow management system, is used to obtain the actual execution logs of scientific workflows to construct workflow instances. The WfCommons tool is used to parse the open-access production workflow instances according to the definitions in steps 1.2 and 1.3 to obtain workflow data in JSON format. Step 2: Feed the workflow data into the model for learning; The model consists of multiple identical layers stacked together, each layer comprising two sub-layers: a GraphTransformer layer with directed edge features and a feedforward neural network; the input task node and edge embeddings are passed to the Graph Transformer layer to compute position encoding and center encoding; The Graph Transformer layer with directed edge features is defined as follows: First, the task nodes in the input workflow are processed through three linear mappings and then combined with pre-calculated task node position codes to obtain the representations of queries, keys, and values, respectively. For each query, the similarity between it and all keys in the graph is calculated using a dot product operation, i.e., the query is multiplied by all keys, and then normalized to obtain attention weights. The values are then weighted and summed using these attention weights to obtain the feature representation of each task node; the larger the weight, the greater the influence of the task node on other nodes. The multi-head self-attention mechanism introduces multiple independent attention calculations, each using different queries, keys, and values. Finally, the results of each attention calculation are concatenated and then linearly transformed to obtain the final multi-head attention representation. The feedforward neural network includes two linear transformations and an activation function. The feedforward neural network maps the representation of each position to a higher-dimensional space, and then maps it back to the original dimension. The features of dependency edges are also incorporated into the learning of node features in the model, and an edge weight matrix is added when calculating attention. When a task node After multiplication and scaling of the query and key feature projections, an attention score is obtained. Seen as about The attention weight of this edge, and its features Perform the dot product; Step 3: Learn node features and update the nodes; Step 4: Combine node features with dependency edge features; At the end of the model, task node embedding and dependency edge embedding are combined, and the information of the two is treated as a whole. The type of a node is determined by the combined operation of task node embedding and dependency edge embedding. Step 5: Classify task nodes based on node characteristics.
2. The emerging application workflow classification method based on composite embedded graph Transformer according to claim 1, characterized in that: The specific method for passing the input task node and edge embedding to the Graph Transformer layer in step 2 is as follows: For each task node Having node characteristics For task nodes and task nodes Each edge between With edge features Workflow Input task node features Sum of edge features The data are passed to the d-dimensional hidden features via linear mapping. and In the following two equations: ; ; in, The number of node features. The number of edge features; , , For the parameters of the linear mapping layer, The linear mapping is achieved by learning trainable parameters, mapping the dimensions of the input task nodes and edges to a low-dimensional representation space for subsequent attention calculation. The method for calculating the position code is as follows: The eigenvectors obtained by eigenvalue decomposition of the graph's Laplacian matrix are used as positional codes, as shown in the following equation: ; in, for The adjacency matrix, For degree matrix, , Corresponding to eigenvalues and eigenvectors respectively. Represent the Laplacian matrix; use the k smallest nontrivial eigenvectors of the task node as the position encoding of the task node, and use... This is represented by a linear mapping; then, a pre-computed task node position code of dimension k is embedded and added to the task node hidden features. In the following formula: ; ; in, , , These are the parameters of the linear mapping layer; , These are the task node features and the position encoding at layer 0, respectively. The center code uses the degree of a node as a measure of its importance. The method for calculating the center code is as follows: Construct a batch of vectors related to node degrees. Each degree has a vector representation, independent of which specific node it belongs to. Nodes with the same degree have the same center code. This center code is then directly added to the node features as input, as shown in the following formula: ; in, They are respectively by in-degree and out-degree The specified learnable embedding vector.
3. The emerging application workflow classification method based on composite embedded graph Transformer according to claim 2, characterized in that: In step 3, the node is updated to the first... The layer is defined with the following layer update equation: ; ; ; ; in, These are weight parameters; Indicates the number of attention points; Indicates connection; output and Then it is passed to the feedforward neural network, where residual connections and normalization are performed beforehand. and The summation is followed by normalization; after passing through the feedforward neural network, there are still residual connections and normalization layers, i.e. and After addition and normalization using Normal, the edge characteristics are the same as described above, as follows: ; ; ; ; ; ; in, For weight parameters, , , , , , This represents hidden features.
4. The emerging application workflow classification method based on composite embedded graph Transformer according to claim 3, characterized in that: In step 4, the combination function for combining task node embedding and dependency edge embedding is as follows: ; in, These represent task node embedding and dependency edge embedding, respectively. It is a combination of task node embedding and dependency edge embedding; This represents the final combined embedding vector; The model is embedded using one of the following three combinations: Add: ; Multiplication: ; Concatenation: This combination method is in the form of concatenating two vectors.
5. The emerging application workflow classification method based on composite embedded graph Transformer according to claim 4, characterized in that: In step 5, the node representations obtained in the last layer of the network model are passed to a fully connected neural network to calculate the task classification-related output Z, as shown in the following formula: ; in, and These are the parameters of the linear mapping layer.
Citation Information
Patent Citations
Deep neural network model parallel computing task asynchronous scheduling method
CN115994567A