Member-only story
Transfer Learning: Why We Freeze and Unfreeze Model Layers
Choosing the Right Layers to Freeze When Fine-tuning | Data Science for Machine Learning Series (3)
If you are not a paid member on Medium, I make my stories available for free: Friends link
When it comes to modern deep learning, transfer learning is like a secret superpower. Instead of starting from scratch every time, we take a model that’s already learned something useful and build on top of it for our new task. It’s so hype that everyone is doing it.
But fine-tuning a pre-trained model isn’t just about throwing some new data at it and hoping for the best. It’s about carefully deciding which parts of the model’s knowledge to keep, and which parts to allow to change.
This process of freezing and unfreezing layers is what makes transfer learning both powerful in practice and surprisingly intuitive once you break it down. Of course there are other parameters that you need to tune, but for the sake of this article, I’ll only focus on this part.
As I go along, I’ll not only cover the technical side of freezing and unfreezing, but also examine the “why” behind it. I’ll use real-world analogies, practical strategies, and…