Hi @dasguptar,
Thanks for your response!
Maybe I wasn’t clear in my question:
I’m trying to solve many-to-many problem-
I have a [seq_len, batch, input_dim] as input.
My output is  [seq_len, batch, ioutput_dim].
my network is a multi-layer lstm, for example - 2 layers.
the current flow:
h1_new= lstm1(input, h1_old,)
h2_new= lstm1(h1_new, h2_old)
out = fc(h2_new)
I want to sum over the num of layers dim, s.t:
h_sum = h1_new + h2_new [seq_len, batch, hidden_dim]
out = fc(h_sum)
It’s like a skip connection in regular feed-forward networks.