MCPcopy Create free account
hub / github.com/KeepTryingTo/Pytorch-GAN / save_checkPoint

Function save_checkPoint

Adversarial_AutoEncoder/utils.py:50–56  ·  view source on GitHub ↗
(model,optimizer,filename)

Source from the content-addressed store, hash-verified

48
49
50def save_checkPoint(model,optimizer,filename):
51 print("=========================================================> save_model...")
52 checkpoint = {
53 "state_dict":model,
54 'optimizer':optimizer.state_dict()
55 }
56 torch.save(obj=checkpoint,f=filename)
57
58def load_checkPoint(model,filename,optimizer,lr):
59 print("========================================================> load_model...")

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected