Datasets:
image image | label int64 | label_name string | source_id string | parent_id string | augmentation string | is_augmented bool |
|---|---|---|---|---|---|---|
1 | savory | image_2026_savory_000 | image_2026_savory_000 | none | false | |
1 | savory | image_2026_savory_022 | image_2026_savory_022 | none | false | |
0 | sweet | image_2026_sweet_020 | image_2026_sweet_020 | none | false | |
1 | savory | image_2026_savory_002 | image_2026_savory_002 | none | false | |
0 | sweet | image_2026_sweet_007 | image_2026_sweet_007 | none | false | |
0 | sweet | image_2026_sweet_018 | image_2026_sweet_018 | none | false | |
0 | sweet | image_2026_sweet_009 | image_2026_sweet_009 | none | false | |
0 | sweet | image_2026_sweet_016 | image_2026_sweet_016 | none | false | |
0 | sweet | image_2026_sweet_010 | image_2026_sweet_010 | none | false | |
1 | savory | image_2026_savory_010 | image_2026_savory_010 | none | false | |
0 | sweet | image_2026_sweet_011 | image_2026_sweet_011 | none | false | |
1 | savory | image_2026_savory_001 | image_2026_savory_001 | none | false | |
1 | savory | image_2026_savory_019 | image_2026_savory_019 | none | false | |
1 | savory | image_2026_savory_004 | image_2026_savory_004 | none | false | |
0 | sweet | image_2026_sweet_002 | image_2026_sweet_002 | none | false | |
1 | savory | image_2026_savory_014 | image_2026_savory_014 | none | false | |
0 | sweet | image_2026_sweet_013 | image_2026_sweet_013 | none | false | |
1 | savory | image_2026_savory_017 | image_2026_savory_017 | none | false | |
0 | sweet | image_2026_sweet_003 | image_2026_sweet_003 | none | false | |
1 | savory | image_2026_savory_008 | image_2026_savory_008 | none | false | |
1 | savory | image_2026_savory_018 | image_2026_savory_018 | none | false | |
1 | savory | image_2026_savory_009 | image_2026_savory_009 | none | false | |
1 | savory | image_2026_savory_005 | image_2026_savory_005 | none | false | |
0 | sweet | image_2026_sweet_004 | image_2026_sweet_004 | none | false | |
1 | savory | image_2026_savory_015 | image_2026_savory_015 | none | false | |
1 | savory | image_2026_savory_024 | image_2026_savory_024 | none | false | |
1 | savory | image_2026_savory_006 | image_2026_savory_006 | none | false | |
1 | savory | image_2026_savory_026 | image_2026_savory_026 | none | false | |
0 | sweet | image_2026_sweet_012 | image_2026_sweet_012 | none | false | |
0 | sweet | image_2026_sweet_008 | image_2026_sweet_008 | none | false | |
1 | savory | image_2026_savory_025 | image_2026_savory_025 | none | false | |
0 | sweet | image_2026_sweet_017 | image_2026_sweet_017 | none | false | |
1 | savory | image_2026_savory_021 | image_2026_savory_021 | none | false | |
0 | sweet | image_2026_sweet_019 | image_2026_sweet_019 | none | false | |
1 | savory | image_2026_savory_007 | image_2026_savory_007 | none | false | |
1 | savory | image_2026_savory_000__brightness | image_2026_savory_000 | brightness | true | |
1 | savory | image_2026_savory_022__brightness | image_2026_savory_022 | brightness | true | |
0 | sweet | image_2026_sweet_020__brightness | image_2026_sweet_020 | brightness | true | |
1 | savory | image_2026_savory_002__brightness | image_2026_savory_002 | brightness | true | |
0 | sweet | image_2026_sweet_007__brightness | image_2026_sweet_007 | brightness | true | |
0 | sweet | image_2026_sweet_018__brightness | image_2026_sweet_018 | brightness | true | |
0 | sweet | image_2026_sweet_009__brightness | image_2026_sweet_009 | brightness | true | |
0 | sweet | image_2026_sweet_016__brightness | image_2026_sweet_016 | brightness | true | |
0 | sweet | image_2026_sweet_010__brightness | image_2026_sweet_010 | brightness | true | |
1 | savory | image_2026_savory_010__brightness | image_2026_savory_010 | brightness | true | |
0 | sweet | image_2026_sweet_011__brightness | image_2026_sweet_011 | brightness | true | |
1 | savory | image_2026_savory_001__brightness | image_2026_savory_001 | brightness | true | |
1 | savory | image_2026_savory_019__brightness | image_2026_savory_019 | brightness | true | |
1 | savory | image_2026_savory_004__brightness | image_2026_savory_004 | brightness | true | |
0 | sweet | image_2026_sweet_002__brightness | image_2026_sweet_002 | brightness | true | |
1 | savory | image_2026_savory_014__brightness | image_2026_savory_014 | brightness | true | |
0 | sweet | image_2026_sweet_013__brightness | image_2026_sweet_013 | brightness | true | |
1 | savory | image_2026_savory_017__brightness | image_2026_savory_017 | brightness | true | |
0 | sweet | image_2026_sweet_003__brightness | image_2026_sweet_003 | brightness | true | |
1 | savory | image_2026_savory_008__brightness | image_2026_savory_008 | brightness | true | |
1 | savory | image_2026_savory_018__brightness | image_2026_savory_018 | brightness | true | |
1 | savory | image_2026_savory_009__brightness | image_2026_savory_009 | brightness | true | |
1 | savory | image_2026_savory_005__brightness | image_2026_savory_005 | brightness | true | |
0 | sweet | image_2026_sweet_004__brightness | image_2026_sweet_004 | brightness | true | |
1 | savory | image_2026_savory_015__brightness | image_2026_savory_015 | brightness | true | |
1 | savory | image_2026_savory_024__brightness | image_2026_savory_024 | brightness | true | |
1 | savory | image_2026_savory_006__brightness | image_2026_savory_006 | brightness | true | |
1 | savory | image_2026_savory_026__brightness | image_2026_savory_026 | brightness | true | |
0 | sweet | image_2026_sweet_012__brightness | image_2026_sweet_012 | brightness | true | |
0 | sweet | image_2026_sweet_008__brightness | image_2026_sweet_008 | brightness | true | |
1 | savory | image_2026_savory_025__brightness | image_2026_savory_025 | brightness | true | |
0 | sweet | image_2026_sweet_017__brightness | image_2026_sweet_017 | brightness | true | |
1 | savory | image_2026_savory_021__brightness | image_2026_savory_021 | brightness | true | |
0 | sweet | image_2026_sweet_019__brightness | image_2026_sweet_019 | brightness | true | |
1 | savory | image_2026_savory_007__brightness | image_2026_savory_007 | brightness | true | |
1 | savory | image_2026_savory_000__rotation | image_2026_savory_000 | rotation | true | |
1 | savory | image_2026_savory_022__rotation | image_2026_savory_022 | rotation | true | |
0 | sweet | image_2026_sweet_020__rotation | image_2026_sweet_020 | rotation | true | |
1 | savory | image_2026_savory_002__rotation | image_2026_savory_002 | rotation | true | |
0 | sweet | image_2026_sweet_007__rotation | image_2026_sweet_007 | rotation | true | |
0 | sweet | image_2026_sweet_018__rotation | image_2026_sweet_018 | rotation | true | |
0 | sweet | image_2026_sweet_009__rotation | image_2026_sweet_009 | rotation | true | |
0 | sweet | image_2026_sweet_016__rotation | image_2026_sweet_016 | rotation | true | |
0 | sweet | image_2026_sweet_010__rotation | image_2026_sweet_010 | rotation | true | |
1 | savory | image_2026_savory_010__rotation | image_2026_savory_010 | rotation | true | |
0 | sweet | image_2026_sweet_011__rotation | image_2026_sweet_011 | rotation | true | |
1 | savory | image_2026_savory_001__rotation | image_2026_savory_001 | rotation | true | |
1 | savory | image_2026_savory_019__rotation | image_2026_savory_019 | rotation | true | |
1 | savory | image_2026_savory_004__rotation | image_2026_savory_004 | rotation | true | |
0 | sweet | image_2026_sweet_002__rotation | image_2026_sweet_002 | rotation | true | |
1 | savory | image_2026_savory_014__rotation | image_2026_savory_014 | rotation | true | |
0 | sweet | image_2026_sweet_013__rotation | image_2026_sweet_013 | rotation | true | |
1 | savory | image_2026_savory_017__rotation | image_2026_savory_017 | rotation | true | |
0 | sweet | image_2026_sweet_003__rotation | image_2026_sweet_003 | rotation | true | |
1 | savory | image_2026_savory_008__rotation | image_2026_savory_008 | rotation | true | |
1 | savory | image_2026_savory_018__rotation | image_2026_savory_018 | rotation | true | |
1 | savory | image_2026_savory_009__rotation | image_2026_savory_009 | rotation | true | |
1 | savory | image_2026_savory_005__rotation | image_2026_savory_005 | rotation | true | |
0 | sweet | image_2026_sweet_004__rotation | image_2026_sweet_004 | rotation | true | |
1 | savory | image_2026_savory_015__rotation | image_2026_savory_015 | rotation | true | |
1 | savory | image_2026_savory_024__rotation | image_2026_savory_024 | rotation | true | |
1 | savory | image_2026_savory_006__rotation | image_2026_savory_006 | rotation | true | |
1 | savory | image_2026_savory_026__rotation | image_2026_savory_026 | rotation | true | |
0 | sweet | image_2026_sweet_012__rotation | image_2026_sweet_012 | rotation | true | |
0 | sweet | image_2026_sweet_008__rotation | image_2026_sweet_008 | rotation | true |
24-679 (Fall 2026): Sweet and Savory Food Images
kwongnon/2026-24679-image-dataset
A binary image-classification dataset of sweet and savory foods, prepared as square RGB images for training and evaluating image-classification models. Images are organized into two classes: 0 = sweet and 1 = savory.
The intended use is a classroom machine-learning exercise focused on image preprocessing, augmentation, transfer learning, and model evaluation rather than production food recognition.
Source and task
The source images are stored in two class-specific folders in Google Drive:
sweet/→ label 0savory/→ label 1
Labels are assigned from the folder containing each image rather than being independently inferred from the image pixels. Therefore, the correctness of the labels depends on the images having been placed in the appropriate folder before dataset preparation.
The classification task is to predict whether the food shown in an image belongs to the sweet or savory category.
Course: 24-679, Fall 2026, Carnegie Mellon University.
Fields
| Field | Meaning and modeling role |
|---|---|
image |
Prepared RGB image pixels; the model input. |
label |
Classification target: 0 = sweet; 1 = savory. |
label_name |
Human-readable class name (sweet or savory); exclude from model inputs. |
source_id, parent_id |
Identifiers connecting prepared or augmented examples to their original source image; provenance only. |
augmentation, is_augmented |
Augmentation method and indicator of whether the row is synthetic; provenance only. |
Splits and original-source counts
The following counts are computed directly from the packaged dataset for this run.
| Split | Original rows | Synthetic rows | Total rows |
|---|---|---|---|
| train | 35 | 350 | 385 |
| validation | 7 | 0 | 7 |
| test | 8 | 0 | 8 |
Class counts include synthetic rows in training only.
| Split | Label | Rows |
|---|---|---|
| train | 0 | 165 |
| train | 1 | 220 |
| validation | 0 | 3 |
| validation | 1 | 4 |
| test | 0 | 3 |
| test | 1 | 5 |
Requested holdout fraction: 30%; test receives 50% of that holdout.
Small-sample rounding may cause the realized split proportions to differ slightly from the requested values. The initial split uses random seed 24679, and the validation/test split uses seed 24680.
Original images are split with class stratification before augmentation. Augmented images are generated only from training-set images. Validation and test sets contain only unaugmented prepared images.
An original image and its augmented descendants therefore remain within the same split and cannot cross into validation or test. However, visually similar foods, images from the same restaurant, similar dishes, or images photographed in similar environments may still appear across different splits because the dataset is not grouped by dish, restaurant, photographer, or location.
The existing partitions should be reused for model comparisons rather than splitting the augmented rows again.
Image preprocessing
Every image is prepared to a resolution of 224 × 224 pixels, in RGB format.
Padding color: (0, 0, 0).
The deterministic preprocessing pipeline:
- Applies EXIF orientation so phone photographs appear in their intended orientation.
- Converts the image to RGB.
- Resizes the image while preserving its original aspect ratio.
- Pads the remaining area to create a square 224 × 224 image without stretching the food.
- Removes metadata from the prepared working copy.
The original source images stored in Google Drive remain unchanged.
The resulting 224 × 224 images are general prepared images. Downstream pretrained models may still require their own checkpoint-specific normalization or image-processing steps.
Data augmentation
Augmentation is applied only to the training split. Each training source retains its prepared parent image and receives separately generated transformed variants. Transformations are applied independently rather than stacked on top of one another.
The current preparation pipeline uses:
- Brightness adjustment: factors from 0.4–0.7 or 1.4–2.0.
- Rotation: approximately 15–30 degrees clockwise or counterclockwise.
- Contrast adjustment: factors from 0.35–0.65 or 1.5–2.2.
- Gaussian blur: radius from 2.0–4.5 pixels.
Lower and higher brightness/contrast ranges are selected with equal probability. Rotation operates on a fixed image canvas and may introduce filled corners or slightly clip image content.
The stored augmentation identifiers mild_brightness, small_rotation, mild_contrast, and
mild_gaussian_blur are retained as method names. They should not be interpreted as guarantees that
the visual effect is objectively mild.
| Training method | Stored rows |
|---|---|
brightness |
35 |
contrast |
35 |
gaussian_blur |
35 |
horizontal_flip |
35 |
none |
35 |
random_zoom |
35 |
rotation |
35 |
saturation |
35 |
sharpness |
35 |
shear |
35 |
translation |
35 |
Intended use
This dataset is intended for educational experiments involving:
- binary image classification,
- image preprocessing,
- data augmentation,
- transfer learning,
- comparison of pretrained vision models,
- validation and test-set evaluation,
- and analysis of classification errors.
A typical task is to train a model to distinguish sweet food from savory food using the training set, select model settings using the validation set, and report final performance on the test set.
Limitations
The distinction between sweet and savory food is not always visually or conceptually unambiguous. Some foods may contain both sweet and savory components, and the assigned class represents the label chosen during dataset collection rather than an objective universal definition.
The dataset may also contain visual shortcuts unrelated to the intended food category. For example, models may learn associations with:
- plates or containers,
- restaurant backgrounds,
- lighting conditions,
- photography style,
- food presentation,
- packaging,
- text or logos,
- colors,
- or repeated types of dishes.
The collection is relatively small, so performance measured on this dataset should not automatically be interpreted as performance on food images from other countries, cuisines, restaurants, photographers, or environments.
Synthetic augmentation increases the number of training examples but does not create additional independent food observations. Augmented versions are correlated with their parent images.
Strong brightness and contrast transformations may remove useful visual details. Blur may obscure texture, ingredients, or text, while rotation may crop parts of the food. Augmented-image galleries should therefore be inspected to confirm that the transformed images still preserve the intended class.
Model evaluation should include overall accuracy as well as per-class performance and F1 scores, especially if the number of sweet and savory images is imbalanced.
Privacy and licensing
Prepared examples use anonymous source identifiers rather than the original image filenames, and camera metadata is not retained in the prepared working images.
Removing filenames and metadata does not remove information that may remain visible inside an image, such as faces, restaurant names, logos, signs, receipts, addresses, or other identifying details. Images should therefore be reviewed before public release.
The dataset card does not establish ownership or redistribution rights for the source images. Applicable permissions and licenses for the original images should be verified before sharing the dataset outside the intended course context.
No license is assigned by this dataset card unless one is separately specified in the repository metadata.
Load and compare
from datasets import load_dataset
ds = load_dataset("kwongnon/2026-24679-image-dataset")
# Train using the training split.
train_ds = ds["train"]
# Use validation for model or hyperparameter selection.
validation_ds = ds["validation"]
# Evaluate the final selected model on the test split.
test_ds = ds["test"]
- Downloads last month
- 51