-
Notifications
You must be signed in to change notification settings - Fork 384
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
Add RNN support for Pytorch #850
base: main
Are you sure you want to change the base?
Conversation
pre-commit.ci autofix |
The tests fail with:
|
All test failures the last time around seemed to be related to issues with the tests themselves, which I have mostly fixed. The only change I made was to add missing includes to some Quartus templates to fix compiliation errors when There are currently still some remaining test failures with the case when activations are used in their |
Adds support for RNN layers (GRU, LSTM, RNN) to the pytorch parser.
Caveat: We currently lack implementation for
getitem
operations, so we can currently not return the hidden state after the calculationsCaveat 2: We currently only support a single recurrent layers, whereas multiple within the same RNN instance are supported by pytorch
Caveat 3: We currently don't support the passing of non-zero initial values for the hidden states to the RNN
So this implementation is slightly hacky at the moment, but might serve as a starting point for discussion, and can be used by interested parties if they can life with the current limitations.
Also, this contains parts of #848 because I was inattentive.
Type of change
For a new feature or function, please create an issue first to discuss it
with us before submitting a pull request.
Note: Please delete options that are not relevant.
Tests
Added pytests to confirm that the layers work.
Checklist
pre-commit
on the files I edited or added.