Hi, I’m working through this notebook, specifically the
Pure Python RNN! section. I’m having trouble understanding the forward pass function. It looks like this:
return scan(one_char, (0,0,0, np.zeros(n_hidden), 0), get_chars(n))
Specifically, the confusing part is the (0,0,0 np.zeros(n_hidden),0). I looked on Theano’s docs, and this appears to be the “sequences” parameter. But I’m not sure that’s correct. The Theano docs say “sequences is the list of Theano variables or dictionaries describing the sequences”. That list aren’t theano variables, so it must represent something else.
So what are those things doing, and why do we have three leading zeros, and one trailing zero, to pad a list of 256 zeros (# of n_hidden). What’s going on here?