Thanks to theidioms.com









[Solved] ModuleNotFoundError: No module named ‘tensorflow’ – Python/Conda

Solution to ModuleNotFoundError No module named ‘tensorflow’
Data Science

[Solved] ModuleNotFoundError: No module named ‘tensorflow’ – Python/Conda



The ModuleNotFoundError: No module named ‘tensorflow’ error comes up when the TensorFlow module is not installed in either your current Python or Conda environment.

ModuleNotFoundError: No module named ‘tensorflow’ - Solution

You can solve it by writing the following command in your command prompt/terminal based on your environment:

  • Python environment
pip install tensorflow
  • Conda environment
conda install tensorflow

This will install TensorFlow in your base environment and you can start using it by writing the following import statement in Python or Jupyter notebook/lab:

import tensorflow
print(tensorflow.__version__)

This will print out the version of the installed TensorFlow module in your current Python or Conda environment.


[Solved] ModuleNotFoundError: No module named ‘tensorflow’ - Python/Conda [Solved] ModuleNotFoundError: No module named ‘tensorflow’ - Python/Conda

Leave your thought here

Your email address will not be published. Required fields are marked *