C2W1 can't import tensorflow.keras.models

Hi,
I downloaded the library Tensorflow in my Windows. I can import it but when i import tensorflow.keras.models, it doesn’t work.
Here is my problem :


Thank you so much for your help

It seems you havent installed tensorflow or even if you have its not finding it. It may be better to create and use python vurtual environment in running your project in. Search in google about it.

Hi @NGUYEN_Thi_Bao_Ngoc ,
@gent.spah is correct! The best way to work with Tensorflow or even Pytorch is to create an environment. You can make use of Conda and then use pip to download and install TensorFlow. Take care to download the correct version to be compatible with the version number you need to use in your project. Making use of an environment will avoid impacting the behavior of your machine.

1 Like

In addition to Gent and Carlos response, you may find this guide helpful for creating a virtual environment in your PC. And if you want to use Colab, read this guide.