Model Compression and Optimization Techniques
Make Models Smaller and Faster With Quantization, Pruning, Distillation, and ONNX, Then Prove the Speedup With a Real Benchmark. (MLOPS: ABSOLUTE BEGINNERS TO PRO IN 100 DAYS - DAY 62)
By Sandip Das · · 5 min read

💡
Hey — It's Sandip Das 👋
In Day 61 we rolled out iris v2 as a 20% canary and promoted it safely. Safe rollouts are great, but they don't make each prediction any cheaper: if the model is slow or huge, you pay for it on every request.
Today we look at how production teams shrink and speed up models: quantization, pruning and distillation, plus ONNX as a portable, optimized format. Then we benchmark sklearn vs ONNX Runtime on iris.
In Day 61 we rolled out iris v2 as a 20% canary and promoted it safely. Safe rollouts are great, but they don't make each prediction any cheaper: if the model is slow or huge, you pay for it on every request.
Today we look at how production teams shrink and speed up models: quantization, pruning and distillation, plus ONNX as a portable, optimized format. Then we benchmark sklearn vs ONNX Runtime on iris.
📚 Key Learnings
- Why model size and latency are cost and SLA problems, not just engineering trivia
- Quantization, pruning and knowledge distillation, and what each trades away
- What ONNX and ONNX Runtime are and why they speed up inference
- Converting a scikit-learn pipeline to ONNX and checking predictions match
- Hands-on: benchmark 1,000 predictions with sklearn vs ONNX Runtime
Read the full article on learnxops.com.
Topics: 100 Days of MLOps, MLOps, ML, Model Serving