Hyperparameter setting for training from scratch on CIFAR-10
Hi,
I am trying to train a convext on CIFAR-10 for a research project that doesn't allow using BN. I use the following configuration:
python -m torch.distributed.launch --nproc_per_node=4 main.py \
--data_set image_folder --data_path ./CIFAR-10-images/train --eval_data_path ./CIFAR-10-images/test \
--nb_classes 10 --num_workers 8 --warmup_epochs 0 \
--save_ckpt false \
--cutmix 0 --mixup 0 \
--model_ema_eval true \
--model convnext_tiny \
--epochs 100 --lr 4e-4 --weight_decay 5e-2 --opt 'sgd' --input_size 32\
--output_dir results/100epochs_lr_4e-4_wd_5e-2_sgd_inputsize_32 \And the accuracy is only 75% percent (standard ResNet18 is about 93%). If I change the optimizer from AdamW to SGD, the best accuracy actually drops to below 50%. If I use the default input size 224, the accuracy is 84%, still significantly low.
Can ConvNeXt work on CIFAR10 without fine-tuning from a pretrained model? Could you provide a recommended set of hyper parameters for CIFAR10 (that should be robust to different types of optimizers and without mix-up and cutmix)?
Also I have another question on fine-tuning on CIFAR10: it seems that in the colab file the input_size is the default 224. However CIFAR10 image is 32*32. Does this mean that in the data preparation stage the image will be padded to 224 * 224?
Thank you!
Source: facebookresearch/ConvNeXt