1. how to build openpose
cmake -DOpenCV_INCLUDE_DIRS=/usr/local/include \
-DOpenCV_LIBS_DIR=/usr/local/lib \
-DCaffe_INCLUDE_DIRS=/home/"${USER}"/workspace/caffe3/distribute/include \
-DCaffe_LIBS=/home/"${USER}"/workspace/caffe3/build/lib/libcaffe.so -DBUILD_CAFFE=OFF ..
cmake -Dpython_version=3 -DBUILD_PYTHON=1 -DCMAKE_INSTALL_PREFIX=/home/ninja/workspace/openpose/build/install ..
make all -j32
sudo make install
export PYTHONPATH=/home/ninja/workspace/openpose/build/install/python
2. how to run testing
./build/examples/openpose/openpose.bin --video examples/media/video.avi
CUDA_VISIBLE_DEVICES=0 ./build/examples/openpose/openpose.bin --net_resolution "160x80" --video examples/media/video.avi
3. how to use python library
ninja@pp-pc:~/workspace/openpose$ python build/examples/tutorial_api_python/01_body_from_image.py
(an output image will be shown)
4. how to use docker (failed)
docker run -it --rm --runtime=nvidia -e NVIDIA_VISIBLE_DEVICES=0 cwaffles/openpose-python
apt-get install xauth
docker run -it --rm --runtime=nvidia -e NVIDIA_VISIBLE_DEVICES=0 openpose:docker
No comments:
Post a Comment