File size: 2,953 Bytes
e9b6542
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
e4ad573
e9b6542
 
e4ad573
e9b6542
 
 
 
 
 
 
 
 
e4ad573
 
 
 
e9b6542
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
---
license: apache-2.0
tags:
- generated_from_trainer
datasets:
- imagefolder
metrics:
- accuracy
- precision
model-index:
- name: swin-base-patch4-window7-224-in22k-finetuned-brain-tumor-skullStrippded_04
  results:
  - task:
      name: Image Classification
      type: image-classification
    dataset:
      name: imagefolder
      type: imagefolder
      config: default
      split: train
      args: default
    metrics:
    - name: Accuracy
      type: accuracy
      value: 0.9842906234658811
    - name: Precision
      type: precision
      value: 0.9845888529063952
---

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

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: 0.0470
- Accuracy: 0.9843
- F1 Score: 0.9844
- Precision: 0.9846

## 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.0001
- train_batch_size: 100
- eval_batch_size: 100
- seed: 42
- gradient_accumulation_steps: 4
- total_train_batch_size: 400
- 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 | Accuracy | F1 Score | Validation Loss | Precision |
|:-------------:|:-----:|:----:|:--------:|:--------:|:---------------:|:---------:|
| 1.2662        | 1.0   | 16   | 0.8370   | 0.8309   | 0.4424          | 0.8464    |
| 0.3778        | 0.98  | 20   | 0.2700   | 0.9062   | 0.9067          | 0.9072    |
| 0.2377        | 2.0   | 41   | 0.2035   | 0.9229   | 0.9234          | 0.9269    |
| 0.1201        | 2.98  | 61   | 0.1345   | 0.9465   | 0.9467          | 0.9512    |
| 0.0774        | 4.0   | 82   | 0.1229   | 0.9612   | 0.9618          | 0.9643    |
| 0.0495        | 4.98  | 102  | 0.0562   | 0.9813   | 0.9815          | 0.9816    |
| 0.0358        | 6.0   | 123  | 0.0470   | 0.9843   | 0.9844          | 0.9846    |
| 0.0228        | 6.98  | 143  | 0.0447   | 0.9833   | 0.9834          | 0.9836    |
| 0.0181        | 8.0   | 164  | 0.0465   | 0.9828   | 0.9830          | 0.9831    |
| 0.0132        | 8.98  | 184  | 0.0436   | 0.9833   | 0.9835          | 0.9836    |
| 0.0126        | 9.76  | 200  | 0.0461   | 0.9838   | 0.9840          | 0.9840    |


### Framework versions

- Transformers 4.27.4
- Pytorch 2.0.0+cu117
- Datasets 2.11.0
- Tokenizers 0.13.3