
<!-- 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. -->

# swin-tiny-patch4-window7-224-PE

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.6756
- Accuracy: 0.5833

## 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: 0.0025
- train_batch_size: 128
- eval_batch_size: 128
- seed: 42
- gradient_accumulation_steps: 4
- total_train_batch_size: 512
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
- lr_scheduler_type: linear
- lr_scheduler_warmup_ratio: 0.1
- num_epochs: 50

### Training results

| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|:-------------:|:-----:|:----:|:---------------:|:--------:|
| 0.5675        | 0.99  | 20   | 0.5504          | 0.7463   |
| 0.7158        | 1.98  | 40   | 0.9070          | 0.5944   |
| 0.6498        | 2.96  | 60   | 0.6501          | 0.6037   |
| 0.6405        | 4.0   | 81   | 0.5655          | 0.7389   |
| 0.7003        | 4.99  | 101  | 0.6786          | 0.5907   |
| 0.6857        | 5.98  | 121  | 0.6820          | 0.5370   |
| 0.6933        | 6.96  | 141  | 0.6819          | 0.5926   |
| 0.6795        | 8.0   | 162  | 0.6783          | 0.5481   |
| 0.6872        | 8.99  | 182  | 0.6907          | 0.5370   |
| 0.6942        | 9.98  | 202  | 0.6922          | 0.5407   |
| 0.6945        | 10.96 | 222  | 0.6935          | 0.4630   |
| 0.6936        | 12.0  | 243  | 0.6974          | 0.4630   |
| 0.6935        | 12.99 | 263  | 0.6907          | 0.5407   |
| 0.6925        | 13.98 | 283  | 0.6945          | 0.4241   |
| 0.6927        | 14.96 | 303  | 0.6952          | 0.4630   |
| 0.6921        | 16.0  | 324  | 0.6901          | 0.5463   |
| 0.6937        | 16.99 | 344  | 0.6935          | 0.4407   |
| 0.6933        | 17.98 | 364  | 0.6922          | 0.5537   |
| 0.6929        | 18.96 | 384  | 0.6971          | 0.4630   |
| 0.6919        | 20.0  | 405  | 0.6901          | 0.5630   |
| 0.6903        | 20.99 | 425  | 0.6850          | 0.5722   |
| 0.6892        | 21.98 | 445  | 0.6876          | 0.5611   |
| 0.6846        | 22.96 | 465  | 0.6871          | 0.5463   |
| 0.6841        | 24.0  | 486  | 0.6742          | 0.5685   |
| 0.682         | 24.99 | 506  | 0.6776          | 0.5741   |
| 0.6796        | 25.98 | 526  | 0.6850          | 0.5407   |
| 0.6849        | 26.96 | 546  | 0.6722          | 0.5907   |
| 0.6855        | 28.0  | 567  | 0.6818          | 0.5648   |
| 0.6903        | 28.99 | 587  | 0.7024          | 0.4685   |
| 0.6845        | 29.98 | 607  | 0.6781          | 0.5630   |
| 0.6806        | 30.96 | 627  | 0.6771          | 0.5778   |
| 0.6808        | 32.0  | 648  | 0.6718          | 0.5833   |
| 0.6811        | 32.99 | 668  | 0.6715          | 0.5833   |
| 0.6814        | 33.98 | 688  | 0.6641          | 0.6370   |
| 0.6848        | 34.96 | 708  | 0.6736          | 0.6111   |
| 0.6848        | 36.0  | 729  | 0.6694          | 0.6259   |
| 0.6848        | 36.99 | 749  | 0.6757          | 0.5907   |
| 0.6865        | 37.98 | 769  | 0.6763          | 0.5667   |
| 0.6876        | 38.96 | 789  | 0.6812          | 0.5889   |
| 0.6858        | 40.0  | 810  | 0.6763          | 0.5926   |
| 0.6863        | 40.99 | 830  | 0.6743          | 0.5981   |
| 0.6838        | 41.98 | 850  | 0.6740          | 0.5796   |
| 0.6833        | 42.96 | 870  | 0.6770          | 0.5611   |
| 0.6883        | 44.0  | 891  | 0.6733          | 0.6037   |
| 0.684         | 44.99 | 911  | 0.6730          | 0.6019   |
| 0.6869        | 45.98 | 931  | 0.6731          | 0.6130   |
| 0.6861        | 46.96 | 951  | 0.6752          | 0.5704   |
| 0.686         | 48.0  | 972  | 0.6761          | 0.5704   |
| 0.683         | 48.99 | 992  | 0.6759          | 0.5722   |
| 0.6847        | 49.38 | 1000 | 0.6756          | 0.5833   |


### Framework versions

- Transformers 4.35.2
- Pytorch 2.0.1+cu117
- Datasets 2.15.0
- Tokenizers 0.15.0

non pneumothroax pneumothroax