0
votes

import tensorflow as tf

ModuleNotFoundError Traceback (most recent call last) ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'


ImportError Traceback (most recent call last) ImportError: numpy.core.multiarray failed to import

The above exception was the direct cause of the following exception:

SystemError Traceback (most recent call last) ~\AppData\Local\Continuum\anaconda3\lib\importlib_bootstrap.py in _find_and_load(name, import_)

SystemError: returned a result with an error set


ImportError Traceback (most recent call last) ImportError: numpy.core._multiarray_umath failed to import


ImportError Traceback (most recent call last) ImportError: numpy.core.umath failed to import

1

1 Answers

2
votes

This happens because jupyter is not picking the tensorflow installed in that particular environment.

Solution for the above is:

conda activate <your-env>
conda install jupyter
pip install tensorflow
jupyter notebook

This should work fine now, as you have installed jupyter using the conda within the environment.

Also, I can see in your post that there is problem with numpy. As a precaution do:

pip install -U numpy

or reinstall after uninstall

pip uninstall numpy
pip install numpy

or the 3rd way:

pip install --ignore-installed numpy

Remember to do after activating your environment.

This should sort it