参考网址
https://tensorflow.google.cn/api_docs/python/tf/keras/layers/Flatten
tf.keras.layers.Flatten(
data_format=None, **kwargs
)
作用:
展平矩阵,将多维矩阵展平为一维矩阵
使用:
import tensorflow as tf
model = tf.keras.Sequential()
model.add(tf.keras.Flatten())
# 展平矩阵