longcw / crossview_3d_pose_tracking

Dataset of the paper "Cross-View Tracking for Multi-Human 3D Pose Estimation at over 100 FPS"
141 stars 18 forks source link

how to get uxc in formula 3 in your paper #7

Open azuryl opened 4 years ago

azuryl commented 4 years ago

in https://openaccess.thecvf.com/content_CVPR_2020/papers/Chen_Cross-View_Tracking_for_Multi-Human_3D_Pose_Estimation_at_Over_100_CVPR_2020_paper.pdf formula 3 my code is:

P = K[T|R], P+ is pseudo-inverse of P

def pseudo(points_2d, K, Tw): K =np.array(K)

R,T = get_R_T(Tw)
P = K.dot(np.hstack((R,T)))
import scipy.linalg as lin
x= np.hstack((points_2d, np.ones([len(points_2d),1], dtype=points_2d.dtype))) 
Xlist =[]
for xx in x:
   X = np.dot(lin.pinv(P),xx) # realize  P+x(tc) in formula 3

and how to realize uxc in formula 3

thank you

longcw commented 4 years ago

@azuryl Imagine that a 2D point in the image should be back-projected as a ray in 3-space. The 3D ray can be determined using 2 3D points, so we use the pseudo-inverse to get one point, and the other can be the camera location. So Xc is the camera center as mentioned in the paper: https://github.com/longcw/crossview_3d_pose_tracking/blob/master/crossview_dataset/calib/camera.py#L265-L267

azuryl commented 4 years ago

Dear @longcw great! if we get one point from pseudo-inverse and the camera location so we can calculate point-to-line distance in 3-space in formula 4 ? and excuse me Vt ′ is use a linear least-square method or employ the geometric consistency in the affinity measurement for simplicity which Vt= (Xt-Xt' )/(t-t')and t' is the time of the previous frame ?

Thank you