# plant_leaves

<br />

- **Description**:

This dataset consists of 4502 images of healthy and unhealthy plant leaves
divided into 22 categories by species and state of health. The images are in
high resolution JPG format.

There are no files with label prefix 0000, therefore label encoding is shifted
by one (e.g. file with label prefix 0001 gets encoded label 0).

> [!NOTE]
> **Note:** Each image is a separate download. Some might rarely fail, therefore make sure to restart if that happens. An exception will be raised in case one of the downloads repeatedly fails.

Dataset URL: <https://data.mendeley.com/datasets/hb74ynkjcn/1> License:
<http://creativecommons.org/licenses/by/4.0>

- **Homepage** :
  <https://data.mendeley.com/datasets/hb74ynkjcn/1>

- **Source code** :
  [`tfds.datasets.plant_leaves.Builder`](https://github.com/tensorflow/datasets/tree/master/tensorflow_datasets/datasets/plant_leaves/plant_leaves_dataset_builder.py)

- **Versions**:

  - `0.1.0`: Initial release.
  - **`0.1.1`** (default): Fix checksum error.
- **Download size** : `6.56 GiB`

- **Dataset size** : `6.81 GiB`

- **Auto-cached**
  ([documentation](https://www.tensorflow.org/datasets/performances#auto-caching)):
  No

- **Splits**:

| Split | Examples |
|---|---|
| `'train'` | 4,502 |

- **Feature structure**:

    FeaturesDict({
        'image': Image(shape=(None, None, 3), dtype=uint8),
        'image/filename': Text(shape=(), dtype=string),
        'label': ClassLabel(shape=(), dtype=int64, num_classes=22),
    })

- **Feature documentation**:

| Feature | Class | Shape | Dtype | Description |
|---|---|---|---|---|
|   | FeaturesDict |   |   |   |
| image | Image | (None, None, 3) | uint8 |   |
| image/filename | Text |   | string |   |
| label | ClassLabel |   | int64 |   |

- **Supervised keys** (See
  [`as_supervised` doc](https://www.tensorflow.org/datasets/api_docs/python/tfds/load#args)):
  `('image', 'label')`

- **Figure**
  ([tfds.show_examples](https://www.tensorflow.org/datasets/api_docs/python/tfds/visualization/show_examples)):

![Visualization](https://storage.googleapis.com/tfds-data/visualization/fig/plant_leaves-0.1.1.png)

- **Examples** ([tfds.as_dataframe](https://www.tensorflow.org/datasets/api_docs/python/tfds/as_dataframe)):

<button id="displaydataframe">Display examples...</button>

- **Citation**:

    @misc{,
      author={Siddharth Singh Chouhan, Ajay Kaul, Uday Pratap Singh, Sanjeev
    Jain},
      title={A Database of Leaf Images: Practice towards Plant Conservation with
    Plant Pathology},
      howpublished={Mendeley Data},
      year={2019}
    }