-
Notifications
You must be signed in to change notification settings - Fork 172
Install Minerva
Minerva is built and tested on Ubuntu 14.04.1 LTS, although it should also work for any *nix system, as long as you have the correct libraries installed.
Minerva depends on several packages. If they are not in the system search path, please set variable EXTERN_INCLUDE_PATH
and EXTERN_LIB_PATH
in configure.in
accordingly.
- CUDA 6.5
- cuDNN R1 (R2 support is under way)
In addition, Minerva also depends on the following packages. Since system package managers usually have poor support for them, the script resolve_deps.sh
can be used to help resolve. Running this script will download and install them in the deps
directory relative to the root of the repository.
- Boost
- Boost.NumPy
- glog
- gflags
- Protocol Buffers and its Python binding
Following packages are needed for use with Owl (Minerva's python binding). You could disable it by passing --disable-owl
during configure if you only need c++ library (and thus none of the followings is needed).
- Python library (python-dev)
- LMDB and its Python binding
- NumPy
- SciPy
Please consult configure.in.example
for a sample configuration of the paths.
- Set
CXX_COMPILER
, andC_COMPILER
inconfigure.in
.g++-4.8
is strongly recommended. - Set
CUDA_ROOT
to the root directory of CUDA SDK, if you have installed it to some non-default location; setCUDNN_ROOT
to the root directory of CUDNN package. - If you are using the provided
resolve_deps.sh
, then all the dependencies should be tracked by cmake; Otherwise, setEXTERN_INCLUDE_PATH
, andEXTERN_LIB_PATH
inconfigure.in
to reflect any dependency not in the system search path. If there are more than one, use a semicolon-separated list. - Run
./configure --prefix=/path/to/install <other_options>
. - Change directory into
release
(ordebug
for more verbose logging) and runmake
.
After these steps, Minerva should be successfully built and linked on your system. But to run the Python interpreter with Owl (Minerva's python binding) enabled, you have to source owl_environ.sh
at the root of the repository. This will set the environment variables for Python to find Owl. You can then run run_owl_shell.sh
to start an interactive shell, or run Python scripts directly.
If you want to install Minerva into another location, run make install
in release
. And then run ./setup.py install --user
. This will install Owl package into your local folder. You could then test it by python -c 'import owl'
. Please make sure that libminerva.so
and all dependent libraries could be found during runtime such as LD_LIBRARY_PATH
.
You could also specify options during configuration:
- Build debug version: add
--build-debug
- Build mnist examples in c++: add
--build-apps
- Build unit tests: add
--build-tests
(GoogleTest is required). - Build without owl library: add
--disable-owl
Minerva is not unusual in this approach; ssh-agent
, pip
, opam
and many others also work similarly. This allows a local version of the Minerva system and its dependencies, while still giving the ability to run from anywhere.