之前训练文件的导出和freeze都是使用tf.train.Saver()方法,这次为了适配 Tensorflow Serving 使用了tf.saved_model.builder.SavedModelBuilder()的方法. 经过一天的尝试,解决了 builder的save和load.在本机导出再载入做inference没问题,但是将模型部署到serving下就碰到了如下问题(粘贴为引用格式太乱了,就粘贴为代码块啦…):
Traceback (most recent call last):
File "/home/max/code/tf-serving/serving/tensorflow_serving/example/inception_client_gold.py", line 64, in <module>
tf.app.run()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 126, in run
_sys.exit(main(argv))
File "/home/max/code/tf-serving/ser