Datasets:

Formats:
parquet
Languages:
English
ArXiv:
Tags:
image
Libraries:
Datasets
Dask
License:
PD12M / tutorials /metadata.md
padge's picture
Partitioned metadata files into 100k rows (down from 1m). Metadata files also include a new column, source. Updated documentation to include source definition.
cc777e2

Working with the Metadata

The metadata files are in parquet format, and contain the following attributes:

  • id: A unique identifier for the image.
  • url: The URL of the image.
  • s3_key: The S3 file key of the image.
  • caption: A caption for the image.
  • hash: The MD5 hash of the image file.
  • width: The width of the image in pixels.
  • height: The height of the image in pixels.
  • mime_type: The MIME type of the image file.
  • license: The URL of the license.
  • source: The source organization of the image.

Open a metadata file

The files are in parquet format, and can be opened with a tool like pandas in Python.

import pandas as pd
df = pd.read_parquet('pd12m.000.parquet')

Get URLs from metadata

Once you have opened a maetadata file with pandas, you can get the URLs of the images with the following command:

urls = df['url']