forked from MR-HosseinzadehTaher/BenchmarkTransferLearning
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtests.txt
More file actions
276 lines (235 loc) · 8.4 KB
/
Copy pathtests.txt
File metadata and controls
276 lines (235 loc) · 8.4 KB
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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
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
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
################################################################################
# Fine-tuning benchmark to literature
################################################################################
0.1.1 ViT_base SimMIM ImageNet1k None NIH
python main_classification.py --data_set ChestXray14 \
--data_dir /Users/felixkrones/python_projects/data/NIH/images \
--model vit_base \
--mode train \
--resume True \
--init simmim \
--proxy_dir /Users/felixkrones/python_projects/models/GMML/Pretrain/simmim_pretrain__vit_base__img224__800ep.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device mps \
--epochs 1 \
--batch_size 64 \
--trial 1 \
--nc 3
################################################################################
# Fine-tuning benchmark
################################################################################
0.2.1 ViT_small GMML Self-supervised NIH (1000e)
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images \
--model vit_small \
--mode train \
--resume True \
--init gmml \
--proxy_dir /home/ubuntu/models/gmml_checkpoint_1000_NIH_Umar.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 30 \
--batch_size 64 \
--trial 6
0.2.2
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images \
--model vit_small \
--mode train \
--resume True \
--init gmml \
--proxy_dir /home/ubuntu/models/gmml_nih1000e_scratch_small_3d.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 20 \
--batch_size 64 \
--trial 6
################################################################################
# Fine-tuning experiments supervised
################################################################################
1.1 ResNet50 supervised Random
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images/ \
--model ResNet50 \
--mode train \
--resume True \
--init random \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 20 \
--batch_size 64 \
--trial 3 \
--lr 2e-4
1.2
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images \
--model ResNet50 \
--mode train \
--resume True \
--init imagenet \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 20 \
--batch_size 64 \
--trial 3 \
--lr 2e-4
2.1 vit_small supervised Random
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images/ \
--model vit_small \
--mode train \
--resume True \
--init random \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--batch_size 64 \
--epochs 20 \
--lr 1e-5 \
--trial 4
2.2 vit_small supervised Imagenet
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images/ \
--model vit_small \
--mode train \
--resume True \
--init imagenet \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--batch_size 64 \
--epochs 20 \
--lr 1e-5 \
--trial 4
################################################################################
# Fine-tuning experiments supervised
################################################################################
1.2 ResNet50 Supervised ImageNet1k COCO pre-training
python main_classification.py --data_set COCO \
--data_dir /Users/felixkrones/python_projects/data/COCO/unlabeled2017/ \
--model ResNet50 \
--mode train \
--resume True \
--init imagenet \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device mps \
--epochs 100 \
--batch_size 64
################################################################################
# Fine-tuning experiments resnet50 moco
################################################################################
3.2 ResNet50 MocoV3 Self-supervised ImageNet1k X-ray, chest (MIMIC)
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIHChest14/images/ \
--model ResNet50 \
--mode train \
--resume True \
--init moco_100e_mimic_imagenet \
--proxy_dir /home/ubuntu/models/moco/mimic/r50/moco-v3_r50_100e_mimic_after_imagenet_deit_prepped.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 21 \
--batch_size 64
################################################################################
# Fine-tuning experiments vit_small moco
################################################################################
12.1 ViT_small MocoV3 Self-supervised ImageNet1k
python main_classification.py --data_set ChestXray14 \
--data_dir /Users/felixkrones/python_projects/data/NIHChest14/images/ \
--model vit_small \
--mode train \
--resume True \
--init moco \
--proxy_dir /Users/felixkrones/python_projects/models/vit-s-300ep.pth.tar \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device mps \
--epochs 20 \
--batch_size 64
12.3 ViT_small MocoV3 Self-supervised ImageNet1k X-ray, chest (MIMIC)
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIHChest14/images/ \
--model vit_small \
--mode train \
--resume True \
--init moco \
--proxy_dir /home/ubuntu/models/moco/mimic/vit_small/moco-v3_vit_small_100e_mimic_after_imagenet.pth.tar \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 20 \
--batch_size 64
################################################################################
# Fine-tuning experiments vit_small sit
################################################################################
4.1 ViT_small SiT Self-supervised ImageNet1k
python main_classification.py --data_set ChestXray14 \
--data_dir /Users/felixkrones/python_projects/data/NIHChest14/images/ \
--model vit_small \
--mode train \
--resume True \
--init sit \
--proxy_dir /Users/felixkrones/python_projects/models/SiT_Small_ImageNet.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device mps \
--epochs 20 \
--batch_size 64
4.2 ViT_small SiT ImageNet1k X-ray, chest (MIMIC)
python main_classification.py --data_set ChestXray14 \
--data_dir /Users/felixkrones/python_projects/data/NIHChest14/images/ \
--model vit_small \
--mode train \
--resume True \
--init sit \
--proxy_dir /Users/felixkrones/python_projects/models/sit_vit_small_mimic_50e_after_imagenet.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device mps \
--epochs 20 \
--batch_size 64
################################################################################
# Covert moco
################################################################################
python convert_to_deit.py \
--input /home/ubuntu/models/moco/imagenet/vit_small/vit-s_300ep.pth.tar \
--output /home/ubuntu/models/moco/imagenet/vit_small/moco-v3_vits_300e_imagenet_deit.pth
################################################################################
# simmim benchmark
################################################################################
# ChestXray14: 78.87
python main_classification.py --data_set ChestXray14 \
--data_dir /home/ubuntu/data/NIH/images \
--model swin_base \
--mode train \
--resume True \
--init simmim \
--proxy_dir /home/ubuntu/models/simmim_swinb_Scratch_ChestXray14.pth \
--train_list dataset/Xray14_train_official.txt \
--val_list dataset/Xray14_val_official.txt \
--test_list dataset/Xray14_test_official.txt \
--device cuda \
--epochs 20 \
--batch_size 48 \
--trial 5 \
--lr 0.1 --opt sgd