# Image as a Foreign Language: BEiT Pretraining for All Vision and Vision-Language Tasks

Source: [Image as a Foreign Language: BEiT Pretraining for All Vision and Vision-Language Tasks](<https://www.sota2.com/research/paper/68fa6d541e209131cea39310>)

Collection index: [llms.txt](<https://www.sota2.com/research/llms.txt>)

Data updated: 2026-01-01T15:01:43.176Z

Authors: Wenhui Wang, Hangbo Bao, Li Dong, Johan Bjorck, Zhiliang Peng, Qiang Liu, Kriti Aggarwal, Owais Khan Mohammed, Saksham Singhal, Subhojit Som, Furu Wei

Published: 2022-08-22T16:55:04.000Z

## Abstract

A big convergence of language, vision, and multimodal pretraining is emerging. In this work, we introduce a general-purpose multimodal foundation model BEiT-3, which achieves state-of-the-art transfer performance on both vision and vision-language tasks. Specifically, we advance the big convergence from three aspects: backbone architecture, pretraining task, and model scaling up. We introduce Multiway Transformers for general-purpose modeling, where the modular architecture enables both deep fusion and modality-specific encoding. Based on the shared backbone, we perform masked "language" modeling on images (Imglish), texts (English), and image-text pairs ("parallel sentences") in a unified manner. Experimental results show that BEiT-3 obtains state-of-the-art performance on object detection (COCO), semantic segmentation (ADE20K), image classification (ImageNet), visual reasoning (NLVR2), visual question answering (VQAv2), image captioning (COCO), and cross-modal retrieval (Flickr30K, COCO).

## Recorded benchmark results

A research result applies to its stated dataset, split, metric and evaluation configuration. Compare like-for-like settings, preserve the metric's unit and direction, and distinguish paper-reported results from independent reproduction. The best result recorded here is not a claim of exhaustive, current global coverage.

- [Natural Language Visual Reasoning on NLVR2 (test-p)](<https://www.sota2.com/research/sota/natural-language-visual-reasoning-on-nlvr2-test-p.md>): Natural Language Visual Reasoning; NLVR2 (test-p); Accuracy: 92.6.

- [Natural Language Visual Reasoning on NLVR2 (dev)](<https://www.sota2.com/research/sota/natural-language-visual-reasoning-on-nlvr2-dev.md>): Natural Language Visual Reasoning; NLVR2 (dev); Accuracy: 91.51.

- [Instance Segmentation on COCO](<https://www.sota2.com/research/sota/instance-segmentation-on-coco.md>): Instance Segmentation; COCO; APmask: 54.8.

- [Image Classification on ImageNet (val) (Top-1/Top-5 Accuracy)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-val-top-1-top-5-accuracy.md>): Image Classification; ImageNet (val); Top-1 Accuracy: 89.6.

- [Image Classification on ImageNet (val) (Top-1 Accuracy)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-val-top-1-accuracy.md>): Image Classification; ImageNet (val); Top-1 Accuracy: 89.6.

- [Image-to-text retrieval on MSCOCO 5K (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-mscoco-5k-test.md>): Image-to-Text Retrieval; MSCOCO 5K (test); R@1: 84.8.

- [Visual Reasoning on NLVR2](<https://www.sota2.com/research/sota/visual-reasoning-on-nlvr2.md>): Visual Reasoning; NLVR2; Accuracy: 92.6.

- [Visual Reasoning on NLVR2 (test-P)](<https://www.sota2.com/research/sota/visual-reasoning-on-nlvr2-test-p.md>): Visual Reasoning; NLVR2 (test-p); Accuracy: 92.6.

- [Visual Question Answering on VQAv2 (dev)](<https://www.sota2.com/research/sota/visual-question-answering-on-vqav2-dev.md>): Visual Question Answering; VQAv2 (dev); Accuracy: 84.19.

- [Image Search on COCO](<https://www.sota2.com/research/sota/image-search-on-coco.md>): Image Search; COCO; Recall@1: 76.

- [Image-Text Retrieval on NAIL-STAR (test)](<https://www.sota2.com/research/sota/image-text-retrieval-on-nail-star-test.md>): Image-Text Retrieval; NAIL-STAR (test); MRR: 34.9.

- [Text-to-Image Retrieval on MS-COCO Easy](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-ms-coco-easy.md>): Text-to-Image Retrieval; MS-COCO Easy; Recall@1: 0.676.

- [Text-to-Image Retrieval on MS-COCO Combined](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-ms-coco-combined.md>): Text-to-Image Retrieval; MS-COCO Combined; R@1: 75.2.

- [Text-to-Image Retrieval on MS-COCO (Hard)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-ms-coco-hard.md>): Text-to-Image Retrieval; MS-COCO (Hard); Recall@1: 43.5.

- [Semantic Segmentation on ADE20K (val)](<https://www.sota2.com/research/sota/semantic-segmentation-on-ade20k-val.md>): Semantic segmentation; ADE20K (val); mIoU: 62.8.

- [Image Captioning on MS COCO Karpathy (test)](<https://www.sota2.com/research/sota/image-captioning-on-ms-coco-karpathy-test.md>): Image Captioning; MS COCO Karpathy (test); CIDEr: 147.6.

- [Image-to-Text Retrieval on MS-COCO 5K (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-ms-coco-5k-test.md>): Image-to-Text Retrieval; MS-COCO 5K (test); R@1: 84.8.

- [Text-to-Image Retrieval on MS-COCO 5K (test)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-ms-coco-5k-test.md>): Text-to-Image Retrieval; MS-COCO 5K (test); R@1: 67.2.

- [Semantic Segmentation on ADE20K](<https://www.sota2.com/research/sota/semantic-segmentation-on-ade20k.md>): Semantic segmentation; ADE20K; mIoU: 62.8.

- [Text Retrieval on Flickr30K 1K (test)](<https://www.sota2.com/research/sota/text-retrieval-on-flickr30k-1k-test.md>): Text Retrieval; Flickr30K 1K (test); R@1: 98.1.

- [Image-to-Text Retrieval on Flickr30K English 1K (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-flickr30k-english-1k-test.md>): Image-to-Text Retrieval; Flickr30K English 1K (test); R@1: 97.5.

- [Order-level classification on BIOSCAN-5M 1.0 (test)](<https://www.sota2.com/research/sota/order-level-classification-on-bioscan-5m-1-0-test.md>): Order-level classification; BIOSCAN-5M 1.0 (test); Accuracy: 85.96.

- [Object Identification on ARMBench (test)](<https://www.sota2.com/research/sota/object-identification-on-armbench-test.md>): Object Identification; ARMBench (test); Recall@1: 84.5.

- [Multimodal Retrieval on WholeHouse-MM (test)](<https://www.sota2.com/research/sota/multimodal-retrieval-on-wholehouse-mm-test.md>): Multimodal Retrieval; WholeHouse-MM (test); Target Object Recall@5: 29.

- [Text-to-Image Retrieval on Flickr30K English 1K (test)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-flickr30k-english-1k-test.md>): Text-to-Image Retrieval; Flickr30K English 1K (test); R@1: 89.1.

- [Text-to-Vision Retrieval on Flickr](<https://www.sota2.com/research/sota/text-to-vision-retrieval-on-flickr.md>): T-to-V Retrieval; Flickr; Recall@1: 90.3.

- [Image-to-Text Retrieval on Flickr (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-flickr-test.md>): Image-to-Text Retrieval; Flickr (test); TR@1: 94.9.

- [Open-vocabulary mobile manipulation on Real-world indoor environment office and kitchen areas (40 trials)](<https://www.sota2.com/research/sota/open-vocabulary-mobile-manipulation-on-real-world-indoor-environment-office-and-kitchen-areas-40-trials.md>): Open Vocabulary Mobile Manipulation; Real-world indoor environment office and kitchen areas (40 trials); R@5: 79.

- [Text-to-Image Retrieval on Flickr (test)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-flickr-test.md>): Text-to-Image Retrieval; Flickr (test); R@1: 81.5.

- [Image Retrieval on NAIL-STAR](<https://www.sota2.com/research/sota/image-retrieval-on-nail-star.md>): Image Retrieval; NAIL-STAR; MRR: 53.9.

- [Image-to-Text Retrieval on Flickr30K 1K (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-flickr30k-1k-test.md>): Image-to-Text Retrieval; Flickr30K 1K (test); R@1: 98.

- [Image-to-text retrieval on Flickr30K 1K Karpathy (test)](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-flickr30k-1k-karpathy-test.md>): Image-to-Text Retrieval; Flickr30K 1K Karpathy (test); R@1: 94.9.

- [Image Retrieval on Marqo Fashion200K](<https://www.sota2.com/research/sota/image-retrieval-on-marqo-fashion200k.md>): Image Retrieval; Marqo Fashion200K; MRR: 66.2.

- [Order-level classification on Insects-1M 1.0 (test)](<https://www.sota2.com/research/sota/order-level-classification-on-insects-1m-1-0-test.md>): Order-level classification; Insects-1M 1.0 (test); Accuracy: 84.02.

- [Image Classification on ImageNet 1k (test)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-1k-test.md>): Image Classification; ImageNet 1k (test); Top-1 Accuracy: 89.6.

- [Object Detection on COCO v2017 (test-dev)](<https://www.sota2.com/research/sota/object-detection-on-coco-v2017-test-dev.md>): Object Detection; COCO v2017 (test-dev); mAP: 63.7.

- [Image Captioning on MS-COCO](<https://www.sota2.com/research/sota/image-captioning-on-ms-coco.md>): Image Captioning; MS-COCO; CIDEr: 147.6.

- [Image Classification on ImageNet-1K (val) (Top-1 Score)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-1k-val-top-1-score.md>): Image Classification; ImageNet-1k (val); Top-1 Acc: 89.6.

- [Image Captioning on COCO](<https://www.sota2.com/research/sota/image-captioning-on-coco.md>): Image Captioning; COCO; CIDEr: 147.6.

- [Vision-Language Probing on VL-CheckList (test)](<https://www.sota2.com/research/sota/vision-language-probing-on-vl-checklist-test.md>): Vision-Language Probing; VL-CheckList (test); Object: Avg: 84.5.

- [Image-Text Retrieval on MSCOCO](<https://www.sota2.com/research/sota/image-text-retrieval-on-mscoco.md>): Image-Text Retrieval; MSCOCO; MR: 74.6.

- [Image Classification on ImageNet 1k (val)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-1k-val.md>): Image Classification; ImageNet-1k (val); Top-1 Accuracy: 89.6.

- [Image Classification on ImageNet-1K (val) (Accuracy)](<https://www.sota2.com/research/sota/image-classification-on-imagenet-1k-val-accuracy.md>): Image Classification; ImageNet-1k (val); Top-1 Accuracy: 89.6.

- [Visual Question Answering on VQA 2.0 (test-dev)](<https://www.sota2.com/research/sota/visual-question-answering-on-vqa-2-0-test-dev.md>): Visual Question Answering; VQA 2.0 (test-dev); Accuracy: 84.2.

- [Object Localization on MS-COCO (val)](<https://www.sota2.com/research/sota/object-localization-on-ms-coco-val.md>): Object Localization; MS-COCO (val); Top-1 Accuracy: 43.

- [Compositional Reasoning on ARO](<https://www.sota2.com/research/sota/compositional-reasoning-on-aro.md>): Compositional Reasoning; ARO; Relation Score: 60.6.

- [Text-to-Image Retrieval on Flickr30K 1K (test)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-flickr30k-1k-test.md>): Text-to-Image Retrieval; Flickr30K 1K (test); R@1: 90.3.

- [Object Detection on COCO 2017 (val)](<https://www.sota2.com/research/sota/object-detection-on-coco-2017-val.md>): Object Detection; COCO 2017 (val); AP: 63.7.

- [Visual Question Answering on VQA v2 (test-std)](<https://www.sota2.com/research/sota/visual-question-answering-on-vqa-v2-test-std.md>): Visual Question Answering; VQA v2 (test-std); Accuracy: 84.03.

- [Text-to-Image Retrieval on MSCOCO 5K (test)](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-mscoco-5k-test.md>): Text-to-Image Retrieval; MSCOCO 5K (test); R@1: 67.2.

- [Text Retrieval on MS-COCO 5K (test)](<https://www.sota2.com/research/sota/text-retrieval-on-ms-coco-5k-test.md>): Text Retrieval; MS-COCO 5K (test); R@1: 81.5.

- [Image-Text Retrieval on Flickr30K](<https://www.sota2.com/research/sota/image-text-retrieval-on-flickr30k.md>): Image-Text Retrieval; Flickr30K; MR: 94.9.

- [Visual Question Answering on VQA v2 (test-dev)](<https://www.sota2.com/research/sota/visual-question-answering-on-vqa-v2-test-dev.md>): Visual Question Answering; VQA v2 (test-dev); Overall Accuracy: 84.2.

- [Image-to-Text Retrieval on Flickr30k](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-flickr30k.md>): Image-to-Text Retrieval; Flickr30K; R@1: 94.9.

- [Image Retrieval on MS-COCO 5K (test)](<https://www.sota2.com/research/sota/image-retrieval-on-ms-coco-5k-test.md>): Image Retrieval; MS-COCO 5K (test); R@1: 61.1.

- [Object Detection on COCO (test-dev)](<https://www.sota2.com/research/sota/object-detection-on-coco-test-dev.md>): Object Detection; COCO (test-dev); mAP: 63.7.

- [Compositional Reasoning on VALSE](<https://www.sota2.com/research/sota/compositional-reasoning-on-valse.md>): Compositional Reasoning; VALSE; Average Score: 70.4.

- [Image Retrieval on Flickr30K](<https://www.sota2.com/research/sota/image-retrieval-on-flickr30k.md>): Image Retrieval; Flickr30K; R@1: 94.2.

- [Image-to-text retrieval on MSCOCO](<https://www.sota2.com/research/sota/image-to-text-retrieval-on-mscoco.md>): Image-to-Text Retrieval; MSCOCO; R@1: 67.2.

- [Text-to-Image Retrieval on Flickr30K](<https://www.sota2.com/research/sota/text-to-image-retrieval-on-flickr30k.md>): Text-to-Image Retrieval; Flickr30K; R@1: 81.5.

- [Visual Question Answering on VQA v2 (Accuracy and Rel.)](<https://www.sota2.com/research/sota/visual-question-answering-on-vqa-v2-accuracy-and-rel.md>): Visual Question Answering; VQA v2; Accuracy: 76.2.

- [Instance Segmentation on COCO (test-dev)](<https://www.sota2.com/research/sota/instance-segmentation-on-coco-test-dev.md>): Instance Segmentation; COCO (test-dev); APM: not recorded.

- [Instance Segmentation on COCO 2017 (test-dev)](<https://www.sota2.com/research/sota/instance-segmentation-on-coco-2017-test-dev.md>): Instance Segmentation; COCO 2017 (test-dev); AP (Overall): not recorded.

- [Object Detection on COCO](<https://www.sota2.com/research/sota/object-detection-on-coco.md>): Object Detection; COCO; AP (Box): not recorded.

- [Object Detection on COCO 2017 (test)](<https://www.sota2.com/research/sota/object-detection-on-coco-2017-test.md>): Object Detection; COCO 2017 (test); Overall AP: not recorded.

## Original sources and implementation

[Original paper](<https://arxiv.org/abs/2208.10442>)

[PDF](<https://arxiv.org/pdf/2208.10442.pdf>)

[Implementation](<https://aka.ms/beit-3>)
