Partitioning control dependency edge in computation graph
AssigneeAlibaba Group Holding Limited
InventorXinli Cai
Life of this patent
Estimating the term…
Abstract
The present disclosure relates to a method for adapting a computation graph of a machine learning model. The method comprises partitioning the computation graph at an edge between a first node and a second node, wherein the edge is a control dependency edge. The method further comprises inserting a proxy node, a send node, and a receive node between the first node and the second node. The proxy node is connected to the first node, the send node is configured to receive output data from the proxy node, and the receive node is configured to receive the output data from the send node.
Claims12
A method for adapting a computation graph of a machine learning model, comprising:
- partitioning the computation graph into a first subgraph and a second subgraph at an edge between a first node and a second node, wherein the edge is a control dependency edge;
- inserting a proxy node, a send node, and a receive node between the first node and the second node, wherein the proxy node is connected to the first node, the send node is configured to receive output data from the proxy node, and the receive node is configured to receive the output data from the send node, wherein the proxy node and the second node are included in the first subgraph and the receive node is included in the second subgraph;
- and
- executing the first subgraph on a first accelerator and the second subgraph on a second accelerator, wherein the first accelerator is configured to execute the proxy node after executing the first node and to transfer the output data of the proxy node to the send node, and the second accelerator is configured to initiate execution of the receive node when the output data from the send node is transferred to or accessible by the second accelerator.
An apparatus for adapting a computation graph of a machine learning model, comprising:
- a memory storing a set of instructions;
- and
- one or more processors configured to execute the set of instructions to cause the apparatus to perform:
- partitioning the computation graph into a first subgraph and a second subgraph at an edge between a first node and a second node, wherein the edge is a control dependency edge;
- inserting a proxy node, a send node, and a receive node between the first node and the second node, wherein the proxy node is connected to the first node, the send node is configured to receive output data from the proxy node, and the receive node is configured to receive the output data from the send node, wherein the proxy node and the second node are included in the first subgraph and the receive node is included in the second subgraph;
- and
- executing the first subgraph on a first accelerator and the second subgraph on a second accelerator, wherein the first accelerator is configured to execute the proxy node after executing the first node and to transfer the output data of the proxy node to the send node, and the second accelerator is configured to initiate execution of the receive node when the output data from the send node is transferred to or accessible by the second accelerator.
A non-transitory computer readable medium that stores a set of instructions that is executable by at least one processor of a computing device to cause the computing device to perform a method for adapting a computation graph of a machine learning model, the method comprising:
- partitioning the computation graph into a first subgraph and a second subgraph at an edge between a first node and a second node, wherein the edge is a control dependency edge;
- inserting a proxy node, a send node, and a receive node between the first node and the second node, wherein the proxy node is connected to the first node, the send node is configured to receive output data from the proxy node, and the receive node is configured to receive the output data from the send node, wherein the proxy node and the second node are included in the first subgraph and the receive node is included in the second subgraph;
- and
- executing the first subgraph on a first accelerator and the second subgraph on a second accelerator, wherein the first accelerator is configured to execute the proxy node after executing the first node and to transfer the output data of the proxy node to the send node, and the second accelerator is configured to initiate execution of the receive node when the output data from the send node is transferred to or accessible by the second accelerator.
Dependencies are inferred from the claim text.