DLs Course 5 Week 1 Assignment 3

I am facing problem with correct shape of x (not X) in assignment 3 of Week 1 Course 5 I think I am making an error taking a slice x out of X. I am using x=X[:,t, :]

I am getting following error;

Do guide where I am getting wrong.

How you are doing this step:

# Step 2.A: select the "t"th time step vector from X. 
        x = None

Hint from the notebook:

var1 = array1[:,1,:]

But we have to select "t"th (not 1) time step vector.

I am using x=X[:, t, :]

Are you using reshaper to reshape x?

Yes. After creating a slice, I am doing this: x=reshaper(x)

Please send me your code of djmodel in a private message. Click my name and message.

OK. Thank you for sending me your code.

Check your step 2.C.

Hint from Notebook:

LSTM_cell(inputs=input_x, initial_state=[previous_hidden_state, previous_cell_state])

Thanks. It worked. I added previous hidden and cell states in LSTM cell instance