physiotheraphy-E2
This model is a fine-tuned version of google/vit-base-patch16-224 on the imagefolder dataset. It achieves the following results on the evaluation set:
Accuracy: 0.9564
F1: 0.9548
Precision: 0.9549
Recall: 0.9556
Loss: 0.2235
Classification Report: precision recall f1-score support
0 0.92 0.95 0.93 57 1 0.99 0.97 0.98 70 2 1.00 1.00 1.00 33 3 0.98 1.00 0.99 43 4 1.00 1.00 1.00 34 5 0.94 1.00 0.97 32 6 0.95 0.94 0.95 65 7 0.87 0.79 0.83 33
accuracy 0.96 367 macro avg 0.95 0.96 0.95 367
weighted avg 0.96 0.96 0.96 367
- Confusion Matrix: [[0.9473684210526315, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.05263157894736842], [0.0, 0.9714285714285714, 0.0, 0.0, 0.0, 0.02857142857142857, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9384615384615385, 0.015384615384615385], [0.06060606060606061, 0.030303030303030304, 0.0, 0.030303030303030304, 0.0, 0.0, 0.09090909090909091, 0.7878787878787878]]
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.0005
- train_batch_size: 4
- eval_batch_size: 4
- seed: 42
- gradient_accumulation_steps: 2
- total_train_batch_size: 8
- 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
- mixed_precision_training: Native AMP
Training results
Training Loss | Epoch | Step | Accuracy | F1 | Precision | Recall | Validation Loss | Classification Report | Confusion Matrix |
---|---|---|---|---|---|---|---|---|---|
0.9195 | 0.9973 | 182 | 0.7248 | 0.7148 | 0.7616 | 0.7319 | 0.8807 | precision recall f1-score support |
0 1.00 0.51 0.67 57
1 0.98 0.69 0.81 70
2 0.70 0.79 0.74 33
3 0.74 0.86 0.80 43
4 0.45 1.00 0.62 34
5 0.80 0.50 0.62 32
6 0.73 0.82 0.77 65
7 0.70 0.70 0.70 33
accuracy 0.72 367
macro avg 0.76 0.73 0.71 367 weighted avg 0.79 0.72 0.73 367 | [[0.5087719298245614, 0.017543859649122806, 0.08771929824561403, 0.08771929824561403, 0.07017543859649122, 0.0, 0.17543859649122806, 0.05263157894736842], [0.0, 0.6857142857142857, 0.0, 0.08571428571428572, 0.1, 0.05714285714285714, 0.07142857142857142, 0.0], [0.0, 0.0, 0.7878787878787878, 0.0, 0.21212121212121213, 0.0, 0.0, 0.0], [0.0, 0.0, 0.023255813953488372, 0.8604651162790697, 0.09302325581395349, 0.0, 0.023255813953488372, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.03125, 0.0, 0.46875, 0.5, 0.0, 0.0], [0.0, 0.0, 0.03076923076923077, 0.015384615384615385, 0.03076923076923077, 0.0, 0.8153846153846154, 0.1076923076923077], [0.0, 0.0, 0.06060606060606061, 0.030303030303030304, 0.09090909090909091, 0.0, 0.12121212121212122, 0.696969696969697]] | | 0.8122 | 2.0 | 365 | 0.8365 | 0.8228 | 0.8668 | 0.8177 | 0.5425 | precision recall f1-score support
0 0.64 0.88 0.74 57
1 0.86 0.84 0.85 70
2 0.91 0.94 0.93 33
3 0.88 0.98 0.92 43
4 0.92 1.00 0.96 34
5 1.00 0.44 0.61 32
6 0.91 0.89 0.90 65
7 0.83 0.58 0.68 33
accuracy 0.84 367
macro avg 0.87 0.82 0.82 367 weighted avg 0.85 0.84 0.83 367 | [[0.8771929824561403, 0.03508771929824561, 0.03508771929824561, 0.0, 0.0, 0.0, 0.03508771929824561, 0.017543859649122806], [0.05714285714285714, 0.8428571428571429, 0.0, 0.08571428571428572, 0.0, 0.0, 0.0, 0.014285714285714285], [0.06060606060606061, 0.0, 0.9393939393939394, 0.0, 0.0, 0.0, 0.0, 0.0], [0.023255813953488372, 0.0, 0.0, 0.9767441860465116, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.25, 0.1875, 0.03125, 0.0, 0.09375, 0.4375, 0.0, 0.0], [0.07692307692307693, 0.0, 0.0, 0.0, 0.0, 0.0, 0.8923076923076924, 0.03076923076923077], [0.24242424242424243, 0.06060606060606061, 0.0, 0.0, 0.0, 0.0, 0.12121212121212122, 0.5757575757575758]] | | 0.4541 | 2.9973 | 547 | 0.7929 | 0.7963 | 0.8137 | 0.8177 | 0.7462 | precision recall f1-score support
0 0.86 0.74 0.79 57
1 1.00 0.51 0.68 70
2 0.91 0.91 0.91 33
3 0.85 0.93 0.89 43
4 0.71 1.00 0.83 34
5 0.70 0.94 0.80 32
6 0.69 0.91 0.78 65
7 0.80 0.61 0.69 33
accuracy 0.79 367
macro avg 0.81 0.82 0.80 367 weighted avg 0.83 0.79 0.79 367 | [[0.7368421052631579, 0.0, 0.05263157894736842, 0.0, 0.07017543859649122, 0.03508771929824561, 0.07017543859649122, 0.03508771929824561], [0.02857142857142857, 0.5142857142857142, 0.0, 0.1, 0.05714285714285714, 0.12857142857142856, 0.17142857142857143, 0.0], [0.0, 0.0, 0.9090909090909091, 0.0, 0.06060606060606061, 0.030303030303030304, 0.0, 0.0], [0.0, 0.0, 0.0, 0.9302325581395349, 0.0, 0.0, 0.046511627906976744, 0.023255813953488372], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0625, 0.9375, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.015384615384615385, 0.0, 0.9076923076923077, 0.03076923076923077], [0.06060606060606061, 0.0, 0.0, 0.0, 0.030303030303030304, 0.030303030303030304, 0.2727272727272727, 0.6060606060606061]] | | 0.3103 | 4.0 | 730 | 0.8583 | 0.8611 | 0.8684 | 0.8670 | 0.4772 | precision recall f1-score support
0 0.96 0.77 0.85 57
1 0.96 0.74 0.84 70
2 0.91 0.97 0.94 33
3 0.93 0.91 0.92 43
4 1.00 0.97 0.99 34
5 0.78 0.97 0.86 32
6 0.73 0.97 0.83 65
7 0.68 0.64 0.66 33
accuracy 0.86 367
macro avg 0.87 0.87 0.86 367 weighted avg 0.87 0.86 0.86 367 | [[0.7719298245614035, 0.017543859649122806, 0.0, 0.0, 0.0, 0.017543859649122806, 0.03508771929824561, 0.15789473684210525], [0.0, 0.7428571428571429, 0.02857142857142857, 0.02857142857142857, 0.0, 0.04285714285714286, 0.15714285714285714, 0.0], [0.0, 0.030303030303030304, 0.9696969696969697, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.9069767441860465, 0.0, 0.023255813953488372, 0.06976744186046512, 0.0], [0.0, 0.0, 0.0, 0.0, 0.9705882352941176, 0.029411764705882353, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 0.96875, 0.03125, 0.0], [0.015384615384615385, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9692307692307692, 0.015384615384615385], [0.030303030303030304, 0.0, 0.030303030303030304, 0.030303030303030304, 0.0, 0.09090909090909091, 0.18181818181818182, 0.6363636363636364]] | | 0.1391 | 4.9973 | 912 | 0.9046 | 0.9055 | 0.9004 | 0.9151 | 0.4130 | precision recall f1-score support
0 0.90 0.79 0.84 57
1 0.96 0.91 0.93 70
2 0.94 1.00 0.97 33
3 0.91 1.00 0.96 43
4 1.00 1.00 1.00 34
5 0.88 0.94 0.91 32
6 0.95 0.86 0.90 65
7 0.66 0.82 0.73 33
accuracy 0.90 367
macro avg 0.90 0.92 0.91 367 weighted avg 0.91 0.90 0.91 367 | [[0.7894736842105263, 0.0, 0.03508771929824561, 0.0, 0.0, 0.0, 0.0, 0.17543859649122806], [0.0, 0.9142857142857143, 0.0, 0.02857142857142857, 0.0, 0.05714285714285714, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.03125, 0.0, 0.0, 0.0, 0.9375, 0.0, 0.03125], [0.06153846153846154, 0.015384615384615385, 0.0, 0.015384615384615385, 0.0, 0.0, 0.8615384615384616, 0.046153846153846156], [0.030303030303030304, 0.030303030303030304, 0.0, 0.030303030303030304, 0.0, 0.0, 0.09090909090909091, 0.8181818181818182]] | | 0.0753 | 6.0 | 1095 | 0.9401 | 0.9367 | 0.9365 | 0.9403 | 0.2873 | precision recall f1-score support
0 0.93 0.89 0.91 57
1 0.97 0.97 0.97 70
2 1.00 0.97 0.98 33
3 1.00 0.98 0.99 43
4 0.87 1.00 0.93 34
5 0.84 0.97 0.90 32
6 0.95 0.92 0.94 65
7 0.93 0.82 0.87 33
accuracy 0.94 367
macro avg 0.94 0.94 0.94 367 weighted avg 0.94 0.94 0.94 367 | [[0.8947368421052632, 0.0, 0.0, 0.0, 0.07017543859649122, 0.017543859649122806, 0.0, 0.017543859649122806], [0.0, 0.9714285714285714, 0.0, 0.0, 0.0, 0.02857142857142857, 0.0, 0.0], [0.0, 0.0, 0.9696969696969697, 0.0, 0.030303030303030304, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.9767441860465116, 0.0, 0.023255813953488372, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.03125, 0.0, 0.0, 0.0, 0.96875, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.015384615384615385, 0.9230769230769231, 0.015384615384615385], [0.030303030303030304, 0.030303030303030304, 0.0, 0.0, 0.0, 0.030303030303030304, 0.09090909090909091, 0.8181818181818182]] | | 0.0178 | 6.9973 | 1277 | 0.9455 | 0.9439 | 0.9535 | 0.9374 | 0.2430 | precision recall f1-score support
0 0.85 0.96 0.90 57
1 0.99 0.97 0.98 70
2 1.00 0.97 0.98 33
3 0.98 0.98 0.98 43
4 1.00 1.00 1.00 34
5 0.97 0.88 0.92 32
6 0.93 0.95 0.94 65
7 0.93 0.79 0.85 33
accuracy 0.95 367
macro avg 0.95 0.94 0.94 367 weighted avg 0.95 0.95 0.95 367 | [[0.9649122807017544, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.03508771929824561], [0.0, 0.9714285714285714, 0.0, 0.014285714285714285, 0.0, 0.014285714285714285, 0.0, 0.0], [0.030303030303030304, 0.0, 0.9696969696969697, 0.0, 0.0, 0.0, 0.0, 0.0], [0.023255813953488372, 0.0, 0.0, 0.9767441860465116, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0625, 0.03125, 0.0, 0.0, 0.0, 0.875, 0.03125, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9538461538461539, 0.0], [0.09090909090909091, 0.0, 0.0, 0.0, 0.0, 0.0, 0.12121212121212122, 0.7878787878787878]] | | 0.0037 | 8.0 | 1460 | 0.9564 | 0.9548 | 0.9549 | 0.9556 | 0.2235 | precision recall f1-score support
0 0.92 0.95 0.93 57
1 0.99 0.97 0.98 70
2 1.00 1.00 1.00 33
3 0.98 1.00 0.99 43
4 1.00 1.00 1.00 34
5 0.94 1.00 0.97 32
6 0.95 0.94 0.95 65
7 0.87 0.79 0.83 33
accuracy 0.96 367
macro avg 0.95 0.96 0.95 367 weighted avg 0.96 0.96 0.96 367 | [[0.9473684210526315, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.05263157894736842], [0.0, 0.9714285714285714, 0.0, 0.0, 0.0, 0.02857142857142857, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9384615384615385, 0.015384615384615385], [0.06060606060606061, 0.030303030303030304, 0.0, 0.030303030303030304, 0.0, 0.0, 0.09090909090909091, 0.7878787878787878]] | | 0.0034 | 8.9973 | 1642 | 0.9564 | 0.9548 | 0.9549 | 0.9556 | 0.2194 | precision recall f1-score support
0 0.92 0.95 0.93 57
1 0.99 0.97 0.98 70
2 1.00 1.00 1.00 33
3 0.98 1.00 0.99 43
4 1.00 1.00 1.00 34
5 0.94 1.00 0.97 32
6 0.95 0.94 0.95 65
7 0.87 0.79 0.83 33
accuracy 0.96 367
macro avg 0.95 0.96 0.95 367 weighted avg 0.96 0.96 0.96 367 | [[0.9473684210526315, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.05263157894736842], [0.0, 0.9714285714285714, 0.0, 0.0, 0.0, 0.02857142857142857, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9384615384615385, 0.015384615384615385], [0.06060606060606061, 0.030303030303030304, 0.0, 0.030303030303030304, 0.0, 0.0, 0.09090909090909091, 0.7878787878787878]] | | 0.0027 | 9.9726 | 1820 | 0.9564 | 0.9548 | 0.9549 | 0.9556 | 0.2193 | precision recall f1-score support
0 0.92 0.95 0.93 57
1 0.99 0.97 0.98 70
2 1.00 1.00 1.00 33
3 0.98 1.00 0.99 43
4 1.00 1.00 1.00 34
5 0.94 1.00 0.97 32
6 0.95 0.94 0.95 65
7 0.87 0.79 0.83 33
accuracy 0.96 367
macro avg 0.95 0.96 0.95 367 weighted avg 0.96 0.96 0.96 367 | [[0.9473684210526315, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.05263157894736842], [0.0, 0.9714285714285714, 0.0, 0.0, 0.0, 0.02857142857142857, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0], [0.046153846153846156, 0.0, 0.0, 0.0, 0.0, 0.0, 0.9384615384615385, 0.015384615384615385], [0.06060606060606061, 0.030303030303030304, 0.0, 0.030303030303030304, 0.0, 0.0, 0.09090909090909091, 0.7878787878787878]] |
Framework versions
- Transformers 4.43.3
- Pytorch 2.3.1+cu121
- Datasets 2.20.0
- Tokenizers 0.19.1
- Downloads last month
- 83
Model tree for khalilUoM/physiotheraphy-E2
Base model
google/vit-base-patch16-224Evaluation results
- Accuracy on imagefolderself-reported0.956
- F1 on imagefolderself-reported0.955
- Precision on imagefolderself-reported0.955
- Recall on imagefolderself-reported0.956