So, when using Theano, remember to switch the backend in Keras Config. Keas will by default try to use the TensorFlow backend. (I’ll be doing a separate guide for installing TensorFlow on Ubuntu) Pip install -upgrade -no-deps git+git:///Theano/Theano.git I’ll be initially using Keras with the Theano backend, so I’ll install Theano first. Once the environment is created, and the package installations are finished, activate the environment, Having these commonly used packages installed will make your life easier later on.Ĭreating the Anaconda environment and installing the packages Now, we are ready to create an Anaconda environment and install Keras in it.Ĭreate a new environment (I’ll name it ‘keras-test’) with the following packages.Ĭonda create -name keras-test numpy scipy scikit-learn pillow h5py Select the option to add Anaconda to the PATHĪfter the installation completed, close the terminal, and open a new one. Note: When installing Anaconda on the default location, you don’t need root access, so there’s no need to 'sudo'.Īt the end of the installation, it will ask whether to add the Anaconda install location to your PATH. You need to include the 'bash' command even if you’re not using the bash shell. Open a terminal, and navigate to the location of the downloaded file, and run the following command to start the installation, This will download a file named Anaconda3-4.2.0-Linux-x86_64.sh (the version numbers might be different based on the latest version available at the time of the download). We’ll be getting the Python 3.5 64-Bit package.ĭownload the Anaconda Python 3.5 64-Bit package for Linux Head over to the Anaconda Python Downloads page, and get the Linux installer for Anaconda. Sudo apt-get install libopenblas-dev liblapack-dev Sudo apt-get install build-essential cmake git unzip pkg-config Then, we’ll install the following necessary packages, But the steps and commands are exactly the same for the standard Ubuntu desktop as well.įirst and foremost, get and install the latest updates in Ubuntu, (Reboot the machine if necessary after updating.) Note: The screenshots I captured are from a virtual machine with Lubuntu 16.10 (the LXDE flavor of Ubuntu). I’ll be using the latest Ubuntu 16.10 (Yakkety Yak) 64-Bit for this. I’m planning to switch to Linux for few of my experiments, so I decided to try out setting up Anaconda Python and Keras from scratch on Ubuntu. I recently did a post on how to install Keras on Anaconda on Windows. I’ve been using Anaconda Python for most of my Machine Learning experiments, mainly because of the flexibility it gives with the isolated Python environments.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |