I’m not understanding why my implementation of flattening the given data set is failing. I have a working answer via transpose, but the following implementation comes naturally to me:
train_set_x_flatten = train_set_x_orig.reshape(num_px * num_px * 3, m_train)
test_set_x_flatten = test_set_x_orig.reshape(num_px * num_px * 3, m_test)
However this fails the provided tests. I am unsure why this fails, and I am also unsure why the transpose method works.
An explanation would help. Thanks.