I have a dataset of shape (100, 51, 128, 128, 3) where 100 are the different samples, 51 are time stamps, 128, 128 are the grid points and 3 are the different populations. When I feed this data into the deep learning architecture I reshape this dataset into
tf.reshape(data, [-1, 128]),
so that it becomes a 2D array which becomes appropriate for the dense layers (which are needed in order to compress the data to a certain latent space).
My deep learning architecture is an autoencoder structure, and I want to reconstruct the original data matrix back. So, I want to know when I reshape the dataset into a 2D matrix, and the use dense layers on this reshaped matrix, and then I reshape this 2D matrix back to my original dataset using:
tf.reshape(2Dmatrix, [-1, 51, 128, 128, 3]).
Will doing this preserve my orientation of the data, or the features of this matrix will mix up and I won’t be able to retain the original orientation back? As my data is a grid structure, so original orientation is important to me. Is there any way to preserve the orientation of data after using dense layers?
After converting the data to 2D matrix, and then reshaping it back to the original shape, the dataset thus obtained has similar values but when plotted it seems completely different from original data as if no patterns were captured.
Kanav Rana is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.