Skip to content

Commit ac36a06

Browse files
committed
cosmetics and README
1 parent 1953d39 commit ac36a06

File tree

3 files changed

+20
-8
lines changed

3 files changed

+20
-8
lines changed

LICENSE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2017 OpenNMT
3+
Copyright (c) 2017-Present OpenNMT
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,23 @@
22

33
[![Build Status](https://travis-ci.org/OpenNMT/OpenNMT-py.svg?branch=master)](https://travis-ci.org/OpenNMT/OpenNMT-py)
44

5-
This is a [Pytorch](https://github.com/pytorch/pytorch)
6-
port of [OpenNMT](https://github.com/OpenNMT/OpenNMT),
7-
an open-source (MIT) neural machine translation system. It is designed to be research friendly to try out new ideas in translation, summary, image-to-text, morphology, and many other domains.
5+
6+
[OpenNMT](https://opennmt.net) is an open-source (MIT) neural machine translation system which has 3 different implementations.
7+
8+
The genuine one was a Lua version based on the Harvard Seq2Seq framework. [OpenNMT-Lua](https://github.com/OpenNMT/OpenNMT)
9+
10+
The [Pytorch](https://github.com/pytorch/pytorch) version is this repo.
11+
12+
The tensorflow version: [OpenNMT-tf](https://github.com/OpenNMT/OpenNMT-tf)
13+
14+
15+
OpenNMT-py is designed to be research friendly to try out new ideas in translation, summary, image-to-text, morphology, and many other domains but also ready for production with a full REST API.
816

917
Codebase is relatively stable, but PyTorch is still evolving. We currently recommend forking if you need to have stable code.
1018

11-
OpenNMT-py is run as a collaborative open-source project. It is maintained by [Sasha Rush](http://github.com/srush) (Cambridge, MA), [Ben Peters](http://github.com/bpopeters) (Saarbrücken), and [Jianyu Zhan](http://github.com/jianyuzhan) (Shenzhen). The original code was written by [Adam Lerer](http://github.com/adamlerer) (NYC).
19+
OpenNMT-py is run as a collaborative open-source project. The original code was written by [Adam Lerer](http://github.com/adamlerer) (NYC) and [Bryan McCann](https://github.com/bmccann).
20+
Major contributions have come from [Sasha Rush](http://github.com/srush) and his group (Cambridge, MA), [Ben Peters](http://github.com/bpopeters) (Saarbrücken), [Jianyu Zhan](http://github.com/jianyuzhan) (Shenzhen), [Paul Tardy](https://github.com/pltrdy) , [Vincent Nguyen](https://github.com/vince62s) and many others.
21+
1222
We love contributions. Please consult the Issues page for any [Contributions Welcome](https://github.com/OpenNMT/OpenNMT-py/issues?q=is%3Aissue+is%3Aopen+label%3A%22contributions+welcome%22) tagged post.
1323

1424
<center style="padding: 40px"><img width="70%" src="http://opennmt.github.io/simple-attn.png" /></center>
@@ -23,6 +33,7 @@ Table of Contents
2333
* [Citation](#citation)
2434

2535
## Requirements
36+
python 3, torch >=0.4.0, torchtext >=0.2.3, six, tqdm, future, cupy pynvrtc for SRU
2637

2738
```bash
2839
pip install -r requirements.txt
@@ -36,7 +47,7 @@ The following OpenNMT features are implemented:
3647
- [data preprocessing](http://opennmt.net/OpenNMT-py/options/preprocess.html)
3748
- [Inference (translation) with batching and beam search](http://opennmt.net/OpenNMT-py/options/translate.html)
3849
- [Multiple source and target RNN (lstm/gru) types and attention (dotprod/mlp) types](http://opennmt.net/OpenNMT-py/options/train.html#model-encoder-decoder)
39-
- [TensorBoard/Crayon logging](http://opennmt.net/OpenNMT-py/options/train.html#logging)
50+
- [TensorBoard logging](http://opennmt.net/OpenNMT-py/options/train.html#logging)
4051
- [Source word features](http://opennmt.net/OpenNMT-py/options/train.html#model-embeddings)
4152
- [Pretrained Embeddings](http://opennmt.net/OpenNMT-py/FAQ.html#how-do-i-use-pretrained-embeddings-e-g-glove)
4253
- [Copy and Coverage Attention](http://opennmt.net/OpenNMT-py/options/train.html#model-attention)
@@ -46,7 +57,7 @@ The following OpenNMT features are implemented:
4657
- Inference time loss functions.
4758

4859
Beta Features (committed):
49-
- multi-GPU
60+
- multi-GPU (based on torch distributed, single node at the moment)
5061
- Structured attention
5162
- [Conv2Conv convolution model]
5263
- SRU "RNNs faster than CNN" paper

onmt/trainer.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
things to users(i.e. how to do it). Also see train.py(one of the
99
users of this library) for the strategy things we do.
1010
"""
11+
#!/usr/bin/env python
1112
from __future__ import division
1213
from __future__ import print_function
1314

@@ -215,7 +216,7 @@ def train_epoch(self, train_iter, epoch):
215216
normalization = 0
216217
idx += 1
217218

218-
# Make sure to process remaining batches in the case of
219+
# Make sure to process remaining batches in the case of
219220
# grad_accum_count > 1 but not enough batches to fill true_batchs
220221
if len(true_batchs) > 0:
221222
self._gradient_accumulation(

0 commit comments

Comments
 (0)