Abstract
Vision-Language Pre-training (VLP) models have achieved remarkable success but often suffer from excessive computational costs, hindering deployment on edge devices. We present DLIP (Distilling Language-Image Pre-training), a systematic framework for compressing large-scale VLP models. DLIP utilizes a multi-layered distillation strategy during pre-training, targeting self-attention maps, cross-attention maps, and hidden representations. Our approach compresses the state-of-the-art BLIP model by 1.9× while maintaining or improving performance across various multimodal tasks, ultimately delivering a 2.7× inference speedup.
Introduction
Vision-Language Pre-training (VLP) models serve as the backbone for critical applications like image captioning and visual search. However, models such as BLIP or ALBEF typically contain hundreds of millions of parameters, making them difficult to deploy on mobile devices or resource-constrained servers. While Knowledge Distillation (KD) is a well-established technique for unimodal models, its application to multimodal architectures remains under-explored. The DLIP framework addresses this gap by establishing practical guidelines for building lightweight, high-performance multimodal models.
Methodology
The DLIP framework employs a multi-layered distillation strategy integrated directly into the pre-training phase. The architecture is based on a "Multimodal Mixture of Encoder-Decoder" (MED) structure, comprising a Vision Encoder (ViT), a Text Encoder (BERT), and a Multimodal Fusion module utilizing cross-attention.
To transfer knowledge from a large "teacher" model to a smaller "student," DLIP introduces two specific distillation objectives:
- Representation Distillation ($L_{HR}$): The student model aligns its hidden feature vectors with those of the teacher using a cosine loss.
- Attention-Based Distillation ($L_{AT}$): The student mimics the teacher's attention patterns by matching both self-attention and cross-attention maps.
Furthermore, the authors found that initializing the vision encoder with weights from an ImageNet-pre-trained model significantly enhances performance, whereas the text encoder can be effectively trained from scratch.
Datasets and Evaluation
Models were pre-trained on a combined dataset of approximately 4 million image-text pairs, including human-annotated data (COCO, Visual Genome) and web-crawled data (CC3M, SBU Captions). Scaling experiments were also conducted using the Conceptual 12M (CC12M) dataset. Performance was evaluated on standard benchmarks: Flickr30k for retrieval, COCO for captioning, and VQAv2 for Visual Question Answering.
Key Insights
The study revealed several critical principles for multimodal distillation:
- Balanced Compression: Scaling down both vision and text encoders proportionally yields better results than compressing a single modality aggressively.
- Fusion Efficiency: Multimodal fusion modules reach saturation quickly; approximately 6 layers of cross-attention are sufficient, with additional layers providing diminishing returns.
- Multimodal Context: Distilling using combined image and text features is significantly more effective than unimodal distillation.
- Decoder Distillation: For generative tasks like captioning, dedicated distillation of the decoder is essential to maintain output quality.
Experimental Results
DLIP achieves a state-of-the-art balance between accuracy and efficiency. The DLIP-Mid variant compresses the BLIP teacher from 213M to 108M parameters (a 1.9× reduction) while matching or exceeding the teacher's scores in retrieval and VQA tasks.
An even more efficient version, DLIP-Small, retains over 95% of the teacher's performance while utilizing only 22.4% of the parameters and 24.8% of the FLOPs. Notably, on the COCO captioning task, DLIP-Small achieved a CIDEr score of 124.7, outperforming other compressed baselines like DistillVLM. Overall, the framework enables a 2.7× acceleration in inference speed, facilitating real-time multimodal applications on edge devices.
Conclusion
DLIP demonstrates that systematic distillation can produce highly efficient VLP models without sacrificing multimodal intelligence. While the performance of the student remains influenced by the teacher's quality and the scale of pre-training data, DLIP provides a robust foundation for future research into billion-scale model compression and complex reasoning tasks.
Summary updated