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

Function save_checkPoint

Dropout_AutoEncoder/utils.py:49–55  ·  view source on GitHub ↗
(model,optimizer,filename)

Source from the content-addressed store, hash-verified

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

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected