简体   繁体   中英

Issue with installing Keras library from Anaconda

I have been trying to install 'Keras' library from Anaconda on my laptop. I have the latest version of Anaconda. After that, I tried

conda update conda

conda update --all

The above two succeeds. After that I tried

conda install -c conda-forge keras

conda install keras

Both of the above fails with the below error.

ERROR conda.core.link:_execute(502): An error occurred while installing package >'::automat-0.7.0-py_1'. CondaError: Cannot link a source that does not exist. >C:\\Users\\Anaconda3\\Scripts\\conda.exe

I downloaded "automat-0.7.0-py_1" from anaconda site into one local folder and tried conda install from there. It works. However when I try to install Keras again, that again fails. I am clueless now what to do.

I had the same issue, and I solved using:

conda update -n base conda

Or, if conda <=4.3:

conda update -n root conda

I see that other users solved with

conda config --add pinned_packages defaults::conda

and

conda clean --all --yes

But it didn't work for me.

I guess the issue is that tensorflow is not yet released for Python3.7 (you have mentioned latest version of Anaconda). To overcome this, you may create a new environment with Python3.6 and simultaneously install Keras.

conda create -n p360 python=3.6 anaconda tensorflow keras

Here p360 is the name of the environment I chose.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM