Caltech Datasets
Loads the Caltech-256 Object Category Dataset for image classification. It consists of 30,607 images across 256 distinct object categories. Each category has at least 80 images, with variability in image size.
Character. Root directory for dataset storage. The dataset will be stored under root/caltech256
.
Optional function to transform input images after loading. Default is NULL
.
Optional function to transform labels. Default is NULL
.
Logical. Whether to download the dataset if not found locally. Default is FALSE
.
An object of class caltech101_dataset
, which behaves like a torch dataset.
Each element is a named list with:
x
: A H x W x 3 integer array representing an RGB image.
y
: An Integer representing the label.
An object of class caltech256_dataset
, which behaves like a torch dataset.
Each element is a named list with:
x
: A H x W x 3 integer array representing an RGB image.
y
: An Integer representing the label.
The Caltech-101 and Caltech-256 collections are classification datasets made of color images with varying sizes. They cover 101 and 256 object categories respectively and are commonly used for evaluating visual recognition models.
The Caltech-101 dataset contains around 9,000 images spread over 101 object categories plus a background class. Images have varying sizes.
Caltech-256 extends this to about 30,000 images across 256 categories.
Other classification_dataset:
cifar10_dataset()
,
eurosat_dataset()
,
fer_dataset()
,
fgvc_aircraft_dataset()
,
flowers102_dataset()
,
mnist_dataset()
,
oxfordiiitpet_dataset()
,
tiny_imagenet_dataset()
if (FALSE) { # \dontrun{
caltech101 <- caltech101_dataset(download = TRUE)
first_item <- caltech101[1]
first_item$x # Image array
first_item$y # Integer label
} # }