Skip to content

Commit

Permalink
[API 2.0] Add transformer apis (#26418)
Browse files Browse the repository at this point in the history
* Add MultiHeadAttention api.
test=develop

* Add MultiHeadAttention cache type and gen_cache.
test=develop

* Add TransformerEncoderLayer and TransformerEncoder.
test=develop

* Add Transformer decoder apis.
test=develop

* Add Transformer api.
test=develop

* add unittests for transformer api

* add unittests for transformer api

* Fix some bugs in Transformer apis.
test=develop

* add unittests for encoder, decoder and transformer

* clean conflicts infor in code

* clean Chinese comments

* Add TransformerDecoderCell and TransformerBeamSearchDecoder.
test=develop

* Remove TransformerDecoderCell and TransformerBeamSearchDecoder temporarily.
test=develop

* Add import for Transformer apis.
test=develop

* Update usage of weight_attr and Tensor in Transformer api docs.
test=develop

* Update Transformer apis by renaming MultiheadAttention and cal_kv according to comments.
test=develop

* Fix MultiHeadAttention in test_transformer_api.py.
test=develop

Co-authored-by: LiuChiaChi <[email protected]>
  • Loading branch information
guoshengCS and LiuChiachi authored Aug 24, 2020
1 parent 8645591 commit 317f7ce
Show file tree
Hide file tree
Showing 4 changed files with 1,589 additions and 1 deletion.
Loading

0 comments on commit 317f7ce

Please sign in to comment.