yinguobing / head-pose-estimation

Realtime human head pose estimation with ONNXRuntime and OpenCV.
MIT License
1.24k stars 288 forks source link

how can I achieve the head position? #47

Open eugeneYz opened 2 years ago

eugeneYz commented 2 years ago

In other words, is the head pose matrix composed of the translation matrix?

yinguobing commented 2 years ago

Please refer to issue #29

eugeneYz commented 2 years ago

代码中相机内参用的是0 # self.dist_coeefs = np.zeros((4, 1)) 我用标定后的畸变参数是不是会更精准一些 另外,# self.r_vec = np.array([[0.01891013], [0.08560084], [-3.14392813]])

self.t_vec = np.array(

    #     [[-14.97821226], [-10.62040383], [-2053.03596872]]) 

这两个数据的值 是怎么来的, 输出的结果不应该才是这两个吗

yinguobing commented 2 years ago

① 有标定参数的话优先使用标定参数。 ② 该数值是我算出来的经验值,在此基础上迭代不容易出错。

eugeneYz commented 2 years ago

输出的tvec 经验证是tx ty tz,但是rvec不是对应坐标轴的旋转向量 且rvec[ [0.129] [0.039] [-3.26]] 对应的第三索引的值在-3左右波动 这是对应pitch yaw roll的哪个偏转角?

yinguobing commented 2 years ago

时间久远,我记得不太清楚了。旋转矩阵不直接对应pitch yaw roll角度,需要使用之前提到的方法转换为角度。

Please refer to issue #29