-
Notifications
You must be signed in to change notification settings - Fork 240
/
Copy pathresnet_adv.yaml
101 lines (101 loc) · 2 KB
/
resnet_adv.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
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
taskname: '+ ResNet-50 [adv]'
common:
run_label: "train"
log_freq: 500
auto_resume: true
mixed_precision: true
tensorboard_logging: false
channels_last: true
save_all_checkpoints: true
dataset:
root_train: "/mnt/imagenet/training"
root_val: "/mnt/imagenet/validation"
name: "imagenet"
category: "classification"
train_batch_size0: 256 # effective batch size is 1024 (256 * 4 GPUs)
val_batch_size0: 100
eval_batch_size0: 100
workers: 8
persistent_workers: true
pin_memory: true
image_augmentation:
random_resized_crop:
enable: true
interpolation: "bicubic"
random_horizontal_flip:
enable: true
rand_augment:
enable: true
mixup:
enable: true
alpha: 0.2
random_erase:
enable: true
p: 0.25
cutmix:
enable: true
alpha: 1.0
resize:
enable: true
size: 256 # shorter size is 256
interpolation: "bicubic"
center_crop:
enable: true
size: 224
sampler:
name: "variable_batch_sampler"
vbs:
crop_size_width: 224
crop_size_height: 224
max_n_scales: 5
min_crop_size_width: 128
max_crop_size_width: 320
min_crop_size_height: 128
max_crop_size_height: 320
check_scale: 32
loss:
category: "classification"
classification:
name: "cross_entropy"
cross_entropy:
label_smoothing: 0.1
optim:
name: "sgd"
weight_decay: 4.e-5
no_decay_bn_filter_bias: true
sgd:
momentum: 0.9
scheduler:
name: "cosine"
is_iteration_based: false
max_epochs: 600
warmup_iterations: 7500
warmup_init_lr: 0.05
cosine:
max_lr: 0.4
min_lr: 2.e-4
model:
classification:
name: "resnet"
activation:
name: "relu"
resnet:
depth: 50
normalization:
name: "batch_norm"
momentum: 0.1
activation:
name: "relu"
inplace: true
layer:
global_pool: "mean"
conv_init: "kaiming_normal"
linear_init: "normal"
ema:
enable: true
momentum: 0.0005
stats:
val: [ "loss", "top1", "top5" ]
train: ["loss"]
checkpoint_metric: "top1"
checkpoint_metric_max: true