Skip to content

Commit 9c4161f

Browse files
committed
update lr
1 parent 343db6c commit 9c4161f

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

config.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def __init__(self, ):
1414
self.DEVICE = 'cuda' if torch.cuda.is_available() else 'cpu'
1515
self.BATCH_SIZE = self.get_batch_size()
1616
# print(f'Batch Size: {self.BATCH_SIZE}')
17-
self.ONE_CYCLE_MAX_LR = 0.0001
17+
self.ONE_CYCLE_MAX_LR = 0.01
1818
self.MODEL_PATH = Path('model')
1919
self.check_path(self.MODEL_PATH)
2020

@@ -30,6 +30,16 @@ def get_batch_size(self, ):
3030
else:
3131
BATCH_SIZE = 2
3232
return BATCH_SIZE
33+
34+
def print_config(self):
35+
print(f'SOURCE_DIR: {self.SOURCE_DIR}')
36+
print(f'TARGET_DIR: {self.TARGET_DIR}')
37+
print(f'BATCH_SIZE: {self.BATCH_SIZE}')
38+
print(f'NUM_EPOCHS: {self.NUM_EPOCHS}')
39+
print(f'N_FOLD: {self.N_FOLD}')
40+
print(f'CROP_RATIO: {self.CROP_RATIO}')
41+
print(f'DEVICE: {self.DEVICE}')
42+
print(f'ONE_CYCLE_MAX_LR: {self.ONE_CYCLE_MAX_LR}')
3343

3444
def check_path(self, path):
3545
path.mkdir(exist_ok=True)

train.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
from utils import *
2525

2626
config = Config()
27+
config.print_config()
2728
os.environ['WANDB_API_KEY'] = '67c99389e1ae37b747c40634c51802a4bf019d49'
2829

2930
def train_transform():

0 commit comments

Comments
 (0)