-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.py
More file actions
36 lines (26 loc) · 1.03 KB
/
config.py
File metadata and controls
36 lines (26 loc) · 1.03 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
import os
class Config:
def __init__(self):
self.image_dir = './data/image'
self.data_dir = './data/annotation'
self.weight_dir = './weight'
self.scored_crops_data = os.path.join(self.data_dir, 'scored_crops')
self.best_crop_data = os.path.join(self.data_dir, 'best_crop')
self.unlabeled_data = os.path.join(self.data_dir, 'unlabeled')
self.gpu_id = 0
self.num_workers = 4
self.perturbation_type_list = ['shift', 'zoom-out', 'crop', 'rotate']
self.augmentation_type_list = ['shift', 'zoom-out', 'rotate']
self.pairwise_margin = 0.3
self.learning_rate = 2e-5
self.weight_decay = 5e-4
self.max_epoch = 100
self.scored_crops_batch_size = 1
self.scored_crops_N = 11
self.test_crops_N = 12
self.best_crop_K = 8
self.unlabeled_P = 8
self.test_score_gap = 0.5
self.image_size = (224, 224)
self.mean = [0.485, 0.456, 0.406]
self.std = [0.229, 0.224, 0.225]