Fine-tuning is a technique that adapts a pre-trained model to a new task. It uses the knowledge learned from training on a large dataset and applies it to a smaller, task-specific dataset, improving performance while reducing training time.
Helps improve performance on domain specific tasks.
Types of Fine-Tuning
Fine-tuning can be performed in different ways depending on the amount of available data, computational resources and the specific requirements of the task.
1. Full Fine-Tuning
In Full Fine-Tuning, all the parameters of the pre-trained model are updated using the new dataset.
Updates every layer of the model.
Provides maximum flexibility and performance.
Requires significant computational resources and training time.
2. Feature Extraction
In Feature Extraction, the pre-trained model is used as a fixed feature extractor and only the final task-specific layers are trained.
Most layers remain frozen.
Faster and more computationally efficient.
Suitable when the new dataset is small.
3. Partial Fine-Tuning
In Partial Fine-Tuning, only selected layers of the model are updated while the remaining layers stay frozen.
Balances performance and computational cost.
Preserves general knowledge learned during pre-training.