You need to agree to share your Hugging Face information to access this dataset

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

COCO 2017 is distributed by the COCO Consortium. The annotations are licensed under CC BY 4.0. The COCO Consortium does not own the copyright of the images: the images come from Flickr and remain under their respective Creative Commons licenses, and about 70% of them are non-commercial. Check the license of each image (license/license_url) before using it, and cite the original work.

Log in or Sign Up to review the conditions and access this dataset content.

COCO 2017

COCO 2017 instance detection, packed once with the official annotations kept whole.

What is here

  • train: 118,287 images (train2017)
  • validation: 5,000 images (val2017)
  • 80 categories with COCO's official ids, 1 to 90 (12, 26, 29, ... are unused)
  • Every official annotation column: annotation id, category id, bbox, area, iscrowd, segmentation
  • Every image's official license and source URLs, because the images come from Flickr and are not all under the same license
  • All 5,000 validation images are kept, including the 48 that have no annotations; their objects lists are empty

test2017 is not included: the official test annotations are not public (the test server only), so there is nothing to pack.

Schema

column type meaning
id string image id, the zero-padded file name stem (e.g. 000000000139)
image Image the original JPEG bytes
width, height int32 image size
license, license_url string the image's official Flickr license name and URL
flickr_url, coco_url string the image's original source URLs
objects.annotation_id int64 official annotation id
objects.category ClassLabel the 80 names in official id order; the index is 0 to 79
objects.category_id int32 COCO's official category id, 1 to 90 with gaps
objects.bbox list of 4 float64 official [x, y, w, h], absolute pixels, top-left origin
objects.area float64 official area in pixels
objects.iscrowd int8 1 for a crowd region the official evaluator ignores
objects.segmentation string official segmentation as JSON: polygon lists, or the RLE dict for crowd boxes

category is the readable class name; category_id keeps the official number so a consumer can map straight back to the COCO category ids. No annotation is filtered, merged or renumbered.

Usage

from datasets import load_dataset

ds = load_dataset("<user>/coco2017", "detection")

Replace <user> with the repo owner.

Source and license

Official COCO 2017: https://cocodataset.org/.

The annotations in this dataset are licensed under a Creative Commons Attribution 4.0 License. The COCO Consortium does not own the copyright of the images. Use of the images must abide by the Flickr Terms of Use. The users of the images accept full responsibility for the use of the dataset, including but not limited to the use of any copies of copyrighted images that they may create from the dataset.

Each image's license is in license/license_url. The images come from Flickr under different Creative Commons licenses, and about 70% of train and validation images are non-commercial (BY-NC, BY-NC-SA, BY-NC-ND): check the per-image license before using an image, especially for commercial work. This packaging adds no rights; use it under the COCO terms of use and cite the original work.

@inproceedings{lin2014microsoft,
  title={Microsoft COCO: Common Objects in Context},
  author={Lin, Tsung-Yi and Maire, Michael and Belongie, Serge and Hays, James and Perona, Pietro and Ramanan, Deva and Doll{\'a}r, Piotr and Zitnick, C. Lawrence},
  booktitle={European Conference on Computer Vision (ECCV)},
  pages={740--755},
  year={2014},
  organization={Springer}
}

Reproducing this dataset

create_dataset.py in this repo builds the parquet from an unpacked official COCO 2017 folder:

python create_dataset.py --dry-run --coco-root /path/to/coco --limit 20
python create_dataset.py --repo <user>/coco2017 --coco-root /path/to/coco

It checks the packed box counts, a random sample of records and the image bytes against the official instances_*.json files before uploading.

Downloads last month
4,958