DrDroid
Resource Cheatsheet

Kubeflow Pipelines

Quick reference guide and commands for Kubeflow Pipelines.

Download PDF

Setup and Connection

pip install kfp
Install Kubeflow Pipelines SDK

kubectl port-forward -n kubeflow svc/ml-pipeline-ui 8080:80
Port forwarding to access Kubeflow Pipelines UI

kfp connect --endpoint http://localhost:8080
Connect to a local Kubeflow Pipelines instance

kfp connect --endpoint https://your-kubeflow-domain.com
Connect to a remote Kubeflow Pipelines instance

Pipeline Management

kfp pipeline list
List all pipelines

kfp pipeline get [PIPELINE_ID]
Get pipeline details

kfp pipeline upload [PIPELINE_PACKAGE_PATH]
Upload a pipeline package

kfp pipeline delete [PIPELINE_ID]
Delete a pipeline

Experiment Management

kfp experiment list
List all experiments

kfp experiment create [EXPERIMENT_NAME]
Create a new experiment

kfp experiment get [EXPERIMENT_ID]
Get experiment details

kfp experiment delete [EXPERIMENT_ID]
Delete an experiment

Run Management

kfp run list
List all runs

kfp run get [RUN_ID]
Get run details

kfp run create --experiment-name [EXPERIMENT_NAME] --pipeline-id [PIPELINE_ID]
Create a run

kfp run delete [RUN_ID]
Delete a run

Recurring Run Management

kfp recurring_run list
List all recurring runs

kfp recurring_run get [RECURRING_RUN_ID]
Get recurring run details

kfp recurring_run create --experiment-name [EXPERIMENT_NAME] --pipeline-id [PIPELINE_ID] --cron-expression [CRON]
Create a recurring run

kfp recurring_run delete [RECURRING_RUN_ID]
Delete a recurring run

Python SDK Examples

client = kfp.Client()
Initialize the KFP client

client.list_pipelines()
List pipelines using Python SDK

client.get_experiment(experiment_name='default')
Get experiment by name

client.run_pipeline(experiment_id, pipeline_name, params)
Run a pipeline with parameters