--- license: cc-by-4.0 task_categories: - image-to-text - text-to-image language: - en tags: - laion - recaptioned - vision-language-alignment - clip-training - webdataset pretty_name: Recaptioned LAION (Gemma-3-27B) size_categories: - 100K *Describe this image in 20-30 words. Do not include any preamble or > introduction, just the description.* This dataset is used by the **PuzzleBench** project for vision/text alignment training. ## Stats | | | |---|---:| | Samples | 508,025 | | Image resolution | up to 1500×1500 (varies) | | Format | JPEG | | Caption type | Gemma-3-27B recaption (declarative, ~130 chars avg) | | Shards | 30 webdataset `.tar` files (~2.4 GB each) | | Total size | ~72 GB | ## Format: WebDataset The dataset ships as **30 webdataset-compatible tar shards**, the de facto standard for large image-text corpora (used by LAION-400M, LAION-5B, CLIP training pipelines, etc.). Each shard is a flat tar containing: ``` shards-00000.tar ├── 000000.jpg # raw image bytes ├── 000000.txt # caption (utf-8) ├── 000001.jpg ├── 000001.txt └── ... ``` A `metadata.csv` with the same `image_id, url, caption` is also shipped alongside for non-webdataset consumers. ## Usage ### With `webdataset` (streaming, no extraction needed) ```python import webdataset as wds url = "https://huggingface.co/datasets/PuzzleBench/Recaptioned_LAION/resolve/main/shards-{00000..00029}.tar" ds = ( wds.WebDataset(url) .decode("pil") .to_tuple("jpg", "txt") ) for image, caption in ds: # image: PIL.Image # caption: str ... ``` ### With `huggingface_hub` snapshot + local extraction ```python from huggingface_hub import snapshot_download snapshot_download( repo_id="PuzzleBench/Recaptioned_LAION", repo_type="dataset", local_dir="recaptioned_laion", ) ``` ### With `pandas` (captions only, no images) ```python import pandas as pd df = pd.read_csv("hf://datasets/PuzzleBench/Recaptioned_LAION/metadata.csv") # columns: image_id, url, caption ``` ## License This dataset of recaptions is released under **CC BY 4.0**. The underlying images are sourced from public LAION URLs and retain their original licensing — please consult the LAION usage terms when redistributing or training on the image content. ## Citation If you use this dataset, please cite the PuzzleBench project and credit the LAION corpus and the Gemma-3 recaptioning model.