forked from lancopku/Graph-to-seq-comment-generation
-
Notifications
You must be signed in to change notification settings - Fork 1
/
gru.txt
162 lines (159 loc) · 6.26 KB
/
gru.txt
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
data: ./sport_data/
vocab: ./sport_data/vocab.txt
vocab_size: 60000
type_num: 4
head_num: 4
log: ./sport_data/log/
epoch: 10
batch_size: 32
param_init: 0.1
optim: adam
learning_rate: 0.0005
max_grad_norm: 8
window_size: [1, 2, 3]
filter_size: 128
learning_rate_decay: 0.5
schedule: True
start_decay_at: 2
emb_size: 128
encoder_hidden_size: 128
decoder_hidden_size: 256
num_layers: 2
bidirec: True
dropout: 0.1
max_tgt_len: 30
max_sentence_len: 100
eval_interval: 500
save_interval: 2000
max_generator_batches: 32
metric: ['bleu', 'xent']
shared_vocab: True
beam_size: 10
graph2gru(
(embedding): Embedding(60000, 128)
(encoder): Memory_Network(
(embedding): Embedding(60000, 128)
(bert): BERT(
(position_emb): Embedding(101, 128)
(encoder): Encoder(
(layers): ModuleList(
(0): EncoderLayer(
(self_attn): MultiHeadedAttention(
(linears): ModuleList(
(0): Linear(in_features=128, out_features=128, bias=True)
(1): Linear(in_features=128, out_features=128, bias=True)
(2): Linear(in_features=128, out_features=128, bias=True)
(3): Linear(in_features=128, out_features=128, bias=True)
)
)
(feed_forward): PositionwiseFeedForward(
(w_1): Linear(in_features=128, out_features=128, bias=True)
(w_2): Linear(in_features=128, out_features=128, bias=True)
(dropout): Dropout(p=0.1, inplace=False)
)
(sublayer): ModuleList(
(0): SublayerConnection(
(norm): LayerNorm()
(dropout): Dropout(p=0.1, inplace=False)
)
(1): SublayerConnection(