# i_naturalist2021

<br />

- **Description**:

The iNaturalist dataset 2021 contains a total of 10,000 species. The full
training dataset contains nearly 2.7M images. To make the dataset more
accessible we have also created a "mini" training dataset with 50 examples per
species for a total of 500K images. The full training `train` split overlaps
with the `mini` split. The val set contains for each species 10 validation
images (100K in total). There are a total of 500,000 test images in the
`public_test` split (without ground-truth labels).

- **Homepage** :
  <https://github.com/visipedia/inat_comp/tree/master/2021>

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

- **Versions**:

  - `1.0.0`: Initial release.
  - `2.0.0`: Update: Class indices follow the order in the JSON train file.
  - **`2.0.1`** (default): Update: Include the example id as provided in the JSON files.
- **Download size** : `316.54 GiB`

- **Dataset size** : `318.45 GiB`

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

- **Splits**:

| Split | Examples |
|---|---|
| `'mini'` | 500,000 |
| `'test'` | 500,000 |
| `'train'` | 2,686,843 |
| `'val'` | 100,000 |

- **Feature structure**:

    FeaturesDict({
        'file_id': Text(shape=(), dtype=string),
        'id': Scalar(shape=(), dtype=int64),
        'image': Image(shape=(None, None, 3), dtype=uint8),
        'label': ClassLabel(shape=(), dtype=int64, num_classes=10000),
        'supercategory': ClassLabel(shape=(), dtype=int64, num_classes=11),
    })

- **Feature documentation**:

| Feature | Class | Shape | Dtype | Description |
|---|---|---|---|---|
|   | FeaturesDict |   |   |   |
| file_id | Text |   | string |   |
| id | Scalar |   | int64 |   |
| image | Image | (None, None, 3) | uint8 |   |
| label | ClassLabel |   | int64 |   |
| supercategory | 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/i_naturalist2021-2.0.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{inaturalist21,
        Howpublished = {~\url{https://github.com/visipedia/inat_comp/tree/master/2021} },
        Title = { {iNaturalist} 2021 competition dataset.},
        Year = {2021},
        key = { {iNaturalist} 2021 competition dataset},
        }