-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathhyperparams.py
31 lines (25 loc) · 874 Bytes
/
hyperparams.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# -*- coding: utf-8 -*-
#/usr/bin/python2
'''
Sept. 2017 by kyubyong park.
https://www.github.com/kyubyong/word_ordering
'''
class Hyperparams:
'''Hyperparameters'''
# data
data = 'eng_news_2015_1M/eng_news_2015_1M-sentences.txt'
# training
batch_size = 32 # alias = N
lr = 0.0001 # learning rate. In paper, learning rate is adjusted to the global step.
logdir = 'logdir' # log directory
# model
maxlen = 10 # Maximum number of words in a sentence. alias = T.
# Feel free to increase this if you are ambitious.
min_cnt = 20 # words whose occurred less than min_cnt are encoded as <UNK>.
hidden_units = 512 # alias = C
num_blocks = 6 # number of encoder/decoder blocks
num_epochs = 20
num_heads = 8
dropout_rate = 0.1
smoothing_rate = 0.