transformers tensorboard safetensors swin image-classification generated_from_trainer dataset:imagefolder base_model:microsoft/swin-tiny-patch4-window7-224 license:apache-2.0 model-index autotrain_compatible endpoints_compatible region:us
---
license: apache-2.0
base_model: microsoft/swin-tiny-patch4-window7-224
tags:
- generated_from_trainer
datasets:
- imagefolder
metrics:
- accuracy
model-index:
- name: compoundleaf-swin-tiny-patch4-window7-224-finetuned
  results:
  - task:
      name: Image Classification
      type: image-classification
    dataset:
      name: imagefolder
      type: imagefolder
      config: default
      split: validation
      args: default
    metrics:
    - name: Accuracy
      type: accuracy
      value: 0.9955357142857143
---

<!-- This model card has been generated automatically according to the information the Trainer had access to. You
should probably proofread and complete it, then remove this comment. -->

# compoundleaf-swin-tiny-patch4-window7-224-finetuned

This model is a fine-tuned version of [microsoft/swin-tiny-patch4-window7-224](https://huggingface.co/microsoft/swin-tiny-patch4-window7-224) on the imagefolder dataset.
It achieves the following results on the evaluation set:
- Loss: 0.0204
- Accuracy: 0.9955

## Model description

More information needed

## Intended uses & limitations

More information needed

## Training and evaluation data

More information needed

## Training procedure

### Training hyperparameters

The following hyperparameters were used during training:
- learning_rate: 5e-05
- train_batch_size: 32
- eval_batch_size: 32
- seed: 42
- gradient_accumulation_steps: 4
- total_train_batch_size: 128
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
- lr_scheduler_type: linear
- lr_scheduler_warmup_ratio: 0.1
- num_epochs: 30

### Training results

| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|:-------------:|:-----:|:----:|:---------------:|:--------:|
| No log        | 1.0   | 7    | 0.9808          | 0.5446   |
| 1.1008        | 2.0   | 14   | 0.6537          | 0.8438   |
| 0.6618        | 3.0   | 21   | 0.2581          | 0.9464   |
| 0.6618        | 4.0   | 28   | 0.0740          | 0.9866   |
| 0.1685        | 5.0   | 35   | 0.0405          | 0.9911   |
| 0.0552        | 6.0   | 42   | 0.0824          | 0.9866   |
| 0.0552        | 7.0   | 49   | 0.0753          | 0.9777   |
| 0.0422        | 8.0   | 56   | 0.0204          | 0.9955   |
| 0.0212        | 9.0   | 63   | 0.0646          | 0.9821   |
| 0.02          | 10.0  | 70   | 0.0172          | 0.9955   |
| 0.02          | 11.0  | 77   | 0.0279          | 0.9955   |
| 0.0159        | 12.0  | 84   | 0.0221          | 0.9955   |
| 0.0053        | 13.0  | 91   | 0.0415          | 0.9866   |
| 0.0053        | 14.0  | 98   | 0.0222          | 0.9955   |
| 0.0075        | 15.0  | 105  | 0.0408          | 0.9955   |
| 0.003         | 16.0  | 112  | 0.0187          | 0.9955   |
| 0.003         | 17.0  | 119  | 0.0307          | 0.9911   |
| 0.0073        | 18.0  | 126  | 0.0327          | 0.9955   |
| 0.0079        | 19.0  | 133  | 0.0203          | 0.9955   |
| 0.0066        | 20.0  | 140  | 0.0319          | 0.9955   |
| 0.0066        | 21.0  | 147  | 0.0451          | 0.9866   |
| 0.0038        | 22.0  | 154  | 0.0264          | 0.9955   |
| 0.0122        | 23.0  | 161  | 0.0968          | 0.9821   |
| 0.0122        | 24.0  | 168  | 0.0547          | 0.9911   |
| 0.0096        | 25.0  | 175  | 0.0260          | 0.9955   |
| 0.0034        | 26.0  | 182  | 0.0432          | 0.9911   |
| 0.0034        | 27.0  | 189  | 0.0587          | 0.9911   |
| 0.009         | 28.0  | 196  | 0.0478          | 0.9911   |
| 0.004         | 29.0  | 203  | 0.0323          | 0.9955   |
| 0.0081        | 30.0  | 210  | 0.0302          | 0.9955   |


### Framework versions

- Transformers 4.38.1
- Pytorch 1.10.0+cu111
- Datasets 2.17.1
- Tokenizers 0.15.2
