How Install Neural Style on Ubuntu 16.04 like a boss..

Welcome to Neural Style Ready in Under 45mins guide, The waiting time will be based on Torch7 being compiled (Fear not) and Registering with NVIDIA CuDNN Page, But it should take no longer than a slow brew coffee being made, so lets get started!

 

Its EXTREMELY recommended to do this on a standalone dedicated Ubuntu HD, Virtual environments are great but will cause issues..

 

By kineticsystem

INSTALL NVIDIA DRIVERS

In Xubuntu start the Software Updater and press the button "Settings...".
Select the "Additional Drivers" tab and once a list of driver is displayed select and install
"NVIDIA binary driver - version 361.42 from nvidia-361 (propietary,tested)"

Type "nvidia-smi" to check if the driver is installed.

At this stage it is important to reboot.

INSTALL NVIDIA CUDA TOOLKIT 7.5

Open a terminal and type

sudo apt-get install nvidia-cuda-toolkit

INSTALL TORCH7

Run the following commands

cd ~/
git clone https://github.com/torch/distro.git ~/torch --recursive
cd ~/torch
./install-deps
./install.sh
source ~/.bashrc

INSTALL LOADCAFFE

sudo apt-get install libprotobuf-dev protobuf-compiler
luarocks install loadcaffe

INSTALL NEURAL-STYLE

cd ~/
git clone https://github.com/jcjohnson/neural-style.git
cd neural-style
sh models/download_models.sh

Test the installation with the following command

th neural_style.lua -gpu -1 -print_iter 1

INSTALL CUDNN V.4

cuDNN is a library from NVIDIA that efficiently implements many of the operations (like convolutions and pooling) that are commonly used in deep learning. Register as a developer and download the cuDNN file from here

https://developer.nvidia.com/cudnn

Download and install the deb runtime package.

libcudnn5_5.1.3-1+cuda7.5_amd64.deb

 

Your welcome to use the comment box below to troubleshoot..

Leave a comment