InvalidArgumentError : Shape in shape_and_slice spec [,] does not match the shape stored in checkpoi

解决方法:

classifier = tf.contrib.learn.DNNClassifier(feature_columns=feature_columns,hidden_units=[10, 20, 10],n_classes=2,
                                              model_dir="/tmp/iris_model")

这里的model_dir给改了。。因为tensorflow默认会先去找已经训练过的模型

tensorflow小白伤不起。。

猜你喜欢

转载自blog.csdn.net/gychixxx/article/details/79240699