Skip to the content.

Pose Estimation

Dataset and Code

Structure of Pose Estimation Dataset

Evaluation Metric

Instructions to run Pose Estimation models

This code was separately tested on RTX 3090, and 3080Ti using CUDA10.2.

  1. To prepare the environment, refer to
  2. Move and replace files according to the directories in $DIR_AK_AR/pose_estimation/code/code_new:
    • Helper script to move / create symbolic links to files
      • Remember to change the root directory $DIR_ROOT in $DIR_AK/pose_estimation/code/code_new/
      • bash $DIR_AK/pose_estimation/code/code_new/
  3. Untar the dataset
    • tar -zxvf $DIR_AK/pose_estimation/dataset.tar.gz
  4. Execute the code
    • python tools/ --cfg $DIR_HRNET/experiments/mpii/hrnet/w32_256x256_adam_lr1e-3_ak.yaml
  5. [Alternative] We have also specially prepared the dataset for use in MMPose by OpenMMLab.
    • COCO annotations are available (Not used in our experiments)
    • Only mAP metric is available (Not used in our experiments) for COCO datasets in MMPose,
    • Helper script to set up environment
      • Remember to change the root directory $DIR_ROOT in $DIR_AK/pose_estimation/code/code_new/
      • bash $DIR_AK/pose_estimation/code/code_new/
      • python $DIR_MMPOSE/tools/ configs/animal/2d_kpt_sview_rgb_img/topdown_heatmap/ak/

Solutions to potential issues:

Click to expand 1. unable to execute 'gcc': No such file or directory. error: command 'gcc' failed with exit status 1 * `sudo apt install gcc` 2. ModuleNotFoundError: No module named 'nms.cpu_nms' * <> * `cd $DIR_HRNET/lib` * `make` 3. OSError: The nvcc binary could not be located in your $PATH. Either add it to your path, or set $CUDAHOME * <> * `export CUDAHOME="/usr/lib/cuda"` 4. OSError: The CUDA nvcc path could not be located in /usr/lib/cuda/bin/nvcc * Ensure cuda and nvcc are installed * `sudo apt install nvidia-cuda-toolkit` * `which nvcc` * should show: `/usr/bin/nvcc` * `echo $CUDAHOME` * should show: `/usr/lib/cuda` * `sudo ln -s /usr/bin/nvcc /usr/lib/cuda/bin/nvcc` 5. RuntimeError: Unexpected error from cudaGetDeviceCount(). Did you run some cuda functions before calling NumCudaDevices() that might have already set an error? Error 804: forward compatibility was attempted on non supported HW * Driver may have been uninstalled after running `sudo apt install nvidia-cuda-toolkit` * Check if the driver is installed * `nvidia-smi` * should show the drivers available for installation (e.g., `sudo apt install nvidia-utils-470`) 6. AttributeError: module 'torch.onnx' has no attribute 'set_training' * <> * `pip install tensorboardX --upgrade` * `pip install tensorboard` 7. ImportError: cannot open shared object file: No such file or directory * <> * `sudo /sbin/ldconfig -v`