transformer opt python files (#35206)
This PR adds fused transformer python related files. It defines interface of fused transformer. Fused transformer implements an optimized version of transformer layer (in python/paddle/nn/layer/transformer.py). In this PR, four layers (functions) are defined: (1) FusedMultiHeadAttention: multi-head attention layer (2) FusedFeedForward: feed forward layer (3) FusedTransformerEncoderLayer: transformer encoder layer (4) FusedTransformer: transformer layer
Showing
想要评论请 注册 或 登录