Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No module named 'keras' on AWS #14

Closed
puhach opened this issue Oct 21, 2019 · 2 comments
Closed

No module named 'keras' on AWS #14

puhach opened this issue Oct 21, 2019 · 2 comments

Comments

@puhach
Copy link

puhach commented Oct 21, 2019

I was trying to use AWS Notebook instance for this project as suggested in the lesson. I installed TensorFlow according to the guidelines in readme (step 5):

sudo python3 -m pip install -r requirements/requirements-gpu.txt

That seems to have worked fine. However, switching Keras backend to TensorFlow (step 6) fails.

KERAS_BACKEND=tensorflow python -c "from keras import backend"

It says "ModuleNotFoundError: No module named 'keras'".

It needs to notice that pip list does not show keras or tensorflow as installed packages. When I run sudo pip list I can see tensorflow-gpu and Keras 2.0.2 (starting with a capital K), but not "keras" (with a small letter). Could that be a cause of the issue and how to fix it?

@ZIBOWANGKANGYU
Copy link

Hi @puhach I encountered the same problem. Did you get an answer?

@puhach
Copy link
Author

puhach commented Mar 14, 2020

I vaguely recall that I found two options:

  1. Use EC2 instance with preinstalled tensorflow and keras libraries (search for machine learning when you choose the instance type)
  2. On a fresh EC2 instance create an environment, install the libraries, and then you will need to install the kernel for Jupyter Notebook.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants