-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Display activation functions as modules. #4045
Conversation
I'm not sure what is failing (cannot see details). I guess tests are failing (test that broke on my branch also seems to be broken on master when I ran that locally). |
Thanks for the PR! You can see the failures by logging into team city as a guest. The failures all come from tests that currently use non-modules to specify the activation. Looks like it's two one-line fixes, here:
While you're at it, can you change the name of this class to be
You'll also need to run |
Also, can you update the docstring to reflect that the input must be a module, not just a function, and give an example; |
…play_activations
…ennlp into display_activations
Oh, wow, nice! I opened #4101 and I just see this. Nice that someone's working on it. DIfferent motivation but same patch! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Hey guys, can we get this merged? |
Currently some of the activation functions (and therefore list of activation functions in FeedForward or any custom model with list / lambda based one) wouldn't be displayed in model textual summary (by summary I mean
print(model)
).I provide wrapper around lambda based implementations of activation functions (non PyTorch ones) and make corresponding change in FeedForward model.
Example result can be seen in test file.