local global_conf = {
cumat_type = nerv.CuMatrixFloat,
param_random = function() return 0 end,
lrate = 0.1,
wcost = 0,
momentum = 0.9,
batch_size = 2,
}
local layer_repo = nerv.LayerRepo(
{
['nerv.RNNLayer'] = {
rnn = {dim_in = {23}, dim_out = {26}},
},
['nerv.AffineLayer'] = {
input = {dim_in = {62}, dim_out = {23}},
output = {dim_in = {26, 79}, dim_out = {79}},
},
['nerv.SigmoidLayer'] = {
sigmoid = {dim_in = {23}, dim_out = {23}},
},
['nerv.IdentityLayer'] = {
softmax = {dim_in = {79}, dim_out = {79}},
},
['nerv.DuplicateLayer'] = {
dup = {dim_in = {79}, dim_out = {79, 79}},
},
}, nerv.ParamRepo(), global_conf)
local connections = {
{'[1]', 'input[1]', 0},
{'input[1]', 'sigmoid[1]', 0},
{'sigmoid[1]', 'rnn[1]', 0},
{'rnn[1]', 'output[1]', 0},
{'output[1]', 'dup[1]', 0},
{'dup[1]', 'output[2]', -1},
{'dup[2]', 'softmax[1]', 0},
{'softmax[1]', '