Dataset Preview
Duplicate
The full dataset viewer is not available (click to read why). Only showing a preview of the rows.
The dataset generation failed
Error code:   DatasetGenerationError
Exception:    ValueError
Message:      Invalid string class label imagent100@9fbe5dc907086b1e55c79cb92e3ee86ed6835ab2
Traceback:    Traceback (most recent call last):
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1537, in _prepare_split_single
                  example = self.info.features.encode_example(record) if self.info.features is not None else record
                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 2162, in encode_example
                  return encode_nested_example(self, example)
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1446, in encode_nested_example
                  {k: encode_nested_example(schema[k], obj.get(k), level=level + 1) for k in schema}
                      ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1469, in encode_nested_example
                  return schema.encode_example(obj) if obj is not None else None
                         ~~~~~~~~~~~~~~~~~~~~~^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1144, in encode_example
                  example_data = self.str2int(example_data)
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1081, in str2int
                  output = [self._strval2int(value) for value in values]
                            ~~~~~~~~~~~~~~~~^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/features/features.py", line 1102, in _strval2int
                  raise ValueError(f"Invalid string class label {value}")
              ValueError: Invalid string class label imagent100@9fbe5dc907086b1e55c79cb92e3ee86ed6835ab2
              
              The above exception was the direct cause of the following exception:
              
              Traceback (most recent call last):
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1369, in compute_config_parquet_and_info_response
                  parquet_operations, partial, estimated_dataset_info = stream_convert_to_parquet(
                                                                        ~~~~~~~~~~~~~~~~~~~~~~~~~^
                      builder, max_dataset_size_bytes=max_dataset_size_bytes
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  )
                  ^
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 948, in stream_convert_to_parquet
                  builder._prepare_split(split_generator=splits_generators[split], file_format="parquet")
                  ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1382, in _prepare_split
                  for job_id, done, content in self._prepare_split_single(
                                               ~~~~~~~~~~~~~~~~~~~~~~~~~~^
                      gen_kwargs=gen_kwargs, job_id=job_id, **_prepare_split_args
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  ):
                  ^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1560, in _prepare_split_single
                  raise DatasetGenerationError("An error occurred while generating the dataset") from e
              datasets.exceptions.DatasetGenerationError: An error occurred while generating the dataset

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

image
image
label
class label
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
0n01498041
End of preview.

ImageNet-100 Dataset (Zipped ImageFolder)

Overview

This dataset is a 100-class subset of the ImageNet-2012 (ILSVRC2012) dataset. It was specifically curated for academic research in computer vision, including tasks such as image compression and color-to-grayscale conversion (decolorization).

Dataset Details

  • Class Selection: 100 classes were selected using a fixed random seed (42) to ensure reproducibility.
  • Format: The dataset is stored as zipped chunks (10 files total) to facilitate stable uploads and high-speed downloads.
  • Total Splits:
    • Train: ~130,000 images, distributed across 5 ZIP chunks (part1 to part5).
    • Validation: 5,000 images, distributed across 5 ZIP chunks (part1 to part5).
  • Labels: A complete mapping of WordNet IDs to human-readable labels is included in the Labels.json file.

πŸ“‚ Class Categories

The 100 selected classes cover a diverse range of categories:

Category Count Examples
Canines (Dogs) 13 Siberian husky, Bloodhound, Miniature schnauzer
Birds 8 Hummingbird, Sulphur-crested cockatoo, Goose
Primates 4 Chimpanzee, Howler monkey, Macaque
Wild Mammals 12 Polar bear, Hippopotamus, Red panda, White wolf
Reptiles & Fish 8 Stingray, Bullfrog, Alligator lizard
Vehicles 5 Minibus, Moped, Trailer truck
Instruments 3 Flute, Bassoon, Trombone
Household Items 18 Teapot, Hourglass, Vacuum cleaner, Reflex camera
Food & Nature 7 Banana, Mushroom, Seashore, Potpie
Sports & Other 22 Volleyball, Baseball, Scuba diver, Stone wall

How to Use

1. Automatic Download and Extraction

Since the data is split into multiple chunks, use the following script to reconstruct the ImageFolder structure.

import os
import zipfile
from huggingface_hub import hf_hub_download

repo_id = "asafaa/imagent100"
target_dir = "./imagenet100"

def download_and_extract(split, num_parts=5):
    for i in range(1, num_parts + 1):
        filename = f"imagenet100_{split}_part{i}.zip"
        print(f"Downloading {filename}...")
        path = hf_hub_download(repo_id=repo_id, filename=filename, repo_type="dataset")
        
        with zipfile.ZipFile(path, 'r') as zip_ref:
            zip_ref.extractall(target_dir)
    print(f"Finished extracting {split} split.")

# Download both splits
download_and_extract("train")
download_and_extract("val")
Downloads last month
168