개정판 755b0a9d
issue #1366: fix save name
Change-Id: I39f9497e9fdc83e9dafe33b27f125f47966f641b
DTI_PID/WebServer/symbol_training/train.py | ||
---|---|---|
198 | 198 |
best_epoch = epoch |
199 | 199 |
print("SAVE MODEL") |
200 | 200 |
# for debug for each loss |
201 |
torch.save(model.state_dict(), os.path.join(opt.saved_path, name + "_only_params_" + "{:.5f}".format(best_loss) + "_" + str(best_loss) + ".pth"))
|
|
201 |
torch.save(model.state_dict(), os.path.join(opt.saved_path, name + "_only_params_" + str(save_count) + "_" + "{:.5f}".format(best_loss) + ".pth"))
|
|
202 | 202 |
torch.save(model, os.path.join(opt.saved_path, name + "_whole_model_" + str(save_count) + "_" + "{:.5f}".format(best_loss) + ".pth")) |
203 | 203 |
# save |
204 | 204 |
torch.save(model.state_dict(), os.path.join(opt.saved_path, name + "_only_params.pth")) |
내보내기 Unified diff