我正在尝试运行基于DL的代码。我的设定是:tensorflow 1.4python 3.6cuda 8.0
我总是得到相同的错误:
Traceback (most recent call last):
File "demo.py", line 285, in <module>
main()
File "demo.py", line 55, in main
import tflearn
File "/.local/lib/python3.6/site-packages/tflearn/__init__.py", line 4, in <module>
import tensorflow.compat.v1 as tf
ModuleNotFoundError: No module named 'tensorflow.compat'
I would appreciate for any help please.
在Tf>=1.13
中添加tf.compat.v1
模块。升级到1.14
,1.15
或2.x
,这将正常工作。