Try   HackMD

DENSEPOSE Windows10 Installation

tags: Deep Learning

1.Install Anaconda
2.conda create -n pose python=3.6.8
3.conda activate pose

4.install pytorch

conda install pytorch==1.0.1 torchvision==0.2.2 cudatoolkit=10.0 -c pytorch

5.install caffe2 requiements
pip install future ^ hypothesis ^ numpy ^ protobuf ^ six
6.install some packages

pip install pyyaml
pip install h5py
pip install scipy
pip install memory_profiler
pip install opencv-python

Chong Ming Wei要先裝cython
pip install cython

  1. install cocoapi

    cd (WinDensePose-master)/cocoapi/PythonAPI/
    python setup.py build
    python setup.py install

  2. install densepose

    cd (WinDensePose-master)/densepose/
    python setup.py build
    python setup.py install

  3. set path enviroment

    set PYTHONPATH=(WinDensePose-master)\densepose;%PYTHONPATH%
    OR
    編輯環境變數>>環境變數>>新增系統變數

    Image Not Showing Possible Reasons
    • The image file may be corrupted
    • The server hosting the image is unavailable
    • The image path is incorrect
    • The image format is not supported
    Learn More →

  4. Download UV data(Necessary)

    We need to download manually the archive below because under Windows we can not eexecute .sh scripts. Follow the link and unzip and copy all files in densepose\DensePoseData\UV_data.

    Another option is to install cygwin and then run the scripts which are in the folder densepose\DensePoseData. Scripts are: get_DensePose_COCO.sh, get_densepose_uv.sh, get_eval_data.sh

  5. Test with(weight檔要額外下載下來,直接打下面指令會報錯)

    python tools/infer_simple.py cfg configs/DensePose_ResNet101_FPN_s1x-e2e.yaml output-dir DensePoseData/infer_out/ image-ext jpg wts https://dl.fbaipublicfiles.com/densepose/DensePose_ResNet101_FPN_s1x-e2e.pkl DensePoseData/demo_data/demo_im.jpg

Reference: