arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2207.05501cs.CV
收藏

Next-ViT:下一代视觉Transformer,可在现实工业场景中高效部署

Next-ViT: Next Generation Vision Transformer for Efficient Deployment in Realistic Industrial Scenarios

ByteDance Inc(字节跳动公司)

Jiashi Li, Xin Xia, Wei Li, Huixia Li, Xing Wang, Xuefeng Xiao, Rui Wang, Min Zheng, Xin Pan

摘要:

由于复杂的注意力机制和模型设计,大多数现有的视觉Transformer(ViT)在现实的工业部署场景中,例如TensorRT和CoreML,不能像卷积神经网络(CNN)那样有效地执行。这提出了一个独特的挑战:视觉神经网络能否被设计成像CNN一样快速地推断,并像ViTs一样强大?最近的作品试图设计CNN-Transformer混合架构来解决这个问题,但这些作品的整体性能远远不能令人满意。为了结束这些,我们提出了下一代视觉Transformer,用于在现实的工业场景中进行有效部署,即Next-ViT,从延迟/准确性权衡的角度来看,它在CNN和ViT中占主导地位。在这项工作中,下一个卷积块(NCB)和下一个Transformer块(NTB)分别开发捕获本地和全局信息与部署友好的机制。然后,下一个混合策略(NHS)的设计堆叠NCB和NTB在一个有效的混合范例,提高性能的各种下游任务。大量的实验表明,Next-ViT在各种视觉任务的延迟/准确性权衡方面明显优于现有的CNN、ViT和CNN-Transformer混合架构。在TensorRT上,Next-ViT在COCO检测上超过ResNet 5.5 mAP(从40.4到45.9),在类似延迟下,在ADE 20 K分割上超过ResNet 7.7% mIoU(从38.8%到46.5%)。同时,它实现了与CSWin相当的性能,而推理速度则加快了3.6倍。在CoreML上,Next-ViT在COCO检测上超过EfficientFormer 4.6 mAP(从42.6到47.2),在类似延迟下,在ADE 20 K分割上超过EfficientFormer 3.5% mIoU(从45.1%到48.6%)。我们的代码和模型在https://github.com/bytedance/Next-ViT上公开

英文摘要:

Due to the complex attention mechanisms and model design, most existing vision Transformers (ViTs) can not perform as efficiently as convolutional neural networks (CNNs) in realistic industrial deployment scenarios, e.g. TensorRT and CoreML. This poses a distinct challenge: Can a visual neural network be designed to infer as fast as CNNs and perform as powerful as ViTs? Recent works have tried to design CNN-Transformer hybrid architectures to address this issue, yet the overall performance of these works is far away from satisfactory. To end these, we propose a next generation vision Transformer for efficient deployment in realistic industrial scenarios, namely Next-ViT, which dominates both CNNs and ViTs from the perspective of latency/accuracy trade-off. In this work, the Next Convolution Block (NCB) and Next Transformer Block (NTB) are respectively developed to capture local and global information with deployment-friendly mechanisms. Then, Next Hybrid Strategy (NHS) is designed to stack NCB and NTB in an efficient hybrid paradigm, which boosts performance in various downstream tasks. Extensive experiments show that Next-ViT significantly outperforms existing CNNs, ViTs and CNN-Transformer hybrid architectures with respect to the latency/accuracy trade-off across various vision tasks. On TensorRT, Next-ViT surpasses ResNet by 5.5 mAP (from 40.4 to 45.9) on COCO detection and 7.7% mIoU (from 38.8% to 46.5%) on ADE20K segmentation under similar latency. Meanwhile, it achieves comparable performance with CSWin, while the inference speed is accelerated by 3.6x. On CoreML, Next-ViT surpasses EfficientFormer by 4.6 mAP (from 42.6 to 47.2) on COCO detection and 3.5% mIoU (from 45.1% to 48.6%) on ADE20K segmentation under similar latency. Our code and models are made public at: https://github.com/bytedance/Next-ViT

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

↑