Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

save the model/training source code to model checkpoint or logs directory #2409

Closed
ares89 opened this issue Jun 29, 2020 · 4 comments
Closed
Labels
feature Is an improvement or enhancement help wanted Open to be worked on won't fix This will not be worked on

Comments

@ares89
Copy link

ares89 commented Jun 29, 2020

🚀 Feature

Save the model/training source code to model checkpoint or logs directory

Motivation

Now, the hparams has been saved in yaml file. Sometimes, we not only change the hparams but also the network arch, the pre-process flow, so if we save the relate source code to model, we will get all the information to restore the model, because the source code is with the model hparams and all other things.

Pitch

add Trainer args parse params, or Checkpoint callback params, one for wether to save source code, and one for which codes to save

@ares89 ares89 added feature Is an improvement or enhancement help wanted Open to be worked on labels Jun 29, 2020
@github-actions
Copy link
Contributor

Hi! thanks for your contribution!, great first issue!

@dscarmo
Copy link
Contributor

dscarmo commented Jun 29, 2020

I achieve this through saving the commit hash (assuming your code is in a git repo).
Some loggers will catch this automatically, or you can have a function to add this to your parameters automatically.

Would be nice as a feature anyway.

@versatran01
Copy link

I think sacred can do this.

@stale
Copy link

stale bot commented Aug 31, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the won't fix This will not be worked on label Aug 31, 2020
@stale stale bot closed this as completed Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Is an improvement or enhancement help wanted Open to be worked on won't fix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants