Skip to content

Commit

Permalink
fix path error
Browse files Browse the repository at this point in the history
  • Loading branch information
HessTaha committed May 31, 2020
1 parent d8f6ab1 commit 261e992
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,8 @@ def main(path_to_data: str,

## Get/Save param dict
logger.info('Saving model in cache dir {}'.format(cache_dir))
torch.save(Model.state_dict(), cache_dir+'state_dict.pt')
with open('config_model.json', 'w') as file:
torch.save(Model.state_dict(), os.path.join(cache_dir,'state_dict.pt'))
with open(os.path.join(cache_dir,'config_model.json'), 'w') as file:
json.dump(config_dict, file)


Expand Down

0 comments on commit 261e992

Please sign in to comment.