AdPE:通过MAE +实现预训练视觉Transformer的对抗性位置嵌入
AdPE: Adversarial Positional Embeddings for Pretraining Vision Transformers via MAE+
摘要:
视觉Transformer的无监督学习试图通过没有标签的借口任务来预训练编码器。其中之一是Masked Image Modeling(MIM),它通过预测掩码补丁作为借口任务,与语言Transformers的预训练保持一致。无监督预训练中的一个标准是,托词任务需要足够困难,以防止Transformer编码器学习不能很好地推广到下游任务的琐碎低级特征。为此,我们提出了一种对抗性位置嵌入(AdPE)方法--它通过扰动位置编码来扭曲局部视觉结构,使得学习的Transformer不能简单地使用局部相关的补丁来预测丢失的补丁。我们假设它迫使Transformer编码器在全局上下文中学习更多的判别特征,并具有更强的下游任务的泛化能力。我们将考虑绝对和相对位置编码,其中可以在嵌入模式和坐标模式中施加对抗位置。我们还将提出一个新的MAE+基线,使MIM预训练的性能与AdPE达到一个新的水平。实验结果表明,在Imagenet 1 K上对ViT-B和ViT-L进行1600次预训练后,我们的方法可以通过$0.8\%$和$0.4\%$提高MAE的微调精度。对于迁移学习任务,它的性能优于具有ViT-B主干的MAE,分别是ADE 20 K上mIoU中的$2.6\%$,以及COCO上AP $^{bbox}$中的$3.2\%$和AP $^{mask}$中的$1.6\%$。这些结果是通过AdPE获得的,AdPE是一种纯MIM方法,不使用任何额外的模型或外部数据集进行预训练。该代码可在https://github.com/maple-research-lab/AdPE上获得。
英文摘要:
Unsupervised learning of vision transformers seeks to pretrain an encoder via pretext tasks without labels. Among them is the Masked Image Modeling (MIM) aligned with pretraining of language transformers by predicting masked patches as a pretext task. A criterion in unsupervised pretraining is the pretext task needs to be sufficiently hard to prevent the transformer encoder from learning trivial low-level features not generalizable well to downstream tasks. For this purpose, we propose an Adversarial Positional Embedding (AdPE) approach -- It distorts the local visual structures by perturbing the position encodings so that the learned transformer cannot simply use the locally correlated patches to predict the missing ones. We hypothesize that it forces the transformer encoder to learn more discriminative features in a global context with stronger generalizability to downstream tasks. We will consider both absolute and relative positional encodings, where adversarial positions can be imposed both in the embedding mode and the coordinate mode. We will also present a new MAE+ baseline that brings the performance of the MIM pretraining to a new level with the AdPE. The experiments demonstrate that our approach can improve the fine-tuning accuracy of MAE by $0.8\%$ and $0.4\%$ over 1600 epochs of pretraining ViT-B and ViT-L on Imagenet1K. For the transfer learning task, it outperforms the MAE with the ViT-B backbone by $2.6\%$ in mIoU on ADE20K, and by $3.2\%$ in AP$^{bbox}$ and $1.6\%$ in AP$^{mask}$ on COCO, respectively. These results are obtained with the AdPE being a pure MIM approach that does not use any extra models or external datasets for pretraining. The code is available at https://github.com/maple-research-lab/AdPE.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。