Problem:
I install keras
and tensorflow
correctly. Although both of them installed but i encounter with the following error when import keras
:
File "/root/PycharmProjects/DeepLearning/paper/test.py", line 1, in <module>
import keras.activations
File "/home/saeed/.conda/envs/py35/lib/python3.5/site-packages/keras/__init__.py", line 3, in <module>
from . import utils
File "/home/saeed/.conda/envs/py35/lib/python3.5/site-packages/keras/utils/__init__.py", line 6, in <module>
from . import conv_utils
File "/home/saeed/.conda/envs/py35/lib/python3.5/site-packages/keras/utils/conv_utils.py", line 9, in <module>
from .. import backend as K
File "/home/saeed/.conda/envs/py35/lib/python3.5/site-packages/keras/backend/__init__.py", line 89, in <module>
from .tensorflow_backend import *
File "/home/saeed/.conda/envs/py35/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py", line 6, in <module>
from tensorflow.python.framework import ops as tf_ops
ImportError: No module named 'tensorflow.python'; 'tensorflow' is not a package
My efforts:
I try these solutions 1, 2, 3 but no result found. Also uninstall keras
and tensorflow
and install again but useless.
Where is the problem?
System: Ubuntu 18.04.1 LTS
Python: 3.5
Keras: 2.2.2
Tensorflow: 1.10.0