Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nicklhy/MemN2N
MXNet implementation of End-To-End Memory Networks for language modelling.
https://github.com/nicklhy/MemN2N
Last synced: 2 months ago
JSON representation
MXNet implementation of End-To-End Memory Networks for language modelling.
- Host: GitHub
- URL: https://github.com/nicklhy/MemN2N
- Owner: nicklhy
- Created: 2016-12-22T08:35:47.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2016-12-26T08:58:36.000Z (about 8 years ago)
- Last Synced: 2024-08-01T22:41:45.564Z (5 months ago)
- Language: Python
- Size: 1.97 MB
- Stars: 11
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- Awesome-MXNet - [sym - Mxnet-Gluon) (<a name="NLP"></a>3. NLP / 2.14 Misc)
README
End-To-End Memory Networks in MemN2N
========================================MXNet implementation of [End-To-End Memory Networks](http://arxiv.org/abs/1503.08895v4) for language modelling. The original Tensorflow code from [carpedm20](https://github.com/carpedm20) can be found [here](https://github.com/carpedm20/MemN2N-tensorflow).
![alt tag](http://i.imgur.com/nv89JLc.png)
**Known issue: SGD does not converge, ADAM converges but is not able to reach a good result([details](https://github.com/nicklhy/MemN2N/issues/1)).**
Setup
--------------This code requires [MXNet](https://github.com/dmlc/mxnet). Also, it uses CUDA to run on GPU for faster training. There is a set of sample Penn Tree Bank (PTB) corpus in `data` directory, which is a popular benchmark for measuring quality of these models. But you can use your own text data set which should be formated like [this](data/).
Usage
--------------To train a model with 6 hops and memory size of 100, run the following command:
$ python train.py --nhop 6 --mem_size 100
To see all training options, run:
$ python train.py --help
To test a model, run the script file test.py like:
$ python test.py --network checkpoint/memnn-symbol.json --params checkpoint/memnn-0100.params --gpus 0