通过分层任务向量实现测试时自适应,提升模型应对数据分布偏移的鲁棒性。
Hierarchical Adaptive networks with Task vectors for Test-Time Adaptation
- 构建分层动态适配网络,按需选择最合适的特征层进行调整。
- 在多个数据集上显著提升模型对复杂分布偏移的适应能力。
- 适合需要强鲁棒性的实际部署场景,如边缘计算与在线学习。
测试时自适应使预训练模型能在接收数据流时动态调整,以应对源域与目标域间的分布偏移。然而,现有方法依赖单一维度的线性分类层,难以处理多样化且复杂的偏移。本文提出分层自适应网络与任务向量(Hi-Vec),利用逐级增大的多层结构实现动态测试时适配。通过将编码器表示空间分解为层次化组织的多层,Hi-Vec以即插即用方式让现有方法适应不同复杂度的偏移。主要贡献有三:第一,提出动态层选择机制,自动识别每批测试数据的最佳适配层;第二,设计权重融合机制,使目标信息传递至所有层级;第三,引入线性层一致性作为门控函数,防止噪声批次导致错误微调。我们在挑战性场景和多个目标数据集上进行了严格评估,结果表明Hi-Vec显著提升了鲁棒性,缓解了不确定性,并能有效应对小批量与高异常率情况。
原文摘要 · Abstract (English)
Test-time adaptation allows pretrained models to adjust to incoming data streams, addressing distribution shifts between source and target domains. However, standard methods rely on single-dimensional linear classification layers, which often fail to handle diverse and complex shifts. We propose Hierarchical Adaptive Networks with Task Vectors (Hi-Vec), which leverages multiple layers of increasing size for dynamic test-time adaptation. By decomposing the encoder's representation space into such hierarchically organized layers, Hi-Vec, in a plug-and-play manner, allows existing methods to adapt to shifts of varying complexity. Our contributions are threefold: First, we propose dynamic layer selection for automatic identification of the optimal layer for adaptation to each test batch. Second, we propose a mechanism that merges weights from the dynamic layer to other layers, ensuring all layers receive target information. Third, we propose linear layer agreement that acts as a gating function, preventing erroneous fine-tuning by adaptation on noisy batches. We rigorously evaluate the performance of Hi-Vec in challenging scenarios and on multiple target datasets, proving its strong capability to advance state-of-the-art methods. Our results show that Hi-Vec improves robustness, addresses uncertainty, and handles limited batch sizes and increased outlier rates.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。