导入预处理模型的权重可以训练,但是用来预测却报错,说是tensorflow的版本问题,那么如何再不改版本的情况下,修改代码呢。
ValueError: Layer #99 (named "batch_normalization_5"), weight <tf.Variable 'batch_normalization_5/gamma:0' shape=(32,) dtype=float32, numpy=
array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.],
dtype=float32)> has shape (32,), but the saved weight has shape (64,).