在保证模型在验证集上的F1达到0.99的情况下,降低CNN模型大小。
模型 | 大小 |
---|---|
CNN | 17.3 MB |
SmallerNet | 532 KB |
SmallestNet | 205 KB |
当前是将原始训练集分为训练集:验证集(9:1),在正式提交的时候可以直接使用全部原始数据集进行训练。
模型默认的参数浮点数是torch.float32,可以改为torch.float16,这样可以降低模型一半大小。
CUDA_VISIBLE_DEVICES=2,3 python CNN_fulltrain.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float32/CNN.pth /Users/cglin/Desktop/CNN/fulltrain/float32/CNN/
CUDA_VISIBLE_DEVICES=2,3 python small_CNN_fulltrain.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float32/SmallerNet.pth /Users/cglin/Desktop/CNN/fulltrain/float32/SmallerNet/
CUDA_VISIBLE_DEVICES=2,3 python smallest_CNN_fulltrain.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float32/SmallestNet.pth /Users/cglin/Desktop/CNN/fulltrain/float32/SmallestNet/
CUDA_VISIBLE_DEVICES=2,3 python CNN_fulltrain_float16.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float16/CNN_16.pth /Users/cglin/Desktop/CNN/fulltrain/float16/CNN/
CUDA_VISIBLE_DEVICES=2,3 python medium_CNN_fulltrain.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float32/medium_CNN.pth /Users/cglin/Desktop/CNN/fulltrain/float32/medium_CNN/
CUDA_VISIBLE_DEVICES=2,3 python medium_CNN_fulltrain_float16.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float16/medium_CNN_16.pth /Users/cglin/Desktop/CNN/fulltrain/float16/medium_CNN/
CUDA_VISIBLE_DEVICES=2,3 python multi_modal_CNN.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/float16/multimodal_CNN.pth /Users/cglin/Desktop/CNN_0715/fulltrain/float16/multimodal_CNN/
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/full_train/final/multimodal_CNN.pth /Users/cglin/Desktop/
CUDA_VISIBLE_DEVICES=2,3 python multi_modal_CNN_A.py --lr 0.01 --name CNN_0.01
scp -P 19000 ms1@120.92.17.23:/mnt/mxy/linchungang/image_diagnosis/
unzip fig2.zip
CUDA_VISIBLE_DEVICES=2,3 python multi_modal_CNN.py --lr 0.01 --name CNN_0.01