PowerAI release 3.2 provides software packages for several Deep Learning frameworks, supporting libraries, and tools:
All the packages are intended for use with Ubuntu 16.04 on POWER with NVIDIA CUDA 8.0 and cuDNN v5.1 packages.
For more information visit https://ibm.biz/powerai.
The Deep Learning packages require Ubuntu 16.04 for IBM POWER8. Ubuntu installation images can be downloaded from:
http://www.ubuntu.com/download/server/power8
NOTE: After installing Ubuntu 16.04 update the libc6
package to version 2.23-0ubuntu5
or higher. That version fixes problems affecting Torch and TensorFlow. You may need to enable the updates repository to install this update.
The Deep Learning packages require NVIDIA CUDA 8.0 and cuDNN 5.1, which can be installed as follows:
PATH
and LD_LIBRARY_PATH
.Install the cuDNN v5.1 packages
$ sudo dpkg -i libcudnn5*deb
CUDA version 8.0.44 is or higher is required.
NVIDIA driver version 361.93.03 or higher is required.
NVIDIA driver updates for POWER8 are available from https://www.nvidia.com (select DRIVERS then All NVIDIA Drivers).
361.93.03 driver download
If you prefer to use the 361.93.03 driver it can be downloaded from the NVIDIA site as follows:
The Deep Learning packages are published as an Ubuntu package that sets up an installation repository on the local machine. The repository can be enabled as follows:
Download the latest mldl-repo-local
.deb
file from https://download.boulder.ibm.com/ibmdl/pub/software/server/mldl/
Install the repository package:
$ sudo dpkg -i mldl-repo-local*.deb
Update the package cache
$ sudo apt-get update
All the Deep Learning frameworks can be installed at once using the power-mldl
meta-package:
$ sudo apt-get install power-mldl
The Deep Learning frameworks can be installed individually if preferred. The framework packages are:
caffe-bvlc
- Berkeley Vision and Learning Center (BVLC) upstream Caffe, v1.0.0rc3caffe-ibm
- IBM Optimized version of BVLC Caffe, v1.0.0rc3caffe-nv
- NVIDIA fork of Caffe, v0.15.13 and v0.14.5chainer
- Chainer, v1.18.0digits
- DIGITS, v5.0.0-rc.1tensorflow
- Google TensorFlow, v0.12.0theano
- Theano, v0.8.2torch
- Torch, v7Each can be installed with:
$ sudo apt-get install <framework>
The digits
and python-socketio-server
packages conflict with Ubuntu's older python-socketio
package. Please uninstall the python-socketio
package before installing DIGITS.
Recommended settings for optimal Deep Learning performance on the S822LC for High Performance Computing are:
Enable Performance Governor
$ sudo apt-get install linux-tools-common cpufrequtils
$ sudo cpupower -c all frequency-set -g performance
Enable GPU persistence mode
Use nvidia-persistenced
(http://docs.nvidia.com/deploy/driver-persistence/index.html) or
$ sudo nvidia-smi -pm ENABLED
Set GPU memory and graphics clocks
$ sudo nvidia-smi -ac 715,1480
For TensorFlow, set the SMT mode
$ sudo ppc64_64 --smt=2
Each framework package provides a shell script to simplify environmental setup.
We recommend that users update their shell rc file (e.g. .bashrc
) to source the desired setup scripts. For example:
source /opt/DL/<framework>/bin/<framework>-activate
Each frame also provides a test script to verify basic function:
$ <framework>-test
Caffe alternatives
Packages are provided for upstream BVLC Caffe (/opt/DL/caffe-bvlc
), IBM optimized BVLC Caffe (/opt/DL/caffe-ibm
), and NVIDIA's Caffe (/opt/DL/caffe-nv
). The system default Caffe (/opt/DL/caffe
) can be selected using Ubuntu's alternatives system:
$ sudo update-alternatives --config caffe
There are 3 choices for the alternative caffe (providing /opt/DL/caffe).
Selection Path Priority Status
------------------------------------------------------------
* 0 /opt/DL/caffe-ibm 100 auto mode
1 /opt/DL/caffe-bvlc 50 manual mode
2 /opt/DL/caffe-ibm 100 manual mode
3 /opt/DL/caffe-nv 75 manual mode
Press <enter> to keep the current choice[*], or type selection number:
Users can activate the system default caffe:
source /opt/DL/caffe/bin/caffe-activate
Or they can activate a specific variant. For example:
source /opt/DL/caffe-bvlc/bin/caffe-activate
Attempting to activate multiple Caffe packages in a single login session will cause unpredictable behavior.
Caffe samples and examples
Each Caffe package includes example scripts and sample models, etc. A script is provided to copy the sample content into a specified directory:
$ caffe-install-samples <somedir>
NVIDIA Caffe versions
This PowerAI release includes packages for both NV Caffe 0.14.5 and 0.15.13. The versions may behave differently (e.g. in performance or convergence) with different models.
NV Caffe 0.15.13 is NCCL enabled and will be installed by default. Version 0.14.5 can be installed as follows:
Uninstall 0.15.13 (if needed)
$ sudo apt-get purge caffe-nv
...
The following packages were automatically installed and are no longer required:
bazel caffe-bvlc caffe-ibm digits libnccl1 libopenblas tensorflow theano torch
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
caffe-nv* power-mldl*
...
Do you want to continue? [Y/n]
Install 0.14.15 version specifically
$ sudo apt-get install caffe-nv=0.14.5-3ibm1
More info
Visit Caffe's website (http://caffe.berkeleyvision.org/) for tutorials and example programs that you can run to get started.
Here are links to a couple of the example programs:
The Chainer home page at http://chainer.org/ includes documentation for the Chainer project, including a Quick Start example.
The TensorFlow homepage (https://www.tensorflow.org/) has a variety of information, including Tutorials, How Tos, and a Getting Started guide.
Additional tutorials and examples are available from the community, for example:
The TensorFlow team provides ready-to-use models on GitHub at https://github.com/tensorflow/models
The Torch Cheatsheet contains lots of info for people new to Torch, including tutorials and examples.
The Torch project has a demos repository at https://github.com/torch/demos
Tutorials can be found at https://github.com/torch/tutorials
Visit Torch's website for the latest from Torch.
Torch samples and examples
The Torch package includes example scripts and samples models. A script is provided to copy the sample content into a specified directory:
$ torch-install-samples <somedir>
Among these are the Imagenet examples from https://github.com/soumith/imagenet-multiGPU.torch with a few modifications.
Extending Torch with additional Lua rocks
The Torch package includes several Lua rocks useful for creating Deep Learning applications. Additional Lua rocks can be installed locally to extend functionality. For example a rock providing NCCL bindings can be installed by:
$ source /opt/DL/torch/bin/torch-activate
$ source /opt/DL/nccl/bin/nccl-activate
$ luarocks install --local --deps-mode=all "https://raw.githubusercontent.com/ngimel/nccl.torch/master/nccl-scm-1.rockspec"
...
nccl scm-1 is now built and installed in /home/user/.luarocks/ (license: BSD)
$ luajit
LuaJIT 2.1.0-beta1 -- Copyright (C) 2005-2015 Mike Pall. http://luajit.org/
JIT: OFF
> require 'torch'
> require 'nccl'
>
Here are some links to help you get started with Theano:
Visit Theano's website for the latest from Theano.
The first time it's run digits-activate
will create a .digits
subdirectory containing the DIGITS jobs
directory, as well as the digits.log
file
Multiple instances of the DIGITS server can be run at once, including by different users, but users may need to set the network port number to avoid conflicts.
To start DIGITS server with default port (5000):
$ digits-devserver
To start DIGITS server with specific port
$ digits-devserver -p <port_num>
NVIDIA's DIGITS site has more information about DIGITS.
The DIGITS Getting Started guide describes how to train a network model to classify the MNIST hand-written digits dataset.
Additional DIGITS examples are available at https://github.com/NVIDIA/DIGITS/tree/master/examples
Using Torch with DIGITS
Using Torch with DIGITS requires additional packages that are not part of this PowerAI release distribution.
Torch can be made to work with DIGITS as follows:
Install PowerAI Torch and DIGITS packages
$ sudo apt-get install digits torch
Install pre-requisite packages from Ubuntu
$ sudo apt-get install libhdf5-serial-dev liblmdb-dev
Install additional luarocks needed for DIGITS' Torch support
$ source /opt/DL/torch/bin/torch-activate
$ luarocks install --local --dep-mode=order tds
$ luarocks install --local --dep-mode=order totem
$ luarocks install --local --dep-mode=order "https://raw.github.com/deepmind/torch-hdf5/master/hdf5-0-0.rockspec"
$ luarocks install --local --dep-mode=order "https://raw.github.com/Neopallium/lua-pb/master/lua-pb-scm-0.rockspec"
$ luarocks install --local --dep-mode=order lightningmdb 0.9.18.1-1 LMDB_INCDIR=/usr/include LMDB_LIBDIR=/usr/lib/powerpc64le-linux-gnu
$ luarocks install --local --dep-mode=order "https://raw.githubusercontent.com/ngimel/nccl.torch/master/nccl-scm-1.rockspec"
© Copyright IBM Corporation 2017
IBM, the IBM logo, ibm.com, POWER, Power, POWER8, and Power systems are trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at “Copyright and trademark information” at www.ibm.com/legal/copytrade.shtml.
Linux is a registered trademark of Linus Torvalds in the United States, other countries, or both.
The TensorFlow package includes code from the BoringSSL project. The following notices may apply:
This product includes software developed by the OpenSSL Project for
use in the OpenSSL Toolkit. (http://www.openssl.org/)
This product includes cryptographic software written by Eric Young
(eay@cryptsoft.com)
This document is current as of the initial date of publication and may be changed by IBM at any time. Not all offerings are available in every country in which IBM operates.
THE INFORMATION IN THIS DOCUMENT IS PROVIDED “AS IS” WITHOUT ANY WARRANTY, EXPRESS OR IMPLIED, INCLUDING WITHOUT ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND ANY WARRANTY OR CONDITION OF NON-INFRINGEMENT. IBM products are warranted according to the terms and conditions of the agreements under which they are provided.