chenyilun95 / tf-cpn

Cascaded Pyramid Network for Multi-Person Pose Estimation (CVPR 2018)
MIT License
793 stars 197 forks source link

In the function of Preprocessing() of dataset.py, does the object objcenter means the center point of bounding box? #7

Closed gdjmck closed 6 years ago

gdjmck commented 6 years ago

I saw that bbox is read from the json file, and the value of key 'bbox' is (start_x, start_y, width, height). So the object adds the latter 2 values with the first 2 values to get the end_x and end_y. Then comes the issue I'm confused of, objcenter = np.array([bbox[0] + bbox[2] / 2., bbox[1] + bbox[3] / 2.]) if it was to calculate the center point, why wasn't it wrote as (bbox[0] + bbox[2]) / 2. instead? Division comes before addition, right? Am I getting the wrong idea?