I am encountering an issue with initializing caches for this exercise:
AssertionError: len(cache) must be T_x = 13
is the persistent error that I am receiving.
I initialized the cache as a list with parameters and x as the inputs using caches = [parameters, x]. I understand because x is appended to the list of caches, len(cache) is expected to be T_x=13. However, I persist in receiving the above error, and I cannot deduce the source of the error. Would anyone have any pointers?
Meanwhile, I noticed that my resulting array for a and y_pred do not align with the expected results of this exercise. However, I am unsure whether this is related to caches.
In rnn_forward, I initialized caches as an empty list. It starts empty and then the instructions describe what gets appended to it in each timestep.
Please show us the error you are seeing about that. Note that in my rnn_forward code, the caches are purely output values. There is no point in the code where I actually use any of the cache values for anything other than to save it in caches for back propagation later.