-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add chinese translation for Book chapter 8 machine translation #555
Add chinese translation for Book chapter 8 machine translation #555
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see we save the parameter anywhere. How does this network re-use its trained parameters?
Otherwise LGTM.
from functools import partial | ||
import os | ||
|
||
dict_size = 30000 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please keep the original comments. They are quite helpful for user to under.
08.machine_translation/README.cn.md
Outdated
``` | ||
```python | ||
def encoder(is_sparse): | ||
# encoder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for this comment.
08.machine_translation/README.cn.md
Outdated
- 输入是一个文字序列,被表示成整型的序列。序列中每个元素是文字在字典中的索引。所以,我们定义数据层的数据类型为`integer_value_sequence`(整型序列),序列中每个元素的范围是`[0, source_dict_dim)`。 | ||
```python | ||
def train_decoder(context, is_sparse): | ||
# decoder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for this.
paddle.reader.shuffle( | ||
paddle.dataset.wmt14.train(dict_size), buf_size=1000), | ||
batch_size=batch_size) | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we show some example outputs during training? Should be helpful.
No description provided.