Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/keon/seq2seq
Minimal Seq2Seq model with Attention for Neural Machine Translation in PyTorch
https://github.com/keon/seq2seq
deep-learning machine-translation seq2seq
Last synced: 3 months ago
JSON representation
Minimal Seq2Seq model with Attention for Neural Machine Translation in PyTorch
- Host: GitHub
- URL: https://github.com/keon/seq2seq
- Owner: keon
- License: mit
- Archived: true
- Created: 2017-12-02T11:42:18.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2020-12-13T10:53:01.000Z (almost 4 years ago)
- Last Synced: 2024-04-20T10:32:41.294Z (7 months ago)
- Topics: deep-learning, machine-translation, seq2seq
- Language: Python
- Homepage:
- Size: 31.3 KB
- Stars: 683
- Watchers: 15
- Forks: 172
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- Awesome-pytorch-list-CNVersion - minimal-seq2seq
- Awesome-pytorch-list - minimal-seq2seq
README
# mini seq2seq
Minimal Seq2Seq model with attention for neural machine translation in PyTorch.This implementation focuses on the following features:
- Modular structure to be used in other projects
- Minimal code for readability
- Full utilization of batches and GPU.This implementation relies on [torchtext](https://github.com/pytorch/text) to minimize dataset management and preprocessing parts.
## Model description
* Encoder: Bidirectional GRU
* Decoder: GRU with Attention Mechanism
* Attention: [Neural Machine Translation by Jointly Learning to Align and Translate](https://arxiv.org/abs/1409.0473)![](http://www.wildml.com/wp-content/uploads/2015/12/Screen-Shot-2015-12-30-at-1.16.08-PM.png)
## Requirements
* GPU & CUDA
* Python3
* PyTorch
* torchtext
* Spacy
* numpy
* Visdom (optional)download tokenizers by doing so:
```
python -m spacy download de
python -m spacy download en
```## References
Based on the following implementations
* [PyTorch Tutorial](http://pytorch.org/tutorials/intermediate/seq2seq_translation_tutorial.html)
* [@spro/practical-pytorch](https://github.com/spro/practical-pytorch)
* [@AuCson/PyTorch-Batch-Attention-Seq2seq](https://github.com/AuCson/PyTorch-Batch-Attention-Seq2seq)