Add nn.module activation support in BetterTransformer (#78394)
Summary:
textray is using nn.module as activation function params, since functional is not scriptable in textray's module.
Therefore we should support this in nn.module as well.
Test Plan: CI
Differential Revision: D36678078
Pull Request resolved: https://github.com/pytorch/pytorch/pull/78394
Approved by: https://github.com/jbschlosser