Meetup

Kubeflow vs MLflow

Byron Allen, ServianEpisode 14 · 54:57 · May 2020 · 11K viewsHosted by Demetrios Brinkmann
Thumbnail for Kubeflow vs MLflow Watch on YouTube
TL;DR
  1. 1

    MLflow is a lightweight, broadly usable tool for tracking models, artifacts, parameters, and metrics, while Kubeflow is a Kubernetes-based system aimed at covering more of the machine learning lifecycle.

  2. 2

    MLflow is easier to install and use, but it does not manage the full lifecycle or track datasets natively, so teams must connect it with other tools.

  3. 3

    Kubeflow can fit on-premises and multi-cloud environments, but its Kubernetes requirement and fragmented ecosystem create more operational work.

Summary

Byron Allen explains why comparing MLflow and Kubeflow directly can mislead. MLflow is a lightweight package that practitioners can install locally or on a virtual machine to track model artifacts, parameters, metrics, and versions. Its Model Registry adds governance for models moving toward production. Kubeflow is a collection of components running on Kubernetes. It aims to support a broader workflow, from notebook-based discovery through pipeline development, training, deployment, and serving. Allen compares their setup effort, overlap, data versioning gaps, cloud options, and production use. MLflow is accessible to individual data scientists, although teams must handle code, dependencies, and dataset references separately. Kubeflow offers more lifecycle coverage and can be attractive for on-premises or multi-cloud work, but it needs Kubernetes knowledge and ongoing maintenance. Allen recommends assessing team maturity and the specific use case before choosing a platform.

Key ideas
05:11

MLflow tracks model work without requiring a larger platform

Byron Allen describes MLflow as a lightweight package that is a pip install away. It tracks models, artifacts, parameters, and metrics, giving teams a way to version the material associated with a model rather than tracking code alone. Artifacts can include files and images. MLflow can run locally, on a virtual machine, or with remote storage and buckets. Allen says its Model Registry, added during the previous year and a half, supports governance as models move toward production. This makes MLflow useful for practitioners who need experiment and model tracking without first standing up a complete machine learning platform.

06:36

Kubeflow covers more of the lifecycle and requires Kubernetes

Allen describes Kubeflow as a collection of components that runs on Kubernetes. It aims to cover the workflow from discovery with notebooks through pipeline development, model training, deployment, and model serving. This is a much broader scope than MLflow's artifact archive. Kubeflow requires a Kubernetes environment, while MLflow can run on a local machine or virtual machine. That difference affects who can install and operate each tool. A data science team with Kubernetes experience may find Kubeflow manageable, while a team without that background faces more setup and maintenance work.

09:14

MLflow and Kubeflow overlap around metadata and governance

The tools overlap because Kubeflow's Metadata component can store dependencies associated with models in a way that resembles MLflow's tracking. Allen considers MLflow's interface more user-friendly and more developed at the time of the talk. He also gives MLflow an important distinction through its Model Registry. The registry provides a process for governing models as they move into production, similar to approving code through a version-control workflow. Allen connects this need to emerging regulation and to organizations that cannot clearly answer which models are running in production.

16:11

MLflow is a practical starting point for teams with limited platform maturity

Allen says MLflow is useful as an introduction to the machine learning operations process because it has minimal overhead and is accessible. He does not call one product the best choice for every organization. Instead, he recommends considering the specific use case and the team's maturity. MLflow can be combined with other tools to cover more of the pipeline, but that combination requires hands-on integration. He describes the work of connecting separate tools as a major challenge when a team wants reproducibility and an automated training process. A focused use case can help a team learn what it actually needs before adopting a larger system.

21:57

MLflow does not natively solve dataset versioning or the whole lifecycle

One limitation Allen identifies is that MLflow does not track the training data itself in a fully integrated way. Changes in data variety or volume can affect a model, so teams need references or extracts that identify the data used. With MLflow, this can feel clunky because the extracts or references must be stored separately. Allen also says MLflow is not designed to fulfill the entire machine learning lifecycle. Teams may prefer to manage data versioning through an OLAP database or another data-specific tool, then use MLflow for model and experiment tracking.

24:06

Kubeflow can be combined with MLflow, but the extra integration may not pay off

Allen says MLflow and Airflow can be combined to manage tracking and orchestration, and MLflow can also be used inside Kubeflow Pipelines. Technically, a team could use MLflow for model tracking while using Kubeflow for pipeline work. He has not seen that combination used often because Kubeflow already includes model and artifact tracking capabilities. If a team builds enough around MLflow and Airflow, it may replace some of what Kubeflow provides, but Allen expects that approach to involve substantial work. His practical preference is to avoid adding Kubeflow when an existing combination already meets the need.

28:47

Cloud choice changes the case for Kubeflow

Allen compares Kubeflow with managed services such as SageMaker and Google's AI platform. The choice depends partly on where a team already runs its workflows. Kubeflow is attractive for on-premises and multi-cloud environments because it runs on Kubernetes. A team tied closely to one cloud may find that cloud provider's managed machine learning service more useful. Allen mentions Feast as an example of functionality available in the Kubeflow ecosystem. Feast decouples feature engineering from the data warehouse and can help generate and track features for reproducibility. Managed cloud services offer similar lifecycle capabilities with service-level agreements, while open-source components may not have the same guarantees.

31:49

Kubeflow's ecosystem is useful but still fragmented

Allen describes Kubeflow as useful but historically clunky, with improvements from tools such as Kale and Fairing. Kale can create Kubeflow Pipelines from a Jupyter notebook by adding annotations, which is convenient for data scientists. The trade-off is that the notebook becomes a dependency of the pipeline. Some data engineers may prefer Fairing's API-based approach for developing pipelines. Allen also compares Kubeflow to a collection of open-source projects brought together in one ecosystem. That creates compatibility problems, especially as components evolve. He says the experience has become more seamless, while still having room to grow.

33:52

Production readiness depends on operating context and team capability

Allen has seen organizations use Kubeflow in production, but says those teams typically spent a year or two developing the surrounding workflows and business use cases. The platform is only part of the work. Teams need a clear business problem, a workable data science process, and people who can operate the infrastructure. For an on-premises installation, he recommends having someone familiar with Kubernetes. Cloud deployment reduces some of the infrastructure burden, although a managed cloud service may then be more attractive. He also warns that setup is easier than maintenance. A platform must continue to work as its dependencies and components change.

"Kubeflow you need Kubernetes and it attempts to play the role of an end-to-end pipeline all the way from discovery using notebooks through to pipeline development training the model and then putting it into production."Byron Allen07:00
Who should watch
  • You are choosing between MLflow, Kubeflow, and a managed cloud machine learning service and need to understand the trade-offs.
  • Your data science team wants experiment tracking but has limited Kubernetes or DevOps support.
  • You are building a production machine learning workflow and need to separate model tracking, data versioning, orchestration, and serving decisions.