This gist is simply a set of scripts to install and test everything you need to get started with Deep Learning. This includes:
- TensorFlow
- Theano
- Keras
- CUDNN
- CUDA Toolkit
- Misc. linux Tools like tmux.
-
Assuming you already have a newly created EC2 GPU instance, and are able to SSH into it.
-
Copy deep_learning_bootstrap.sh, test_install.sh and theano_test.py on the machine.
-
Run chmod +x *.sh to make the .sh files executable
-
Run sudo ./deep_learning_bootstrap.sh and go have a cup of tea while it installs everything for you
- If a pink screen pops up mentioning "A new version of /boot/grub/menu.lst is available", choose "Keep local version" and select OK.
-
When the message to restart system comes up, just restart with sudo shutdown -r 0
-
After restart, run ./test_install.sh
- If everything has gone correct, then you will see output matching the expected output (in green). You are all set to get started!
- In case of errors, please ping me at @navinpai on twitter or email at navin[at]fiftheye[dot]in
1.0b
Navin "M@dMAx" Pai (@navinpai)
If you get the following error on running python -m tensorflow.models.image.mnist.convolutional:
Traceback (most recent call last): File "/usr/lib/python2.7/runpy.py", line 151, in _run_module_as_main mod_name, loader, code, fname = _get_module_details(mod_name) File "/usr/lib/python2.7/runpy.py", line 101, in _get_module_details loader = get_loader(mod_name) File "/usr/lib/python2.7/pkgutil.py", line 464, in get_loader return find_loader(fullname) File "/usr/lib/python2.7/pkgutil.py", line 474, in find_loader for importer in iter_importers(fullname): File "/usr/lib/python2.7/pkgutil.py", line 430, in iter_importers __import__(pkg) File "/usr/local/lib/python2.7/dist-packages/tensorflow/__init__.py", line 23, in <module> from tensorflow.python import * File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/__init__.py", line 98, in <module> from tensorflow.python.platform import test File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/test.py", line 63, in <module> from tensorflow.python.framework import test_util File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/test_util.py", line 43, in <module> from tensorflow.python.platform import googletest File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/googletest.py", line 32, in <module> from tensorflow.python.platform import benchmark # pylint: disable=unused-import File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/benchmark.py", line 112, in <module> class Benchmark(six.with_metaclass(_BenchmarkRegistrar, object)): File "/usr/lib/python2.7/dist-packages/six.py", line 617, in with_metaclass return meta("NewBase", bases, {}) File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/benchmark.py", line 107, in __new__ if not newclass.is_abstract(): AttributeError: type object 'NewBase' has no attribute 'is_abstract'
run
sudo pip install six --upgrade --target="/usr/lib/python2.7/dist-packages"
and then try again