Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sooftware/attentions
PyTorch implementation of some attentions for Deep Learning Researchers.
https://github.com/sooftware/attentions
additive-attention attention dot-product-attention location-aware-attention location-sensitive-attension multi-head-attention pytorch relative-multi-head-attention relative-positional-encoding
Last synced: 3 days ago
JSON representation
PyTorch implementation of some attentions for Deep Learning Researchers.
- Host: GitHub
- URL: https://github.com/sooftware/attentions
- Owner: sooftware
- License: mit
- Created: 2020-03-21T17:31:05.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-03-04T07:30:05.000Z (almost 3 years ago)
- Last Synced: 2024-12-29T16:21:05.925Z (10 days ago)
- Topics: additive-attention, attention, dot-product-attention, location-aware-attention, location-sensitive-attension, multi-head-attention, pytorch, relative-multi-head-attention, relative-positional-encoding
- Language: Python
- Homepage:
- Size: 80.1 KB
- Stars: 516
- Watchers: 3
- Forks: 71
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
An Apache 2.0 PyTorch implementation of some attentions for Deep Learning Researchers.
***
## Intro
`attentions` provides some attentions used in natural language processing using pytorch.
these attentions can used in neural machine translation, speech recognition, image captioning etc...
![image](https://user-images.githubusercontent.com/42150335/83331902-7bf9f780-a2d3-11ea-8f7e-172f55deef45.png)
`attention` allows to attend to different parts of the source sentence at each step of the output generation.
Instead of encoding the input sequence into a single fixed context vector, we let the model learn how to generate a context vector for each output time step.
## Implementation list
|Name|Citation|
|---|---|
|Additive Attention|[Bahdanau et al., 2015](https://arxiv.org/pdf/1409.0473.pdf)|
|Dot-Product Attention|[Luong et al., 2015](https://arxiv.org/pdf/1508.04025.pdf)|
|Location-Aware (Location Sensitive) Attention|[Chorowski et al., 2015](http://papers.nips.cc/paper/5847-attention-based-models-for-speech-recognition.pdf)|
|Scaled Dot-Product Attention|[Vaswani et al., 2017](https://arxiv.org/abs/1706.03762)|
|Multi-Head Attention|[Vaswani et al., 2017](https://arxiv.org/abs/1706.03762)|
|Relative Multi-Head Self Attention|[ZihangDai et al., 2019](https://arxiv.org/abs/1901.02860)|
## Troubleshoots and Contributing
If you have any questions, bug reports, and feature requests, please [open an issue](https://github.com/sooftware/nlp-attentions/issues) on Github.
or Contacts [email protected] please.
I appreciate any kind of feedback or contribution. Feel free to proceed with small issues like bug fixes, documentation improvement. For major contributions and new features, please discuss with the collaborators in corresponding issues.
## Code Style
I follow [PEP-8](https://www.python.org/dev/peps/pep-0008/) for code style. Especially the style of docstrings is important to generate documentation.
## Author
* Soohwan Kim [@sooftware](https://github.com/sooftware)
* Contacts: [email protected]