MCPcopy Create free account
hub / github.com/dangf15/THLNet / __init__

Method __init__

utils.py:13–27  ·  view source on GitHub ↗
(self, start_epoch=None, start_iter=None, train_loss=None, eval_loss=None, best_val_loss=float("inf"),
                 prev_val_loss=float("inf"), state_dict=None, optimizer=None, num_no_improv=0, half_lr=False)

Source from the content-addressed store, hash-verified

11
12class Checkpoint(object):
13 def __init__(self, start_epoch=None, start_iter=None, train_loss=None, eval_loss=None, best_val_loss=float("inf"),
14 prev_val_loss=float("inf"), state_dict=None, optimizer=None, num_no_improv=0, half_lr=False):
15 self.start_epoch = start_epoch
16 self.start_iter = start_iter
17 self.train_loss = train_loss
18 self.eval_loss = eval_loss
19
20 self.best_val_loss = best_val_loss
21 self.prev_val_loss = prev_val_loss
22
23 self.state_dict = state_dict
24 self.optimizer = optimizer
25
26 self.num_no_improv = num_no_improv
27 self.half_lr = half_lr
28
29
30 def save(self, is_best, filename, best_model):

Callers 2

__init__Method · 0.45
__init__Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected