Hello!
While working on “Exercise 4 - lstm_forward” for the “Building your Recurrent Neural Network - Step by Step” lab assignment, I encounter the following error:
What could be the reason?
Thanks in advance!
Hello!
While working on “Exercise 4 - lstm_forward” for the “Building your Recurrent Neural Network - Step by Step” lab assignment, I encounter the following error:
What could be the reason?
Thanks in advance!
It is possible that this line:
or the previous lines of the code where you find the shapes:
are not implemented right!
I have applied recommended function np.zeros() to initialize ‘a’, ‘c’ and ‘y’ with zeros, and have retrieved shapes of x and parameters[‘Wy’] with .shape.
Did you also correctly initialize a_next
before the loop? Note that is not zeros.
Also I assume that your lstm_cell_forward
function already passes its tests.
Yes, my mistake was that I initialized ‘a_next’ as zeros before the loop.
Thanks!