Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Practical Deep Learning at Scale with MLflow

You're reading from   Practical Deep Learning at Scale with MLflow Bridge the gap between offline experimentation and online production

Arrow left icon
Product type Paperback
Published in Jul 2022
Publisher Packt
ISBN-13 9781803241333
Length 288 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Yong Liu Yong Liu
Author Profile Icon Yong Liu
Yong Liu
Arrow right icon
View More author details
Toc

Table of Contents (17) Chapters Close

Preface 1. Section 1 - Deep Learning Challenges and MLflow Prime
2. Chapter 1: Deep Learning Life Cycle and MLOps Challenges FREE CHAPTER 3. Chapter 2: Getting Started with MLflow for Deep Learning 4. Section 2 –
Tracking a Deep Learning Pipeline at Scale
5. Chapter 3: Tracking Models, Parameters, and Metrics 6. Chapter 4: Tracking Code and Data Versioning 7. Section 3 –
Running Deep Learning Pipelines at Scale
8. Chapter 5: Running DL Pipelines in Different Environments 9. Chapter 6: Running Hyperparameter Tuning at Scale 10. Section 4 –
Deploying a Deep Learning Pipeline at Scale
11. Chapter 7: Multi-Step Deep Learning Inference Pipeline 12. Chapter 8: Deploying a DL Inference Pipeline at Scale 13. Section 5 – Deep Learning Model Explainability at Scale
14. Chapter 9: Fundamentals of Deep Learning Explainability 15. Chapter 10: Implementing DL Explainability with MLflow 16. Other Books You May Enjoy

Understanding DL model challenges

In this section, we will discuss DL model challenges. Let's look at the challenges at each stage of the DL life cycle, as depicted in Figure 1.3:

  • Data collection/cleaning/annotation: While the data challenge has already been stated, the challenge of linking data to the model of interest still exists. MLflow has native integration with Delta Lake so that any trained model can be traced back to a particular version within Delta Lake.
  • Model development: This is the time for trying lots of model frameworks, packages, and model selections. We need to track all the packages we use, along with the model parameters, hyperparameters, and model metrics in all experiments we run. Without a scalable and standardized way to track all experiments, this becomes a very tangled space. This not only causes trouble in terms of not knowing which experiments have been done so that we don't waste time doing them again, but it also creates problems when tracking which model is ready to be deployed or has already been deployed. Model serialization is another major challenge as different DL frameworks tend to use different ways to serialize the model. For example, pickle. (https://github.com/cloudpipe/cloudpickle) is usually used in serializing the model written in Python. However, TorchScript (https://pytorch.org/docs/stable/jit.html) is now highly performant for PyTorch models. In addition, Open Neural Network Exchange or ONNX (https://onnx.ai/) tries to provide more framework-agnostic DL serialization. Finally, we need to log the serialized model and register the model so that we can track model versioning. MLflow is one of the first open source tools to overcome these challenges.
  • Model deployment and serving in production: An easy-to-use model deployment tool that can tie into the model registry is a challenge. MLflow can be used to alleviate that, allowing you to load models for production deployment with full provenance tracking.
  • Model validation and A/B testing: During online validation and experimentation, model performance needs to be validated and user behavior metrics need to be collected. This is so that we can easily roll back or redeploy a particular version of the models. A model registry is critical for at-scale online model production validation and experimentation.
  • Monitoring and feedback loops: Model drifting and degradation over time is a real challenge. The visibility of model performance in production needs to be continuously monitored. Feedback data can be used to decide whether a model needs to be retrained.

In summary, DL model challenges in the full life cycle are unique. It is also worth pointing out a common framework that can assist the model development and online production back-and-forth is of great importance, as we don't want to use different tools just because the execution environment is different. MLflow provides this unified framework to bridge such gaps.

You have been reading a chapter from
Practical Deep Learning at Scale with MLflow
Published in: Jul 2022
Publisher: Packt
ISBN-13: 9781803241333
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image