Skip to content

Comments

gru/lstm: Fix missing/incorrect variables and options use#655

Merged
huningxin merged 1 commit intowebmachinelearning:mainfrom
inexorabletash:bugfix-lstm-gru-variables
Apr 24, 2024
Merged

gru/lstm: Fix missing/incorrect variables and options use#655
huningxin merged 1 commit intowebmachinelearning:mainfrom
inexorabletash:bugfix-lstm-gru-variables

Conversation

@inexorabletash
Copy link
Contributor

@inexorabletash inexorabletash commented Apr 24, 2024

  • In gru(), batchSize and numDirections were used without being defined. Define them.

  • In lstm(), numDirections was initialized to 2 if the direction was "backward", should be 1.

  • In gru() and gruCell(), options.activations was unconditionally added to the operator. Make this conditional.

  • In lstm() and lstmCell(), options.activations were not added to the operator. Add if given.


Preview | Diff

- In gru(), batchSize and numDirections were used without being
  defined. Define them.

- In lstm(), numDirections was initialized to 2 if the direction was
  "backward", should be 1.

- In gru() and gruCell(), options.activations was unconditionally
  added to the operator. Make this conditional.

- In lstm() and lstmCell(), options.activations were not added to the
  operator. Add if given.
@inexorabletash
Copy link
Contributor Author

Straightforward fixes noticed while working on other PRs. Please take a look?

Copy link
Collaborator

@fdwr fdwr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@inexorabletash
Copy link
Contributor Author

@huningxin - can you review and merge if it looks good? Thanks!

Copy link
Contributor

@huningxin huningxin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

@huningxin huningxin merged commit 0df0296 into webmachinelearning:main Apr 24, 2024
github-actions bot added a commit that referenced this pull request Apr 24, 2024
SHA: 0df0296
Reason: push, by huningxin

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@inexorabletash inexorabletash deleted the bugfix-lstm-gru-variables branch April 25, 2024 16:41
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.

3 participants