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

invert h and x arguments in RNNs #2521

Closed
wants to merge 5 commits into from
Closed

invert h and x arguments in RNNs #2521

wants to merge 5 commits into from

Conversation

CarloLucibello
Copy link
Member

In order to cause less breakage and avoid confusion such as in
https://discourse.julialang.org/t/dimension-mismatch-in-flux-jl-rnn-example/122410
this PR reinstates the previous ordering for the arguments to a cell, i.e. cell(h, x) instead of the cell(x, h) we have on master.

@CarloLucibello
Copy link
Member Author

I'm not sure we should do this, I like more the cell(x, h) convention, and also pytorch and lux do the same.
It is true that we have cell(h, x) on v0.14, but the cells are not documented and exported, they only casually appear in the recurrent layers' docstrings https://fluxml.ai/Flux.jl/stable/reference/models/layers/#Flux.RNN

@MartinuzziFrancesco
Copy link
Contributor

Weighing in on this, I do think that the cell(x, h) convention is more intuitive and, as you pointed out, in line with other libraries. Also the rnn changes in 0.15 are breaking already, so all examples should be adapted anyway I assume

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants