update model card README.md
Browse files
README.md
ADDED
@@ -0,0 +1,94 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: apache-2.0
|
3 |
+
tags:
|
4 |
+
- generated_from_trainer
|
5 |
+
datasets:
|
6 |
+
- imagefolder
|
7 |
+
metrics:
|
8 |
+
- accuracy
|
9 |
+
- precision
|
10 |
+
model-index:
|
11 |
+
- name: finalProject
|
12 |
+
results:
|
13 |
+
- task:
|
14 |
+
name: Image Classification
|
15 |
+
type: image-classification
|
16 |
+
dataset:
|
17 |
+
name: imagefolder
|
18 |
+
type: imagefolder
|
19 |
+
config: default
|
20 |
+
split: train
|
21 |
+
args: default
|
22 |
+
metrics:
|
23 |
+
- name: Accuracy
|
24 |
+
type: accuracy
|
25 |
+
value: 0.9886095836606441
|
26 |
+
- name: Precision
|
27 |
+
type: precision
|
28 |
+
value: 0.9890037194336745
|
29 |
+
---
|
30 |
+
|
31 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
32 |
+
should probably proofread and complete it, then remove this comment. -->
|
33 |
+
|
34 |
+
# finalProject
|
35 |
+
|
36 |
+
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.
|
37 |
+
It achieves the following results on the evaluation set:
|
38 |
+
- Loss: 0.0376
|
39 |
+
- Accuracy: 0.9886
|
40 |
+
- F1 Score: 0.9888
|
41 |
+
- Precision: 0.9890
|
42 |
+
- Sensitivity: 0.9887
|
43 |
+
- Specificity: 0.9971
|
44 |
+
|
45 |
+
## Model description
|
46 |
+
|
47 |
+
More information needed
|
48 |
+
|
49 |
+
## Intended uses & limitations
|
50 |
+
|
51 |
+
More information needed
|
52 |
+
|
53 |
+
## Training and evaluation data
|
54 |
+
|
55 |
+
More information needed
|
56 |
+
|
57 |
+
## Training procedure
|
58 |
+
|
59 |
+
### Training hyperparameters
|
60 |
+
|
61 |
+
The following hyperparameters were used during training:
|
62 |
+
- learning_rate: 0.0001
|
63 |
+
- train_batch_size: 64
|
64 |
+
- eval_batch_size: 64
|
65 |
+
- seed: 42
|
66 |
+
- gradient_accumulation_steps: 4
|
67 |
+
- total_train_batch_size: 256
|
68 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
69 |
+
- lr_scheduler_type: linear
|
70 |
+
- lr_scheduler_warmup_ratio: 0.1
|
71 |
+
- num_epochs: 10
|
72 |
+
|
73 |
+
### Training results
|
74 |
+
|
75 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 Score | Precision | Sensitivity | Specificity |
|
76 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|:--------:|:---------:|:-----------:|:-----------:|
|
77 |
+
| 0.3384 | 1.0 | 30 | 0.2387 | 0.9144 | 0.9163 | 0.9197 | 0.9146 | 0.9781 |
|
78 |
+
| 0.1608 | 2.0 | 60 | 0.1635 | 0.9466 | 0.9476 | 0.9485 | 0.9474 | 0.9865 |
|
79 |
+
| 0.0953 | 3.0 | 90 | 0.0915 | 0.9698 | 0.9703 | 0.9706 | 0.9706 | 0.9924 |
|
80 |
+
| 0.0573 | 4.0 | 120 | 0.1125 | 0.9607 | 0.9617 | 0.9634 | 0.9621 | 0.9901 |
|
81 |
+
| 0.0335 | 5.0 | 150 | 0.0536 | 0.9827 | 0.9831 | 0.9837 | 0.9826 | 0.9957 |
|
82 |
+
| 0.0185 | 6.0 | 180 | 0.0543 | 0.9827 | 0.9830 | 0.9837 | 0.9825 | 0.9957 |
|
83 |
+
| 0.0226 | 7.0 | 210 | 0.0478 | 0.9859 | 0.9861 | 0.9866 | 0.9856 | 0.9965 |
|
84 |
+
| 0.0131 | 8.0 | 240 | 0.0468 | 0.9843 | 0.9846 | 0.9847 | 0.9846 | 0.9961 |
|
85 |
+
| 0.0087 | 9.0 | 270 | 0.0411 | 0.9890 | 0.9892 | 0.9894 | 0.9891 | 0.9972 |
|
86 |
+
| 0.0043 | 10.0 | 300 | 0.0376 | 0.9886 | 0.9888 | 0.9890 | 0.9887 | 0.9971 |
|
87 |
+
|
88 |
+
|
89 |
+
### Framework versions
|
90 |
+
|
91 |
+
- Transformers 4.30.2
|
92 |
+
- Pytorch 2.0.1+cu117
|
93 |
+
- Datasets 2.13.0
|
94 |
+
- Tokenizers 0.13.3
|