Skip to content

Commit

Permalink
Merge branch 'develop' into bugfix/sagemaker-training-job-name
Browse files Browse the repository at this point in the history
  • Loading branch information
strickvl authored Apr 28, 2023
2 parents 4e1fe24 + d8e1d1c commit be06686
Show file tree
Hide file tree
Showing 64 changed files with 939 additions and 784 deletions.
10 changes: 9 additions & 1 deletion docs/book/advanced-guide/pipelines/settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Settings are categorized into two types:
- **General settings** that can be used on all ZenML pipelines. Examples of these are:
- [`DockerSettings`](../../starter-guide/production-fundamentals/containerization.md) to specify docker settings.
- [`ResourceSettings`](./step-resources.md) to specify resource settings.
- **Stack component specific settings**: These can be used to supply runtime configurations to certain stack components (key= <COMPONENT_CATEGORY>.<COMPONENT_FLAVOR>). Settings for components not in the active stack will be ignored. Examples of these are:
- **Stack component specific settings**: These can be used to supply runtime configurations to certain stack components `(key= <COMPONENT_CATEGORY>.<COMPONENT_FLAVOR>)`. Settings for components not in the active stack will be ignored. Examples of these are:
- [`KubeflowOrchestratorSettings`](../../component-gallery/orchestrators/kubeflow.md) to specify Kubeflow settings.
- [`MLflowExperimentTrackerSettings`](../../component-gallery/experiment-trackers/mlflow.md) to specify MLflow settings.
- [`WandbExperimentTrackerSettings`](../../component-gallery/experiment-trackers/wandb.md) to specify W&B settings.
Expand Down Expand Up @@ -72,6 +72,14 @@ Or like this:
settings={'docker': {'requirements': ['pandas']}}
```

#### Using stack component specific settings
Settings for stack components must be passed with the key having a specific format: `<COMPONENT_CATEGORY>.<COMPONENT_FLAVOR>`. For example, an instance of [`SagemakerStepOperatorSettings`](https://apidocs.zenml.io/latest/integration_code_docs/integrations-aws/#zenml.integrations.aws.flavors.sagemaker_step_operator_flavor.SagemakerStepOperatorSettings) for the [SageMaker Step Operator](../../component-gallery/step-operators/sagemaker.md) can be passed in as follows:

```python
from zenml.integrations.aws.flavors.sagemaker_step_operator_flavor import SagemakerStepOperatorSettings
settings = { 'step_operator.sagemaker': SagemakerStepOperatorSettings(estimator_args={}) }
```

### How to use settings

#### Method 1: Directly on the decorator
Expand Down
45 changes: 0 additions & 45 deletions src/zenml/artifacts/__init__.py

This file was deleted.

49 changes: 0 additions & 49 deletions src/zenml/artifacts/base_artifact.py

This file was deleted.

28 changes: 0 additions & 28 deletions src/zenml/artifacts/data_analysis_artifact.py

This file was deleted.

23 changes: 0 additions & 23 deletions src/zenml/artifacts/data_artifact.py

This file was deleted.

23 changes: 0 additions & 23 deletions src/zenml/artifacts/model_artifact.py

This file was deleted.

23 changes: 0 additions & 23 deletions src/zenml/artifacts/schema_artifact.py

This file was deleted.

24 changes: 0 additions & 24 deletions src/zenml/artifacts/service_artifact.py

This file was deleted.

23 changes: 0 additions & 23 deletions src/zenml/artifacts/statistics_artifact.py

This file was deleted.

20 changes: 20 additions & 0 deletions src/zenml/cli/code_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,20 @@ def code_repository() -> None:
required=False,
help="Module containing the code repository implementation if type is custom.",
)
@click.option(
"--description",
"-d",
type=str,
required=False,
help="The code repository description.",
)
@click.option(
"--logo-url",
"-l",
type=str,
required=False,
help="URL of a logo (png, jpg or svg) for the code repository.",
)
@click.argument(
"args",
nargs=-1,
Expand All @@ -67,6 +81,8 @@ def register_code_repository(
name: str,
type_: str,
source_path: Optional[str],
description: Optional[str],
logo_url: Optional[str],
args: List[str],
) -> None:
"""Register a code repository.
Expand All @@ -81,6 +97,8 @@ def register_code_repository(
name: Name of the code repository
type_: Type of the code repository
source_path: Path to the source module if type is custom
description: The code repository description.
logo_url: URL of a logo (png, jpg or svg) for the code repository.
args: Additional arguments to be passed to the code repository
"""
cli_utils.print_active_config()
Expand Down Expand Up @@ -138,6 +156,8 @@ def register_code_repository(
name=name,
config=parsed_args,
source=source,
description=description,
logo_url=logo_url,
)

cli_utils.declare(f"Successfully registered code repository `{name}`.")
Expand Down
Loading

0 comments on commit be06686

Please sign in to comment.