Instructions to use bombshelll/swin-brain-modality-classification with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use bombshelll/swin-brain-modality-classification with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="bombshelll/swin-brain-modality-classification") pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")# Load model directly from transformers import AutoImageProcessor, AutoModelForImageClassification processor = AutoImageProcessor.from_pretrained("bombshelll/swin-brain-modality-classification") model = AutoModelForImageClassification.from_pretrained("bombshelll/swin-brain-modality-classification", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| { | |
| "best_metric": 0.6410256410256411, | |
| "best_model_checkpoint": "/kaggle/working/swin-brain-modality-classification/checkpoint-35", | |
| "epoch": 2.873239436619718, | |
| "eval_steps": 500, | |
| "global_step": 51, | |
| "is_hyper_param_search": false, | |
| "is_local_process_zero": true, | |
| "is_world_process_zero": true, | |
| "log_history": [ | |
| { | |
| "epoch": 0.9577464788732394, | |
| "grad_norm": 4.190108776092529, | |
| "learning_rate": 3.777777777777778e-05, | |
| "loss": 0.6378, | |
| "step": 17 | |
| }, | |
| { | |
| "epoch": 0.9577464788732394, | |
| "eval_accuracy": 0.6239316239316239, | |
| "eval_loss": 3.3409788608551025, | |
| "eval_runtime": 3.7527, | |
| "eval_samples_per_second": 124.711, | |
| "eval_steps_per_second": 3.997, | |
| "step": 17 | |
| }, | |
| { | |
| "epoch": 1.971830985915493, | |
| "grad_norm": 3.4180703163146973, | |
| "learning_rate": 1.777777777777778e-05, | |
| "loss": 0.0669, | |
| "step": 35 | |
| }, | |
| { | |
| "epoch": 1.971830985915493, | |
| "eval_accuracy": 0.6410256410256411, | |
| "eval_loss": 4.32125186920166, | |
| "eval_runtime": 3.6088, | |
| "eval_samples_per_second": 129.681, | |
| "eval_steps_per_second": 4.156, | |
| "step": 35 | |
| }, | |
| { | |
| "epoch": 2.873239436619718, | |
| "grad_norm": 4.94912052154541, | |
| "learning_rate": 0.0, | |
| "loss": 0.0425, | |
| "step": 51 | |
| }, | |
| { | |
| "epoch": 2.873239436619718, | |
| "eval_accuracy": 0.6410256410256411, | |
| "eval_loss": 4.431879997253418, | |
| "eval_runtime": 3.8435, | |
| "eval_samples_per_second": 121.765, | |
| "eval_steps_per_second": 3.903, | |
| "step": 51 | |
| }, | |
| { | |
| "epoch": 2.873239436619718, | |
| "step": 51, | |
| "total_flos": 1.608272360368128e+17, | |
| "train_loss": 0.2495375123678469, | |
| "train_runtime": 94.7041, | |
| "train_samples_per_second": 71.053, | |
| "train_steps_per_second": 0.539 | |
| } | |
| ], | |
| "logging_steps": 1, | |
| "max_steps": 51, | |
| "num_input_tokens_seen": 0, | |
| "num_train_epochs": 3, | |
| "save_steps": 500, | |
| "stateful_callbacks": { | |
| "TrainerControl": { | |
| "args": { | |
| "should_epoch_stop": false, | |
| "should_evaluate": false, | |
| "should_log": false, | |
| "should_save": true, | |
| "should_training_stop": true | |
| }, | |
| "attributes": {} | |
| } | |
| }, | |
| "total_flos": 1.608272360368128e+17, | |
| "train_batch_size": 32, | |
| "trial_name": null, | |
| "trial_params": null | |
| } | |