可以从tensorflow.python.keras导入元素,但不能从整个模块导入

时间:2018-11-15 09:01:45

标签: python tensorflow keras python-import

以下python会话如何有意义?

(ctlearn) jsevillamol@jsevillamol-N551JK:~/Documentos/ctlearn_keras$ python
Python 3.6.5 | packaged by conda-forge | (default, Apr  6 2018, 13:39:56) 
[GCC 4.8.2 20140120 (Red Hat 4.8.2-15)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from tensorflow.python.keras.models import Model
>>> import tensorflow.python.keras as K
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: module 'tensorflow' has no attribute 'python'

我可以导入tensorflow.python.keras.models,但不能导入tensorflow.python.keras

什么。我什至没有。

0 个答案:

没有答案