Skip to content

Instantly share code, notes, and snippets.

@neerajvashistha
Last active March 5, 2020 22:11
Show Gist options
  • Save neerajvashistha/3bf0173443f68e2b2536a459b5d04743 to your computer and use it in GitHub Desktop.
Save neerajvashistha/3bf0173443f68e2b2536a459b5d04743 to your computer and use it in GitHub Desktop.
git clone https://github.com/CMU-Perceptual-Computing-Lab/openpose
sudo apt purge cmake-qt-gui
sudo apt-get install qtbase5-dev libssl-dev
tar xvzf Downloads/cmake-3.17.0-rc2.tar.gz
cd cmake-3.17.0-rc2.tar.gz
./configure --qt-gui
./bootstrap && make -j`nproc` && sudo make install -j`nproc`
echo "install cuda 10 and cudnn 7.5 explained in my blog https://medium.com/@neerajvash8/getting-your-hand-dirty-on-ubuntu-18-04-tensorflow-1-13-1-cuda10-0-f7a49f42a22f"
#install open-cv and hdf5
sudo apt-get --assume-yes install libatlas-base-dev libprotobuf-dev libleveldb-dev libsnappy-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get --assume-yes install --no-install-recommends libboost-all-dev
sudo apt-get --assume-yes install libopencv-dev
sudo apt-get --assume-yes install opencl-headers ocl-icd-opencl-dev libviennacl-dev
sudo -H pip3 install --upgrade numpy protobuf opencv-python
#caffe installation requirements
sudo apt-get install libopenblas-dev
sudo apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get install libgflags-dev libgoogle-glog-dev liblmdb-dev
#caffe installation
git clone https://github.com/BVLC/caffe.git
git checkout f019d0dfe86f49d1140961f8c7dec22130c8315 # layering issue in current version https://github.com/CMU-Perceptual-Computing-Lab/openpose/issues/787
echo "edit Makefile.config according to https://mc.ai/installing-caffe-on-ubuntu-18-04-with-cuda-and-cudnn/"
make all -j4 # 4 represents number of CPU Cores
make pycaffe -j4 # 4 represents number of CPU Cores
export PYTHONPATH=~/caffe/python:$PYTHONPATH
export Caffe_INCLUDE_DIRS=/home/nv/caffe/include/caffe
export Caffe_LIBS=/home/nv/caffe/.build_release/lib/
# pybind11 installation
git clone https://github.com/pybind/pybind11.git
cd pybind11
mkdir -p build
cd build
cmake .. -DDOWNLOAD_CATCH=1
make check -j 4
export PYBIND=/usr/local/share/cmake/pybind11
# follow steps https://github.com/CMU-Perceptual-Computing-Lab/openpose/blob/master/doc/installation.md#openpose-configuration
# finally
cd build/
make -j`nproc`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment