Model saving
This commit is contained in:
parent
d95bf0d73d
commit
0751bcce7e
@ -109,3 +109,6 @@ for t in range(epochs):
|
|||||||
train(train_dataloader, model, loss_fn, optimizer)
|
train(train_dataloader, model, loss_fn, optimizer)
|
||||||
test(test_dataloader, model, loss_fn)
|
test(test_dataloader, model, loss_fn)
|
||||||
print("Done!")
|
print("Done!")
|
||||||
|
|
||||||
|
torch.save(model.state_dict(), './model_out')
|
||||||
|
print("Model saved in ./model_out file.")
|
||||||
|
Loading…
Reference in New Issue
Block a user