That said, this prerequisite knowledge is not strictly necessary to complete the tutorial, and you may still find the exercise worthwhile without it.php
html
$ cd /some/directory/
$ git clone https://ejhumphrey@bitbucket.org/ejhumphrey/dltutorial.git
$ cd dltutorial
For your machine learning enjoyment, we provide two datasets that will work seamlessly with the provided source code:python
The provided source code has the following dependencies, which must be installed and configured:linux
Note: We have not provided links (yet) to discourage indiscriminate downloading; proceed to the platform-specific advice below to get the right answers for you.git
Additionally, we strongly recommend the following optional tools:github
easy_install ipython
(you may need to sudo
this).
First, apply the following OS Version logic:web
If you are able to use Mavericks, which comes standard with Python 2.7 and Numpy, you’re two-thirds of the way home. Installing Theano requires a few steps:shell
xcode-select --install
. Note: Apple does not provide very informative error messages if conditions are already satisfied.git clone git://github.com/Theano/Theano.git
)cd Theano
python setup.py build
python setup.py install
You should now be good to go; remember to back-out of the Theano directory first (cd ~
for example) before running Python.macos
You’ll be following Theano’s instructions closely:apt-get install python-numpy python-scipy python-matplotlib python-dev libopenblas-dev liblapack-dev g++ python-pip
ubuntu
And pip (Python package manager) to get theano:pip install theano
And that should do it!
To be honest, our experience with Windows is limited. However, we have it on reasonably good authority the Anaconda distribution should work out of the box. This distribution comes with Numpy, Theano, and IPython (among plenty other third-party libraries), and keeps itself installed in a single directory, making uninstallation as easy as removing that lone directory.
If you run into any issues (and perhaps even solve them), please contactejhumphrey@nyu.edu and we’ll work on updating this tutorial with your insight and experience.
To verify you’ve configured everything correctly, start Python in a terminal and run the following:
>>> import numpy
>>> import theano
If everything executes without complaining, then you’re all set!
If you’ve landed here, make extra sure your path variables (PATH and PYTHONPATH) are configured correctly. This should happen automatically during installation, but things may be wonky for some reason. If you are unfamiliar with manual system configuration, environment variables and the like, we refer you to these resources:
If this does not resolve your issues, it is probably due to a Theano issue. There are, generally, three things you can do at this point:
If, after this, you still cannot manage to import theano
, continue to the following section.
In the event that you cannot / don’t want to go through the system configuration process, we additionally provide a VirtualBox disk image of a pre-configured Ubuntu machine you are free to use. All tutorial code is guaranteed to work in this environment, but it may not be as efficient as native code. However, in our experience developing this tutorial, the performance seems mostly comparable.
To use this virtual image, do the following:
tar -xzvf linux-image.tgz
).
Congratulations! You’re now ready to dive into deep learning.
Proceed to the first example: Monophonic Instrument Classification.
If you find yourself looking for more information, insight, or references at any point, we recommend the following: