leoxiaobin / deep-high-resolution-net.pytorch

The project is an official implementation of our CVPR2019 paper "Deep High-Resolution Representation Learning for Human Pose Estimation"
https://jingdongwang2017.github.io/Projects/HRNet/PoseEstimation.html
MIT License
4.31k stars 909 forks source link

why set TEST.USE_GT_BBOX False #20

Open SamuelSJTU opened 5 years ago

SamuelSJTU commented 5 years ago

you provide coco test command

python tools/test.py \
    --cfg experiments/coco/hrnet/w32_256x192_adam_lr1e-3.yaml \
    TEST.MODEL_FILE models/pytorch/pose_coco/pose_hrnet_w32_256x192.pth \
    TEST.USE_GT_BBOX False

But I found I can get high accuracy only if I set it true. Otherwise, the accuracy is almost zero.

mrbulb commented 5 years ago

I test your command(set TEST.USE_GT_BBOX False), and achieve the AP of 0.744, which is the same in the README.md. So I think there may be someting wrong with your code.

For why setting TEST.USE_GT_BBOX False, in my view, HRNet adopts the top-down method for pose estimation. First use a detector generate the person box, and then the HR-Net is used to predict the person keypoints.

So person detection result is a keypoint that determines the final keypoints performance. If your set TEST.USE_GT_BBOX True, it means you use ground truth as the input of the second stage. And it's nonsense for the top-down method's evaluation.

zhj123169 commented 5 years ago

I have the same question.Have you solved it?? @SamuelSJTU

SamuelSJTU commented 5 years ago

@mrbulb I read the code. HRNet use bbox to crop the image in training and validation stage. If TEST.USE_GT_BBOX set to false, it uses bbox annotation in COCO_val2017_detections_AP_H_56_person.json. Otherwise, it uses bbox annotation in coco_val.json. This two annotation data is different. I think it dosen't provide annotation for human pose. Maybe I get wrong data for COCO_val2017_detections_AP_H_56_person.json.