TL;DR
This paper introduces a novel constraint-based pre-training paradigm called WeiT that decouples size-agnostic knowledge from size-specific model configurations. By training reusable weight templates via Kronecker-based constraints, it enables parameter-efficient, minute-level initialization of models across diverse depths and widths without needing costly re-training or repeated distillation.
What Problem Does This Paper Address?
The standard "pre-train then fine-tune" paradigm is incredibly powerful, but it suffers from a major flexibility flaw: pre-trained models are typically delivered at a fixed scale (e.g., a standard ViT-B with exactly 12 layers). In the real world, deployment environments have strict and highly variable hardware constraints regarding memory, computational budgets, and latency.
When a target deployment size doesn't match the pre-trained configuration, practitioners usually resort to heuristic pruning or knowledge distillation. However, pruning often breaks the structured knowledge embedded in the weights, and distillation requires computationally expensive retraining for every single target size. This limitation exists because conventional pre-training tightly entangles learned knowledge with the specific architecture scale. The authors ask: Can we disentangle size-agnostic knowledge during pre-training to enable parameter-efficient initialization across scales?
Methods
The authors reformulate variable-sized model initialization as a multi-task adaptation problem, where each model size is treated as a distinct task.
To achieve this, they introduce WeiT (Weight Templates), which applies structured constraints during the pre-training phase:
- Unified Weight Templates: Instead of learning separate templates for different components (like attention vs. feed-forward layers), WeiT flattens and aggregates all primary weight matrices across all layers into a single unified weight matrix $W$.
- Kronecker-based Constraints: This unified matrix is decomposed using a Kronecker product: $W = T \otimes S$. Here, $T$ represents frozen, size-agnostic Weight Templates (a shared knowledge dictionary), while $S$ represents lightweight, size-specific Weight Scalers (combination coefficients).
- Template Scaling Mechanism: To handle width variations, the method applies dimension-wise dropout to the templates during pre-training. This prevents the templates from overfitting to a fixed width and allows them to be adaptively truncated or concatenated to match target model widths.
During downstream deployment, the large weight templates ($T$) remain frozen. Only the lightweight weight scalers ($S$) are optimized using a tiny fraction of downstream data. This optimization takes only a few hundred gradient steps, translating to minute-level wall-clock time.
Datasets
The authors evaluated WeiT across three distinct domains:
- Image Classification: Pre-trained on ImageNet-1K. Downstream transfer was evaluated on Oxford Flowers, CUB-200-2011, Stanford Cars, CIFAR-10, CIFAR-100, Food-101, and iNaturalist-2019.
- Image Generation: Class-conditional generation using Diffusion Transformers (DiTs) pre-trained on ImageNet-1K and transferred to CelebA-HQ, LSUN-Bedroom, LSUN-Church, Hubble, MRI, and Pokemon.
- Embodied Control: Universal morphology control tasks within the UNIMAL design space, pre-training on Flat Terrain and adapting to Variable Terrain, Incline, Obstacle, and Patrol.
Key Insights and Ideas
- Disentangling Scale from Knowledge: The paper proves that core structural knowledge (like the diagonal attention patterns in ViTs) is inherently size-agnostic and can be cleanly isolated from the network's macro-architecture.
- Unified Parameter Sharing: Merging heterogeneous components (MSA and FFN) into a single matrix reveals shared, underlying structural patterns that component-specific methods completely miss, enhancing template generality.
- Enduring Inductive Biases: Interestingly, the benefits of constraint-based pre-training persist even over extended training horizons. The templates act as permanent, helpful inductive structures rather than just a temporary "warm start."
Key Results
WeiT achieves state-of-the-art performance across all three evaluation domains while dramatically reducing computational overhead:
- Massive Speedups: Compared to training from scratch, WeiT reduces the downstream training cost by 11.1$\times$ for standard models (DeiT-B) and up to 37.5$\times$ for smaller models (DeiT-Ti).
- Cross-Architecture Generality: While designed with Transformers in mind, the authors successfully extended WeiT to convolutional spaces (ConvNeXt-v2), outperforming standard rule- and pruning-based initializations by up to 2.7% accuracy on ImageNet-1K.
- Robust Embodied Control: In reinforcement learning tasks, WeiT-initialized models converged faster and achieved significantly higher cumulative rewards across varying depths and widths compared to competitive baselines like HyperDistill and GRL.
Limitations and Future Work
- Operator Restrictions: The current Kronecker-based constraints are optimized for standard dense operators (linear projections and regular convolutions). They do not easily map to more heterogeneous operations like depth-wise convolutions without a careful architectural redesign.
- Extreme Domain Shifts: Because the weight templates are frozen during downstream initialization, the method assumes a baseline level of cross-domain transferability. Under massive domain shifts (e.g., natural images to highly specialized medical imagery), keeping $T$ entirely frozen can limit adaptation performance.
Future Directions: The authors point toward developing Cross-Modal Templates (sharing knowledge across vision and text) and exploring Adaptive Structure Learning to discover optimal constraint configurations automatically via data-driven differentiable searches.
Summary updated