I have a numpy matrix 'mat', which is 888 * 100 * 100. This represents 888 samples of 100 by 100 grids.
I want to apply a transformation to each grid in the matrix.
I tried mod_mat = np.rot90(mat), but it changed the dimension to 100 * 888 * 100.
Is there a way to carry out the transformations in one go? Or, do I need to iterate over each grid and transform it separately? Thanks.