docs/en/datasets/classify/imagewoof.md
The ImageWoof dataset is a subset of ImageNet consisting of 10 dog-breed classes that are deliberately hard to tell apart, created by fast.ai as a tougher challenge for image classification algorithms. It contains 12,954 color images — 9,025 for training and 3,929 for validation — across breeds such as Beagle, Shih-Tzu, and Golden retriever, pushing models to distinguish subtle fine-grained differences rather than obvious object categories.
ImageWoof ships with a predefined train/validation split, with each dog breed stored in its own folder:
| Split | Images | Classes |
|---|---|---|
| Train | 9,025 | 10 |
| Validation | 3,929 | 10 |
Because all 10 classes are dog breeds, the split is designed to test fine-grained classification — telling apart visually similar categories — rather than the broad object recognition of the full ImageNet dataset.
The ImageWoof dataset is widely used for training and evaluating deep learning models on more complex and similar classes. Its challenge lies in the subtle differences between the dog breeds, pushing the limits of model performance and generalization. It is particularly valuable for:
To train a classification model on the ImageWoof dataset for 100 epochs with an image size of 224x224, use the code snippets below. For a comprehensive list of available arguments, refer to the model Training page.
!!! example "Train Example"
=== "Python"
```python
from ultralytics import YOLO
# Load a model
model = YOLO("yolo26n-cls.pt") # load a pretrained model (recommended for training)
# Train the model
results = model.train(data="imagewoof", epochs=100, imgsz=224)
```
=== "CLI"
```bash
# Start training from a pretrained *.pt model
yolo classify train data=imagewoof model=yolo26n-cls.pt epochs=100 imgsz=224
```
ImageWoof comes in three sizes to accommodate different research needs and computational budgets:
imagewoof): The original version with full-sized images, ideal for final training and performance benchmarking.imagewoof320): Images resized to a maximum edge length of 320 pixels, suitable for faster training without significantly sacrificing model performance.imagewoof160): Images resized to a maximum edge length of 160 pixels, designed for rapid prototyping and experimentation where training speed is a priority.To use these variants, simply replace imagewoof in the dataset argument with imagewoof320 or imagewoof160. For example:
!!! example
=== "Python"
```python
from ultralytics import YOLO
# Load a model
model = YOLO("yolo26n-cls.pt") # load a pretrained model (recommended for training)
# For medium-sized dataset
model.train(data="imagewoof320", epochs=100, imgsz=224)
# For small-sized dataset
model.train(data="imagewoof160", epochs=100, imgsz=224)
```
=== "CLI"
```bash
# Load a pretrained model and train on the medium-sized dataset
yolo classify train model=yolo26n-cls.pt data=imagewoof320 epochs=100 imgsz=224
```
Note that smaller images will likely yield lower classification accuracy, but they are an excellent way to iterate quickly in the early stages of model development. You can also manage classification datasets and run training in the cloud with Ultralytics Platform.
The ImageWoof dataset contains colorful images of various dog breeds, providing a challenging dataset for image classification tasks. Here are some examples of images from the dataset:
The example showcases the subtle differences and similarities among the different dog breeds, highlighting the complexity and difficulty of the classification task.
If you use the ImageWoof dataset in your research or development work, please acknowledge the creators of the dataset by linking to the official dataset repository.
We would like to acknowledge the fast.ai team for creating and maintaining ImageWoof as a valuable resource for the machine learning and computer vision research community. For more information about ImageWoof, visit the ImageWoof dataset repository.
The ImageWoof dataset is a challenging subset of ImageNet focused on 10 dog breeds, containing 12,954 images (9,025 training and 3,929 validation). Created by fast.ai to push the limits of image classification models, it features breeds such as Beagle, Shih-Tzu, and Golden retriever. The dataset is available at various resolutions (full size, 320px, 160px) and even includes noisy labels for more realistic training scenarios, making it ideal for developing advanced deep learning models.
ImageWoof contains 12,954 images in total — 9,025 for training and 3,929 for validation — across 10 dog breeds: Australian terrier, Border terrier, Samoyed, Beagle, Shih-Tzu, English foxhound, Rhodesian ridgeback, Dingo, Golden retriever, and Old English sheepdog. Each breed is stored in its own folder, following the standard classification layout Ultralytics expects.
To train a classification model on the ImageWoof dataset using Ultralytics YOLO for 100 epochs at an image size of 224x224, use the following code:
!!! example "Train Example"
=== "Python"
```python
from ultralytics import YOLO
model = YOLO("yolo26n-cls.pt") # Load a pretrained model
results = model.train(data="imagewoof", epochs=100, imgsz=224)
```
=== "CLI"
```bash
yolo classify train data=imagewoof model=yolo26n-cls.pt epochs=100 imgsz=224
```
For more details on available training arguments, refer to the Training page.
The ImageWoof dataset comes in three sizes:
imagewoof): Ideal for final training and benchmarking, containing full-sized images.imagewoof320): Resized images with a maximum edge length of 320 pixels, suited for faster training.imagewoof160): Resized images with a maximum edge length of 160 pixels, perfect for rapid prototyping.Use these versions by replacing imagewoof in the dataset argument accordingly. Note that smaller images may yield lower classification accuracy but are useful for quicker iterations.
Noisy labels in the ImageWoof dataset simulate real-world conditions where labels are not always accurate. Training models with this data helps develop robustness and generalization in image classification tasks. It prepares models to handle ambiguous or mislabeled data effectively, which is often encountered in practical applications.
The primary challenge of ImageWoof lies in the subtle differences among the dog breeds it includes. Because it focuses on 10 closely related breeds, distinguishing between them requires more advanced and fine-tuned image classification models. This makes ImageWoof an excellent benchmark to test the capabilities and improvements of deep learning models.