# Understanding How Image Quality Affects Transformer Neural Networks
## 4 Results
This characteristic of JPEG compression often results in perceptually similar images despite significant compression, which may not significantly affect the performance of transformer models. Further, transformer models leverage self-attention mechanisms to capture long-range dependencies and relationships between different parts of an image. This allows them to focus on relevant features while disregarding irrelevant or noisy information. As a result, transformer models can effectively handle the distortions introduced by JPEG compression without significantly compromising performance. Figure 1: Top-1 accuracy rates under different additive Gaussian distortions. (**a**) SwiftFormer-X, SwiftFormer-X, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. (**b**) CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. (**c**) Swin-S, Swin-B, Swin-L, MobileViT-XS, MobileViT-S. (**d**) ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 3: Top-1 accuracy rates under Gaussian blur. **(a)** SwiftFormer-XS, SwiftFormer-S, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. **(b)** CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L7. **(c)** Swin-S, Swin-B, Swin-L, MobileViT-XS, MobileViT-S, MobileViT-S. **(d)** ViT-L/16, VeViT-128, LeViT-256, LeViT-384. Figure 2: Top-1 accuracy rates under different multiplicative Gaussian distortions. **(a)** SwiftFormer-XS, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. **(b)** CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. **(c)** Swin-S, Swin-B, Swin-L, MobileViT-XS, MobileViT-XS, MobileViT-S. **(d)** ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 4: Top-1 accuracy rates under different salt-and-pepper distortions. (**a**) SwiftFormer-XS, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. (**b**) CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. (**c**) Swin-S, Swin-B, Swin-L, MobileViT-XXS, MobileViT-XS, MobileViT-S. (**d**) ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 5: Top-1 accuracy rates under different JPEG distortions. (**a**) SwiftFormer-XS, SwiftFormer-S, SwiftFormer-S, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. (**b**) CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L7. (**c**) Swin-S, Swin-B, Swin-L, MobileViT-XXS, MobileViT-XS, MobileViT-S. (**d**) ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 6: Top-5 accuracy rates under different additive Gaussian distortions. (**a**) SwiftFormer-XS, SwiftFormer-S, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. (**b**) CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. (**c**) Swin-S, Swin-B, Swin-L, MobileViT-XXS, MobileViT-XS, MobileViT-S. (**d**) ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 7: Top-5 accuracy rates under different multiplicative Gaussian distortions. (**a**) SwiftFormer-XS, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. (**b**) CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. (**c**) Swin-S, Swin-B, Swin-L, MobileViT-XXS, MobileViT-XS, MobileViT-S. (**d**) ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. Figure 8: Top-5 accuracy rates under Gaussian blur. **(a)** SwiftFormer-XS, SwiftFormer-S, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. **(b)** CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L7. **(c)** Swin-S, Swin-B, Swin-L, MobileViT-XS, MobileViT-S, MobileViT-S. **(d)** ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. \[\text{top-5 accuracy}=\frac{\text{number of correct top-5 predictions}}{\text{total number of test images}}\times 100\% \tag{6}\]0 Top-5 accuracy rates under different salt-and-pepper distortions. **(a)** SwiftFormer-XS, SwiftFormer-L1, SwiftFormer-L3, VAN-B6. **(b)** CVT-13, CVT-21, CVT-W24, EfficientFormer-L1, EfficientFormer-L3, EfficientFormer-L7. **(c)** Swin-S, Swin-B, Swin-L, MobileViT-XS, MobileViT-S. **(d)** ViT-B/16, ViT-L/16, LeViT-128, LeViT-256, LeViT-384. From Figures 6-10, it can be observed that top-5 accuracies are less sensitive to noise compared to top-1 accuracies.