-
Notifications
You must be signed in to change notification settings - Fork 42
/
config.py
47 lines (33 loc) · 932 Bytes
/
config.py
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
# Third party imports
import torch
from torchvision import transforms
# Device configuration
DEVICE = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
# Data preprocessing details
data_transforms = {
'train': transforms.Compose([
transforms.Resize((256, 256)),
transforms.ToTensor(),
transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225])
]),
'val': transforms.Compose([
transforms.Resize((256, 256)),
transforms.ToTensor(),
transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225])
]),
}
texture_transform = transforms.Compose([
# transforms.Resize((300, 450)),
transforms.ToTensor(),
transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225])
])
dense_transform = transforms.Compose([
transforms.ToTensor()
])
# params info
PARAMS = {'batch_size': 1,
'shuffle': True,
'num_workers': 16}
# network parameters
# command line arguments
args = {}