nv_dfm_core.api.Pipeline#
- class nv_dfm_core.api.Pipeline(*, dfm_body=[], api_version='', mode='execute', name=None)[source]#
Represents a DFM pipeline containing a sequence of operations and control flow.
A Pipeline is the top-level construct that defines the workflow to be executed across a federation. It contains statements, operations, and control structures.
- Parameters:
dfm_body (list[Statement])
api_version (str)
mode (Literal['execute', 'discovery'])
name (str | None)
- classmethod load_from_file(file, **fsspec_kwargs)[source]#
Load a stored pipeline from a .json file.
- The file argument can be:
a local filename (str or Path)
a remote URI (e.g., s3://bucket/file.json, gs://bucket/file.json, etc.)
any fsspec-compatible URL
If fsspec is installed, it will be used for all paths (including local). If fsspec is not installed, only local files are supported.
Additional keyword arguments are passed to fsspec.filesystem().
- Parameters:
file (str | Path)
fsspec_kwargs (Any)
- Return type:
- model_config: ConfigDict = {'extra': 'forbid', 'frozen': True}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- classmethod save_to_file(pipeline, file, **fsspec_kwargs)[source]#
Store a pipeline to a .json file.
- The file argument can be:
a local filename (str or Path)
a remote URI (e.g., s3://bucket/file.json, gs://bucket/file.json, etc.)
any fsspec-compatible URL
If fsspec is installed, it will be used for all paths (including local). If fsspec is not installed, only local files are supported.
Additional keyword arguments are passed to fsspec.filesystem().
- Parameters:
pipeline (Pipeline)
file (str | Path)
fsspec_kwargs (Any)
- Return type:
None