TL;DR
ConvNeXt modernizes the classic ResNet architecture by systematically integrating design choices from Vision Transformers (ViTs) without adding any self-attention mechanisms. The resulting pure convolutional network matches or outperforms state-of-the-art Transformers in accuracy, scalability, and hardware efficiency across major computer vision benchmarks.
What Problem Does This Paper Address?
The early 2020s saw a massive paradigm shift in computer vision: Vision Transformers (ViTs) and hierarchical variants like Swin Transformers rapidly overtook Convolutional Neural Networks (ConvNets) as the state-of-the-art backbones for visual recognition. This led to a widespread belief that the self-attention mechanism was inherently superior to convolution.
However, hierarchical Transformers actually reintroduced several classic ConvNet priors (like local windows and multi-stage architectures). The authors of this paper ask a fundamental question: Is the success of Transformers truly due to the intrinsic superiority of self-attention, or is it a reflection of modernized macro/micro design choices and superior training techniques? To answer this, they test the limits of pure ConvNets by gradually evolving a standard ResNet into a Transformer-like architecture.
Methods
The authors take a standard ResNet (ResNet-50/200) and apply a step-by-step "modernization roadmap" inspired by Swin Transformers, completely avoiding attention modules:
- Modern Training Recipe: They swap standard SGD for the AdamW optimizer, extend training to 300 epochs, and introduce advanced data augmentations (Mixup, Cutmix, RandAugment) and regularization schemes.
- Macro Design Adjustments: They change the stage compute ratio from ResNet's empirical distribution to Swin’s 1:1:3:1 ratio (specifically, 3:3:9:3 blocks per stage). They also replace the traditional stem with a 4×4, stride-4 "patchify" convolutional layer.
- ResNeXt-ify: They adopt depthwise convolutions (where the number of groups equals the number of channels). This effectively separates spatial mixing from channel mixing, mimicking the behavior of self-attention.
- Inverted Bottleneck: They implement an inverted bottleneck structure where the hidden dimension of the block is four times wider than the input dimension—matching the design of Transformer MLP blocks.
- Large Kernel Sizes: They move the depthwise convolutional layer up in the block and increase the kernel size from 3×3 to 7×7, matching Swin’s local window size.
- Micro-level Refinements: They replace ReLU with GELU activations, drastically reduce the number of activation and normalization layers, substitute BatchNorm (BN) with LayerNormalization (LN), and introduce separate downsampling layers between stages.
The final optimized architecture family is named ConvNeXt.
Datasets
The models were trained and evaluated on several standard computer vision benchmarks:
- ImageNet-1K: Used for standard image classification training and evaluation (1.2 million images across 1,000 classes).
- ImageNet-22K: A larger dataset (~14 million images, 21,841 classes) used to evaluate the architecture's large-scale pre-training and scalability behaviors.
- COCO: Used to evaluate downstream object detection and instance segmentation performance via Mask R-CNN and Cascade Mask R-CNN frameworks.
- ADE20K: Used to evaluate semantic segmentation performance via the UperNet framework.
Key Insights and Ideas
- Optimization Matters Immensely: Simply updating the training recipe boosted the baseline ResNet-50 performance by 2.7% (from 76.1% to 78.8%), showing that a significant portion of the Transformer's perceived superiority stemmed from modern training tricks.
- Convolutions Can Scale: ConvNeXt proves that pure ConvNets can scale just as effectively as Transformers when pre-trained on massive datasets like ImageNet-22K, debunking the idea that only Transformers benefit from scale.
- Simplicity Wins on Hardware: Because ConvNeXt relies entirely on standard, highly optimized convolutional operations and avoids complex mechanisms like shifted windows or relative position biases, it achieves significantly higher inference throughput on modern GPUs.
Key Results
- ImageNet-1K Classification: ConvNeXt-T achieved 82.1% top-1 accuracy, outperforming Swin-T (81.3%). When scaled up and pre-trained on ImageNet-22K, ConvNeXt-XL reached a peak top-1 accuracy of 87.8%.
- Downstream Tasks: On COCO object detection, ConvNeXt outperformed Swin Transformers across equivalent model complexities (e.g., ConvNeXt-B achieved 54.0% box AP vs. Swin-B's 53.0%). On ADE20K semantic segmentation, ConvNeXt-L achieved 53.7% mIoU, beating Swin-L (53.5%).
- Hardware Efficiency: On an NVIDIA A100 GPU, ConvNeXt models enjoyed up to a 49% higher inference throughput compared to their Swin Transformer counterparts of similar FLOP complexities. They also proved to be less memory-intensive during training.
Limitations and Future Work
While ConvNeXt proves to be an exceptional backbone for standard vision tasks, the authors acknowledge that Transformers may still retain an edge in flexibility for specific domains:
- Multi-modal Learning: In tasks requiring cross-attention between different modalities (e.g., text and video processing), Transformer modules remain highly preferable.
- Structured Outputs: Transformers may be inherently more flexible when dealing with tasks that require discretized, sparse, or highly structured outputs.
The authors suggest that future research should continue exploring the robustness, fairness, and broader application boundaries of modernized ConvNets compared to Transformers.
Summary updated