In recent years, the applications of Machine Learning have spread across diverse segments of the industry, hence making it an extremely crucial element for the growth of the businesses. However, the potential of these applications has not been fully exploited as most of them cannot make it to production. To mitigate this problem, a new concept of MLOps has been introduced which builds upon the already existing practice of DevOps. So, you might be wondering how MLOps is different from DevOps? Don’t worry, you have come to the right place. Let’s get started.
What is DevOps?
DevOps consist of a set of strategies that help to ensure a smooth development life cycle along with maintaining Continuous Integration (CI) and Continuous Development (CD) pipelines for successful production. It basically helps ease the process of adding new features, testing, monitoring and granting appropriate rights to different members involved in the project. The figure below demonstrates a DevOps lifecycle.
What is MLOps?
MLOps is a set of practices that help with development, deployment and governance of ML models throughout their lifecycle. It incorporates the operations (‘Ops’) part from DevOps as it includes Continuous Integration (CI) and Continuous Delivery (CD) pipelines in addition to its own Continuous Training (CT) pipeline. In contrast with DevOps, MLOps require not only managing model artefacts but also maintaining versions of data and various parameters. A sample MLOps life cycle influenced by DevOps is demonstrated below.
Comparison of DevOps and MLOps life cycles:
Development: In DevOps, the development part involves writing code for an application and building the final executable whereas in MLOps, tasks such as data preprocessing, model training and evaluation are part of development which produce a final model file.
Continuous Integration: With continuous integration in DevOps, new features can be added to the existing product after ensuring code reproducibility. In MLOps, retraining the model after adding new data or changing some part of code belongs to the continuous integration phase.
Versioning: Maintaining and efficiently managing different versions of the code is a part of DevOps versioning. On the other hand, MLOps require keeping a track of versions of data, train-test split while training, model files, hyperparameters, performance of the model with different evaluation metrics.
Continuous Delivery: Continuous Delivery in DevOps involves making sure the tests work fine and the product with its updates can be successfully released for the production. Quite similarly, MLOps also involves successful deployments to staging and production environments accompanied by progressive testing for continuous delivery.
Monitoring: Monitoring in general refers to comprehensively checking each and every stage of the pipeline for any bugs or anomalies to ensure long term success of a product. In MLOps, the performance of the model needs to be examined to check for any difference in the model’s properties. Over time, differences in the data used for training the model and the data on which model is tested can give unexpected results. Hence, monitoring keeps a check on issues such as data drift and model drift.
Open Source Tools for DevOps and MLOps:
Now, let’s take a look at the most popular open source tools for DevOps and MLOps automation.
Top 3 tools for DevOps Automation:
Kubernetes: This tool automates the process of manually releasing the microservices. It helps with deployment and maintenance of groups of containers in production.
Docker: Docker enables running of an application inside a container. This lightweight container consists of dependencies and libraries required to run the program.
Git: Git is definitely the most widely used tool for code versioning, collaboration, and CI/CD processes.
Top 3 tools for MLOps Automation:
Kubeflow: This is an open source tool for the development and productionisation of the ML projects. It has integration with various frameworks for the complete workflow.
MLflow: This tool primarily helps with the model building, tracking of experiments, model versioning, and model governance for the MLOps lifecycle.
Seldon Core: It provides the functionalities to test, log the models with various metrics. It also provides support to easily build containers and deploy them for production.
In this blog, we briefly understood the core differences between DevOps and MLOps. We also looked at the most popular open source tools available for the DevOps and MLOps life cycles.