--- license: apache-2.0 base_model: google/vit-base-patch16-224 tags: - image-classification - generated_from_trainer metrics: - accuracy - precision - recall - f1 model-index: - name: vit-lr-cosine-restarts results: [] --- # vit-lr-cosine-restarts This model is a fine-tuned version of [google/vit-base-patch16-224](https://huggingface.co/google/vit-base-patch16-224) on the skin-cancer dataset. It achieves the following results on the evaluation set: - Loss: 0.5117 - Accuracy: 0.8221 - Precision: 0.8347 - Recall: 0.8221 - F1: 0.8100 ## 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: 16 - eval_batch_size: 8 - seed: 42 - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08 - lr_scheduler_type: cosine_with_restarts - lr_scheduler_warmup_steps: 770 - num_epochs: 12 - mixed_precision_training: Native AMP ### Training results | Training Loss | Epoch | Step | Validation Loss | Accuracy | Precision | Recall | F1 | |:-------------:|:-----:|:----:|:---------------:|:--------:|:---------:|:------:|:------:| | 0.5999 | 1.0 | 321 | 0.5250 | 0.8141 | 0.8100 | 0.8141 | 0.8011 | | 0.4483 | 2.0 | 642 | 0.5117 | 0.8221 | 0.8347 | 0.8221 | 0.8100 | | 0.3425 | 3.0 | 963 | 0.5709 | 0.8270 | 0.8208 | 0.8270 | 0.8107 | | 0.176 | 4.0 | 1284 | 0.5579 | 0.8575 | 0.8549 | 0.8575 | 0.8544 | | 0.0183 | 5.0 | 1605 | 0.5555 | 0.8773 | 0.8762 | 0.8773 | 0.8759 | | 0.0273 | 6.0 | 1926 | 0.8166 | 0.8415 | 0.8369 | 0.8415 | 0.8328 | | 0.1186 | 7.0 | 2247 | 0.6380 | 0.8617 | 0.8598 | 0.8617 | 0.8591 | | 0.0166 | 8.0 | 2568 | 0.6608 | 0.8731 | 0.8716 | 0.8731 | 0.8709 | | 0.0003 | 9.0 | 2889 | 1.0045 | 0.8460 | 0.8438 | 0.8460 | 0.8306 | | 0.1258 | 10.0 | 3210 | 0.6712 | 0.8499 | 0.8527 | 0.8499 | 0.8490 | | 0.0137 | 11.0 | 3531 | 0.7952 | 0.8738 | 0.8765 | 0.8738 | 0.8740 | | 0.0004 | 12.0 | 3852 | 0.7956 | 0.8731 | 0.8708 | 0.8731 | 0.8699 | ### Framework versions - Transformers 4.39.0.dev0 - Pytorch 2.2.1+cu121 - Datasets 2.18.0 - Tokenizers 0.15.2