'DataParallel' object has no attribute 'init_hidden'

I want to compile my RNN on GPU.
But there’re some problems…


Above is my RNN.

And this is the approach I call RNN and initalization for the hidden0.
%E5%9C%96%E7%89%87


I guess the error is in row:171
But I have no ideal how to fix it…
It seems like I initialize hidden_0 in a wrong way.

BTW, I remember that there are two ways to initialize h0, one is tune a parameter in def init, another is define/declare h0 by user, right?

Thanks a lot!