Skip to content
This repository was archived by the owner on Jan 8, 2021. It is now read-only.

Commit bd2d902

Browse files
committed
Model Name Changed
1 parent 4c69d3a commit bd2d902

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Train.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ def train(EPOCH, dataloader, optimizer, loss_function, network, model_name, nega
2424
print('Epoch: ', epoch + 1, '| Step: ', step + 1, '| Train loss: %.4f' % loss.cpu().data.numpy())
2525
if step % SAVE_STEP == 1:
2626
print('Saving models...')
27-
torch.save(network, "{}-{}-step{}.pkl".format(model_name, epoch, step))
27+
torch.save(network, model_name)
2828
print('Saving models...')
29-
torch.save(network, "{}-{}.pkl".format(model_name, epoch))
29+
torch.save(network, model_name)
3030
print('Saving logs...')
3131
f.write("{} {}\n".format(epoch, loss.cpu().data.numpy()))
3232

0 commit comments

Comments
 (0)