updates
This commit is contained in:
parent
3c4a9ff69e
commit
7ee28a7bb6
4
train.py
4
train.py
|
@ -53,6 +53,7 @@ hyp = {'giou': 1.582, # giou loss gain
|
|||
'scale': 0.1059, # image scale (+/- gain)
|
||||
'shear': 0.5768} # image shear (+/- deg)
|
||||
|
||||
|
||||
# # Hyperparameters (i-series)
|
||||
# hyp = {'giou': 1.43, # giou loss gain
|
||||
# 'xy': 4.688, # xy loss gain
|
||||
|
@ -103,9 +104,10 @@ def train(cfg,
|
|||
model = Darknet(cfg).to(device)
|
||||
|
||||
# Optimizer
|
||||
# optimizer = optim.Adam(model.parameters(), lr=hyp['lr0'], weight_decay=hyp['weight_decay'])
|
||||
# optimizer = AdaBound(model.parameters(), lr=hyp['lr0'], final_lr=0.1)
|
||||
optimizer = optim.SGD(model.parameters(), lr=hyp['lr0'], momentum=hyp['momentum'], weight_decay=hyp['weight_decay'],
|
||||
nesterov=True)
|
||||
# optimizer = AdaBound(model.parameters(), lr=hyp['lr0'], final_lr=0.1)
|
||||
|
||||
cutoff = -1 # backbone reaches to cutoff layer
|
||||
start_epoch = 0
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import torch
|
||||
import torch.nn as nn
|
||||
|
||||
|
||||
def init_seeds(seed=0):
|
||||
|
|
Loading…
Reference in New Issue