Reputation: 121
I created a v.environment
where I have Python version 3.6.5 and there I installed tensorflow-gpu
.
The version of TensorFlow is 1.4.0 and of Keras is 2.6.0.
When I write on the script import keras
it appears the following Error:
ImportError: cannot import name 'tf2'
Have you any idea?
Upvotes: 2
Views: 13669
Reputation:
From comments
Here the problem caused by the
TF
is too old, and thekeras
is too new. Your choice is to downgradekeras
to2.2.1
, or use newer version oftf
(paraphrased by Vinson Ciawandy & homomathematicus)
Upvotes: 2