Graph Class
A class to define a pipeline run graph.
Initialize Graph.
- Inheritance
-
builtins.objectGraph
Constructor
Graph(name, context)
Parameters
- context
- <xref:azureml.pipeline.core._GraphContext>
The current graph context.
- context
- <xref:azureml.pipeline.core._GraphContext>
The current graph context.
Methods
add_datasource_node |
Add a datasource node to the graph. |
add_module_node |
Add a module node to the graph. |
connect |
Connect two ports and creates an Edge. |
delete_node |
Delete a node from the graph. |
finalize |
Finalize resources for nodes in the graph. |
generate_yaml |
Generate the yaml representation of the graph. |
get_node |
Get a node by ID. |
sequence |
Configure a list of nodes to run in a sequence following the first node in the list. |
submit |
Submit the graph to run in the cloud. |
validate |
Validate graph. Returns a list of errors. |
add_datasource_node
Add a datasource node to the graph.
add_datasource_node(name, datasource=None, datasource_builder=None, datapath_param_name=None)
Parameters
- datasource_builder
- <xref:azureml.pipeline.core._DatasourceBuilder>
_DatasourceBuilder for this node.
Returns
node
Return type
add_module_node
Add a module node to the graph.
add_module_node(name, input_bindings, output_bindings=None, param_bindings=None, module=None, module_builder=None, module_wiring=None, runconfig=None, cloud_settings=None)
Parameters
- module_builder
- <xref:azureml.pipeline.core._ModuleBuilder>
_ModuleBuilder for this node
A mapping between the node's inputs/outputs and the module inputs/outputs. Holds two keys, inputs and outputs, each mapped to a dict whose keys are the module's inputs/outputs names, and the values are the node's ports.
- cloud_settings
- <xref:azureml.pipeline.core._restclients.aeva.models.CloudSettings>
Settings that will be used for clouds
Returns
node
Return type
connect
Connect two ports and creates an Edge.
connect(source_port, dest_port)
Parameters
Returns
edge
Return type
delete_node
finalize
Finalize resources for nodes in the graph.
finalize(dry_run=None, regenerate_outputs=False)
Parameters
- dry_run
- bool
Set to True to verify that the graph can be built without making any external API calls to Azure ML service.
- regenerate_outputs
- bool
Set to True to force a new run (disallows module/datasource reuse).
Returns
Dictionary of {node_id, (resource_id, is_new_resource)}
Return type
generate_yaml
Generate the yaml representation of the graph.
generate_yaml()
Returns
Return the yaml dict
Return type
get_node
Get a node by ID.
get_node(node_id)
Parameters
Returns
The node.
Return type
sequence
Configure a list of nodes to run in a sequence following the first node in the list.
sequence(nodes)
Parameters
submit
Submit the graph to run in the cloud.
submit(pipeline_parameters=None, continue_on_step_failure=False, regenerate_outputs=False, parent_run_id=None, **kwargs)
Parameters
- continue_on_step_failure
- bool
Indicates whether to let the experiment continue executing if one step fails. If True, only steps that have no dependency on the output of the failed step will continue execution.
- regenerate_outputs
- bool
Set to True to force a new run (disallows module/datasource reuse)
- parent_run_id
Optional run ID to set for the parent run of this pipeline run, which is reflected in RunHistory. The parent run must belong to same experiment as this pipeline is being submitted to.
Returns
A PipelineRun.
Return type
validate
Attributes
datasource_nodes
edges
module_nodes
node_dict
node_name_dict
Get a dictionary containing all nodes indexed by name.
Returns
Dictionary of {node name, Node}
Return type
nodes
params
Get a dictionary containing all graph parameters. Values are literal types or data reference as JSON string.
Returns
Dictionary of {param name, param value}
Return type
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for