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

Fix LSTM training continuity for cloned nets #951

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rizmyabdulla
Copy link

Fixes #949

Update src/recurrent.ts to ensure cloned LSTM nets continue training from the point where the original stopped.

  • Add fromJSON method to properly restore the training state.
  • Modify train method to account for the state of the cloned net.
  • Update trainPattern method to consider the previous training state of the cloned net.
  • Adjust initialize method to handle state restoration for cloned nets.
  • Ensure runInputs method maintains continuity in training for cloned nets.

Add a test case in src/recurrent/lstm.test.ts to verify that training a cloned LSTM net continues evolving from the point where the original stopped.

Fixes BrainJS#949

Update `src/recurrent.ts` to ensure cloned LSTM nets continue training from the point where the original stopped.

* Add `fromJSON` method to properly restore the training state.
* Modify `train` method to account for the state of the cloned net.
* Update `trainPattern` method to consider the previous training state of the cloned net.
* Adjust `initialize` method to handle state restoration for cloned nets.
* Ensure `runInputs` method maintains continuity in training for cloned nets.

Add a test case in `src/recurrent/lstm.test.ts` to verify that training a cloned LSTM net continues evolving from the point where the original stopped.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Training resets (destroy) cloned (or saved) Neural Nets
1 participant