Beyond MACs: Hardware Efficient Architecture Design for Vision Backbones
About
Vision backbone networks play a central role in modern computer vision. Enhancing their efficiency directly benefits a wide range of downstream applications. To measure efficiency, many publications rely on MACs (Multiply Accumulate operations) as a predictor of execution time. In this paper, we experimentally demonstrate the shortcomings of such a metric, especially in the context of edge devices. By contrasting the MAC count and execution time of common architectural design elements, we identify key factors for efficient execution and provide insights to optimize backbone design. Based on these insights, we present LowFormer, a novel vision backbone family. LowFormer features a streamlined macro and micro design that includes Lowtention, a lightweight alternative to Multi-Head Self-Attention. Lowtention not only proves more efficient, but also enables superior results on ImageNet. Additionally, we present an edge GPU version of LowFormer, that can further improve upon its baseline's speed on edge GPU and desktop GPU. We demonstrate LowFormer's wide applicability by evaluating it on smaller image classification datasets, as well as adapting it to several downstream tasks, such as object detection, semantic segmentation, image retrieval, and visual object tracking. LowFormer models consistently achieve remarkable speed-ups across various hardware platforms compared to recent state-of-the-art backbones. Code and models are available at https://github.com/altair199797/LowFormer/blob/main/Beyond_MACs.md.
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| Semantic segmentation | ADE20K (val) | mIoU44.6 | 2888 | |
| Image Classification | ImageNet-1K 1.0 (val) | Top-1 Accuracy83.6 | 1952 | |
| Visual Object Tracking | LaSOT (test) | AUC61.7 | 446 | |
| Object Detection | COCO 2017 | AP (Box)43.1 | 321 | |
| Image Classification | Stanford Cars (test) | -- | 316 | |
| Image Classification | Oxford Flowers-102 (test) | Top-1 Accuracy98.9 | 192 | |
| Image Classification | Oxford-IIIT Pets (test) | Mean Accuracy95 | 172 | |
| Image Classification | ImageNet | Top-1 Accuracy83.6 | 80 | |
| Image Retrieval | GPR1200 | mAP49 | 17 | |
| Image Classification | ImageNet-1k (val) | GPU Throughput (images/s)6.34e+3 | 16 |