brjathu / PHALP

Code repository for the paper "Tracking People by Predicting 3D Appearance, Location & Pose". (CVPR 2022 Oral)
Other
282 stars 43 forks source link

3D Location prediction #10

Closed silence-cho closed 9 months ago

silence-cho commented 2 years ago

https://github.com/brjathu/PHALP/blob/master/PHALP.py#:~:text=y_p_%20%3D%20(y_p%2D0.5)*np.exp(n_p)/5000.0*256.0

Thanks for your great work, I am reading your code and paper. But I am confused about the meaning of 5000 and 256 in the code. May you give more explanation about the location prediction.

markkim1115 commented 1 year ago

I think it is a perspective projection process with focal_length = 5000, image width is 256, np.exp(n_p) is depth value in camera coordinate.

After the line, xp would be a coordinate in image space may be.

brjathu commented 1 year ago

@silence-cho Yes focal length is 5000 and we compute x,y distance in a normalized (256) space. We predict the x, and y in the pixels space and project it back into 3D coordinates in this line (https://github.com/brjathu/PHALP/blob/1d49d1e5173fbf556e77da6d54c1540c505ba2e2/phalp/trackers/PHALP.py#LL500C19-L500C58). Also we have fully updated the code to support better models, please feel free to try, and let us know if you have any questions.

brjathu commented 9 months ago

closing due to inactivity, please reopen if you have any questions.