# citrus_leaves

<br />

- **Description**:

The original citrus dataset contains 759 images of healthy and unhealthy citrus
fruits and leaves. However, for now we only export 594 images of citrus leaves
with the following labels: Black Spot, Canker, Greening, and Healthy. The
exported images are in PNG format and have 256x256 pixels.

> [!NOTE]
> **Note:** Leaf images with Melanose label were dropped due to very small count and other non-leaf images being present in the same directory.

Dataset URL: <https://data.mendeley.com/datasets/3f83gxmv57/2> License:
<http://creativecommons.org/licenses/by/4.0>

- **Homepage** :
  <https://data.mendeley.com/datasets/3f83gxmv57/2>

- **Source code** :
  [`tfds.image_classification.CitrusLeaves`](https://github.com/tensorflow/datasets/tree/master/tensorflow_datasets/image_classification/citrus.py)

- **Versions**:

  - `0.1.1`: Citrus Leaves dataset
  - **`0.1.2`** (default): Website URL update
- **Download size** : `63.87 MiB`

- **Dataset size** : `37.89 MiB`

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

- **Splits**:

| Split | Examples |
|---|---|
| `'train'` | 594 |

- **Feature structure**:

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

- **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/citrus_leaves-0.1.2.png)

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

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

- **Citation**:

    @article{rauf2019citrus,
      title={A citrus fruits and leaves dataset for detection and classification of
    citrus diseases through machine learning},
      author={Rauf, Hafiz Tayyab and Saleem, Basharat Ali and Lali, M Ikram Ullah
    and Khan, Muhammad Attique and Sharif, Muhammad and Bukhari, Syed Ahmad Chan},
      journal={Data in brief},
      volume={26},
      pages={104340},
      year={2019},
      publisher={Elsevier}
    }