Node scheduling optimization method for relatively independent subgraphs

By identifying relatively independent subgraphs and using beam search to optimize node scheduling, the memory management problem in AI inference process is solved, and the scheduling solution with the smallest memory peak is realized, avoiding resource waste and data confusion.

CN119493640APending Publication Date: 2025-02-21HEFEI JUNZHENG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311038219.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-16
Publication Date
2025-02-21

AI Technical Summary

Technical Problem

In the process of AI inference, it is difficult for the existing technology to effectively manage the operator memory in the computing graph, resulting in data confusion and waste of memory resources. The scheduling and sorting belongs to the NP hard problem and consumes a lot of resources.

Method used

By identifying relatively independent subgraphs, determine the dependencies of some subgraphs in advance, reduce the scale of the problem, and use beam search global search schemes to optimize node scheduling, and find the scheduling scheme with the smallest memory peak.

Benefits of technology

The node scheduling optimization of relatively independent subgraphs is realized, which reduces memory peaks, avoids data confusion and resource waste, and does not require a large amount of training data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119493640A_ABST
    Figure CN119493640A_ABST
Patent Text Reader

Abstract

The invention provides a node scheduling optimization method for relatively independent sub-graphs, which at least comprises the following steps of: S1, judging whether relatively independent segmentation points exist or not and optimizing: assuming that certain nodes in an original graph are neither completely independent segmentation points nor not completely independent segmentation points, and ordering the sub-graphs determined by the nodes is mutually influenced, however, the internal sequence of the sub-graph is determined by the internal part of the sub-graph, and the nodes are relatively independent segmentation points, namely, the sub-graph memory determines the sequence of the nodes of the sub-graph; s2, performing beam search sorting on the sub-graphs determined in the step S1 in advance, and numbering corresponding nodes; s3, sorting all the sub-graphs obtained in the step S2, and merging the sorted sub-graphs into the whole large network graph; and S4, if the sequencing is finished, ending, and if the sequencing is not finished, returning to the step S1 to continuously optimize the expanded sub-graphs in the step S3 until the sequencing optimization is finished. The width of the beam is reduced in advance, and particularly, the node scheduling of relatively independent sub-graphs is optimized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of computer technology, and in particular relates to a node scheduling optimization method for relatively independent subgraphs. Background Art

[0002] With the development of the Internet, artificial intelligence (AI) has developed rapidly, and AI models have been applied to various products and services. Generally, AI models are constructed using deep neural networks or convolutional neural networks, and then the constructed models are trained using training samples to obtain AI models that can be used for reasoning in application scenarios.

[0003] The network graph will have multiple operators and multiple edges. Each edge will be associated with two operators. The edge is also used to represent the input / output relationship between the two associated operators. During the AI ​​reasoning process, the terminal side needs to calculate one by one according to the execution order of each operator in the network. Each operator has input data and output data. For example, the convolution operator performs convolution calculation on the input data and then outputs it. Therefore, at least one block of memory is required for each operator to store the corresponding output data, and this output data is used as the input data of the next operator associated with it. In actual applications, some special operators such as GRU and LSTM will have multiple output tensors. If the memory of these operators is not managed, the executing operator cannot know where to schedule the input data, nor can it determine the location where the output data should be stored in the memory, resulting in data confusion and inability to complete reasoning.

[0004] If a piece of memory is allocated to each operator in the computation graph, it will cause a waste of memory resources. Because the operators in the network are executed in sequence, when the subsequent operator is executed, the memory of the previous operator in the previous execution order may have been cleared. In this way, the subsequent operator can use all or part of the memory of the previous operator. When pre-allocating memory, multiple operators with non-overlapping life cycles can share memory. The industry has explored a variety of solutions to reduce the actual deployment memory peak of the computation graph.

[0005] However, in all current solutions, in practical applications, it is assumed that a certain sorting order has been determined, and how to pre-allocate memory. Since scheduling sorting is an NP-hard problem with a huge solution space, using a learning and training AI algorithm to conduct supervised training to study sorting will consume a lot of resources.

[0006] This article focuses on heuristic algorithms, which are traditional algorithms. Different from AI learning and training methods, they do not require a large amount of training data. They use beam search to search for global solutions, which guarantees the global optimal solution as much as possible and finds the scheduling solution with the smallest memory peak. Among current researchers, this is the only and best method for heuristic case generation when offline server space is limited.

[0007] The width of beam search is actually very large. Server resources are limited. The naive method of beam search is that every time the numbering is completed, the next optional number is taken into consideration.

[0008] In addition, completely independent subgraphs do not affect each other, and the influence between non-completely independent subgraphs is certain. However, there are relatively independent subgraphs, and of course they are relatively ranked, but the internal dependency of a relatively independent subgraph is certain. For example, the strength relationship within a group of members can be determined by the group, for example, A must be greater than B. When put in the national competition, member A is ranked 10th, then member B’s number is at least 11, which is definitely greater than B, and A and B do not have to re-judge and rank each other in the national competition.

[0009] In addition, common terms in the prior art include:

[0010] 1) Node, operator, operator: In the embodiments of the present application, the node in the neural network can also be called an operator, operator, etc., which is the smallest unit of the network structure. In the embodiments of the present application, the operator is used as an example for description.

[0011] 2)Tensor, tensor:

[0012] The output data results of the operator should be saved in a tensor. An operator generally has one output result, and only one tensor is needed to save the output result. In actual applications, an operator may output multiple tensors, such as LSTM operator and GRU operator. The life cycle of each tensor may be different, but this application only discusses the general case.

[0013] 3) Computational graphs, AI models, neural networks, deep learning networks, directed acyclic graphs: all belong to the same concept, and are directed acyclic graph structures composed of multiple nodes.

[0014] 4) Operator memory:

[0015] When an operator has one output tensor, the memory occupied by the tensor is the memory of the operator. When an operator has multiple output tensors, the sum of the memory occupied by the multiple tensors is the memory of the operator.

[0016] This application only discusses one operator with one output tensor.

[0017] 5) Network memory at time t:

[0018] The execution order of the network has calculated the memory required for the operator executed at time t:

[0019] First: input tensor memory.

[0020] Second: the memory of this operator,

[0021] Third: The memory of the tensors in the network that have not been consumed.

[0022] 6) The maximum memory peak of the network, the first memory peak of the network, the second memory peak of the network, the third memory peak of the network, and the tth memory peak:

[0023] The execution order of the network has been calculated up to time t.

[0024] Calculate the network memory at the 1st moment, the 2nd moment, the 3rd moment, ..., the tth moment, and sort them in descending order, so as to know the first memory peak value of the network, the second memory peak value of the network, ..., the tth memory peak value of the network.

[0025] 7) Scheduling, sorting, and execution order:

[0026] Common network sorting schemes are depth-first sorting and breadth-first sorting, but the actual number of network sorting schemes is very large. When calculating offline on the PC side, it is even impossible to store all the scheduling schemes. Summary of the invention

[0027] In order to solve the above problems, the purpose of this application is to optimize the node scheduling of relatively independent subgraphs.

[0028] Specifically, the present invention provides a node scheduling optimization method for relatively independent subgraphs, and the method comprises the following steps:

[0029] S0, determine whether there is a relatively independent subgraph, that is, the entire original graph is cut into multiple independent subgraphs by completely independent segmentation points and non-completely independent segmentation points. The multiple subgraphs are independent of each other, and there is no constraint relationship between the subgraphs on node scheduling. However, the above independent subgraphs can be further divided into a relatively independent subgraph, which is a relatively independent subgraph. The scheduling priority of the relatively independent subgraph can be determined by the relatively independent subgraph itself. Therefore, the problem scale can be reduced by determining the dependency relationship of some subgraphs in advance;

[0030] S1, for each independent subgraph, determine whether there is a minimum relatively independent subgraph. The minimum relatively independent subgraph refers to a subgraph connected by {common input node + two straight-line branches + common output node}, and the common input node and the common output node are called the minimum relatively independent subgraph splitting points.

[0031] S2, if there is no minimum relatively independent subgraph in step S1, the independence itself is subjected to a simple beam search and sorting method; if there is a minimum relatively independent subgraph, each minimum relatively independent subgraph is sorted internally in advance, and the remaining subgraphs are not processed temporarily, waiting for the minimum relatively independent subgraph of this iteration to be sorted in advance;

[0032] S3, connecting the sorting information of the smallest relatively independent subgraphs obtained in step S2 with straight lines in order, and then merging them into the corresponding independent subgraphs;

[0033] S4, for the independent subgraph optimized in S3, continue the operations of S1, S2, and S3.

[0034] There are X, ABCDEFGHIJ, KLMO, and Y nodes in the original graph. The entire graph can be further cut into the smallest relatively independent subgraphs and sorted in advance.

[0035] The step S1 further comprises:

[0036] 1) Try to use X as the starting node of a relatively independent subgraph module to determine the multiple outputs of the X node:

[0037] The first straight line output: [X->A]

[0038] The second straight line output: [X->K]

[0039] The ends of the two lines do not overlap: the output nodes of A are {B, E, G}, the output nodes of K are {L, N}, {B, E, G} and {L, N} have no overlapping points, so at this time, a relatively independent subgraph with X as the common input does not exist;

[0040] 2) Find the next node, for example, starting with node K as a relatively independent subgraph module with multiple outputs:

[0041] The first straight line output: [K->L->M->Y]

[0042] The second straight line output: [K->N->O->Y]

[0043] The two straight lines both end with Y and overlap, so the relatively independent subgraph {KLMNOY} can be optimized in advance;

[0044] The step S2 further comprises: after scheduling and sorting the relatively independent subgraph {KLMNOY}, optimizing the best sorting scheme, assuming that it is: {K->N->L->M->O->Y};

[0045] The step S3 further comprises: merging the relatively independent subgraph optimized sort {K->N->L->M->O->Y} with the X node, the {ABCDEFGHIJ} subgraph, and Y to form a new graph, wherein the original graph {KNLMOY} part is two branches, and after optimization, the {KNLMOY} part is a straight line;

[0046] The step S4 further includes: the new graph continues to determine whether there is a relatively independent subgraph, continues to sort the new relatively independent subgraphs, and iterates to enter S1, S2, and S3.

[0047] The step S1 further comprises:

[0048] Second judgment, start optimization:

[0049] Start node with A as module

[0050] A node has multiple outputs:

[0051] The first straight line output: [A->B->C->D->J]

[0052] The second straight line output: [A->E->F->J]

[0053] The third straight line output: [A->G->H->I->J]

[0054] The three straight lines all end with J, and the ends overlap, so {ABCDEFGHIJ} is a relatively independent subgraph. Then any two straight lines are selected to form the smallest relatively independent subgraph, for example, the relatively independent subgraph {ABCDEFJ} formed by [A->B->C->D->J] and [A->E->F->J], and the scheduling sorting is optimized. Assume that the best sorting of {ABCDEFJ} is {A->E->F->B->C->D->J};

[0055] The step S2 further includes: {ABCDEFJ} subgraph optimization sorting: {A->E->F->B->C->D->J};

[0056] The step S3 further includes: merging the subgraph optimized sort {A->E->F->B->C->D->J} with the {AGHIJ}, {K->N->L->M->O} subgraphs, and the X and Y nodes into a new graph formed again;

[0057] The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

[0058] The step S1 further comprises:

[0059] The third judgment starts with optimization:

[0060] Start node with A as module

[0061] A node has multiple outputs:

[0062] The first straight line output: [A->E->F->B->C->D->J]

[0063] The second straight line output: [A->G->H->I->J]

[0064] If the ends of the two straight lines overlap, then {ABCDEFGHIJ} constitutes a relatively independent subgraph.

[0065] The step S2 further includes: subgraph optimization sorting: {A->E->G->F->B->H->I->C->D->J};

[0066] The step S3 further comprises: merging the subgraph optimized order {A->E->G->F->B->H->I->C->D->J} and {K->N->L->M->O->Y}, and the X and Y nodes together to form a new graph;

[0067] The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

[0068] The step S1 further comprises:

[0069] Judge again and start optimization:

[0070] Start node with X as module

[0071] X-node multiple outputs:

[0072] The first straight line output: [X->A->E->G->F->B->H->I->C->D->J->Y]

[0073] The second straight line output: [X->K->N->L->M->O->Y]

[0074] If the ends of two straight lines overlap, they form relatively independent subgraphs, which can be optimized into the best sorting solution;

[0075] The step S2 further comprises: the optimized result;

[0076] The step S3 further comprises: obtaining the ranking of all graphs;

[0077] The step S4 further includes: finally adding the sorting to the corresponding independent subgraph, and the optimization is completed.

[0078] Therefore, the advantages of this application are: in the simple method of beam search, every time the numbering is completed, the next optional numbering is all taken into consideration. However, in practical applications, there are certain rules that can be used to determine the sorting relationship between some nodes in advance, so that after entering the beam search, the remaining node relationships that need to be sorted have been reduced, the beam width is reduced in advance, and in particular, the node scheduling of relatively independent subgraphs is optimized. BRIEF DESCRIPTION OF THE DRAWINGS

[0079] The drawings described herein are used to provide a further understanding of the present invention, constitute a part of this application, and do not constitute a limitation of the present invention.

[0080] Figure 1 (a) and Figure 1 (b) is a schematic diagram of the smallest independent subgraph.

[0081] Figure 2 It is a schematic diagram of the original image structure of this article.

[0082] Figure 3 This is a schematic diagram of the optimized sorted order of the {KLMNO} minimum relative subgraph judged by S2 for the first time, and merged into the large network.

[0083] Figure 4 This is a schematic diagram of the optimized sorted order of the {ABCDEFJ} minimum relative subgraph judged by S2 for the second time, and merged into the schematic diagram of the large network.

[0084] Figure 5 This is a schematic diagram of the optimized sorted order of the {ABCDEFJHIJ} minimum relative subgraph judged by S2 for the third time, and merged into the large network.

[0085] Figure 6 It is a schematic diagram of the sorting of the entire graph after optimizing the smallest relatively independent sub-graph in the graph.

[0086] Figure 7 is a schematic diagram of the process of this method. DETAILED DESCRIPTION

[0087] In order to more clearly understand the technical content and advantages of the present invention, the present invention is now further described in detail in conjunction with the accompanying drawings.

[0088] In practical applications of beam search, there are certain rules that can be used to determine the sorting relationship between some nodes in advance, so that after entering the beam search, the remaining node relationships that need to be sorted have been reduced, and the beam width can be reduced in advance.

[0089] Relatively independent subgraphs, such as Figure 2 As shown, A, J, K, and Y are neither completely independent nor partially independent points, so the ordering of the ABCDEFGHIJ subgraph and the KLMNOY subgraph affects each other, that is, after the numbering of node A is completed, its next number can be B, E, G, or any one of KLMNO. Of course, the next number of any one of KLMNO can also be A.

[0090] However, the order within the ABCDEFGHIJ subgraph is determined by its own subgraph. Similarly, the memory of the KLMNO subgraph determines the order of its own subgraph nodes.

[0091] like Figure 3 As shown in , 4, 5, the KLMNO subgraph is sorted by beam search in advance and then merged into the entire large network. Figure 6 As shown, it is a schematic diagram of the sorting of the entire graph after optimizing the smallest relatively independent sub-graph in the graph.

[0092] The present application embodiment relates to a node scheduling optimization method for relatively independent subgraphs, such as Figure 7 As shown, this is the process of this method:

[0093] S0, the entire original graph is divided into multiple independent subgraphs by completely independent segmentation points and non-completely independent segmentation points. The multiple subgraphs are independent of each other, and there is no constraint relationship between the subgraphs on node scheduling. However, the above independent subgraphs can be further divided into a relatively independent subgraph, and the scheduling priority of the relatively independent subgraph can be determined by the relatively independent subgraph itself. Therefore, the scale of the problem can be reduced by determining the dependency relationship of some subgraphs in advance.

[0094] S1, for each independent subgraph, determine whether there is a minimum relatively independent subgraph. The minimum relatively independent subgraph refers to a subgraph connected by {common input node + two straight-line branches + common output node}, such as Figure 1 (a) Figure 1 As shown in (b), the common input node and the common output node are called the minimum relatively independent subgraph partition point.

[0095] S2: If there is no minimum relatively independent subgraph in step S1, the independence itself is subjected to a simple beam search and sorting method; if there is a minimum relatively independent subgraph, each minimum relatively independent subgraph is sorted internally in advance, and the remaining subgraphs are not processed for the time being, waiting for the minimum relatively independent subgraph of this iteration to be sorted in advance.

[0096] S3, connecting the sorting information of the smallest relatively independent subgraphs obtained in step S2 with straight lines in order, and then merging them into the corresponding independent subgraphs.

[0097] S4, for the independent subgraph optimized in S3, continue the operations of S1, S2, and S3.

[0098] The cutting judgment method of the smallest relatively independent subgraph is as follows:

[0099] When two straight-line branches have a common input node and output node, the subgraph connected by {common input node, two straight lines, common output node} is called the smallest relatively independent subgraph. A straight-line branch refers to a graph in which nodes with a single input and a single output are connected and communicated together, such as Figure 1 (a) Figure 1 (b) as shown.

[0100] There are X, ABCDEFGHIJ, KLMO, and Y nodes in the original graph. The entire graph can be further cut into the smallest relatively independent subgraphs and sorted in advance.

[0101] The step S1 further comprises:

[0102] 1) Try to use X as the starting node of a relatively independent subgraph module to determine the multiple outputs of the X node:

[0103] The first straight line output: [X->A]

[0104] The second straight line output: [X->K]

[0105] The ends of the two straight lines do not overlap: the output nodes of A are {B, E, G}, the output nodes of K are {L, N}, {B, E, G} and {L, N} have no overlapping points, so at this time, a relatively independent subgraph with X as the common input does not exist.

[0106] 2) Find the next node, for example, starting with node K as a relatively independent subgraph module with multiple outputs:

[0107] The first straight line output: [K->L->M->Y]

[0108] The second straight line output: [K->N->O->Y]

[0109] The two straight lines both end with Y and overlap, so the relatively independent subgraph {KLMNOY} can be optimized in advance;

[0110] The step S2 further comprises: after scheduling and sorting the relatively independent subgraph {KLMNOY}, optimizing the best sorting scheme, assuming that it is: {K->N->L->M->O->Y};

[0111] The step S3 further comprises: merging the relatively independent subgraph optimized sort {K->N->L->M->O->Y} with the X node, the {ABCDEFGHIJ} subgraph, and Y to form a new graph, wherein the original graph {KNLMOY} part is two branches, and after optimization, the {KNLMOY} part is a straight line;

[0112] The step S4 further includes: the new graph continues to determine whether there is a relatively independent subgraph, continues to sort the new relatively independent subgraphs, and iterates to enter S1, S2, and S3.

[0113] The step S1 further comprises:

[0114] Second judgment, start optimization:

[0115] Start node with A as module

[0116] A node has multiple outputs:

[0117] The first straight line output: [A->B->C->D->J]

[0118] The second straight line output: [A->E->F->J]

[0119] The third straight line output: [A->G->H->I->J]

[0120] The three straight lines all end with J, and the ends overlap, so {ABCDEFGHIJ} is a relatively independent subgraph. Then any two straight lines are selected to form the smallest relatively independent subgraph, for example, the relatively independent subgraph {ABCDEFJ} formed by [A->B->C->D->J] and [A->E->F->J], and the scheduling sorting is optimized. Assume that the best sorting of {ABCDEFJ} is {A->E->F->B->C->D->J};

[0121] The step S2 further includes: {ABCDEFJ} subgraph optimization sorting: {A->E->F->B->C->D->J};

[0122] The step S3 further includes: merging the subgraph optimized sort {A->E->F->B->C->D->J} with the {AGHIJ}, {K->N->L->M->O} subgraphs, and the X and Y nodes into a new graph formed again;

[0123] The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

[0124] The step S1 further comprises:

[0125] The third judgment starts with optimization:

[0126] Start node with A as module

[0127] A node has multiple outputs:

[0128] The first straight line output: [A->E->F->B->C->D->J]

[0129] The second straight line output: [A->G->H->I->J]

[0130] If the ends of the two straight lines overlap, then {ABCDEFGHIJ} constitutes a relatively independent subgraph.

[0131] The step S2 further includes: subgraph optimization sorting: {A->E->G->F->B->H->I->C->D->J};

[0132] The step S3 further comprises: merging the subgraph optimized order {A->E->G->F->B->H->I->C->D->J} and {K->N->L->M->O->Y}, and the X and Y nodes together to form a new graph;

[0133] The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

[0134] The step S1 further comprises:

[0135] Judge again and start optimization:

[0136] Start node with X as module

[0137] X-node multiple outputs:

[0138] The first straight line output: [X->A->E->G->F->B->H->I->C->D->J->Y]

[0139] The second straight line output: [X->K->N->L->M->O->Y]

[0140] If the ends of two straight lines overlap, they form relatively independent subgraphs, which can be optimized into the best sorting solution;

[0141] The step S2 further comprises: the optimized result;

[0142] The step S3 further comprises: obtaining the ranking of all graphs;

[0143] The step S4 further includes: finally adding the sorting to the corresponding independent subgraph, and the optimization is completed.

[0144] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the embodiments of the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A node scheduling optimization method for relatively independent subgraphs, characterized in that: The method comprises the following steps: S0, determine whether there is a relatively independent subgraph, that is, the entire original graph is cut into multiple independent subgraphs by completely independent segmentation points and non-completely independent segmentation points. The multiple subgraphs are independent of each other, and there is no constraint relationship between the subgraphs on node scheduling. However, the above independent subgraphs can be further divided into a relatively independent subgraph, which is a relatively independent subgraph. The scheduling priority of the relatively independent subgraph can be determined by the relatively independent subgraph itself. Therefore, the problem scale can be reduced by determining the dependency relationship of some subgraphs in advance; S1, for each independent subgraph, determine whether there is a minimum relatively independent subgraph; the minimum relatively independent subgraph refers to a subgraph connected by {common input node + two straight-line branches + common output node}, and the common input node and the common output node are called the minimum relatively independent subgraph splitting points; S2, if there is no minimum relatively independent subgraph in step S1, a simple beam search and sorting method is performed on the independence itself; if there is a minimum relatively independent subgraph, one of the minimum relatively independent subgraphs is sorted internally in advance, and the remaining subgraphs are not processed temporarily; S3, connecting the sorting information of the smallest relatively independent subgraphs obtained in step S2 in order with straight lines, and then merging them into the corresponding independent subgraphs; S4, continuing the operations of steps S1, S2, and S3 for the independent subgraph optimized in step S3.

2. The node scheduling optimization method for a relatively independent subgraph according to claim 1, characterized in that: There are X, ABCDEFGHIJ, KLMO, and Y nodes in the original graph. The whole graph can be further cut into the smallest relatively independent subgraphs and sorted in advance; The step S1 further comprises: 1) Try to start node X as a relatively independent subgraph module Determine if node X has multiple outputs: The first straight line output: [X->A] The second straight line output: [X->K] The ends of the two lines do not overlap: the output nodes of A are {B, E, G}, the output nodes of K are {L, N}, {B, E, G} and {L, N} have no overlapping points, so at this time, a relatively independent subgraph with X as the common input does not exist; 2) Find the next node, for example, starting with node K as a relatively independent subgraph module with multiple outputs: The first straight line output: [K->L->M->Y] The second straight line output: [K->N->O->Y] The two straight lines both end with Y and overlap, so the relatively independent subgraph {KLMNOY} can be optimized in advance; The step S2 further comprises: after scheduling and sorting the relatively independent subgraph {KLMNOY}, optimizing the best sorting scheme, assuming that it is: {K->N->L->M->O->Y}; The step S3 further comprises: merging the relatively independent subgraph optimized sort {K->N->L->M->O->Y} with the X node, the {ABCDEFGHIJ} subgraph, and Y to form a new graph, wherein the original graph {KNLMOY} part is two branches, and after optimization, the {KNLMOY} part is a straight line; The step S4 further includes: the new graph continues to determine whether there is a relatively independent subgraph, continues to sort the new relatively independent subgraphs, and iterates to enter S1, S2, and S3.

3. The node scheduling optimization method for a relatively independent subgraph according to claim 2 is characterized in that: The step S1 further comprises: Second judgment, start optimization: Start node with A as module A node has multiple outputs: The first straight line output: [A->B->C->D->J] The second straight line output: [A->E->F->J] The third straight line output: [A->G->H->I->J] The three straight lines all end with J and overlap, so {ABCDEFGHIJ} is a relatively independent subgraph. Then any two straight lines can form the smallest relatively independent subgraph, for example, the relatively independent subgraph {ABCDEFJ} is formed by [A->B->C->D->J] and [A->E->F->J]. The step S2 further includes: after the relatively independent subgraph {ABCDEFJ} is scheduled and sorted, optimizing the best sorting scheme, assuming that the best sorting scheme of {ABCDEFJ} is {A->E->F->B->C->D->J}; the step S3 further includes: merging the relatively independent subgraph optimized sorting {A->E->F->B->C->D->J} with the X node, the {KLMO} subgraph, and Y to form a new graph.

4. The node scheduling optimization method for a relatively independent subgraph according to claim 3 is characterized in that: The step S1 comprises: A node has multiple outputs: The first straight line output: [A->E->F->B->C->D->J] The second straight line output: [A->G->H->J]; The step S2 further includes: {ABCDEFJ} subgraph optimization sorting: {A->E->F->B->C->D->J}; The step 2 further includes: merging the subgraph optimized sort {A->E->F->B->C->D->J} with the {AGHIJ}, {K->N->L->M->O} subgraphs, and the X and Y nodes into a new graph formed again; The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

5. The node scheduling optimization method for a relatively independent subgraph according to claim 4 is characterized in that: The step S1 further comprises: The third judgment starts with optimization: Start node with A as module A node has multiple outputs: The first straight line output: [A->E->F->B->C->D->J] The second straight line output: [A->G->H->I->J] If the ends of the two straight lines overlap, then {ABCDEFGHIJ} constitutes a relatively independent subgraph; The step S2 further includes: subgraph optimization sorting: {A->E->G->F->B->H->I->C->D->J}; The step S3 further includes: optimizing the order of the subgraphs {A->E->G->F->B->H->I->C->D->J} and {K->N->L->M->O->Y}, X and Y nodes are merged together to form a new graph; The step S4 further includes: the new graph continues to determine whether there is a relatively independent segmentation sub-graph, continues to sort the new relatively independent sub-graphs, and iterates to enter S1, S2, and S3.

6. The node scheduling optimization method for a relatively independent subgraph according to claim 5, characterized in that: The step S1 further comprises: Judge again and start optimization: Start node with X as module X-node multiple outputs: The first straight line output: [X->A->E->G->F->B->H->I->C->D->J->Y] The second straight line output: [X->K->N->L->M->O->Y] If the ends of two straight lines overlap, they form relatively independent subgraphs, which can be optimized into the best sorting solution; The step S2 further comprises: the optimized result; The step S3 further comprises: obtaining the ranking of all graphs; The step S4 further includes: finally adding the sorting to the corresponding independent subgraph, and the optimization is completed.