Reshape层主要是用来把输入shape转化为特定的shape
'''
from keras.layers import Reshape
from keras.models import Sequential
model = Sequential()
model.add(Reshape((3, 4), input_shape=(12,)))
print(model.output_shape)
model.add(Reshape((6, 2)))
print(model.output_shape)
model.add(Reshape((-1, 2, 2)))
print(model.output_shape)
'''
Permute 层将输入的维度按照给定模式进行重排
'''
from keras.layers import Reshape, Permute
from keras.models import Sequential
model = Sequential()
model.add(Permute((2, 1), input_shape=(10, 64)))
print(model.output_shape)
'''