arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2105.15203cs.CVcs.LG
收藏

SegFormer:基于Transformers的简单高效语义分割设计

SegFormer: Simple and Efficient Design for Semantic Segmentation with Transformers

The University of Hong Kong(香港大学);Nanjing University(南京大学);NVIDIA(英伟达);Caltech(加州理工学院)

Enze Xie, Wenhai Wang, Zhiding Yu, Anima Anandkumar, Jose M. Alvarez, Ping Luo

摘要:

我们提出了SegFormer,一个简单,高效而强大的语义分割框架,它将Transformers与轻量级多层感知(MLP)解码器相结合。SegFormer具有两个吸引人的特征:1)SegFormer包括一种新颖的分层结构的Transformer编码器,其输出多尺度特征。它不需要位置编码,从而避免了位置代码的内插,当测试分辨率与训练不同时,位置代码的内插导致性能降低。2)SegFormer避免了复杂的解码器。所提出的MLP解码器聚合来自不同层的信息,从而结合局部注意力和全局注意力来呈现强大的表示。我们表明,这种简单而轻便的设计是有效的分割Transformers的关键。我们扩展了我们的方法,以获得从SegFormer-B 0到SegFormer-B5的一系列模型,达到比以前的同行更好的性能和效率。例如,SegFormer-B4在具有64 M参数的ADE 20 K上实现了50.3%的mIoU,比之前的最佳方法小5倍,好2.2%。我们的最佳模型SegFormer-B5在Cityscapes验证集上实现了84.0%的mIoU,并在Cityscapes-C上显示出出色的zero-shot鲁棒性。代码将在github.com/NVlabs/SegFormer上发布。

英文摘要:

We present SegFormer, a simple, efficient yet powerful semantic segmentation framework which unifies Transformers with lightweight multilayer perception (MLP) decoders. SegFormer has two appealing features: 1) SegFormer comprises a novel hierarchically structured Transformer encoder which outputs multiscale features. It does not need positional encoding, thereby avoiding the interpolation of positional codes which leads to decreased performance when the testing resolution differs from training. 2) SegFormer avoids complex decoders. The proposed MLP decoder aggregates information from different layers, and thus combining both local attention and global attention to render powerful representations. We show that this simple and lightweight design is the key to efficient segmentation on Transformers. We scale our approach up to obtain a series of models from SegFormer-B0 to SegFormer-B5, reaching significantly better performance and efficiency than previous counterparts. For example, SegFormer-B4 achieves 50.3% mIoU on ADE20K with 64M parameters, being 5x smaller and 2.2% better than the previous best method. Our best model, SegFormer-B5, achieves 84.0% mIoU on Cityscapes validation set and shows excellent zero-shot robustness on Cityscapes-C. Code will be released at: github.com/NVlabs/SegFormer.

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

↑