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

Model saving bug #464

Closed
1 of 2 tasks
WenjieDu opened this issue Jul 18, 2024 · 3 comments · Fixed by #470
Closed
1 of 2 tasks

Model saving bug #464

WenjieDu opened this issue Jul 18, 2024 · 3 comments · Fixed by #470
Labels
bug Something isn't working

Comments

@WenjieDu
Copy link
Owner

1. System Info

PyPOTS v0.6

2. Information

  • The official example scripts
  • My own created scripts

3. Reproduction

When model_saving_strategy is set as better, PyPOTS doesn't save models when loss gets decreased.

4. Expected behavior

Models should be properly saved

@vemuribv
Copy link
Contributor

Hi @WenjieDu! I think this may have had an unintended effect--now (in v0.7 and later) even when model_saving_strategy is set as "best", PyPOTS saves the model every time the loss is decreased. In v0.6, setting to "best" had the intended behavior (saving only the best model at the very end after training is finished).

@WenjieDu
Copy link
Owner Author

Bug confirmed. Thank you, @vemuribv! I should have taken model_saving_strategy into consideration within confirm_saving when saving, but I forgot to do so when global replacing.

I'm reopening this issue and going to submit a PR to fix this. Could you please help review it?

@WenjieDu
Copy link
Owner Author

@vemuribv PR submitted. You are also very welcome to propose a better way to optimize the current saving strategy ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants