Last active
August 22, 2018 12:43
-
-
Save ontheklaud/dbd9d78754aa1e07c385f09df95e2989 to your computer and use it in GitHub Desktop.
build intel caffe with latest anaconda3 on CentOS 7 (system-wide anaconda python)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# I installed anaconda3 in /opt/anaconda3, which is a system-wide accessable | |
# make directory of 'build' from root of caffe source | |
mkdir build | |
cd build | |
# source Intel Parallel Studio (currently r2018u3) | |
source /opt/intel/parallel_studio_xe_2018/bin/psxevars.sh; | |
# initialize caffe build with latest Python 3 (DO NOT ADD -DPYTHON_INCLUDE_DIR, otherwise gcc won't use system library) | |
# worse case (and confirmed malfunction with: -DPYTHON_INCLUDE_DIR=/opt/anaconda3/include/) | |
rm -rf ./*;cmake -DPYTHON_LIBRARY=/opt/anaconda3/lib/libpython3.6m.so -DPYTHON_EXECUTABLE=/opt/anaconda3/bin/python ../; | |
# build caffe with make (multi-threading not work; only -j1) | |
CPLUS_INCLUDE_PATH=/opt/anaconda3/include/python3.6m/ make all | |
# install caffe under built directory | |
make install | |
# test built caffe | |
make runtest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment