
<!-- 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-base-patch4-window7-224-in22k-finetuned-brain-tumor-final_03

This model is a fine-tuned version of [microsoft/swin-base-patch4-window7-224-in22k](https://huggingface.co/microsoft/swin-base-patch4-window7-224-in22k) on the imagefolder dataset.
It achieves the following results on the evaluation set:
- Loss: 1.3844
- Accuracy: 0.2739
- F1 Score: 0.2367
- Precision: 0.3487

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

### Training results

| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 Score | Precision |
|:-------------:|:-----:|:----:|:---------------:|:--------:|:--------:|:---------:|
| 1.407         | 0.96  | 20   | 1.3971          | 0.2648   | 0.2170   | 0.3446    |
| 1.4124        | 1.98  | 41   | 1.3943          | 0.2665   | 0.2219   | 0.3467    |
| 1.4035        | 2.99  | 62   | 1.3918          | 0.2682   | 0.2255   | 0.3508    |
| 1.3978        | 4.0   | 83   | 1.3897          | 0.2705   | 0.2293   | 0.3512    |
| 1.3903        | 4.96  | 103  | 1.3880          | 0.2699   | 0.2295   | 0.3492    |
| 1.3978        | 5.98  | 124  | 1.3866          | 0.2733   | 0.2342   | 0.3537    |
| 1.3864        | 6.99  | 145  | 1.3855          | 0.2739   | 0.2362   | 0.3552    |
| 1.3913        | 8.0   | 166  | 1.3848          | 0.2733   | 0.2357   | 0.3507    |
| 1.3901        | 8.96  | 186  | 1.3844          | 0.2739   | 0.2367   | 0.3487    |
| 1.3921        | 9.64  | 200  | 1.3844          | 0.2739   | 0.2367   | 0.3487    |


### Framework versions

- Transformers 4.29.2
- Pytorch 2.0.1+cu117
- Datasets 2.12.0
- Tokenizers 0.13.3

glioma meningioma notumor pituitary