run.sh 10.0 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
#      >log_SE_ResNeXt50_32x4d.txt 2>&1 &
16 17

#SE_154
R
ruri 已提交
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
#python train.py \
#            --model=SE_154_vd \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
#            --use_mixup=True \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1 \
33 34

#ResNeXt101_64x4d
R
ruri 已提交
35 36 37 38 39 40 41 42 43 44 45 46
#python train.py \
#	--model=ResNeXt101_64x4d \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=piecewise_decay \
#            --lr=0.1 \
#            --num_epochs=120 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=15e-5
47

R
ruri 已提交
48
#python train.py \
49
#ResNeXt101_vd_64x4d
R
ruri 已提交
50 51 52 53 54 55 56 57 58 59 60 61 62 63
#	--model=ResNeXt101_vd_64x4d \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
#            --use_mixup=True \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1
64 65

#InceptionV4
R
ruri 已提交
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81
#python train.py
#	    --model=InceptionV4 \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,299,299 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.045 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
#            --use_mixup=True \
#            --resize_short_size=320 \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1 \
82
#ResNet152_vd
R
ruri 已提交
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
#python train.py
#            --model=ResNet152_vd \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
#            --use_mixup=True \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1
98 99

#ResNet200_vd
R
ruri 已提交
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114
#python train.py
#            --model=ResNet200_vd \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
#            --use_mixup=True \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1
115 116

#ResNet50_vd
R
ruri 已提交
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131
#python train.py
#            --model=ResNet50_vd \
#            --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=7e-5 \
#            --use_mixup=True \
#            --use_label_smoothing=True \
#            --label_smoothing_epsilon=0.1
132
#ResNet50_vc
R
ruri 已提交
133 134 135 136 137 138 139 140 141 142 143 144
#python train.py
#  	    --model=ResNet50_vc \
#	    --batch_size=256 \
#            --total_images=1281167 \
#            --image_shape=3,224,224 \
#            --class_dim=1000 \
#            --lr_strategy=cosine_decay \
#            --lr=0.1 \
#            --num_epochs=200 \
#            --with_mem_opt=True \
#            --model_save_dir=output/ \
#            --l2_decay=1e-4 \
145

R
ruri 已提交
146 147 148 149 150 151 152 153
#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 已提交
154
#       --with_mem_opt=True \
R
ruri 已提交
155 156
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
157 158
#       --lr=0.01 \
#       --l2_decay=1e-4
R
ruri 已提交
159 160 161 162 163 164 165 166 167

#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 已提交
168
#       --with_mem_opt=True \
R
ruri 已提交
169 170
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
171 172
#       --lr=0.1 \
#       --l2_decay=3e-5
R
ruri 已提交
173

R
root 已提交
174 175 176 177 178 179 180 181 182
#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 \
183 184 185
#	--num_epochs=240 \
#	--lr=0.1 \
#       --l2_decay=4e-5
186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 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 234 235 236 237
#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 已提交
238 239 240 241 242 243 244 245
#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 已提交
246
#       --with_mem_opt=True \
R
ruri 已提交
247 248
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
249 250
#       --lr=0.1 \
#       --l2_decay=1e-4
R
ruri 已提交
251 252 253 254 255 256 257 258 259

#ResNet101:
#python train.py \
#       --model=ResNet101 \
#       --batch_size=256 \
#       --total_images=1281167 \
#       --class_dim=1000 \
#       --image_shape=3,224,224 \
#       --model_save_dir=output/ \
260
#       --with_mem_opt=True \
R
ruri 已提交
261 262
#       --lr_strategy=piecewise_decay \
#	--num_epochs=120 \
263 264
#       --lr=0.1 \
#       --l2_decay=1e-4
R
ruri 已提交
265

S
shippingwang 已提交
266 267 268 269 270
#ResNet152:
#python train.py \
#       --model=ResNet152 \
#       --batch_size=256 \
#       --total_images=1281167 \
271
#       --class_dim=1000 \
S
shippingwang 已提交
272
#       --image_shape=3,224,224 \
273
#       --model_save_dir=output/ \
S
shippingwang 已提交
274
#       --lr_strategy=piecewise_decay \
275
#       --with_mem_opt=True \
S
shippingwang 已提交
276 277
#       --lr=0.1 \
#       --num_epochs=120 \
278
#       --l2_decay=1e-4
S
shippingwang 已提交
279 280


281
#SE_ResNeXt50_32x4d:
S
shippingwang 已提交
282
#python train.py \
283
#       --model=SE_ResNeXt50_32x4d \
S
shippingwang 已提交
284 285
#       --batch_size=400 \
#       --total_images=1281167 \
286
#	--class_dim=1000 \
S
shippingwang 已提交
287 288
#       --image_shape=3,224,224 \
#       --lr_strategy=cosine_decay \
289
#       --model_save_dir=output/ \
S
shippingwang 已提交
290 291
#       --lr=0.1 \
#       --num_epochs=200 \
292 293
#       --with_mem_opt=True \
#       --l2_decay=1.2e-4
S
shippingwang 已提交
294

295
#SE_ResNeXt101_32x4d:
S
shippingwang 已提交
296
#python train.py \
297
#        --model=SE_ResNeXt101_32x4d \
S
shippingwang 已提交
298 299
#        --batch_size=400 \
#        --total_images=1281167 \
300
#        --class_dim=1000 \
S
shippingwang 已提交
301 302
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
303
#        --model_save_dir=output/ \
S
shippingwang 已提交
304 305
#        --lr=0.1 \
#        --num_epochs=200 \
306 307
#        --with_mem_opt=True \
#        --l2_decay=1.5e-5
S
shippingwang 已提交
308 309 310 311 312 313 314 315

#VGG11:
#python train.py \
#        --model=VGG11 \
#        --batch_size=512 \
#        --total_images=1281167 \
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
316 317
#        --class_dim=1000 \
#        --model_save_dir=output/ \
S
shippingwang 已提交
318 319
#        --lr=0.1 \
#        --num_epochs=90 \
320
#        --with_mem_opt=True \
321
#        --l2_decay=2e-4
S
shippingwang 已提交
322 323 324 325 326 327

#VGG13:
#python train.py
#        --model=VGG13 \          
#        --batch_size=256 \
#        --total_images=1281167 \
328
#        --class_dim=1000 \
S
shippingwang 已提交
329 330 331 332
#        --image_shape=3,224,224 \
#        --lr_strategy=cosine_decay \
#        --lr=0.01 \
#        --num_epochs=90 \
333 334
#        --model_save_dir=output/ \
#        --with_mem_opt=True \
335
#        --l2_decay=3e-4
336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363

#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 已提交
364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384

#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