Code for image-classification Competition by AiStage To read the detailed report, please, refer to team report
- pytorch 1.6.0
- torchvision 0.7.0
- pandas 1.1.5
- opencv-python 4.5.1.48
- scikit-learn 0.24.1
- matplotlib 3.2.1
The following specs were to create original solution.
- GPU : Tesla V100 (32GB) (1GPU for 1Server)
- CPU : 8 X vCPU
- RAM : 90G
$ wget -d https://aistages-prod-server-public.s3.amazonaws.com/app/Competitions/000074/data/train.tar.gz
$ tar -zxvf train.tar.gz
$ python crop.py
$ python eval_crop.py
To train models, run follwing commands. You can choose multi-tasking model or multi-class model to train.
$ python train_by_CLASS.py SM_CHANNEL_TRAIN=[train image dir] SM_MODEL_DIR=[model saving dir]
$ python train_multitask.py SM_CHANNEL_TRAIN=[train image dir] SM_MODEL_DIR=[model saving dir]
You can add arguments (label, optimizer, criterion, resize, epochs, and more) for more detailed train.
You can download pretrained model that used for my trian from Link
You can watch how your model learning visually by using grad_cam.ipynb
If trained weights are prepared, you can create submission files that contains label of images.
$ python inference.py