# US 2020/0348912 A1 · Optimized machine learning pipeline execution based on execution graphs

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2020/0348912 A1
- Document ID: US20200348912A1
- Status: Published application
- Kind: A1
- Application number: 16/598,663
- Filed: 2019-10-10
- Published: 2020-11-05
- Earliest claimed: 2019-05-03
- Assignees: Microsoft Technology Licensing, LLC
- Applicants: Microsoft Technology Licensing, LLC
- Inventors: Gary Shon Katzenberger; Thomas William Finley; Petro Luferenko; Mohammad Zeeshan Siddiqui; Costin I. Eseanu; Eric Anthony Erhardt; Yael Dekel; Ivan Matantsev
- Web page: https://patentgrep.com/patent/US20200348912A1

## CPC

- G06F 8/31: {Programming languages or programming paradigms}
- G06F 12/0207: {with multidimensional access, e.g. row/column, matrix}
- G06F 9/30036: {Instructions to perform operations on packed data, e.g. vector, tile or matrix operations}
- G06F 9/30079: {Pipeline control instructions, e.g. multicycle NOP}
- G06F 9/5016: {the resource being the memory}
- G06F 9/5022: {Mechanisms to release resources}
- G06F 9/544: {Buffers; Shared memory; Pipes}
- G06F 16/24535: {of sub-queries or views}
- G06F 16/24568: {Data stream processing; Continuous queries}
- G06N 20/00: Machine learning
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Embodiments provide a machine learning framework that enables developers to author and deploy machine learning pipelines into their applications regardless of the programming language in which the applications are structured. The framework may provide a programming language-specific API that enables the application to call a plurality of operators provided by the framework. The framework provides any number of APIs, each for a different programming language. The pipeline generated via the application is represented as an execution graph comprising node(s), where each node represents a particular operator. When a pipeline is submitted for execution, calls to the operators are detected, and nodes corresponding to the operators are generated for the execution graph. Once the execution graph is complete, the execution graph is provided to an execution engine, which reconstructs a corresponding execution graph that is structured in accordance with the operators' programming language and executes the reconstructed execution graph.

## Claims

### Claim 1

A method, comprising:
detecting calls to an application programming interface (API), each call being configured to invoke a particular operator in a plurality of operators and being structured in accordance with a first programming language, each of the operators in the plurality of operators being configured to perform a particular task with respect to a machine learning pipeline of a machine learning model;
for each detected call, generating a corresponding node that corresponds to the operator invoked thereby in a first execution graph that is representative of the machine learning pipeline and is structured in accordance with the first programming language;
providing the first execution graph to a graph execution engine;
generating, by the graph execution engine, a second execution graph that is structured in accordance with a second programming language; and
executing, by the graph execution engine, the second execution graph.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
searching for the plurality of operators in an operator library;
generating a manifest that provides a definition for each operator in the plurality of operators; and
generating at least a portion of the API based on the manifest.

### Claim 3 (depends on 2)

The method of claim 2, wherein the definition for each operator specifies at least one of:
a name of the operator;
a description of the operator;
one or more inputs for the operator;
a data type for each of the one or more inputs;
a description for each of the one or more inputs;
one or more outputs for the operator;
a data type for each of the one or more outputs; or
a description for each of the one or more outputs.

### Claim 4 (depends on 1)

The method of claim 1, wherein the plurality of operators comprises one or more of:
a data transformation;
a data featurizer; or
a machine learning algorithm.

### Claim 5 (depends on 1)

The method of claim 1, wherein providing the first execution graph to the graph execution engine comprises:
providing the first execution graph to the graph execution engine responsive to receiving a call to a function that is configured to initiate the training of the machine learning model; and
wherein providing the first execution graph to the graph execution engine further comprises:
providing one or more pointers to memory in which data to be utilized by the second execution graph is located.

### Claim 6 (depends on 1)

The method of claim 1, wherein each node specifies at least one of:
a name of the corresponding operator;
one or more inputs for the corresponding operator;
one or more outputs for corresponding operator;
another node from which the one or more inputs are provided; or
another node to which the one or more outputs are provided.

### Claim 7 (depends on 1)

The method of claim 1, wherein the second execution graph comprises a plurality of nodes each of which corresponds to an operator and wherein said executing, by the graph execution engine, the second execution graph comprises:
for each node in the second execution graph, issuing a function call corresponding to the operator associated with the node, the function call being structured in accordance with the second programming language.

### Claim 8

A system, comprising:
at least one processor circuit; and
at least one memory that stores program code configured to be executed by the at least one processor circuit, the program code comprising:
an API detector configured to detect calls to an application programming interface (API), each call being configured to invoke a particular operator in a plurality of operators and being structured in accordance with a first programming language, each of the operators in the plurality of operators being configured to perform a particular task with respect to a machine learning pipeline of a machine learning model;
a graph builder configured to, for each detected call, generate a corresponding node that corresponds to the operator invoked thereby in a first execution graph that is representative of the machine learning pipeline and is structured in accordance with the first programming language; and
a graph execution engine configured to:
receive the first execution graph to a graph execution engine;
generate a second execution graph that is structured in accordance with a second programming language; and
execute the second execution graph.

### Claim 9 (depends on 8)

The system of claim 8, wherein the program code further comprises:
a manifest generator configured to:
search for the plurality of operators in an operator library; and
generate a manifest that provides a definition for each operator in the plurality of operators; and
a bindings generator configured to generate at least a portion of the API based on the manifest.

### Claim 10 (depends on 9)

The system of claim 9, wherein the definition for each operator specifies at least one of:
a name of the operator;
a description of the operator;
one or more inputs for the operator;
a data type for each of the one or more inputs;
a description for each of the one or more inputs;
one or more outputs for the operator;
a data type for each of the one or more outputs; or
a description for each of the one or more outputs.

### Claim 11 (depends on 8)

The system of claim 8, wherein the plurality of operators comprises one or more of:
a data transformation;
a data featurizer; or
a machine learning algorithm.

### Claim 12 (depends on 8)

The system of claim 8, wherein each node specifies at least one of:
a name of the corresponding operator;
one or more inputs for the corresponding operator;
one or more outputs for corresponding operator;
another node from which the one or more inputs are provided; or
another node to which the one or more outputs are provided.

### Claim 13 (depends on 8)

The system of claim 8, wherein the second execution graph comprises a plurality of nodes each of which corresponds to an operator and wherein the graph execution engine is further configured to:
for each node in the second execution graph, issue a function call corresponding to the operator associated with the node, the function call being structured in accordance with the second programming language.

### Claim 14

A computer-readable storage medium having program instructions recorded thereon that, when executed by at least one processor of a computing device, perform a method, the method comprising:
detecting calls to an application programming interface (API), each call being configured to invoke a particular operator in a plurality of operators and being structured in accordance with a first programming language, each of the operators in the plurality of operators being configured to perform a particular task with respect to a machine learning pipeline of a machine learning model;
for each detected call, generating a corresponding node that corresponds to the operator invoked thereby in a first execution graph that is representative of the machine learning pipeline and is structured in accordance with the first programming language;
providing the first execution graph to a graph execution engine;
generating, by the graph execution engine, a second execution graph that is structured in accordance with a second programming language; and
executing, by the graph execution engine, the second execution graph.

### Claim 15 (depends on 14)

The computer-readable storage medium of claim 14, wherein the method further comprises:
searching for the plurality of operators in an operator library;
generating a manifest that provides a definition for each operator in the plurality of operators; and
generating at least a portion of the API based on the manifest.

### Claim 16 (depends on 15)

The computer-readable storage medium of claim 15, wherein the definition for each operator specifies at least one of:
a name of the operator;
a description of the operator;
one or more inputs for the operator;
a data type for each of the one or more inputs;
a description for each of the one or more inputs;
one or more outputs for the operator;
a data type for each of the one or more outputs; or
a description for each of the one or more outputs.

### Claim 17 (depends on 14)

The computer-readable storage medium of claim 14, wherein the plurality of operators comprises one or more of:
a data transformation;
a data featurizer; or
a machine learning algorithm.

### Claim 18 (depends on 14)

The computer-readable storage medium of claim 14, wherein providing the first execution graph to the graph execution engine comprises:
providing the first execution graph to the graph execution engine responsive to receiving a call to a function that is configured to initiate the training of the machine learning model; and
wherein providing the first execution graph to the graph execution engine further comprises:
providing one or more pointers to memory in which data to be utilized by the second execution graph is located.

### Claim 19 (depends on 14)

The computer-readable storage medium of claim 14, wherein each node specifies at least one of:
a name of the corresponding operator;
one or more inputs for the corresponding operator;
one or more outputs for corresponding operator;
another node from which the one or more inputs are provided; or
another node to which the one or more outputs are provided.

### Claim 20 (depends on 14)

The computer-readable storage medium of claim 14, wherein the second execution graph comprises a plurality of nodes each of which corresponds to an operator and wherein said executing, by the graph execution engine, the second execution graph comprises:
for each node in the second execution graph, issuing a function call corresponding to the operator associated with the node, the function call being structured in accordance with the second programming language.
