![](/img/trans.png)
[英]Issues with implementing TensorFlow's MNIST example without feed_dict using a queue
[英]How to execute TensorFlow serving example mnist_export without using bazel?
我已經安裝了TensorFlow服務的所有先決條件,如下所述
當我嘗試在Ubuntu 16.04計算機上使用以下行運行默認mnist示例時:
python mnist_export.py --training_iteration=1000 --export_version=1 export_models
我收到以下錯誤:
Traceback (most recent call last):
File "mnist_export.py", line 40, in <module>
from tensorflow_serving.example import mnist_input_data
ImportError: No module named tensorflow_serving.example
該代碼在此處可用 。
但是,當我使用bazel進行如下構建時,它可以完美運行:
bazel-bin/tensorflow_serving/example/mnist_export --training_iteration=1000 --export_version=1 export_models
通過將以下行更改為解決了此問題:
from tensorflow_serving.example import mnist_input_data
到這行:
from tensorflow.contrib.learn.python.learn.datasets import mnist as mnist_input_data
這里討論這個問題。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.