run.sh 6.1 KB
Newer Older
R
ruri 已提交
1
#Hyperparameters config
2
#Example: SE_ResNext50_32x4d
R
ruri 已提交
3 4
python train.py \
       --model=SE_ResNeXt50_32x4d \
5
       --batch_size=400 \
R
ruri 已提交
6 7 8 9
       --total_images=1281167 \
       --class_dim=1000 \
       --image_shape=3,224,224 \
       --model_save_dir=output/ \
R
root 已提交
10
       --with_mem_opt=True \
11 12 13 14
       --lr_strategy=cosine_decay \
       --lr=0.1 \
       --num_epochs=200 \
       --l2_decay=1.2e-4 \
R
ruri 已提交
15 16 17 18 19 20 21 22 23
#      >log_SE_ResNeXt50_32x4d.txt 2>&1 &
#AlexNet:
#python train.py \
#       --model=AlexNet \
#       --batch_size=256 \
#       --total_images=1281167 \
#       --class_dim=1000 \
#       --image_shape=3,224,224 \
#       --model_save_dir=output/ \
R
root 已提交
24
#       --with_mem_opt=True \
R
ruri 已提交
25 26
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
27 28
#       --lr=0.01 \
#       --l2_decay=1e-4
R
ruri 已提交
29 30 31 32 33 34 35 36 37

#MobileNet v1:
#python train.py \
#       --model=MobileNet \
#       --batch_size=256 \
#       --total_images=1281167 \
#       --class_dim=1000 \
#       --image_shape=3,224,224 \
#       --model_save_dir=output/ \
R
root 已提交
38
#       --with_mem_opt=True \
R
ruri 已提交
39 40
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
41 42
#       --lr=0.1 \
#       --l2_decay=3e-5
R
ruri 已提交
43

R
root 已提交
44 45 46 47 48 49 50 51 52
#python train.py \
#	--model=MobileNetV2 \
#	--batch_size=500 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--model_save_dir=output/ \
#	--with_mem_opt=True \
#	--lr_strategy=cosine_decay \
53 54 55
#	--num_epochs=240 \
#	--lr=0.1 \
#       --l2_decay=4e-5
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107
#ResNet18:
#python train.py \
#	--model=ResNet18 \
#	--batch_size=256 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--model_save_dir=output/ \
#	--with_mem_opt=True \
#	--lr_strategy=cosine_decay \
#	--lr=0.1 \
#	--num_epochs=120 \
#	--l2_decay=1e-4
#ResNet34:
#python train.py \
#	--model=ResNet34 \
#	--batch_size=256 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--model_save_dir=output/ \
#	--with_mem_opt=True \
#	--lr_strategy=cosine_decay \
#	--lr=0.1 \
#	--num_epochs=120 \
#	--l2_decay=1e-4
#ShuffleNetv2:
#python train.py \
#	--model=ShuffleNetV2 \
#	--batch_size=1024 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--model_save_dir=output/ \
#	--with_mem_opt=True \
#	--lr_strategy=cosine_decay_with_warmup \
#	--lr=0.5 \
#	--num_epochs=240 \
#	--l2_decay=4e-5 
#GoogleNet:
#python train.py \
#	--model=GoogleNet \
#	--batch_size=256 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--model_save_dir=output/ \
#	--with_mem_opt=True \
#	--lr_strategy=cosine_decay \
#	--lr=0.01 \
#	--num_epochs=200 \
#	--l2_decay=1e-4
R
ruri 已提交
108 109 110 111 112 113 114 115
#ResNet50:
#python train.py \
#       --model=ResNet50 \
#       --batch_size=256 \
#       --total_images=1281167 \
#       --class_dim=1000 \
#       --image_shape=3,224,224 \
#       --model_save_dir=output/ \
R
root 已提交
116
#       --with_mem_opt=True \
R
ruri 已提交
117 118
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
119 120
#       --lr=0.1 \
#       --l2_decay=1e-4
R
ruri 已提交
121 122 123 124 125 126 127 128 129

#ResNet101:
#python train.py \
#       --model=ResNet101 \
#       --batch_size=256 \
#       --total_images=1281167 \
#       --class_dim=1000 \
#       --image_shape=3,224,224 \
#       --model_save_dir=output/ \
130
#       --with_mem_opt=True \
R
ruri 已提交
131 132
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
133 134
#       --lr=0.1 \
#       --l2_decay=1e-4
R
ruri 已提交
135

S
shippingwang 已提交
136 137 138 139 140
#ResNet152:
#python train.py \
#       --model=ResNet152 \
#       --batch_size=256 \
#       --total_images=1281167 \
141
#       --class_dim=1000 \
S
shippingwang 已提交
142
#       --image_shape=3,224,224 \
143
#       --model_save_dir=output/ \
S
shippingwang 已提交
144
#       --lr_strategy=piecewise_decay \
145
#       --with_mem_opt=True \
S
shippingwang 已提交
146 147
#       --lr=0.1 \
#       --num_epochs=120 \
148
#       --l2_decay=1e-4
S
shippingwang 已提交
149 150


151
#SE_ResNeXt50_32x4d:
S
shippingwang 已提交
152
#python train.py \
153
#       --model=SE_ResNeXt50_32x4d \
S
shippingwang 已提交
154 155
#       --batch_size=400 \
#       --total_images=1281167 \
156
#	--class_dim=1000 \
S
shippingwang 已提交
157 158
#       --image_shape=3,224,224 \
#       --lr_strategy=cosine_decay \
159
#       --model_save_dir=output/ \
S
shippingwang 已提交
160 161
#       --lr=0.1 \
#       --num_epochs=200 \
162 163
#       --with_mem_opt=True \
#       --l2_decay=1.2e-4
S
shippingwang 已提交
164

165
#SE_ResNeXt101_32x4d:
S
shippingwang 已提交
166
#python train.py \
167
#        --model=SE_ResNeXt101_32x4d \
S
shippingwang 已提交
168 169
#        --batch_size=400 \
#        --total_images=1281167 \
170
#        --class_dim=1000 \
S
shippingwang 已提交
171 172
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
173
#        --model_save_dir=output/ \
S
shippingwang 已提交
174 175
#        --lr=0.1 \
#        --num_epochs=200 \
176 177
#        --with_mem_opt=True \
#        --l2_decay=1.5e-5
S
shippingwang 已提交
178 179 180 181 182 183 184 185

#VGG11:
#python train.py \
#        --model=VGG11 \
#        --batch_size=512 \
#        --total_images=1281167 \
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
186 187
#        --class_dim=1000 \
#        --model_save_dir=output/ \
S
shippingwang 已提交
188 189
#        --lr=0.1 \
#        --num_epochs=90 \
190
#        --with_mem_opt=True \
191
#        --l2_decay=2e-4
S
shippingwang 已提交
192 193 194 195 196 197

#VGG13:
#python train.py
#        --model=VGG13 \          
#        --batch_size=256 \
#        --total_images=1281167 \
198
#        --class_dim=1000 \
S
shippingwang 已提交
199 200 201 202
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
#        --lr=0.01 \
#        --num_epochs=90 \
203 204
#        --model_save_dir=output/ \
#        --with_mem_opt=True \
205
#        --l2_decay=3e-4
206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233

#VGG16:
#python train.py
#	--model=VGG16 \
#	--batch_size=256 \
#	--total_images=1281167 \
#       --class_dim=1000 \
#	--lr_strategy=cosine_decay \
#	--image_shape=3,224,224 \
#       --model_save_dir=output/ \
#	--lr=0.01 \
#	--num_epochs=90 \
#       --with_mem_opt=True \
#	--l2_decay=3e-4

#VGG19:
#python train.py
#	--model=VGG19 \
#	--batch_size=256 \
#	--total_images=1281167 \
#	--class_dim=1000 \
#	--image_shape=3,224,224 \
#	--lr_strategy=cosine_decay \
#	--lr=0.01 \
#	--num_epochs=90 \
#       --with_mem_opt=True \
#       --model_save_dir=output/ \
#	--l2_decay=3e-4
T
tensor-tang 已提交
234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254

#ResNet50 nGraph:
# Training:
#OMP_NUM_THREADS=`nproc` FLAGS_use_ngraph=true python train.py \
#    --model=ResNet50 \
#    --batch_size=128 \
#    --total_images=1281167 \
#    --class_dim=1000 \
#    --image_shape=3,224,224 \
#    --lr=0.001 \
#    --num_epochs=120 \
#    --with_mem_opt=False \
#    --model_save_dir=output/ \
#    --lr_strategy=adam \
#    --use_gpu=False
# Inference:
#OMP_NUM_THREADS=`nproc` FLAGS_use_ngraph=true python infer.py  \
#    --use_gpu=false \
#    --model=ResNet50 \
#    --pretrained_model=ResNet50_pretrained