TensorFlow2.x冻结模型,保存为.pb格式方便部署
1、用tf.keras创建模型inputs = tf.keras.Input(shape=(1000, 9,), name='input')input = tf.keras.layers.Flatten(name="flatten")(inputs)f1 = tf.keras.layers.Dense(512, activation='relu', name='dense_1')(input)d1 = tf.keras.layers.Dropout(0.2,name='dro