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

feat: Deprecate activation functions for GRU #1198

Merged
merged 6 commits into from
Nov 21, 2024
Merged

Conversation

marcopeix
Copy link
Contributor

@marcopeix marcopeix commented Nov 12, 2024

Currently, there's a parameter for the encoder activation function, but it is not used.

PyTorch has frozen the activation function in GRU, meaning that we cannot change this. This PR deprecates this argument and we'll remove it in a future version.

Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@marcopeix marcopeix linked an issue Nov 12, 2024 that may be closed by this pull request
@marcopeix marcopeix marked this pull request as ready for review November 13, 2024 13:42
Copy link
Contributor

@elephaint elephaint left a comment

Choose a reason for hiding this comment

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

Thanks! Encoder activation should be in the definition of GRU, not in the forward method

neuralforecast/models/gru.py Outdated Show resolved Hide resolved
Copy link
Contributor

@elephaint elephaint left a comment

Choose a reason for hiding this comment

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

I think we should raise a deprecation message if we deprecate the argument, and keep the argument.

neuralforecast/models/gru.py Outdated Show resolved Hide resolved
@marcopeix marcopeix changed the title feat: Add activation functions for GRU feat: Deprecate activation functions for GRU Nov 21, 2024
Copy link
Contributor

@elephaint elephaint left a comment

Choose a reason for hiding this comment

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

Non-blocking typo

nbs/models.gru.ipynb Outdated Show resolved Hide resolved
@marcopeix marcopeix merged commit 15f061f into main Nov 21, 2024
18 checks passed
@marcopeix marcopeix deleted the feature/gru_activation branch November 21, 2024 20:15
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.

GRU encoder_activation
2 participants