After installing tensorflow, the problem that spyder cannot import tf

I installed conda in advance. Then I installed tensorflow 1.4 on this basis, first used the conda command to create a tensorflow environment,

conda create -n tensorflow python=3.5;

and found that the spyder previously installed with conda could not successfully import tensorflow, but activated After the tensorflow environment,

source activate tensorflow;

using the terminal can be successfully imported, and later check the predecessor blog, it may be caused by the python version problem, the solution is: activate the tensorflow environment, use the

conda install spyder;

command to reinstall in the tf environment spyder, after the installation is complete, enter spyder in the terminal, you can open spyder, the python3.5 version is displayed, after this time is turned off, the originally installed spyder can continue to be opened and used, the version is python2.7, the two do not affect, It's just a different way of opening.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324694254&siteId=291194637