| --- |
| license: apache-2.0 |
| task_categories: |
| - image-segmentation |
| - image-classification |
| language: |
| - en |
| tags: |
| - stanford-cars |
| - segmentation |
| - sam |
| - bounding-box |
| - mask |
| size_categories: |
| - 10K<n<100K |
| --- |
| |
| # Stanford Cars with SAM3 Segmentation Masks |
|
|
| This dataset was created using [segmentationAPI.com](https://segmentationapi.com) |
|
|
| A version of the [Stanford Cars](https://ai.stanford.edu/~jkrause/cars/car_dataset.html) dataset |
| augmented with per-image segmentation masks generated by SAM3 (Segment Anything Model 3). |
|
|
| ## Dataset Description |
|
|
| - **Images**: 196 car model classes, original Stanford Cars images |
| - **Masks**: Binary segmentation masks from SAM3, stored as grayscale PNG (255 = car, 0 = background) |
| - **Bounding boxes**: `[x1, y1, x2, y2]` pixel coordinates of the primary car object |
| - **Splits**: `train` (8,144 images), `test` (8,041 images) |
|
|
| ## Schema |
|
|
| | Column | Type | Description | |
| |--------|------------|--------------------------------------------------| |
| | image | Image | Original car photograph (JPEG) | |
| | label | int | Class label (0–195, 196 car models) | |
| | split | string | `train` or `test` | |
| | mask | Image | Binary segmentation mask (grayscale PNG) | |
| | bbox | list[int] | Bounding box `[x1, y1, x2, y2]` in pixels | |
|
|
| ## Usage |
|
|
| ```python |
| from datasets import load_dataset |
| |
| ds = load_dataset("segmentationAPIs/standford_cars_masks") |
| sample = ds["train"][0] |
| |
| sample["image"] # PIL Image — original photo |
| sample["mask"] # PIL Image — grayscale mask (255 = car) |
| sample["bbox"] # [x1, y1, x2, y2] |
| sample["label"] # int class label |
| ``` |
|
|
| ## Class Labels |
|
|
| 196 fine-grained car model classes covering major manufacturers (Acura, Aston Martin, Audi, BMW, |
| Bentley, Bugatti, Buick, Cadillac, Chevrolet, Chrysler, Dodge, Ferrari, FIAT, Ford, GMC, Honda, |
| Hyundai, Infiniti, Isuzu, Jaguar, Jeep, Lamborghini, Land Rover, Lincoln, MINI, Maybach, McLaren, |
| Mercedes-Benz, Mitsubishi, Nissan, Plymouth, Pontiac, Porsche, Ram, Rolls-Royce, Scion, Spyker, |
| Subaru, Suzuki, Tesla, Toyota, Volkswagen, Volvo). |
|
|
| ## Source |
|
|
| - Original dataset: [Stanford Cars Dataset](https://ai.stanford.edu/~jkrause/cars/car_dataset.html) |
| - Masks generated with SAM3 (Segment Anything Model 3) |