kfp: Kubeflow Pipelines SDK
Kubeflow Pipelines is a platform for building and deploying portable, scalable machine learning workflows based on Docker containers within the Kubeflow project.
Use Kubeflow Pipelines to compose a multi-step workflow (pipeline) as a graph of containerized tasks using Python code and/or YAML. Then, run your pipeline with specified pipeline arguments, rerun your pipeline with new arguments or data, schedule your pipeline to run on a recurring basis, organize your runs into experiments, save machine learning artifacts to compliant artifact registries, and visualize it all through the Kubeflow Dashboard.
Documentation
Installation
To install the latest stable release, run:
pip install kfp
Getting started
The following is an example of a simple pipeline with one Python function-based component used in two separate tasks to do basic addition:
import kfp
from kfp.components import create_component_from_func
import kfp.dsl as dsl
def add(a: float, b: float) -> float:
'''Calculates sum of two arguments'''
return a + b
# create a component using the add function
add_op = create_component_from_func(add)
# compose your pipeline using the dsl.pipeline decorator
@dsl.pipeline(
name='Addition pipeline',
description='An example pipeline that performs addition calculations.')
def add_pipeline(
a: float=1.0,
b: float=7.0,
):
first_add_task = add_op(a=a, b=4.0)
second_add_task = add_op(a=first_add_task.output, b=b)
# instantiate a client and submit your pipeline with arguments
client = kfp.Client(host='<my-host-url>')
client.create_run_from_pipeline_func(
add_pipeline, arguments={
'a': 7.0,
'b': 8.0
})
For more information, refer to Building Python function-based components.
Release files for kfp 1.8.22
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| kfp-1.8.22.tar.gz | 304.9 kB | Details |
Release files / kfp-1.8.22.tar.gz
| Download URL | kfp-1.8.22.tar.gz |
|---|---|
| Size | 304.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3d300cb0f6d5bb303c1197f4d2740f2f27ab1fa6fd6aaa6dd8e72cfa85a72989
|
|
BLAKE2b-256 checksum How to use checksums |
4a45d621d339eb76885a8d6b912f8632b5c070867ac886df2fc5b21a575e2bd2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.7.12
|