arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2412.16901cs.LGcs.CV
收藏

通过测试时训练层学习为测试时适应生成梯度

Learning to Generate Gradients for Test-Time Adaptation via Test-Time Training Layers

South China University of Technology(华南理工大学);Nanyang Technological University(南洋理工大学);Artificial Intelligence Research Institute, Shenzhen MSU-BIT University(深圳北理莫斯科大学人工智能研究院)

Qi Deng, Shuaicheng Niu, Ronghao Zhang, Yaofo Chen, Runhao Zeng, Jian Chen, Xiping Hu

AI总结:

本文提出基于学习优化方法的Meta Gradient Generator(MGG),通过梯度记忆层利用历史梯度信息,解决测试时适应中无监督学习信号噪声导致的优化不稳定问题,以更少数据和迭代实现更高准确率与更快适应速度。

摘要:

测试时适应(TTA)旨在利用无标签测试数据在线微调已训练模型,以适应新环境或分布外数据,在现实场景中展现出广泛的应用潜力。然而,在该优化过程中,如熵最小化等无监督学习目标经常遇到噪声学习信号。这些信号产生不可靠的梯度,阻碍模型快速收敛至最优解的能力,并给优化过程引入显著的不稳定性。在本文中,我们寻求从优化器设计的角度解决这些问题。与以往使用如SGD等手动设计优化器的TTA不同,我们采用学习优化方法自动学习一个优化器,称为Meta Gradient Generator(MGG)。具体而言,我们旨在让MGG在在线优化过程中有效利用历史梯度信息来优化当前模型。为此,在MGG中,我们设计了一个轻量且高效的序列建模层——梯度记忆层。它利用自监督重建损失将历史梯度信息压缩到网络参数中,从而在长期适应过程中实现更好的记忆能力。我们仅需少量无标签样本预训练MGG,训练好的MGG即可部署处理未见样本。在ImageNet-C、R、Sketch和A上的优异结果表明,我们的方法以更少的更新、更少的数据和显著更短的适应迭代次数超越了当前最先进的方法。与先前的SOTA方法SAR相比,我们在ImageNet-C上实现了7.4%的准确率提升和4.2倍的适应速度提升。

英文摘要:

Test-time adaptation (TTA) aims to fine-tune a trained model online using unlabeled testing data to adapt to new environments or out-of-distribution data, demonstrating broad application potential in real-world scenarios. However, in this optimization process, unsupervised learning objectives like entropy minimization frequently encounter noisy learning signals. These signals produce unreliable gradients, which hinder the model ability to converge to an optimal solution quickly and introduce significant instability into the optimization process. In this paper, we seek to resolve these issues from the perspective of optimizer design. Unlike prior TTA using manually designed optimizers like SGD, we employ a learning-to-optimize approach to automatically learn an optimizer, called Meta Gradient Generator (MGG). Specifically, we aim for MGG to effectively utilize historical gradient information during the online optimization process to optimize the current model. To this end, in MGG, we design a lightweight and efficient sequence modeling layer -- gradient memory layer. It exploits a self-supervised reconstruction loss to compress historical gradient information into network parameters, thereby enabling better memorization ability over a long-term adaptation process. We only need a small number of unlabeled samples to pre-train MGG, and then the trained MGG can be deployed to process unseen samples. Promising results on ImageNet-C, R, Sketch, and A indicate that our method surpasses current state-of-the-art methods with fewer updates, less data, and significantly shorter adaptation iterations. Compared with a previous SOTA method SAR, we achieve 7.4% accuracy improvement and 4.2 times faster adaptation speed on ImageNet-C.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑