簡體   English   中英

Tensorflow導入錯誤AttributeError:'模塊'對象沒有屬性'導出器'

[英]Tensorflow import error AttributeError: 'module' object has no attribute 'Exporter'

當我嘗試導入tensorflow集線器時,出現以下錯誤,提示``模塊''對象沒有屬性``導出器''。

AttributeErrorTraceback (most recent call last)
<ipython-input-1-31fb71834c8c> in <module>()
      1 # Install TF-Hub.
      2 import tensorflow as tf
----> 3 import tensorflow_hub as hub
      4 import matplotlib.pyplot as plt
      5 import numpy as np

/usr/local/lib/python2.7/dist-packages/tensorflow_hub/__init__.py in <module>()
     24 import tensorflow as tf
     25 
---> 26 from tensorflow_hub.estimator import LatestModuleExporter
     27 from tensorflow_hub.estimator import register_module_for_export
     28 from tensorflow_hub.feature_column import image_embedding_column

/usr/local/lib/python2.7/dist-packages/tensorflow_hub/estimator.py in <module>()
     59 
     60 
---> 61 class LatestModuleExporter(tf.estimator.Exporter):
     62   """Regularly exports registered modules into timestamped directories.
     63 

AttributeError: 'module' object has no attribute 'Exporter'

這是由於tensorflow的舊版本。 應該> 1.7

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM