Stack & Components
Understanding and working with ZenML Stacks and Stack Components
Last updated
Was this helpful?
Understanding and working with ZenML Stacks and Stack Components
Last updated
Was this helpful?
A is a collection of components that together form an MLOps infrastructure to run your ML pipelines. While your pipeline code defines what happens in your ML workflow, the stack determines where and how that code runs.
Stacks provide several key benefits:
Environment Flexibility: Run the same pipeline code locally during development and in the cloud for production
Infrastructure Separation: Change your infrastructure without modifying your pipeline code
Specialized Resources: Use specialized tools for different aspects of your ML workflow
Team Collaboration: Share infrastructure configurations across your team
Reproducibility: Ensure consistent pipeline execution across different environments
Each ZenML stack must include these core components:
Orchestrator: Controls how your pipeline steps are executed
Artifact Store: Manages where your pipeline artifacts are stored
Stacks may also include these optional components:
Container Registry: Stores Docker images for your pipeline steps
Step Operator: Runs specific steps on specialized hardware
Model Deployer: Deploys models as prediction services
Experiment Tracker: Tracks metrics and parameters
Feature Store: Manages ML features
Alerter: Sends notifications about pipeline events
Annotator: Manages data labeling workflows
In ZenML, you always have an active stack that's used when you run a pipeline:
You can create and manage stacks through the CLI:
Or through the Python API:
ZenML provides two main types of stacks:
Local Stack: Uses your local machine for orchestration and storage. This is the default and requires no additional setup.
Cloud Stack: Uses cloud services for orchestration, storage, and other components. These stacks offer more scalability and features but require additional deployment and configuration.
When you start with ZenML, you're automatically using a local stack. As your ML projects grow, you'll likely want to deploy cloud stacks to handle larger workloads and collaborate with your team.
Now that you understand what stacks are, you might want to:
Learn about on cloud platforms
Understand for authenticating with cloud services
Explore how to as ZenML stack components