Instructions to use tanganke/convnext-base-224_gtsrb_sgd_batch-size-64_lr-0.01_steps-4000 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tanganke/convnext-base-224_gtsrb_sgd_batch-size-64_lr-0.01_steps-4000 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="tanganke/convnext-base-224_gtsrb_sgd_batch-size-64_lr-0.01_steps-4000") 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("tanganke/convnext-base-224_gtsrb_sgd_batch-size-64_lr-0.01_steps-4000") model = AutoModelForImageClassification.from_pretrained("tanganke/convnext-base-224_gtsrb_sgd_batch-size-64_lr-0.01_steps-4000") - Notebooks
- Google Colab
- Kaggle
| hydra: | |
| run: | |
| dir: ${path.log_dir} | |
| sweep: | |
| dir: ${oc.env:FUSION_BENCH_PROJECT_ROOT,"."}/outputs/multirun/${hydra.job.config_name}/${now:%Y-%m-%d_%H-%M-%S} | |
| subdir: ${hydra.job.num} | |
| launcher: | |
| _target_: hydra._internal.core_plugins.basic_launcher.BasicLauncher | |
| sweeper: | |
| _target_: hydra._internal.core_plugins.basic_sweeper.BasicSweeper | |
| max_batch_size: null | |
| params: null | |
| help: | |
| app_name: fusion_bench | |
| header: == ${hydra.help.app_name} == | |
| footer: 'Powered by Hydra (https://hydra.cc) | |
| Use --hydra-help to view Hydra specific help' | |
| template: '${hydra.help.header} | |
| fusion_bench is the command line interface for running model fusion benchmarks | |
| in the FusionBench project. | |
| It provides a flexible way to configure and execute various fusion algorithms | |
| on different model pools and evaluate them across multiple tasks. | |
| == Configuration groups == | |
| Compose your configuration from these groups (method, modelpool, taskpool are | |
| the most important): | |
| $APP_CONFIG_GROUPS | |
| == Config == | |
| You can override options, for example: | |
| fusion_bench method=task_arithmetic modelpool=clip-vit-base-patch32_svhn_and_mnist | |
| taskpool=clip-vit-base-patch32_svhn_and_mnist | |
| == Basic usage == | |
| fusion_bench [--config-path CONFIG_PATH] [--config-name CONFIG_NAME] OPTION_1=VALUE_1 | |
| OPTION_2=VALUE_2 ... | |
| == Key options == | |
| --help, -h : Print this help message and exit | |
| --hydra-help : Hydra''s help | |
| --cfg, -c : Show config instead of running [job|hydra|all] | |
| --config-path, -cp : Overrides the config_path | |
| --config-name, -cn : Overrides the config_name | |
| --shell-completion, -sc : Install or Uninstall shell completion | |
| For more detailed information on options and usage, please refer to the online | |
| documentation: | |
| https://tanganke.github.io/fusion_bench/cli/fusion_bench/ | |
| ${hydra.help.footer}' | |
| hydra_help: | |
| template: 'Hydra (${hydra.runtime.version}) | |
| See https://hydra.cc for more info. | |
| == Flags == | |
| $FLAGS_HELP | |
| == Configuration groups == | |
| Compose your configuration from those groups (For example, append hydra/job_logging=disabled | |
| to command line) | |
| $HYDRA_CONFIG_GROUPS | |
| Use ''--cfg hydra'' to Show the Hydra config. | |
| ' | |
| hydra_help: ??? | |
| hydra_logging: | |
| version: 1 | |
| formatters: | |
| simple: | |
| format: '[%(asctime)s][HYDRA] %(message)s' | |
| handlers: | |
| console: | |
| class: logging.StreamHandler | |
| formatter: simple | |
| stream: ext://sys.stdout | |
| root: | |
| level: INFO | |
| handlers: | |
| - console | |
| loggers: | |
| logging_example: | |
| level: DEBUG | |
| disable_existing_loggers: false | |
| job_logging: | |
| version: 1 | |
| formatters: | |
| simple: | |
| format: '[%(asctime)s][%(name)s][%(levelname)s] - %(message)s' | |
| rich_handler: | |
| format: '%(message)s' | |
| handlers: | |
| console: | |
| class: rich.logging.RichHandler | |
| formatter: rich_handler | |
| file: | |
| class: logging.FileHandler | |
| formatter: simple | |
| filename: ${hydra.runtime.output_dir}/${hydra.job.name}.log | |
| root: | |
| level: INFO | |
| handlers: | |
| - console | |
| - file | |
| disable_existing_loggers: false | |
| env: {} | |
| mode: RUN | |
| searchpath: [] | |
| callbacks: {} | |
| output_subdir: '' | |
| overrides: | |
| hydra: | |
| - hydra.mode=RUN | |
| task: | |
| - path.log_dir="outputs/convnext-base-224/gtsrb/batch_size=64,lr=0.01" | |
| - seed=0 | |
| - method=classification/image_classification_finetune | |
| - method.max_epochs=-1 | |
| - method.max_steps=4000 | |
| - method.save_top_k=-1 | |
| - method.save_interval=1000 | |
| - method.save_on_train_epoch_end=false | |
| - method.optimizer.lr=0.01 | |
| - method.lr_scheduler=null | |
| - method.dataloader_kwargs.batch_size=64 | |
| - modelpool=ConvNextForImageClassification/convnext-base-224 | |
| - modelpool.models._pretrained_.dataset_name=gtsrb | |
| - +dataset/image_classification/train@modelpool.train_datasets=gtsrb | |
| - +dataset/image_classification/test@modelpool.val_datasets=gtsrb | |
| job: | |
| name: cli | |
| chdir: null | |
| override_dirname: +dataset/image_classification/test@modelpool.val_datasets=gtsrb,+dataset/image_classification/train@modelpool.train_datasets=gtsrb,method.dataloader_kwargs.batch_size=64,method.lr_scheduler=null,method.max_epochs=-1,method.max_steps=4000,method.optimizer.lr=0.01,method.save_interval=1000,method.save_on_train_epoch_end=false,method.save_top_k=-1,method=classification/image_classification_finetune,modelpool.models._pretrained_.dataset_name=gtsrb,modelpool=ConvNextForImageClassification/convnext-base-224,path.log_dir="outputs/convnext-base-224/gtsrb/batch_size=64,lr=0.01",seed=0 | |
| id: ??? | |
| num: ??? | |
| config_name: model_fusion | |
| env_set: | |
| HYDRA_FULL_ERROR: ${oc.env:HYDRA_FULL_ERROR,1} | |
| env_copy: [] | |
| config: | |
| override_dirname: | |
| kv_sep: '=' | |
| item_sep: ',' | |
| exclude_keys: [] | |
| runtime: | |
| version: 1.3.2 | |
| version_base: '1.3' | |
| cwd: /data/users/anke/fusion_bench | |
| config_sources: | |
| - path: hydra.conf | |
| schema: pkg | |
| provider: hydra | |
| - path: /data/users/anke/fusion_bench/config | |
| schema: file | |
| provider: main | |
| - path: '' | |
| schema: structured | |
| provider: schema | |
| output_dir: /data/users/anke/fusion_bench/outputs/convnext-base-224/gtsrb/batch_size=64,lr=0.01 | |
| choices: | |
| dataset/image_classification/test@modelpool.val_datasets: gtsrb | |
| dataset/image_classification/train@modelpool.train_datasets: gtsrb | |
| taskpool: dummy | |
| method: classification/image_classification_finetune | |
| modelpool: ConvNextForImageClassification/convnext-base-224 | |
| path: default | |
| hydra: default | |
| hydra/env: default | |
| hydra/callbacks: null | |
| hydra/job_logging: rich_logging | |
| hydra/hydra_logging: default | |
| hydra/hydra_help: default | |
| hydra/help: fusion_bench_help | |
| hydra/sweeper: basic | |
| hydra/launcher: basic | |
| hydra/output: default | |
| verbose: false | |