# Flickr30k (2014)

> 31,000 Flickr photos of people and everyday scenes, each with five written captions.

Page: https://mralbu.github.io/ai-datasets/d/flickr30k

## Key facts

- Category: Vision, Retrieval
- Task: Image captioning and image–text retrieval
- Creators: Peter Young, Alice Lai, Micah Hodosh, Julia Hockenmaier (UIUC)
- Size: 31,783 images, 158,915 captions (Karpathy's split uses 31,014)
- Splits: train 29,000, validation 1,014, test 1,000
- Input: A photo
- Labels: Five independent one-sentence descriptions
- License: Captions for research use; images under their Flickr terms
- Paper: [From image descriptions to visual denotations: New similarity metrics for semantic inference over event descriptions](https://aclanthology.org/Q14-1006/)
- Homepage: https://shannon.cs.illinois.edu/DenotationGraph/
- Hugging Face: [nlphuji/flickr30k](https://huggingface.co/datasets/nlphuji/flickr30k)
- Sampled at Hub revision 2b239befc81b6e3f035ce6bd52f5f4d60f5625f7 (2026-11-07)

## Why it matters

With COCO Captions, the benchmark that turned "describe this picture" into a deep-learning problem: CNN-plus-RNN captioners (Show and Tell, Karpathy's alignment model) were scored on it. Its retrieval task, find the caption for this image and vice versa, outlived captioning: CLIP and later vision-language models still report zero-shot Flickr30k retrieval.

## Worth knowing

- Most papers use the "Karpathy split" of 29k / 1k / 1k images, not an official one.
- SNLI's premises are Flickr30k captions; crowdworkers wrote hypotheses about them.
- Annotators often guessed age, gender or ethnicity, as in the captions below, which a 2016 study ("Stereotyping and Bias in the Flickr30K Dataset") documented.
- Flickr30k Entities (2015) later linked phrases in the captions to boxes in the images.

## Get the data

```bash
# pip install -U huggingface_hub
hf download nlphuji/flickr30k --repo-type dataset \
  --local-dir flickr30k
```

```python
from datasets import load_dataset   # pip install datasets

ds = load_dataset("nlphuji/flickr30k", "TEST")
print(ds)
```

```python
import polars as pl

df = pl.read_parquet("hf://datasets/nlphuji/flickr30k@~parquet/TEST/test/*.parquet")
print(df.shape)
```

## Related datasets

- [Flickr8k](https://hockenmaier.cs.illinois.edu/8k-pictures.html): 2013, the 8k-image predecessor
- [MS COCO Captions](https://huggingface.co/datasets/rafaelpadilla/coco2017): 2015, 5 captions on 120k+ COCO images (on this site: https://mralbu.github.io/ai-datasets/d/coco)
- [SNLI](https://huggingface.co/datasets/stanfordnlp/snli): 2015, inference pairs built on these captions (on this site: https://mralbu.github.io/ai-datasets/d/snli)
- [Visual Genome](https://huggingface.co/datasets/ljnlonoljpiljm/visual_genome): 2016, objects, attributes and relationships on 108k images (on this site: https://mralbu.github.io/ai-datasets/d/visual-genome)

## Landmark papers

- [Show and Tell: A Neural Image Caption Generator](https://arxiv.org/abs/1411.4555) (2014)
- [Deep Visual-Semantic Alignments for Generating Image Descriptions](https://arxiv.org/abs/1412.2306) (2015)
- [Learning Transferable Visual Models From Natural Language Supervision (CLIP)](https://arxiv.org/abs/2103.00020) (2021)

## Papers on this site that use it

- [CLIP (2021)](https://mralbu.github.io/ai-datasets/p/clip.md): Learn images from 400 million captions found on the web, then classify anything you can name.
- [Flamingo (2022)](https://mralbu.github.io/ai-datasets/p/flamingo.md): Bridged a frozen vision encoder and a frozen LLM with gated cross-attention so one model learns new visual tasks from a few examples in the prompt.
- [BLIP-2 (2023)](https://mralbu.github.io/ai-datasets/p/blip-2.md): Connected off-the-shelf frozen ViTs and frozen LLMs through a compact 188M-parameter Querying Transformer trained in two stages.
